diff
stringlengths
65
26.7k
message
stringlengths
7
9.92k
diff --git a/project_generator/project.py b/project_generator/project.py index <HASH>..<HASH> 100644 --- a/project_generator/project.py +++ b/project_generator/project.py @@ -471,19 +471,23 @@ class Project: def _set_output_dir_path(self, tool, workspace_path): if self.pgen_workspace.settings.generated_projects_dir != self.pgen_workspace.settings.generated_projects_dir_default: + # global settings defined, replace keys pgen is familiar, this overrides anything in the project output_dir = Template(self.pgen_workspace.settings.generated_projects_dir) output_dir = output_dir.substitute(target=self.project['target'], workspace=self._get_workspace_name(), project_name=self.name, tool=tool) else: if self.project['export_dir'] == self.pgen_workspace.settings.generated_projects_dir_default: + # if export_dir is not defined we use tool_name for a project project_name = "%s_%s" % (tool, self.name) else: project_name = "" + # TODO: below works only if we are using default export dir, will blow up with user defined paths if workspace_path: output_dir = os.path.join(self.project['export_dir'], workspace_path, project_name) else: output_dir = os.path.join(self.project['export_dir'], project_name) self.pgen_workspace.settings.generated_projects_dir_default + # After all adjusting , set the output_dir path, which tools will use to export a project self.project['output_dir']['path'] = os.path.normpath(output_dir) @staticmethod
Project - set output dir path - add comments
diff --git a/aws/resource_aws_secretsmanager_secret_policy_test.go b/aws/resource_aws_secretsmanager_secret_policy_test.go index <HASH>..<HASH> 100644 --- a/aws/resource_aws_secretsmanager_secret_policy_test.go +++ b/aws/resource_aws_secretsmanager_secret_policy_test.go @@ -28,7 +28,7 @@ func testSweepSecretsManagerSecretPolicies(region string) error { } conn := client.(*AWSClient).secretsmanagerconn - err = conn.ListSecretsPages(&secretsmanager.ListSecretsInput{}, func(page *secretsmanager.ListSecretsOutput, isLast bool) bool { + err = conn.ListSecretsPages(&secretsmanager.ListSecretsInput{}, func(page *secretsmanager.ListSecretsOutput, lastPage bool) bool { if len(page.SecretList) == 0 { log.Print("[DEBUG] No Secrets Manager Secrets to sweep") return true @@ -51,7 +51,7 @@ func testSweepSecretsManagerSecretPolicies(region string) error { } } - return !isLast + return !lastPage }) if err != nil { if testSweepSkipSweepError(err) {
tests/r/secretsmanager_secret_policy: Use consistent var name
diff --git a/Form/Type/ImmutableArrayType.php b/Form/Type/ImmutableArrayType.php index <HASH>..<HASH> 100644 --- a/Form/Type/ImmutableArrayType.php +++ b/Form/Type/ImmutableArrayType.php @@ -21,9 +21,12 @@ class ImmutableArrayType extends AbstractType public function buildForm(FormBuilder $builder, array $options) { foreach($options['keys'] as $infos) { - list($name, $type, $options) = $infos; - - $builder->add($name, $type, $options); + if ($infos instanceof FormBuilder) { + $builder->add($infos); + } else { + list($name, $type, $options) = $infos; + $builder->add($name, $type, $options); + } } }
mmutableArrayType buildForm with FormBuilder as option
diff --git a/aikif/project.py b/aikif/project.py index <HASH>..<HASH> 100644 --- a/aikif/project.py +++ b/aikif/project.py @@ -80,11 +80,6 @@ class Project(object): res += t.name + '\n' return res - def add_goal(self, goal_id, name, due_date=None, priority=None): - """ - adds a goal for the project - """ - self.goals.append([goal_id, name, due_date, priority]) def add_task(self, task): """ @@ -93,13 +88,6 @@ class Project(object): self.tasks.append(task) - def add_link(self, src_id, dest_id, src_type='Goal', dest_type='Task'): - """ - creates links for the projects, mainly for tasks to goals - but also for folders to projects - """ - self.links.append([src_id, dest_id, src_type, dest_type]) - def add_source(self, name, location, schedule='Daily', op=''): """ handles the data sources used in projects, mainly as an
removed project functions add_link add_goal
diff --git a/neo4jrestclient/query.py b/neo4jrestclient/query.py index <HASH>..<HASH> 100644 --- a/neo4jrestclient/query.py +++ b/neo4jrestclient/query.py @@ -215,7 +215,7 @@ class Q(BaseQ): op_not = self._not.get_query_objects(params=params, version=version) params.update(op_not[1]) - query = u"NOT ( {0} )".format(op_not[0]) + query = u"True = NOT ( {0} )".format(op_not[0]) elif self._or is not None: left_or = self._or[0].get_query_objects(params=params, version=version)
Update NOT check to in query.Q to use True=NOT()
diff --git a/lib/workable/client.rb b/lib/workable/client.rb index <HASH>..<HASH> 100644 --- a/lib/workable/client.rb +++ b/lib/workable/client.rb @@ -57,7 +57,7 @@ module Workable when 404 raise Errors::NotFound, response.body when 503 - raise Errors::RequestToLong, "Response code: #{response.code}" + raise Errors::RequestToLong, response.body when proc { |code| code != 200 } raise Errors::InvalidResponse, "Response code: #{response.code}" end
We know it's <I>, let's return body as message
diff --git a/index.js b/index.js index <HASH>..<HASH> 100644 --- a/index.js +++ b/index.js @@ -35,8 +35,10 @@ module.exports = { var headerConfig = appConfig.contentSecurityPolicy; if (options.liveReload) { - headerConfig['connect-src'] = headerConfig['connect-src'] + ' ws://localhost:' + options.liveReloadPort; - headerConfig['script-src'] = headerConfig['script-src'] + ' localhost:' + options.liveReloadPort; + ['localhost', '0.0.0.0'].forEach(function(host) { + headerConfig['connect-src'] = headerConfig['connect-src'] + ' ws://' + host + ':' + options.liveReloadPort; + headerConfig['script-src'] = headerConfig['script-src'] + ' ' + host + ':' + options.liveReloadPort; + }); } var headerValue = Object.keys(headerConfig).reduce(function(memo, value) {
Allow both <I> and localhost for livereload.
diff --git a/lib/bootstrap.js b/lib/bootstrap.js index <HASH>..<HASH> 100644 --- a/lib/bootstrap.js +++ b/lib/bootstrap.js @@ -38,7 +38,7 @@ module.exports = function(options, db) { }, function(err, file) { if (!file) { - fs.createReadStream(appPath + '/public/lib/bootstrap/dist/css/bootstrap.css').pipe(res); + fs.createReadStream(config.root + '/bower_components/bootstrap/dist/css/bootstrap.css').pipe(res); } else { // streaming to gridfs var readstream = gfs.createReadStream({ @@ -65,7 +65,8 @@ module.exports = function(options, db) { res.send(mean.aggregated.css); }); - app.use('/public', express.static(config.root + '/public')); + app.use('/packages', express.static(config.root + '/packages')); + app.use('/bower_components', express.static(config.root + '/bower_components')); mean.events.on('modulesEnabled', function() {
update path to bower_components
diff --git a/src/SVGImage.php b/src/SVGImage.php index <HASH>..<HASH> 100644 --- a/src/SVGImage.php +++ b/src/SVGImage.php @@ -20,8 +20,8 @@ class SVGImage private $document; /** - * @param int $width The image's width, in pixels. - * @param int $height The image's height, in pixels. + * @param string $width The image's width (any CSS length). + * @param string $height The image's height (any CSS length). * @param string[] $namespaces An optional array of additional namespaces. */ public function __construct($width, $height, array $namespaces = array())
Fix misleading SVGImage constructor doc comment The size does not have to be in pixels, and neither of type int.
diff --git a/kernel/content/ezcontentoperationcollection.php b/kernel/content/ezcontentoperationcollection.php index <HASH>..<HASH> 100644 --- a/kernel/content/ezcontentoperationcollection.php +++ b/kernel/content/ezcontentoperationcollection.php @@ -283,9 +283,9 @@ class eZContentOperationCollection $tmpRes =& eZNodeviewfunctions::generateNodeView( $tpl, $parentNode, $parentNode->attribute( 'object' ), $language, $viewMode, 0, $cacheFileArray['cache_dir'], $cacheFileArray['cache_path'], true ); } } - // Restore the old user as the current one - $user->setCurrentlyLoggedInUser( $user, $user->attribute( 'contentobject_id' ) ); } + // Restore the old user as the current one + $user->setCurrentlyLoggedInUser( $user, $user->attribute( 'contentobject_id' ) ); $GLOBALS['eZCurrentAccess']['name'] = $currentSiteAccess; $res->setDesignSetting( $currentSiteAccess, 'site' );
#- Moved the restoration of the current user (PreGeneration) to outside of # the siteaccess loop. # (Manually merged from stable/<I> (<I>) rev. <I>) git-svn-id: file:///home/patrick.allaert/svn-git/ezp-repo/ezpublish/trunk@<I> a<I>eee8c-daba-<I>-acae-fa<I>f<I>
diff --git a/lib/Model.js b/lib/Model.js index <HASH>..<HASH> 100644 --- a/lib/Model.js +++ b/lib/Model.js @@ -150,7 +150,7 @@ function Model(opts) { if (data.length === 0) { return cb(new Error("Not found")); } - Singleton.get(opts.table + "/" + id, { + Singleton.get(opts.driver.uid + "/" + opts.table + "/" + id, { cache : options.cache, save_check : opts.settings.get("instance.cacheSaveCheck") }, function (cb) { @@ -226,7 +226,7 @@ function Model(opts) { merge : merge, offset : options.offset, newInstance: function (data, cb) { - Singleton.get(opts.table + (merge ? "+" + merge.from.table : "") + "/" + data[opts.id], { + Singleton.get(opts.driver.uid + "/" + opts.table + (merge ? "+" + merge.from.table : "") + "/" + data[opts.id], { cache : options.cache, save_check : opts.settings.get("instance.cacheSaveCheck") }, function (cb) {
Changes singleton uid creation to use driver uid (#<I>)
diff --git a/core/core.go b/core/core.go index <HASH>..<HASH> 100644 --- a/core/core.go +++ b/core/core.go @@ -117,7 +117,7 @@ type Config struct { Vault struct { Address string `yaml:"address" env:"SHIELD_VAULT_ADDRESS"` - CACert string `yaml:"ca" env:"SHIELD_VAULT_CA"` + CACert string `yaml:"ca" env:"SHIELD_VAULT_CA"` } `yaml:"vault"` Mbus struct { @@ -126,11 +126,11 @@ type Config struct { } `yaml:"mbus"` Prometheus struct { - Namespace string `yaml:"namespace"` + Namespace string `yaml:"namespace" env:"SHIELD_PROMETHEUS_NAMESPACE"` - Username string `yaml:"username"` - Password string `yaml:"password"` - Realm string `yaml:"realm"` + Username string `yaml:"username" env:"SHIELD_PROMETHEUS_USERNAME"` + Password string `yaml:"password" env:"SHIELD_PROMETHEUS_PASSWORD"` + Realm string `yaml:"realm" env:"SHIELD_PROMETHEUS_REALM"` } `yaml:"prometheus"` Cipher string `yaml:"cipher" env:"SHIELD_CIPHER"`
More environment configuration in SHIELD core
diff --git a/grade/report/user/externallib.php b/grade/report/user/externallib.php index <HASH>..<HASH> 100644 --- a/grade/report/user/externallib.php +++ b/grade/report/user/externallib.php @@ -115,6 +115,9 @@ class gradereport_user_external extends external_api { require_once($CFG->dirroot . '/grade/lib.php'); require_once($CFG->dirroot . '/grade/report/user/lib.php'); + // Force regrade to update items marked as 'needupdate'. + grade_regrade_final_grades($course->id); + $gpr = new grade_plugin_return( array( 'type' => 'report',
MDL-<I> gradereport_user: Force regrade in external function
diff --git a/semantic_version/base.py b/semantic_version/base.py index <HASH>..<HASH> 100644 --- a/semantic_version/base.py +++ b/semantic_version/base.py @@ -91,13 +91,13 @@ class Version(object): return int(value) def next_major(self): - if self.prerelease and self.minor is 0 and self.patch is 0: + if self.prerelease and self.minor == 0 and self.patch == 0: return Version('.'.join(str(x) for x in [self.major, self.minor, self.patch])) else: return Version('.'.join(str(x) for x in [self.major + 1, 0, 0])) def next_minor(self): - if self.prerelease and self.patch is 0: + if self.prerelease and self.patch == 0: return Version('.'.join(str(x) for x in [self.major, self.minor, self.patch])) else: return Version(
Don't use `is` for integer comparisons. Closes #<I>.
diff --git a/sdjournal/journal.go b/sdjournal/journal.go index <HASH>..<HASH> 100644 --- a/sdjournal/journal.go +++ b/sdjournal/journal.go @@ -736,14 +736,13 @@ func (j *Journal) GetEntry() (*JournalEntry, error) { entry.MonotonicTimestamp = uint64(monotonicUsec) var c *C.char - defer C.free(unsafe.Pointer(c)) - r = C.my_sd_journal_get_cursor(sd_journal_get_cursor, j.cjournal, &c) if r < 0 { return nil, fmt.Errorf("failed to get cursor: %d", syscall.Errno(-r)) } entry.Cursor = C.GoString(c) + C.free(unsafe.Pointer(c)) // Implements the JOURNAL_FOREACH_DATA_RETVAL macro from journal-internal.h var d unsafe.Pointer @@ -842,7 +841,6 @@ func (j *Journal) GetCursor() (string, error) { } var d *C.char - defer C.free(unsafe.Pointer(d)) j.mu.Lock() r := C.my_sd_journal_get_cursor(sd_journal_get_cursor, j.cjournal, &d) @@ -853,6 +851,7 @@ func (j *Journal) GetCursor() (string, error) { } cursor := C.GoString(d) + C.free(unsafe.Pointer(d)) return cursor, nil }
sdjournal: free correct pointer Since defer creates a closure, it ends up freeing the wrong pointer in these situations (i.e. not the one that ends up getting allocated by asprintf during the actual sdjournal call).
diff --git a/server/storage/backend/backend_test.go b/server/storage/backend/backend_test.go index <HASH>..<HASH> 100644 --- a/server/storage/backend/backend_test.go +++ b/server/storage/backend/backend_test.go @@ -32,7 +32,7 @@ func TestBackendClose(t *testing.T) { b, _ := betesting.NewTmpBackend(t, time.Hour, 10000) // check close could work - done := make(chan struct{}) + done := make(chan struct{}, 1) go func() { err := b.Close() if err != nil {
fixing the goroutine leak in TestBackendClose
diff --git a/cli/command/config/remove_test.go b/cli/command/config/remove_test.go index <HASH>..<HASH> 100644 --- a/cli/command/config/remove_test.go +++ b/cli/command/config/remove_test.go @@ -77,6 +77,7 @@ func TestConfigRemoveContinueAfterError(t *testing.T) { cmd := newConfigRemoveCommand(cli) cmd.SetArgs(names) + cmd.SetOutput(ioutil.Discard) assert.EqualError(t, cmd.Execute(), "error removing config: foo") assert.Equal(t, names, removedConfigs) }
fixed the output leak from error test case for config/remove
diff --git a/src/cf/terminal/ui.go b/src/cf/terminal/ui.go index <HASH>..<HASH> 100644 --- a/src/cf/terminal/ui.go +++ b/src/cf/terminal/ui.go @@ -50,8 +50,7 @@ func (c TerminalUI) Ok() { func (c TerminalUI) Failed(message string) { c.Say(FailureColor("FAILED")) c.Say(message) - - return + os.Exit(1) } func (c TerminalUI) FailWithUsage(ctxt *cli.Context, cmdName string) {
exit with status 1 on failure [#<I>]
diff --git a/code/editor/EditableCheckboxGroupField.php b/code/editor/EditableCheckboxGroupField.php index <HASH>..<HASH> 100755 --- a/code/editor/EditableCheckboxGroupField.php +++ b/code/editor/EditableCheckboxGroupField.php @@ -65,7 +65,7 @@ class EditableCheckboxGroupField extends EditableFormField { continue; } - if($data[$option->ID]) { + if(isset($data[$option->ID])) { $option->populateFromPostData( $data[$option->ID] ); }
BUGFIX added isset to [->ID]
diff --git a/lib/components/Redoc/redoc.js b/lib/components/Redoc/redoc.js index <HASH>..<HASH> 100644 --- a/lib/components/Redoc/redoc.js +++ b/lib/components/Redoc/redoc.js @@ -12,8 +12,8 @@ import {ChangeDetectionStrategy} from 'angular2/angular2'; providers: [SchemaManager], templateUrl: './lib/components/Redoc/redoc.html', styleUrls: ['./lib/components/Redoc/redoc.css'], - directives: [ApiInfo, MethodsList, SideMenu] - //changeDetection: ChangeDetectionStrategy.Default + directives: [ApiInfo, MethodsList, SideMenu], + changeDetection: ChangeDetectionStrategy.Default }) export default class Redoc extends BaseComponent { constructor(schemaMgr) {
uncomment changeDetection spec in redoc
diff --git a/core/server/models/base/index.js b/core/server/models/base/index.js index <HASH>..<HASH> 100644 --- a/core/server/models/base/index.js +++ b/core/server/models/base/index.js @@ -118,6 +118,7 @@ ghostBookshelf.Model = ghostBookshelf.Model.extend({ debug(model.tableName, event); if (!options.transacting) { + debug(`event: ${event}`); return common.events.emit(event, model, options); } @@ -137,6 +138,7 @@ ghostBookshelf.Model = ghostBookshelf.Model.extend({ } _.each(this.ghostEvents, (ghostEvent) => { + debug(`event: ${event}`); common.events.emit(ghostEvent, model, _.omit(options, 'transacting')); });
Added base model debug log for events no issue
diff --git a/addon/components/tour-start-button.js b/addon/components/tour-start-button.js index <HASH>..<HASH> 100644 --- a/addon/components/tour-start-button.js +++ b/addon/components/tour-start-button.js @@ -195,9 +195,9 @@ export default Ember.Component.extend({ let tour = get(this, 'tour'); let callout = get(this, 'callout'); let placement = get(this, 'calloutPlacement') || 'top'; - let [target] = this.$().children(); + let target = this.$().children().get(0); - if (tour && callout) { + if (tour && callout && target) { tourManager.addCallout(tour, { calloutMessage: callout, placement,
Do not use array deconstructing on jQuery collection This caused the code to fail on environments where Symbol is not natively available (e.g. IE or phantomjs)
diff --git a/tests/PosPaymentTest.php b/tests/PosPaymentTest.php index <HASH>..<HASH> 100644 --- a/tests/PosPaymentTest.php +++ b/tests/PosPaymentTest.php @@ -62,7 +62,6 @@ class PosPaymentTest extends TestCase $this->validateApiPermission($e); } - print $result; $this->assertTrue(isset($result['SaleToPOIResponse'])); $this->assertEquals('Success', $result['SaleToPOIResponse']['PaymentResponse']['Response']['Result']);
PW-<I>: removed print statement
diff --git a/go/vt/vtadmin/cluster/cluster.go b/go/vt/vtadmin/cluster/cluster.go index <HASH>..<HASH> 100644 --- a/go/vt/vtadmin/cluster/cluster.go +++ b/go/vt/vtadmin/cluster/cluster.go @@ -211,14 +211,20 @@ func New(ctx context.Context, cfg Config) (*Cluster, error) { // to avoid data races in tests (the latter of these is caused by the cache // goroutines). // -// Sub-components of the cluster are `Close`-d concurrently. +// Sub-components of the cluster are `Close`-d concurrently, caches first, then +// proxy connections. func (c *Cluster) Close() error { var ( wg sync.WaitGroup rec concurrency.AllErrorRecorder ) - for _, closer := range []io.Closer{c.DB, c.Vtctld, c.schemaCache} { + // First, close any caches, which may have connections to DB or Vtctld + // (N.B. (andrew) when we have multiple caches, we can close them + // concurrently, like we do with the proxies). + rec.RecordError(c.schemaCache.Close()) + + for _, closer := range []io.Closer{c.DB, c.Vtctld} { wg.Add(1) go func(closer io.Closer) { defer wg.Done()
Fix data race in vtadmin (#<I>) The schema cache has a backfill goroutine running which depends on the clutser's Vtctld, so there's a more subtle `Close` ordering dependency here. It's okay (and good!) to close caches concurrently, and proxy connections concurrently, but never concurrently _with each other_, and always do the caches first.
diff --git a/src/livestreamer/plugins/tvcatchup.py b/src/livestreamer/plugins/tvcatchup.py index <HASH>..<HASH> 100644 --- a/src/livestreamer/plugins/tvcatchup.py +++ b/src/livestreamer/plugins/tvcatchup.py @@ -25,7 +25,7 @@ class TVCatchup(Plugin): stream_url = match.groupdict()["stream_url"] if stream_url: - return {"720p": HLSStream(self.session, stream_url)} + return HLSStream.parse_variant_playlist(self.session, stream_url) __plugin__ = TVCatchup
tvcatchup now returns a variant playlist
diff --git a/client/http_client.go b/client/http_client.go index <HASH>..<HASH> 100644 --- a/client/http_client.go +++ b/client/http_client.go @@ -11,10 +11,10 @@ import ( "os" "path/filepath" "regexp" - "text/template" + "strconv" "strings" + "text/template" "time" - "strconv" ) const NON_VERBOSE = "NON_VERBOSE" @@ -177,7 +177,7 @@ func (slc *HttpClient) makeHttpRequest(url string, requestType string, requestBo SL_API_RETRY_COUNT = 5 } - for i:=1; i<=SL_API_RETRY_COUNT; i++ { + for i := 1; i <= SL_API_RETRY_COUNT; i++ { resp, err = slc.HTTPClient.Do(req) if err != nil { if !strings.Contains(err.Error(), "i/o timeout") || i > SL_API_RETRY_COUNT { @@ -189,7 +189,7 @@ func (slc *HttpClient) makeHttpRequest(url string, requestType string, requestBo break } - time.Sleep(SL_API_WAIT_TIME * time.Second) + time.Sleep(time.Duration(SL_API_WAIT_TIME) * time.Second) } defer resp.Body.Close()
Need to cast to time.Duration
diff --git a/xmantissa/tdb.py b/xmantissa/tdb.py index <HASH>..<HASH> 100644 --- a/xmantissa/tdb.py +++ b/xmantissa/tdb.py @@ -142,6 +142,7 @@ class TabularDataModel: # hasNextPage and hasPrevPage methosd. We gracefully handle it # anyway simply because we expect multiple frontends for this # model, and multiple frontends means lots of places for bugs. + self.totalItems = self.totalPages = 0 return self._currentResults = results self._paginate()
ensure "totalItems" and "totalPages" are always attributes of the TDM, even if their values are 0.
diff --git a/index.js b/index.js index <HASH>..<HASH> 100644 --- a/index.js +++ b/index.js @@ -371,7 +371,7 @@ wjs.prototype.addPlayer = function(wcpSettings) { } else vlcs[wjsPlayer.context].hideUI = setTimeout(function(i) { return function() { hideUI.call(players[i]); } }(wjsPlayer.context),3000); } } - } + } else wjsPlayer.wrapper.css({cursor: 'default'}); }); /* Progress and Volume Bars */
Fixed mouse cursor on UI hidden
diff --git a/.tools/validate.go b/.tools/validate.go index <HASH>..<HASH> 100644 --- a/.tools/validate.go +++ b/.tools/validate.go @@ -210,7 +210,7 @@ func GitCommits(commitrange string) ([]CommitEntry, error) { // GitFetchHeadCommit returns the hash of FETCH_HEAD func GitFetchHeadCommit() (string, error) { - output, err := exec.Command("git", "rev-parse", "--verify", "HEAD").Output() + output, err := exec.Command("git", "rev-parse", "--verify", "FETCH_HEAD").Output() if err != nil { return "", err }
.tools: make GetFetchHeadCommit do what it says
diff --git a/sidebar-templates/sidebar-herocanvas.php b/sidebar-templates/sidebar-herocanvas.php index <HASH>..<HASH> 100644 --- a/sidebar-templates/sidebar-herocanvas.php +++ b/sidebar-templates/sidebar-herocanvas.php @@ -16,4 +16,4 @@ if ( ! defined( 'ABSPATH' ) ) { <?php dynamic_sidebar( 'herocanvas' ); ?> -<?php endif; ?> \ No newline at end of file +<?php endif; ?>
Fix missing new line at end of file
diff --git a/TYPO3.Fluid/Classes/ViewHelpers/Form/UploadViewHelper.php b/TYPO3.Fluid/Classes/ViewHelpers/Form/UploadViewHelper.php index <HASH>..<HASH> 100644 --- a/TYPO3.Fluid/Classes/ViewHelpers/Form/UploadViewHelper.php +++ b/TYPO3.Fluid/Classes/ViewHelpers/Form/UploadViewHelper.php @@ -16,21 +16,22 @@ namespace F3\Fluid\ViewHelpers\Form; * */ /** - * @package - * @subpackage + * @package + * @subpackage * @version $Id:$ */ /** * Enter description here... * @scope prototype */ -class UploadViewHelper extends \F3\Fluid\Core\AbstractViewHelper { - +class UploadViewHelper extends \F3\Fluid\ViewHelpers\Form\AbstractFormViewHelper { + public function initializeArguments() { - $this->registerArgument('name', 'string', 'Name of the upload form', TRUE); + parent::initializeArguments(); + $this->registerUniversalTagAttributes(); } public function render() { - return '<input type="file" name="' . $this->arguments['name'] . '" />'; + return '<input type="file" name="' . $this->getName() . '" ' . $this->renderTagAttributes() . ' />'; } }
Small addition to the upload view helper Original-Commit-Hash: <I>b<I>fd<I>b3f4f<I>a<I>bc
diff --git a/lib/table.js b/lib/table.js index <HASH>..<HASH> 100644 --- a/lib/table.js +++ b/lib/table.js @@ -44,7 +44,8 @@ Table.prototype.getName = function() { } Table.prototype.star = function() { - return new TextNode('"'+this._name+'".*'); + var name = this.alias || this._name; + return new TextNode('"'+name+'".*'); } Table.prototype.select = function() { diff --git a/test/postgres/namespace-tests.js b/test/postgres/namespace-tests.js index <HASH>..<HASH> 100644 --- a/test/postgres/namespace-tests.js +++ b/test/postgres/namespace-tests.js @@ -9,6 +9,11 @@ Harness.test({ pg :'SELECT u."name" FROM "user" AS u' }); +Harness.test({ + query : u.select(u.star()).from(u), + pg : 'SELECT "u".* FROM "user" AS u' +}); + var p = post.as('p'); Harness.test({ query : u.select(u.name).from(u.join(p).on(u.id.equals(p.userId).and(p.id.equals(3)))),
table alias were not applying to star queries
diff --git a/src/Http/StringHttpAdapter.php b/src/Http/StringHttpAdapter.php index <HASH>..<HASH> 100644 --- a/src/Http/StringHttpAdapter.php +++ b/src/Http/StringHttpAdapter.php @@ -7,7 +7,6 @@ use Aidantwoods\SecureHeaders\HeaderBag; class StringHttpAdapter implements HttpAdapter { private $headers = []; - private $initialHeaders; /** * Create a HttpAdapter for output as a string, with initial headers @@ -20,7 +19,7 @@ class StringHttpAdapter implements HttpAdapter */ public function __construct(array $initialHeaders = []) { - $this->initialHeaders = $initialHeaders; + $this->headers = $initialHeaders; } /** @@ -45,11 +44,13 @@ class StringHttpAdapter implements HttpAdapter */ public function getHeaders() { - return HeaderBag::fromHeaderLines($this->initialHeaders); + return HeaderBag::fromHeaderLines($this->headers); } /** * @api + * + * @return string */ public function getSentHeaders() {
bugfix: ensure only one list of headers in StringAdapter
diff --git a/classes/Gems/Util/DatabasePatcher.php b/classes/Gems/Util/DatabasePatcher.php index <HASH>..<HASH> 100644 --- a/classes/Gems/Util/DatabasePatcher.php +++ b/classes/Gems/Util/DatabasePatcher.php @@ -64,7 +64,17 @@ class Gems_Util_DatabasePatcher $this->patch_files[] = $file; } elseif ($paths) { - foreach ($paths as $location => $path) { + foreach ($paths as $path => $pathData) { + if (is_array($pathData)) { + $location = $pathData['name']; + + } elseif ($pathData instanceof Zend_Db_Adapter_Abstract) { + $config = $pathData->getConfig(); + $location = $config['dbname']; + + } else { + $location = $pathData; + } if (file_exists($path . '/' . $file)) { $this->patch_files[] = $path . '/' . $file;
Adapted patcher to new database path strings
diff --git a/test/test_helper.rb b/test/test_helper.rb index <HASH>..<HASH> 100644 --- a/test/test_helper.rb +++ b/test/test_helper.rb @@ -27,4 +27,5 @@ CREATE SCHEMA "Bar"; CREATE TABLE "Bar"."Foo"("Id" int); INSERT INTO "Bar"."Foo" SELECT * FROM generate_series(1, 100000); +ANALYZE "Bar"."Foo"; SQL
Analyze before tests [skip ci]
diff --git a/gns3server/handlers/api/controller/server_handler.py b/gns3server/handlers/api/controller/server_handler.py index <HASH>..<HASH> 100644 --- a/gns3server/handlers/api/controller/server_handler.py +++ b/gns3server/handlers/api/controller/server_handler.py @@ -169,7 +169,7 @@ class ServerHandler: data = r.body.decode("utf-8") except Exception as e: data = str(e) - with open(os.path.join(debug_dir, "compute_{}.txt".format(compute.name)), "w+") as f: + with open(os.path.join(debug_dir, "compute_{}.txt".format(compute.id)), "w+") as f: f.write("Compute ID: {}\n".format(compute.id)) f.write(data)
Fix bug when exporting debug information with multiple remote servers Fix #<I>
diff --git a/salt/master.py b/salt/master.py index <HASH>..<HASH> 100644 --- a/salt/master.py +++ b/salt/master.py @@ -1805,9 +1805,9 @@ class ClearFuncs(object): 'user': token['name']} try: self.event.fire_event(data, tagify([jid, 'new'], 'wheel')) - ret = self.wheel_.call_func(fun, **clear_load) - data['return'] = ret - data['success'] = True + ret = self.wheel_.call_func(fun, full_return=True, **clear_load) + data['return'] = ret['return'] + data['success'] = ret['success'] self.event.fire_event(data, tagify([jid, 'ret'], 'wheel')) return {'tag': tag, 'data': data}
Fix 'success' value for wheel commands The ClearFuncs was assuming a 'success' of True <I>% of the time for wheel functions. This causes wheel funcs executed via salt-api (and probably elsewhere) to incorrectly report the 'success' field when the wheel function triggers a traceback (such as when required positional arguments are not passed). Resolves #<I>
diff --git a/Documentation/conf.py b/Documentation/conf.py index <HASH>..<HASH> 100644 --- a/Documentation/conf.py +++ b/Documentation/conf.py @@ -130,6 +130,7 @@ extlinks = { 'jenkins-branch': (jenkins_branch + "/%s", ''), 'github-project': (project_link + '%s', ''), 'github-backport': (backport_format, ''), + 'gh-issue': (github_repo + 'issues/%s', 'GitHub issue '), } # The language for content autogenerated by Sphinx. Refer to documentation
docs: conf.py: add :gh-issue: role to reference GitHub issues Use the extlink Sphinx extension to add a role for referencing GitHub issues in a uniform fashion. Writing :gh-issue:`<I>` will automatically convert into "GitHub issue <I>", with a link to the relevant issue.
diff --git a/provision/kubernetes/helpers.go b/provision/kubernetes/helpers.go index <HASH>..<HASH> 100644 --- a/provision/kubernetes/helpers.go +++ b/provision/kubernetes/helpers.go @@ -1084,6 +1084,7 @@ func runPod(ctx context.Context, args runSinglePodArgs) error { if err != nil { return err } + enableServiceLinks := false pod := &apiv1.Pod{ ObjectMeta: metav1.ObjectMeta{ Name: args.name, @@ -1091,6 +1092,7 @@ func runPod(ctx context.Context, args runSinglePodArgs) error { Labels: args.labels.ToLabels(), }, Spec: apiv1.PodSpec{ + EnableServiceLinks: &enableServiceLinks, ImagePullSecrets: pullSecrets, ServiceAccountName: serviceAccountNameForApp(args.app), NodeSelector: nodeSelector,
Disable serviceLinks for isolated run
diff --git a/src/CleanFormatter.php b/src/CleanFormatter.php index <HASH>..<HASH> 100644 --- a/src/CleanFormatter.php +++ b/src/CleanFormatter.php @@ -104,7 +104,7 @@ final class CleanFormatter implements Formatter $types = implode('|', $types); - [$oldTypes, $nameAndDescription] = explode(' ', (string) $tag); + [$oldTypes, $nameAndDescription] = explode(' ', (string) $tag, 2); return trim($types . ' ' . $nameAndDescription); }
fix CleanFormatter removing description
diff --git a/test/fragmentation-test-server.js b/test/fragmentation-test-server.js index <HASH>..<HASH> 100755 --- a/test/fragmentation-test-server.js +++ b/test/fragmentation-test-server.js @@ -130,7 +130,7 @@ router.mount('*', 'fragmentation-test', function(request) { } }); - connection.on('close', function(connection) { + connection.on('close', function(reasonCode, description) { console.log((new Date()) + " peer " + connection.remoteAddress + " disconnected."); });
Fixing fragmentation-test-server to accept the correct parameters for the 'close' event.
diff --git a/packages/neos-ui/src/Containers/LeftSideBar/PageTree/Node/index.js b/packages/neos-ui/src/Containers/LeftSideBar/PageTree/Node/index.js index <HASH>..<HASH> 100644 --- a/packages/neos-ui/src/Containers/LeftSideBar/PageTree/Node/index.js +++ b/packages/neos-ui/src/Containers/LeftSideBar/PageTree/Node/index.js @@ -30,7 +30,7 @@ export default class Node extends PureComponent { uri: PropTypes.string.isRequired, children: PropTypes.arrayOf( PropTypes.string - ), + ) }), getTreeNode: PropTypes.func, onNodeToggle: PropTypes.func,
BUGFIX: Remove trailing comma to satisfy linter
diff --git a/src/watoki/curir/composition/PostProcessor.php b/src/watoki/curir/composition/PostProcessor.php index <HASH>..<HASH> 100644 --- a/src/watoki/curir/composition/PostProcessor.php +++ b/src/watoki/curir/composition/PostProcessor.php @@ -37,8 +37,6 @@ class PostProcessor { 'button' => 'name' ); - const HEADER_HTML_HEAD = 'x-html-head'; - /** * @var Map */ @@ -94,14 +92,7 @@ class PostProcessor { */ private function postProcessHtml(Response $response, $html) { $printer = new Printer(); - $response->setBody($printer->printNodes($this->extractBody($html)->getChildren())); - - $elements = array(); - foreach ($this->headElements as $element) { - $elements[] = $printer->printNode($element); - } - $response->getHeaders()->set(self::HEADER_HTML_HEAD, implode("", $elements)); } /**
Removed html head from http header
diff --git a/Tests/Acceptance/Support/Extension/BackendStyleguideEnvironment.php b/Tests/Acceptance/Support/Extension/BackendStyleguideEnvironment.php index <HASH>..<HASH> 100644 --- a/Tests/Acceptance/Support/Extension/BackendStyleguideEnvironment.php +++ b/Tests/Acceptance/Support/Extension/BackendStyleguideEnvironment.php @@ -34,7 +34,6 @@ class BackendStyleguideEnvironment extends BackendEnvironment 'extbase', 'fluid', 'backend', - 'about', 'install', 'frontend', 'recordlist',
[BUGFIX] AC tests don't reference ext:about anymore
diff --git a/test/campaign.test.js b/test/campaign.test.js index <HASH>..<HASH> 100644 --- a/test/campaign.test.js +++ b/test/campaign.test.js @@ -249,10 +249,10 @@ describe('@campaign-contactlists', function() { } Rhizome.Contactlist .create({ - campaign: _campaign.id, + campaignId: _campaign.id, name: 'test list', - companies: _campaign.companies, - user: _user.id + companyIds: _campaign.companies, + userId: _user.id }) .then(function(contactList) { contactList.name.should.equal('test list');
- CHANGED: harmonise the naming conventions
diff --git a/openquake/engine/calculators/hazard/scenario/core.py b/openquake/engine/calculators/hazard/scenario/core.py index <HASH>..<HASH> 100644 --- a/openquake/engine/calculators/hazard/scenario/core.py +++ b/openquake/engine/calculators/hazard/scenario/core.py @@ -173,7 +173,7 @@ class ScenarioHazardCalculator(haz_general.BaseHazardCalculator): models.OqJob.objects.get(pk=self.job.id)) gsim = valid.gsim(oqparam.gsim) self.computer = GmfComputer( - self.rupture, self.site_collection, self.imts, gsim, + self.rupture, self.site_collection, self.imts, [gsim], trunc_level, correlation_model) @EnginePerformanceMonitor.monitor
Fixed the scenario calculator Former-commit-id: e2c0ca1af<I>d<I>fe<I>b2cf<I>fb<I>c
diff --git a/text/atlas.go b/text/atlas.go index <HASH>..<HASH> 100644 --- a/text/atlas.go +++ b/text/atlas.go @@ -30,6 +30,8 @@ type Atlas struct { // NewAtlas creates a new Atlas containing glyphs of the given set of runes from the given font // face. +// +// Do not destroy or close the font.Face after creating the Atlas. func NewAtlas(face font.Face, runes []rune) *Atlas { fixedMapping, fixedBounds := makeSquareMapping(face, runes, fixed.I(2))
add note about not destroying face.Face to Atlas doc
diff --git a/meme.py b/meme.py index <HASH>..<HASH> 100755 --- a/meme.py +++ b/meme.py @@ -13,6 +13,8 @@ GENERATORS = { 'BUTTHURT_DWELLER' : ('AdviceDogSpinoff' , 1438 , 'Butthurt-Dweller' , ) , 'B_FROG' : ('AdviceDogSpinoff' , 1211 , 'Foul-Bachelorette-Frog' , ) , 'B_FROG2' : ('AdviceDogSpinoff' , 1045 , 'Foul-Bachelor-Frog' , ) , + 'BILL_PROVES_GOD' : ('AdviceDogSpinoff' , 435227 , 'Bill-Oreilly-Proves-God' , ) , + 'BILL_PROVES_GOD_2' : ('AdviceDogSpinoff' , 445648 , 'Bill-Oreilly-Proves-God' , ) , 'BUSICAT' : ('AdviceDogSpinoff' , 330000 , 'BusinessCat' , ) , 'COOL_STORY_HOUSE' : ('AdviceDogSpinoff' , 16948 , 'cool-story-bro-house' , ) , 'CREEPER' : ('AdviceDogSpinoff' , 173501 , 'Minecraft-Creeper' , ) ,
added bill oreilly, you can't explain that
diff --git a/admin/langimport.php b/admin/langimport.php index <HASH>..<HASH> 100755 --- a/admin/langimport.php +++ b/admin/langimport.php @@ -331,7 +331,7 @@ /** * Returns a list of available language packs from a * local copy shipped with standard moodle distro - * this is for site that can't perform fopen + * this is for site that can't download components. * @return array */ function get_local_list_of_languages() {
MDL-<I>, MDL-<I> - fixed inline docs; merged from MOODLE_<I>_STABLE
diff --git a/gitreceived.go b/gitreceived.go index <HASH>..<HASH> 100644 --- a/gitreceived.go +++ b/gitreceived.go @@ -40,7 +40,7 @@ var privateKey string func init() { flag.Usage = func() { - fmt.Fprintf(os.Stderr, "Usage: %v [options] <authchecker> <receiver>\n\n", os.Args[0]) + fmt.Fprintf(os.Stderr, "Usage: %v [options] <privatekey> <authchecker> <receiver>\n\n", os.Args[0]) flag.PrintDefaults() } }
gitreceived: Fix usage Closes #<I>
diff --git a/tests/test_settings.py b/tests/test_settings.py index <HASH>..<HASH> 100644 --- a/tests/test_settings.py +++ b/tests/test_settings.py @@ -42,12 +42,6 @@ class TestProject(TestCase): def test_update(self): self.settings.update(settings_dict) - assert self.settings.get_env_settings('definitions') == settings_dict['definitions_dir'][0] assert self.settings.get_env_settings('iar') == settings_dict['tools']['iar']['path'][0] assert self.settings.get_env_settings('uvision') == settings_dict['tools']['uvision']['path'][0] assert self.settings.export_location_format == settings_dict['export_dir'][0] - - def test_definition(self): - self.settings.update(settings_dict) - self.settings.update_definitions_dir('new_path') - assert self.settings.get_env_settings('definitions') == 'new_path'
Tests - path definitions removal
diff --git a/lib/tomlrb/scanner.rb b/lib/tomlrb/scanner.rb index <HASH>..<HASH> 100644 --- a/lib/tomlrb/scanner.rb +++ b/lib/tomlrb/scanner.rb @@ -29,7 +29,7 @@ module Tomlrb @eos = false end - def next_token + def next_token # rubocop:disable Metrics/MethodLength case when @ss.eos? then process_eos when @ss.scan(SPACE) then next_token
Allow many lines to Scanner#next_token
diff --git a/src/medpy/itkvtk/application/gradient.py b/src/medpy/itkvtk/application/gradient.py index <HASH>..<HASH> 100755 --- a/src/medpy/itkvtk/application/gradient.py +++ b/src/medpy/itkvtk/application/gradient.py @@ -14,11 +14,13 @@ import logging from medpy.io import load, save, header from medpy.core import Logger from medpy.itkvtk import filter +import os +from medpy.core.exceptions import ArgumentError # information __author__ = "Oskar Maier" -__version__ = "r0.4.0, 2011-12-12" +__version__ = "r0.4.1, 2011-12-12" __email__ = "oskar.maier@googlemail.com" __status__ = "Release" __description__ = """ @@ -39,6 +41,11 @@ def main(): if args.debug: logger.setLevel(logging.DEBUG) elif args.verbose: logger.setLevel(logging.INFO) + # check if output image exists (will also be performed before saving, but as the gradient might be time intensity, a initial check can save frustration) + if not args.force: + if os.path.exists(args.output): + raise ArgumentError('The output image {} already exists.'.format(args.output)) + # loading image data_input, header_input = load(args.input)
Minor change: A possible existance of the output file is now checked beforehand to save frustration.
diff --git a/dipper/sources/FlyBase.py b/dipper/sources/FlyBase.py index <HASH>..<HASH> 100644 --- a/dipper/sources/FlyBase.py +++ b/dipper/sources/FlyBase.py @@ -64,7 +64,7 @@ class FlyBase(PostgreSQLSource): # itself (watch out for is_not) ] - #columns = { WIP + # columns = { WIP #'genotype': ( #feature_genotype_id, feature_id, genotype_id, chromosome_id, rank, #cgroup, cvterm_id), @@ -124,6 +124,8 @@ class FlyBase(PostgreSQLSource): # the indexes and mature relational engine to the the # work on someone elses machine. # we can call it "in the cloud" + # from Lilly: http://gmod.org/wiki/FlyBase_Field_Mapping_Tables + 'feature_dbxref_WIP': """ -- 17M rows in ~2 minutes SELECT feature.name feature_name, feature.uniquename feature_id,
fly bits cimments and prep
diff --git a/src/ui/InputPopover.js b/src/ui/InputPopover.js index <HASH>..<HASH> 100644 --- a/src/ui/InputPopover.js +++ b/src/ui/InputPopover.js @@ -48,7 +48,7 @@ export default class InputPopover extends Component { } componentDidMount() { - document.addEventListener('click', this._onDocumentClick); + document.addEventListener('click', this._onDocumentClick, true); document.addEventListener('keydown', this._onDocumentKeydown); if (this._inputRef) { this._inputRef.focus(); @@ -56,7 +56,7 @@ export default class InputPopover extends Component { } componentWillUnmount() { - document.removeEventListener('click', this._onDocumentClick); + document.removeEventListener('click', this._onDocumentClick, true); document.removeEventListener('keydown', this._onDocumentKeydown); }
Fix Link and Image popover button not working in React <I> (#<I>)
diff --git a/www/src/pages/components/overlays.js b/www/src/pages/components/overlays.js index <HASH>..<HASH> 100644 --- a/www/src/pages/components/overlays.js +++ b/www/src/pages/components/overlays.js @@ -74,7 +74,7 @@ export default withLayout(function TooltipSection({ data }) { Overlay </LinkedHeading> <p> - <code>Overlay</code> is the fundemental component for positioning and + <code>Overlay</code> is the fundamental component for positioning and controlling tooltip visibility. It's a wrapper around react-popper, that adds support for transitions, and visibility toggling. </p>
Fixed spelling in documentation (#<I>)
diff --git a/src/main/java/com/relayrides/pushy/apns/util/ApnsPayloadBuilder.java b/src/main/java/com/relayrides/pushy/apns/util/ApnsPayloadBuilder.java index <HASH>..<HASH> 100644 --- a/src/main/java/com/relayrides/pushy/apns/util/ApnsPayloadBuilder.java +++ b/src/main/java/com/relayrides/pushy/apns/util/ApnsPayloadBuilder.java @@ -46,12 +46,14 @@ public class ApnsPayloadBuilder { private String localizedActionButtonKey = null; private Integer badgeNumber = null; private String soundFileName = null; - + private boolean contentAvailable = false; + private static final String APS_KEY = "aps"; private static final String ALERT_KEY = "alert"; private static final String BADGE_KEY = "badge"; private static final String SOUND_KEY = "sound"; - + private static final String CONTENT_AVAILABLE_KEY = "content-available"; + private static final String ALERT_BODY_KEY = "body"; private static final String ACTION_LOC_KEY = "action-loc-key"; private static final String ALERT_LOC_KEY = "loc-key";
Patch fail. Added a couple lines that were accidentally dropped from <I>cab<I>.
diff --git a/pyaxiom/netcdf/sensors/timeseries.py b/pyaxiom/netcdf/sensors/timeseries.py index <HASH>..<HASH> 100644 --- a/pyaxiom/netcdf/sensors/timeseries.py +++ b/pyaxiom/netcdf/sensors/timeseries.py @@ -520,7 +520,6 @@ class TimeSeries(object): @property def ncd(self): - warnings.warn('This property is deprecated in favor of `dataset`', DeprecationWarning) return self._nc def __del__(self):
Don't warn about using the .ncd method (#3)
diff --git a/naima/radiative.py b/naima/radiative.py index <HASH>..<HASH> 100644 --- a/naima/radiative.py +++ b/naima/radiative.py @@ -93,6 +93,8 @@ class BaseRadiative(object): else: out_unit = 'erg/s' + photon_energy = _validate_ene(photon_energy) + sed = (self.flux(photon_energy,distance) * photon_energy ** 2.).to(out_unit) return sed
fix radiative sed when calling with dict or table
diff --git a/setup.py b/setup.py index <HASH>..<HASH> 100644 --- a/setup.py +++ b/setup.py @@ -84,7 +84,7 @@ setup_kwargs = dict( ) setup_kwargs['install_requires'] = [ - 'tornado', 'trollius', 'lxml', 'chardet', 'sqlalchemy', + 'tornado', 'trollius', 'chardet', 'sqlalchemy', 'namedlist', 'html5lib', ]
setup.py: Drop lxml as hard requirement
diff --git a/mod/hotpot/db/update_to_v2.php b/mod/hotpot/db/update_to_v2.php index <HASH>..<HASH> 100644 --- a/mod/hotpot/db/update_to_v2.php +++ b/mod/hotpot/db/update_to_v2.php @@ -7,7 +7,7 @@ function hotpot_update_to_v2_1_16() { $length = 20; $field = 'name'; $table = 'hotpot_questions'; - $index = '{$table}_{$name}_idx'; + $index = "{$table}_{$name}_idx"; // remove the index hotpot_db_delete_index("{$CFG->prefix}$table", $index);
change single quotes to double quotes. Probable fix for bug <I>
diff --git a/tests/integration/mixins/track-relationships-test.js b/tests/integration/mixins/track-relationships-test.js index <HASH>..<HASH> 100644 --- a/tests/integration/mixins/track-relationships-test.js +++ b/tests/integration/mixins/track-relationships-test.js @@ -1,4 +1,5 @@ import Model, { hasMany, belongsTo, attr } from '@ember-data/model'; +import JSONAPISerializer from '@ember-data/serializer/json-api'; import { run } from '@ember/runloop'; import { resolve, all } from 'rsvp'; import { module, test } from 'qunit'; @@ -12,6 +13,7 @@ module('Integration | Mixin | track relationships', function(hooks) { setupRenderingTest(hooks); hooks.beforeEach(function() { + this.owner.register('serializer:application', JSONAPISerializer); this.owner.register('model:post', Model.extend(TrackRelationships, { title: attr('string'), comments: hasMany(),
Add default serializer with deprecation and removal of fallback serializer
diff --git a/lxd/instance/operationlock/operationlock.go b/lxd/instance/operationlock/operationlock.go index <HASH>..<HASH> 100644 --- a/lxd/instance/operationlock/operationlock.go +++ b/lxd/instance/operationlock/operationlock.go @@ -57,6 +57,8 @@ func Create(instanceID int, action string, reusable bool, reuse bool) (*Instance go func(op *InstanceOperation) { for { select { + case <-op.chanDone: + return case <-op.chanReset: continue case <-time.After(time.Second * 30):
lxd/instance/operationlock: Exit go routine started in Create when the operation is done Otherwise I have observed that go routines can hang around for up to <I>s after operation is completed.
diff --git a/src/sentry_plugins/splunk/plugin.py b/src/sentry_plugins/splunk/plugin.py index <HASH>..<HASH> 100644 --- a/src/sentry_plugins/splunk/plugin.py +++ b/src/sentry_plugins/splunk/plugin.py @@ -180,6 +180,7 @@ class SplunkPlugin(CorePluginMixin, Plugin): headers={ 'Authorization': 'Splunk {}'.format(token) }, + timeout=5, ).raise_for_status() except Exception: metrics.incr('integrations.splunk.forward-event.error', tags={
ref(splunk): Lower timeout to 5s
diff --git a/index.js b/index.js index <HASH>..<HASH> 100644 --- a/index.js +++ b/index.js @@ -182,7 +182,8 @@ class mochaPlugin { // Verify that the service runtime matches with the current runtime let { runtime } = inited.provider; // Fix the real version for node10 - runtime = runtime.replace('.x', ''); + if (runtime) + runtime = runtime.replace('.x', ''); let nodeVersion; if (typeof process.versions === 'object') {
Check runtime var To avoid "Cannot read property 'replace' of undefined" error if provider dont have Node version.
diff --git a/tests/test_basic.py b/tests/test_basic.py index <HASH>..<HASH> 100644 --- a/tests/test_basic.py +++ b/tests/test_basic.py @@ -108,6 +108,13 @@ class TestBasic(unittest.TestCase): class NoMoreDocOrder(WithDocOrder): _doc_order = None + assert properties.Property('').equal(5, 5) + assert not properties.Property('').equal(5, 'hi') + assert properties.Property('').equal(np.array([1., 2.]), + np.array([1., 2.])) + assert not properties.Property('').equal(np.array([1., 2.]), + np.array([3., 4.])) + def test_bool(self): class BoolOpts(properties.HasProperties):
Add properties.Property.equal tests which fail
diff --git a/lib/runners/to-result.js b/lib/runners/to-result.js index <HASH>..<HASH> 100644 --- a/lib/runners/to-result.js +++ b/lib/runners/to-result.js @@ -2,9 +2,10 @@ var log = require('npmlog'); -module.exports = function toResult(launcherId, err, code, runnerProcess, config, testContext = {}) { +module.exports = function toResult(launcherId, err, code, runnerProcess, config, testContext) { var logs = []; var message = ''; + testContext = testContext ? testContext : {}; if (err) { logs.push({
Make toResult compatiable with node4
diff --git a/src/pt-BR/validation.php b/src/pt-BR/validation.php index <HASH>..<HASH> 100644 --- a/src/pt-BR/validation.php +++ b/src/pt-BR/validation.php @@ -121,7 +121,7 @@ return [ 'city' => 'cidade', 'country' => 'país', 'date' => 'data', - 'day' => 'día', + 'day' => 'dia', 'description' => 'descrição', 'excerpt' => 'resumo', 'first_name' => 'primeiro nome',
Update pt-br validation.php Minor type in the translation of the "day" word.
diff --git a/js/feature/featureFileReader.js b/js/feature/featureFileReader.js index <HASH>..<HASH> 100644 --- a/js/feature/featureFileReader.js +++ b/js/feature/featureFileReader.js @@ -156,17 +156,15 @@ var igv = (function (igv) { }; igv.FeatureFileReader.prototype.isIndexable = function () { + var hasIndexURL, + isValidType, + isIndexed; - var hasIndexURL = (undefined !== this.config.indexURL), - isValidType = (this.format !== 'wig' && this.format !== 'seg'); + hasIndexURL = (undefined !== this.config.indexURL); + isValidType = (this.format !== 'wig' && this.format !== 'seg'); + isIndexed = (false !== this.config.indexed); - // Local files are currently not indexable - if (this.config.isLocalFile) { - return false; - } - else { - return this.config.indexed != false && (hasIndexURL || isValidType); - } + return isIndexed && (hasIndexURL || isValidType); }; /**
track - config.localFile param removed.
diff --git a/test/cluster/cluster-registry-clusterSpec.js b/test/cluster/cluster-registry-clusterSpec.js index <HASH>..<HASH> 100644 --- a/test/cluster/cluster-registry-clusterSpec.js +++ b/test/cluster/cluster-registry-clusterSpec.js @@ -9,7 +9,7 @@ const connectionEndpointMock = { getConnectionCount() { return 8 } } -describe('distributed-state-registry adds and removes names', () => { +xdescribe('distributed-state-registry adds and removes names', () => { const createClusterRegistry = function (serverName, externalUrl) { const options = { serverName, diff --git a/test/cluster/cluster-registrySpec.js b/test/cluster/cluster-registrySpec.js index <HASH>..<HASH> 100644 --- a/test/cluster/cluster-registrySpec.js +++ b/test/cluster/cluster-registrySpec.js @@ -12,7 +12,7 @@ const EventEmitter = require('events').EventEmitter let realProcess let emitter -describe('cluster registry adds and removes names', () => { +xdescribe('cluster registry adds and removes names', () => { let clusterRegistry const addSpy = jasmine.createSpy('add')
test: disabling cluster registry tests
diff --git a/src/main/java/org/minimalj/application/Configuration.java b/src/main/java/org/minimalj/application/Configuration.java index <HASH>..<HASH> 100644 --- a/src/main/java/org/minimalj/application/Configuration.java +++ b/src/main/java/org/minimalj/application/Configuration.java @@ -70,12 +70,19 @@ public class Configuration { if (parameters == null) { return configuredClass.newInstance(); } else { - Class<?>[] parameterTypes = new Class[parameters.length]; - for (int i = 0; i<parameters.length; i++) { - parameterTypes[i] = parameters[i].getClass(); + CONSTRUCTOR: for (Constructor<?> constructor : configuredClass.getConstructors()) { + if (constructor.getParameterCount() != parameters.length) { + continue; + } + int i = 0; + for (i = 0; i<constructor.getParameterCount(); i++) { + if (!constructor.getParameterTypes()[i].isAssignableFrom(parameters[i].getClass())) { + continue CONSTRUCTOR; + } + } + return (T) constructor.newInstance(parameters); } - Constructor<? extends T> constructor = configuredClass.getConstructor(parameterTypes); - return constructor.newInstance(parameters); + throw new NoSuchMethodException(); } } catch (ClassNotFoundException e) { throw new LoggingRuntimeException(e, logger, className + " not found / " + key + " configuration failed");
Configuration: java doesn't provide getContructor with specific classes
diff --git a/app/models/user.rb b/app/models/user.rb index <HASH>..<HASH> 100644 --- a/app/models/user.rb +++ b/app/models/user.rb @@ -2,7 +2,9 @@ class User < ActiveRecord::Base has_secure_password + # associations connected to tkh_content gem. Any page or comment model will do has_many :pages + has_many :comments, :dependent => :destroy # not allowed are :admin:boolean, :auth_token:string, password_reset_token:string, password_reset_sent_at:datetime attr_accessible :email, :password, :password_confirmation, :first_name, :last_name
Added has_many comments association.
diff --git a/tests/Models/EntryTest.php b/tests/Models/EntryTest.php index <HASH>..<HASH> 100644 --- a/tests/Models/EntryTest.php +++ b/tests/Models/EntryTest.php @@ -457,4 +457,22 @@ class EntryTest extends TestCase $this->assertEquals(['New Common Name'], $model->getAttributes()['cn']); $this->assertEquals(['John Doe'], $model->getOriginal()['cn']); } + + public function test_set_first_attribute() + { + $model = $this->newEntryModel([], $this->newBuilder()); + + $model->setFirstAttribute('cn', 'John Doe'); + + $this->assertEquals(['cn' => ['John Doe']], $model->getAttributes()); + } + + public function test_get_first_attribute() + { + $model = $this->newEntryModel([ + 'cn' => 'John Doe', + ], $this->newBuilder()); + + $this->assertEquals('John Doe', $model->getFirstAttribute('cn')); + } }
Added tests for setFirstAttribute and getFirstAttribute
diff --git a/src/ui/legend.js b/src/ui/legend.js index <HASH>..<HASH> 100644 --- a/src/ui/legend.js +++ b/src/ui/legend.js @@ -28,8 +28,8 @@ d3plus.ui.legend = function(vars) { var color_groups = {}, placed = [], data = vars.nodes.restricted ? vars.nodes.restricted : - vars.nodes.value ? vars.nodes.value : vars.data.pool - + vars.nodes.value ? vars.nodes.value : vars.data.app + data.forEach(function(d){ if (placed.indexOf(d[vars.id.key]) < 0) {
legend colors should be determined from app data, not pooled data
diff --git a/spec/integration/memory_spec.rb b/spec/integration/memory_spec.rb index <HASH>..<HASH> 100644 --- a/spec/integration/memory_spec.rb +++ b/spec/integration/memory_spec.rb @@ -18,7 +18,7 @@ describe "Memory Leak" do load_defaults! GC.start - count_instances_of(klass).should == count + count_instances_of(klass).should <= count end end
memory_spec: objects become less is acceptable
diff --git a/lib/comma/version.rb b/lib/comma/version.rb index <HASH>..<HASH> 100644 --- a/lib/comma/version.rb +++ b/lib/comma/version.rb @@ -1,3 +1,3 @@ module Comma - VERSION = "3.0.3" + VERSION = "3.0.4" end
Bump gem patch version for customisable file extensions
diff --git a/releaf-core/spec/lib/template_field_type_mapper_spec.rb b/releaf-core/spec/lib/template_field_type_mapper_spec.rb index <HASH>..<HASH> 100644 --- a/releaf-core/spec/lib/template_field_type_mapper_spec.rb +++ b/releaf-core/spec/lib/template_field_type_mapper_spec.rb @@ -272,6 +272,15 @@ describe Releaf::TemplateFieldTypeMapper do end end end # describe ".field_type_name_for_boolean" do + describe ".field_type_name_for_float" do + %w[no matter what].each do |field_name| + context "when attribute name is '#{field_name}'" do + it "returns 'float'" do + expect( subject.send(:field_type_name_for_float, field_name, nil) ).to eq 'float' + end + end + end + end # describe ".field_type_name_for_float" do describe ".field_type_name_for_integer" do before do
Added field_type_name_for_float test
diff --git a/lxd/container_lxc.go b/lxd/container_lxc.go index <HASH>..<HASH> 100644 --- a/lxd/container_lxc.go +++ b/lxd/container_lxc.go @@ -4157,6 +4157,31 @@ func (c *containerLXC) Restore(sourceContainer container, stateful bool) error { if c.IsRunning() { wasRunning = true + ephemeral := c.IsEphemeral() + if ephemeral { + // Unset ephemeral flag + args := db.ContainerArgs{ + Architecture: c.Architecture(), + Config: c.LocalConfig(), + Description: c.Description(), + Devices: c.LocalDevices(), + Ephemeral: false, + Profiles: c.Profiles(), + Project: c.Project(), + } + + err := c.Update(args, false) + if err != nil { + return err + } + + // On function return, set the flag back on + defer func() { + args.Ephemeral = ephemeral + c.Update(args, true) + }() + } + // This will unmount the container storage. err := c.Stop(false) if err != nil {
lxd/containers: Fix snapshot restore on ephemeral Closes #<I>
diff --git a/Swat/SwatCellRenderer.php b/Swat/SwatCellRenderer.php index <HASH>..<HASH> 100644 --- a/Swat/SwatCellRenderer.php +++ b/Swat/SwatCellRenderer.php @@ -130,9 +130,8 @@ abstract class SwatCellRenderer extends SwatUIObject $css_class_name = substr($css_class_name, 1); $css_class_names[] = $css_class_name; - - $php_class_name = get_parent_class($php_class_name); } + $php_class_name = get_parent_class($php_class_name); } return array_reverse($css_class_names);
fix an infinite loop bug. crisis averted svn commit r<I>
diff --git a/logger.go b/logger.go index <HASH>..<HASH> 100644 --- a/logger.go +++ b/logger.go @@ -10,8 +10,7 @@ import ( "time" ) -// LoggerEntry is the structure -// passed to the template. +// LoggerEntry is the structure passed to the template. type LoggerEntry struct { StartTime string Status int @@ -22,13 +21,10 @@ type LoggerEntry struct { Request *http.Request } -// LoggerDefaultFormat is the format -// logged used by the default Logger instance. -var LoggerDefaultFormat = "{{.StartTime}} | {{.Status}} | \t {{.Duration}} | {{.Hostname}} | {{.Method}} {{.Path}} \n" +// LoggerDefaultFormat is the format logged used by the default Logger instance. +var LoggerDefaultFormat = "{{.StartTime}} | {{.Status}} | \t {{.Duration}} | {{.Hostname}} | {{.Method}} {{.Path}}" -// LoggerDefaultDateFormat is the -// format used for date by the -// default Logger instance. +// LoggerDefaultDateFormat is the format used for date by the default Logger instance. var LoggerDefaultDateFormat = time.RFC3339 // ALogger interface
Remove newline character from default logging template + Clean up comments
diff --git a/test/unit/test_composites.py b/test/unit/test_composites.py index <HASH>..<HASH> 100644 --- a/test/unit/test_composites.py +++ b/test/unit/test_composites.py @@ -276,7 +276,7 @@ def get_url_tester_mock(identifier): return source -class UrlTesterChainTest( +class URLTesterChainTest( UrlTesterTestBaseMixin, TestFunctionDoesNotHandleMixin, unittest.TestCase
Rename UrlTesterChainTest to URLTesterChainTest
diff --git a/green/runner.py b/green/runner.py index <HASH>..<HASH> 100644 --- a/green/runner.py +++ b/green/runner.py @@ -83,6 +83,8 @@ class GreenTestRunner(): # This blocks until the worker who is processing this # particular test actually finishes result.addProtoTestResult(async_response.get()) + pool.terminate() + pool.join() result.stopTestRun() diff --git a/green/test/test_runner.py b/green/test/test_runner.py index <HASH>..<HASH> 100644 --- a/green/test/test_runner.py +++ b/green/test/test_runner.py @@ -120,12 +120,7 @@ class TestSubprocesses(unittest.TestCase): os.chdir(self.startdir) # On windows, the subprocesses block access to the files while # they take a bit to clean themselves up. - for i in range(20): - try: - shutil.rmtree(self.tmpdir) - break - except PermissionError: - time.sleep(.01) + shutil.rmtree(self.tmpdir) del(self.stream)
Explicitly terminating and joining pools after we have finished, which makes it much easier to clean up after unit tests that exercise subprocesses on Windows.
diff --git a/src/bootstrap-table.js b/src/bootstrap-table.js index <HASH>..<HASH> 100644 --- a/src/bootstrap-table.js +++ b/src/bootstrap-table.js @@ -200,7 +200,7 @@ columns.push(column); }); - this.options.columns = $.extend(columns, this.options.columns); + this.options.columns = $.extend(true, columns, this.options.columns); $.each(this.options.columns, function(i, column) { that.options.columns[i] = $.extend({}, BootstrapTable.COLUMN_DEFAULTS, column); });
Fix for headers where data is split to html and js Tables with headers defined in markup (<th>Label<th>) and extra data (like visiblity) in JS would get existing Labels overwritten unless deep-extend is performed.
diff --git a/src/commands/open.js b/src/commands/open.js index <HASH>..<HASH> 100644 --- a/src/commands/open.js +++ b/src/commands/open.js @@ -8,9 +8,9 @@ const Logger = require('../logger.js'); async function open (params) { const { alias } = params.options; - const { org_id, app_id: appId } = await AppConfig.getAppData(alias).toPromise(); + const { ownerId, appId } = await AppConfig.getAppDetails({ alias }); - const vhost = await Domain.getBest(appId, org_id); + const vhost = await Domain.getBest(appId, ownerId); const url = 'https://' + vhost.fqdn; Logger.println('Opening the application in your browser');
Use `getAppDetails()` in `clever open`
diff --git a/djstripe/models.py b/djstripe/models.py index <HASH>..<HASH> 100644 --- a/djstripe/models.py +++ b/djstripe/models.py @@ -193,7 +193,7 @@ Use ``Customer.sources`` and ``Customer.subscriptions`` to access them. try: self._api_delete() except InvalidRequestError as exc: - if str(exc).startswith("No such customer:"): + if "No such customer:" in str(exc): # The exception was thrown because the stripe customer was already # deleted on the stripe side, ignore the exception pass
API Change breaks customer deleted on stripe sync (#<I>) When deleting a customer, check the entire error message string for "No such customer", as in newer versions of the API it is not at the beginning of the string.
diff --git a/client/src/views/channel.js b/client/src/views/channel.js index <HASH>..<HASH> 100644 --- a/client/src/views/channel.js +++ b/client/src/views/channel.js @@ -88,6 +88,10 @@ _kiwi.view.Channel = _kiwi.view.Panel.extend({ var nice = url, extra_html = ''; + if (url.match(/^javascript:/)) { + return url; + } + // Add the http if no protoocol was found if (url.match(/^www\./)) { url = 'http://' + url;
Patching XSS vulnerability The following message produces a clickable link that triggers JavaScript when clicked (pre-patch): javascript://www.google.com/?%0Aalert(0); Patch was designed to prevent this while maintaining support for arbitrary link protocols.
diff --git a/userns.go b/userns.go index <HASH>..<HASH> 100644 --- a/userns.go +++ b/userns.go @@ -113,7 +113,7 @@ func parseMountedFiles(containerMount, passwdFile, groupFile string) uint32 { size = u.Uid } if u.Gid > size { - size = u.Uid + size = u.Gid } } }
Coverity found an issue with copy and pasted code
diff --git a/agario-client.js b/agario-client.js index <HASH>..<HASH> 100644 --- a/agario-client.js +++ b/agario-client.js @@ -137,7 +137,28 @@ Client.prototype = { this.log('dump: ' + packet.toString()); this.emit('message', packet); - processor(this, packet); + + try { + processor(this, packet); + }catch(err){ + this.onPacketError(packet, err); + } + }, + + // Had to do this because sometimes somehow packets get moving by 1 byte + // https://github.com/pulviscriptor/agario-client/issues/46#issuecomment-169764771 + onPacketError: function(packet, err) { + var crash = true; + + this.emit('packetError', packet, err, function() { + crash = false; + }); + + if(crash) { + if(this.debug >= 1) + this.log('Packet error detected! Check packetError event in README.md'); + throw err; + } }, send: function(buf) {
Event client.on.packetError added
diff --git a/will/plugins/storage.py b/will/plugins/storage.py index <HASH>..<HASH> 100644 --- a/will/plugins/storage.py +++ b/will/plugins/storage.py @@ -4,6 +4,11 @@ from will.decorators import respond_to, periodic, hear, randomly, route, rendere class StoragePlugin(WillPlugin): + @respond_to("^How big is the db?") + def db_size(self, message): + self.bootstrap_storage() + self.say("It's %s." % self.storage.info()["used_memory_human"], message=message) + @respond_to("^SERIOUSLY. Clear (?P<key>.*)", case_sensitive=True) def clear_storage(self, message, key=None): if not key:
Adds "how big is the db?"
diff --git a/plugins/org.eclipse.xtext/src/org/eclipse/xtext/internal/ResourceServiceProviderDescriptor.java b/plugins/org.eclipse.xtext/src/org/eclipse/xtext/internal/ResourceServiceProviderDescriptor.java index <HASH>..<HASH> 100644 --- a/plugins/org.eclipse.xtext/src/org/eclipse/xtext/internal/ResourceServiceProviderDescriptor.java +++ b/plugins/org.eclipse.xtext/src/org/eclipse/xtext/internal/ResourceServiceProviderDescriptor.java @@ -39,6 +39,8 @@ public class ResourceServiceProviderDescriptor implements IResourceServiceProvid this.extension = element.createExecutableExtension(attClass); } catch (CoreException e) { log.error(e.getMessage(), e); + } catch (NoClassDefFoundError e) { + log.error(e.getMessage(), e); } } if (this.extension instanceof IResourceServiceProvider.Provider) {
[general] Improved handling of broken plugin.xml Catch NoClassDefFoundError and provide a meaningful log output. Change-Id: I<I>f<I>a<I>b6ca<I>c6b<I>bcb1b<I>b6a7cd
diff --git a/marklogic-sesame/src/test/java/com/marklogic/semantics/sesame/MarkLogicGraphPermsTest.java b/marklogic-sesame/src/test/java/com/marklogic/semantics/sesame/MarkLogicGraphPermsTest.java index <HASH>..<HASH> 100644 --- a/marklogic-sesame/src/test/java/com/marklogic/semantics/sesame/MarkLogicGraphPermsTest.java +++ b/marklogic-sesame/src/test/java/com/marklogic/semantics/sesame/MarkLogicGraphPermsTest.java @@ -104,7 +104,7 @@ public class MarkLogicGraphPermsTest extends SesameTestBase { String defGraphQuery = "INSERT DATA { GRAPH <http://marklogic.com/test/graph/permstest> { <http://marklogic.com/test> <pp1> <oo1> } }"; String checkQuery = "ASK WHERE { GRAPH <http://marklogic.com/test/graph/permstest> {<http://marklogic.com/test> <pp1> <oo1> }}"; MarkLogicUpdateQuery updateQuery = conn.prepareUpdate(QueryLanguage.SPARQL, defGraphQuery); - updateQuery.setGraphPerms(gmgr.permission("test-role", Capability.READ)); + updateQuery.setGraphPerms(gmgr.permission("admin", Capability.READ)); updateQuery.execute(); BooleanQuery booleanQuery = conn.prepareBooleanQuery(QueryLanguage.SPARQL, checkQuery);
change test to use pre-existing role
diff --git a/registry/storage/driver/swift/swift.go b/registry/storage/driver/swift/swift.go index <HASH>..<HASH> 100644 --- a/registry/storage/driver/swift/swift.go +++ b/registry/storage/driver/swift/swift.go @@ -39,6 +39,7 @@ import ( storagedriver "github.com/docker/distribution/registry/storage/driver" "github.com/docker/distribution/registry/storage/driver/base" "github.com/docker/distribution/registry/storage/driver/factory" + "github.com/docker/distribution/version" ) const driverName = "swift" @@ -151,7 +152,7 @@ func New(params Parameters) (*Driver, error) { ApiKey: params.Password, AuthUrl: params.AuthURL, Region: params.Region, - UserAgent: "distribution", + UserAgent: "distribution/" + version.Version, Tenant: params.Tenant, TenantId: params.TenantID, Domain: params.Domain,
Show distribution version in User-Agent
diff --git a/ui/app/helpers/lazy-click.js b/ui/app/helpers/lazy-click.js index <HASH>..<HASH> 100644 --- a/ui/app/helpers/lazy-click.js +++ b/ui/app/helpers/lazy-click.js @@ -1,5 +1,4 @@ import Helper from '@ember/component/helper'; -import $ from 'jquery'; /** * Lazy Click Event @@ -10,7 +9,7 @@ import $ from 'jquery'; * that should be handled instead. */ export function lazyClick([onClick, event]) { - if (!$(event.target).is('a')) { + if (event.target.tagName.toLowerCase() !== 'a') { onClick(event); } }
Remove jquery from the lazy-click helper
diff --git a/features/bootstrap/FeatureContext.php b/features/bootstrap/FeatureContext.php index <HASH>..<HASH> 100644 --- a/features/bootstrap/FeatureContext.php +++ b/features/bootstrap/FeatureContext.php @@ -7,8 +7,6 @@ use Behat\Behat\Context\ClosuredContextInterface, use \WP_CLI\Utils; -require_once 'PHPUnit/Framework/Assert/Functions.php'; - require_once __DIR__ . '/../../php/utils.php'; /** diff --git a/features/bootstrap/support.php b/features/bootstrap/support.php index <HASH>..<HASH> 100644 --- a/features/bootstrap/support.php +++ b/features/bootstrap/support.php @@ -2,6 +2,12 @@ // Utility functions used by Behat steps +function assertEquals( $expected, $actual ) { + if ( $expected != $actual ) { + throw new Exception( "Actual value: " . var_export( $actual ) ); + } +} + function checkString( $output, $expected, $action ) { switch ( $action ) {
replace PHPUnit assertEquals() with homegrown variant
diff --git a/lib/vagrant/action/vm/import.rb b/lib/vagrant/action/vm/import.rb index <HASH>..<HASH> 100644 --- a/lib/vagrant/action/vm/import.rb +++ b/lib/vagrant/action/vm/import.rb @@ -22,10 +22,12 @@ module Vagrant end # Import completed successfully. Continue the chain - @app.call(env) if !env.error? - + @app.call(env) + end + + def rescue(env) # Interrupted, destroy the VM - env["actions"].run(:destroy) if env.interrupted? + env["actions"].run(:destroy) end end end
first middleware, import, moved to rescue for cleanup
diff --git a/sdk/go/src/sawtooth_sdk/processor/worker.go b/sdk/go/src/sawtooth_sdk/processor/worker.go index <HASH>..<HASH> 100644 --- a/sdk/go/src/sawtooth_sdk/processor/worker.go +++ b/sdk/go/src/sawtooth_sdk/processor/worker.go @@ -28,7 +28,7 @@ import ( ) // The main worker thread finds an appropriate handler and processes the request -func worker(context *zmq.Context, uri string, queue chan *validator_pb2.Message, handlers []TransactionHandler) { +func worker(context *zmq.Context, uri string, queue <-chan *validator_pb2.Message, handlers []TransactionHandler) { // Connect to the main send/receive thread connection, err := messaging.NewConnection(context, zmq.DEALER, uri) if err != nil {
Make worker() queue a receive-only channel Making this a receive-only channel clarifies the intent and prevents sending on the channel.
diff --git a/builtin/providers/aws/resource_aws_rds_cluster_instance_test.go b/builtin/providers/aws/resource_aws_rds_cluster_instance_test.go index <HASH>..<HASH> 100644 --- a/builtin/providers/aws/resource_aws_rds_cluster_instance_test.go +++ b/builtin/providers/aws/resource_aws_rds_cluster_instance_test.go @@ -177,10 +177,25 @@ resource "aws_rds_cluster" "default" { } resource "aws_rds_cluster_instance" "cluster_instances" { - identifier = "tf-cluster-instance-%d" - cluster_identifier = "${aws_rds_cluster.default.id}" - instance_class = "db.r3.large" + identifier = "tf-cluster-instance-%d" + cluster_identifier = "${aws_rds_cluster.default.id}" + instance_class = "db.r3.large" + db_parameter_group_name = "${aws_db_parameter_group.bar.name}" } +resource "aws_db_parameter_group" "bar" { + name = "tfcluster-test-group" + family = "aurora5.6" + + parameter { + name = "back_log" + value = "32767" + apply_method = "pending-reboot" + } + + tags { + foo = "bar" + } +} `, n, n) }
provider/aws: Add db_param group to RDS Cluster Instance test
diff --git a/pyethereum/packeter.py b/pyethereum/packeter.py index <HASH>..<HASH> 100644 --- a/pyethereum/packeter.py +++ b/pyethereum/packeter.py @@ -64,11 +64,11 @@ class Packeter(object): dict((v, k) for k, v in disconnect_reasons_map.items()) SYNCHRONIZATION_TOKEN = 0x22400891 - PROTOCOL_VERSION = 0x0c + PROTOCOL_VERSION = 0x0f + # is the node s Unique Identifier and is the 512-bit hash that serves to # identify the node. NETWORK_ID = 0 - # as sent by Ethereum(++)/v0.3.11/brew/Darwin/unknown CLIENT_ID = 'Ethereum(py)/0.5.1/%s/Protocol:%d' % (sys.platform, PROTOCOL_VERSION) CAPABILITIES = 0x01 + 0x02 + 0x04 # node discovery + transaction relaying
increase protocol version to 0x0f
diff --git a/lib/dentaku/calculator.rb b/lib/dentaku/calculator.rb index <HASH>..<HASH> 100644 --- a/lib/dentaku/calculator.rb +++ b/lib/dentaku/calculator.rb @@ -71,9 +71,14 @@ module Dentaku end if block_given? - result = yield - @memory = restore - return result + begin + result = yield + @memory = restore + return result + rescue => e + @memory = restore + raise e + end end self diff --git a/spec/calculator_spec.rb b/spec/calculator_spec.rb index <HASH>..<HASH> 100644 --- a/spec/calculator_spec.rb +++ b/spec/calculator_spec.rb @@ -130,6 +130,17 @@ describe Dentaku::Calculator do expect(calculator.solve(expressions) { :foo }) .to eq(more_apples: :foo) end + + it "solves remainder of expressions with unbound variable" do + calculator.store(peaches: 1, oranges: 1) + expressions = { more_apples: "apples + 1", more_peaches: "peaches + 1" } + result = calculator.solve(expressions) + expect(calculator.memory).to eq("peaches" => 1, "oranges" => 1) + expect(result).to eq( + more_apples: :undefined, + more_peaches: 2 + ) + end end it 'evaluates a statement with no variables' do
prevent errors from corrupting calculator memory Closes #<I>
diff --git a/activiti-engine/src/main/java/org/activiti/engine/repository/DeploymentBuilder.java b/activiti-engine/src/main/java/org/activiti/engine/repository/DeploymentBuilder.java index <HASH>..<HASH> 100644 --- a/activiti-engine/src/main/java/org/activiti/engine/repository/DeploymentBuilder.java +++ b/activiti-engine/src/main/java/org/activiti/engine/repository/DeploymentBuilder.java @@ -18,7 +18,7 @@ import java.util.zip.ZipInputStream; /** * Builder for creating new deployments. * - * A builder instance can be obtained through {@link org.activiti.engine.RuntimeService#createDeployment()}. + * A builder instance can be obtained through {@link org.activiti.engine.RepositoryService#createDeployment()}. * * Multiple resources can be added to one deployment before calling the {@link #deploy()} * operation.
Javadoc fix for DeploymentBuilder