diff
stringlengths
65
26.7k
message
stringlengths
7
9.92k
diff --git a/lib/discordrb/bot.rb b/lib/discordrb/bot.rb index <HASH>..<HASH> 100644 --- a/lib/discordrb/bot.rb +++ b/lib/discordrb/bot.rb @@ -1069,6 +1069,14 @@ module Discordrb end raise_event(DisconnectEvent.new(self)) + + # Safely close the WS connection and handle any errors that occur there + begin + @ws.close + rescue => e + LOGGER.warn 'Got the following exception while closing the WS after being disconnected:' + LOGGER.log_exception e + end rescue => e LOGGER.log_exception e raise
Make sure the websocket connection is always closed after a close event is received
diff --git a/actionpack/test/dispatch/test_request_test.rb b/actionpack/test/dispatch/test_request_test.rb index <HASH>..<HASH> 100644 --- a/actionpack/test/dispatch/test_request_test.rb +++ b/actionpack/test/dispatch/test_request_test.rb @@ -5,7 +5,7 @@ class TestRequestTest < ActiveSupport::TestCase env = ActionDispatch::TestRequest.new.env assert_equal "GET", env.delete("REQUEST_METHOD") - assert_equal nil, env.delete("HTTPS") + assert_equal "off", env.delete("HTTPS") assert_equal "http", env.delete("rack.url_scheme") assert_equal "example.org", env.delete("SERVER_NAME") assert_equal "80", env.delete("SERVER_PORT")
Rack: HTTPS is either 'on' or 'off' as of 9b7a<I>e<I>d0c<I>a<I>fc<I>e<I>c<I>d7f
diff --git a/dodgy/__pkginfo__.py b/dodgy/__pkginfo__.py index <HASH>..<HASH> 100644 --- a/dodgy/__pkginfo__.py +++ b/dodgy/__pkginfo__.py @@ -1,5 +1,5 @@ -VERSION = (0, 1, 2) +VERSION = (0, 1, 3) def get_version():
Bumping version to <I>
diff --git a/potypo/__main__.py b/potypo/__main__.py index <HASH>..<HASH> 100644 --- a/potypo/__main__.py +++ b/potypo/__main__.py @@ -8,13 +8,6 @@ from .check import Check from enchant import DictWithPWL from enchant.checker import SpellChecker -# TODO: packaging -# TODO: gh + README -# TODO: alle .po-files finden -# TODO: tests schreiben -# TODO: bei typo: exit 1 -# TODO: config-option für sprachen ohne fail - def main(): config = configparser.ConfigParser() config.read('setup.cfg')
move TODOs from __main__ to README
diff --git a/ResourceLocator/src/UniformResourceLocator.php b/ResourceLocator/src/UniformResourceLocator.php index <HASH>..<HASH> 100644 --- a/ResourceLocator/src/UniformResourceLocator.php +++ b/ResourceLocator/src/UniformResourceLocator.php @@ -248,7 +248,7 @@ class UniformResourceLocator implements ResourceLocatorInterface $filePath = '/' . ltrim(substr($file, strlen($prefix)), '\/'); if (is_array($path)) { // Handle scheme lookup. - $path[1] .= $filePath; + $path[1] = trim($path[1] . $filePath, '/'); $found = $this->find($path, $array, $absolute, $all); if ($found) { if (!$array) { @@ -259,7 +259,7 @@ class UniformResourceLocator implements ResourceLocatorInterface } } else { // Handle relative path lookup. - $path .= $filePath; + $path = trim($path . $filePath, '/'); $lookup = $this->base . '/' . $path; if ($all || file_exists($lookup)) {
UniformResourceLocator: Remove extra slashes from the output
diff --git a/parse.go b/parse.go index <HASH>..<HASH> 100644 --- a/parse.go +++ b/parse.go @@ -140,7 +140,7 @@ func (p *parser) next() { case '\n': p.advance('\n', "") default: - p.setTok(p.doToken(r)) + p.advance(p.doToken(r), "") } return } @@ -419,7 +419,8 @@ func (p *parser) command() { var cmd Command p.push(&cmd.Args) p.add(Lit{Val: p.lval}) - first := p.lpos + fpos := p.lpos + fval := p.lval args: for p.tok != EOF { switch { @@ -438,14 +439,13 @@ func (p *parser) command() { p.binaryExpr(LOR, cmd) return case p.got(LPAREN): - name := p.lval p.want(RPAREN) - if !identRe.MatchString(name) { - p.posErr(first, "invalid func name %q", name) + if !identRe.MatchString(fval) { + p.posErr(fpos, "invalid func name %q", fval) break args } fun := FuncDecl{ - Name: Lit{Val: name}, + Name: Lit{Val: fval}, } p.push(&fun.Body) p.command()
Get rid of one more setTok()
diff --git a/src/Elcodi/UserBundle/Entity/Customer.php b/src/Elcodi/UserBundle/Entity/Customer.php index <HASH>..<HASH> 100644 --- a/src/Elcodi/UserBundle/Entity/Customer.php +++ b/src/Elcodi/UserBundle/Entity/Customer.php @@ -432,7 +432,7 @@ class Customer extends AbstractUser implements CustomerInterface /** * Sleep implementation for some reason * - * Url http://asiermarques.com/2013/symfony2-security-usernamepasswordtokenserialize-must-return-a-string-or-null/ + * @link http://asiermarques.com/2013/symfony2-security-usernamepasswordtokenserialize-must-return-a-string-or-null/ */ public function __sleep() {
Really changed the annotation @url to @link
diff --git a/module.flow.js b/module.flow.js index <HASH>..<HASH> 100644 --- a/module.flow.js +++ b/module.flow.js @@ -198,6 +198,10 @@ declare module '@solana/web3.js' { keys: Array<{pubkey: PublicKey, isSigner: boolean, isDebitable: boolean}>; programId: PublicKey; data: Buffer; + + constructor( + opts?: TransactionInstructionCtorFields, + ): TransactionInstruction; } declare type SignaturePubkeyPair = {|
fix: add transaction instruction ctor to flow def (#<I>)
diff --git a/integration-tests/spec/archive_spec.rb b/integration-tests/spec/archive_spec.rb index <HASH>..<HASH> 100644 --- a/integration-tests/spec/archive_spec.rb +++ b/integration-tests/spec/archive_spec.rb @@ -41,7 +41,7 @@ if embedded_from_disk? output = `java -Djava.io.tmpdir=#{@tmpdir}/tmp -jar #{archive} \ -S torquebox --version`.split('\n') output.first.should include(TorqueBox::VERSION) - glob = Dir.glob('tmp/*') + glob = Dir.glob('tmp/wunderboss*') unless glob.empty? $stderr.puts "Did not clean up temp dirs #{glob.inspect}" end
Don't let jffi and other tmp turds fail our archive_spec.rb
diff --git a/lib/slop.rb b/lib/slop.rb index <HASH>..<HASH> 100644 --- a/lib/slop.rb +++ b/lib/slop.rb @@ -249,7 +249,8 @@ class Slop option = @options[$1] argument = $2 when /\A--no-(.+)\z/ - option.force_argument_value(false) if option = @options[$1] + option = @options[$1] + option.force_argument_value(false) if option end end
dont use assignment in postfix conditional
diff --git a/spec/pycall/conversion_spec.rb b/spec/pycall/conversion_spec.rb index <HASH>..<HASH> 100644 --- a/spec/pycall/conversion_spec.rb +++ b/spec/pycall/conversion_spec.rb @@ -105,10 +105,16 @@ module PyCall context 'for a unicode string' do let(:ruby_snowman) { "\u{2603}" } - let(:python_snowman) { p Conversion.from_ruby(ruby_snowman) } + let(:python_snowman) { Conversion.from_ruby(ruby_snowman) } subject { Conversion.to_ruby(python_snowman) } it { is_expected.to eq(ruby_snowman) } end + + context 'for a large size string' do + let(:large_string) { 'x' * 10000 } + subject { Conversion.to_ruby(Conversion.from_ruby(large_string)) } + it { is_expected.to eq(large_string) } + end end describe '.from_ruby' do
Add an example to investigate #<I>
diff --git a/vtkInterface/plotting.py b/vtkInterface/plotting.py index <HASH>..<HASH> 100755 --- a/vtkInterface/plotting.py +++ b/vtkInterface/plotting.py @@ -3,17 +3,17 @@ vtk plotting module """ import colorsys - -import vtk -from vtk.util import numpy_support as VN import numpy as np - import vtkInterface -font_keys = {'arial': vtk.VTK_ARIAL, - 'courier': vtk.VTK_COURIER, - 'times': vtk.VTK_TIMES} - +try: + import vtk + from vtk.util import numpy_support as VN + font_keys = {'arial': vtk.VTK_ARIAL, + 'courier': vtk.VTK_COURIER, + 'times': vtk.VTK_TIMES} +except: + pass def Plot(mesh, **args): """
allowed to pass on loading vtk for autodoc for plotting
diff --git a/tensorflow_datasets/text/glue.py b/tensorflow_datasets/text/glue.py index <HASH>..<HASH> 100644 --- a/tensorflow_datasets/text/glue.py +++ b/tensorflow_datasets/text/glue.py @@ -118,6 +118,10 @@ class GlueConfig(tfds.core.BuilderConfig): """ super(GlueConfig, self).__init__( version=tfds.core.Version("2.0.0"), + supported_versions=[ + tfds.core.Version("1.0.0"), + tfds.core.Version("1.0.1"), + ], release_notes={ "1.0.0": "New split API (https://tensorflow.org/datasets/splits)", "1.0.1": "Update dead URL links.",
Add <I>.x GLUE versions as supported. PiperOrigin-RevId: <I>
diff --git a/index.js b/index.js index <HASH>..<HASH> 100644 --- a/index.js +++ b/index.js @@ -21,13 +21,16 @@ module.exports = function (source) { return accumulator; }, {}); - options.sourceMap = true; + options.sourceMap = this.sourceMap; options.filename = loaderUtils.getRemainingRequest(this); result = to5.transform(source, options); code = result.code; + map = result.map; - map.sourcesContent = [source]; + if (map) { + map.sourcesContent = [source]; + } this.callback(null, code, map);
Don't generate sourcemaps if user disables them
diff --git a/lib/flipper/api/action.rb b/lib/flipper/api/action.rb index <HASH>..<HASH> 100644 --- a/lib/flipper/api/action.rb +++ b/lib/flipper/api/action.rb @@ -29,7 +29,7 @@ module Flipper end def self.match?(request) - !!match.call(request) + match.call(request) end # Internal: Initializes and runs an action for a given request. diff --git a/lib/flipper/ui/action.rb b/lib/flipper/ui/action.rb index <HASH>..<HASH> 100644 --- a/lib/flipper/ui/action.rb +++ b/lib/flipper/ui/action.rb @@ -29,7 +29,7 @@ module Flipper end def self.match?(request) - !!match.call(request) + match.call(request) end # Internal: Initializes and runs an action for a given request.
Make rubo happy by removing double negation
diff --git a/themes/_administration/header.php b/themes/_administration/header.php index <HASH>..<HASH> 100644 --- a/themes/_administration/header.php +++ b/themes/_administration/header.php @@ -99,7 +99,9 @@ echo '<li><ul>'; foreach (get_all_gedcoms() as $ged_id=>$gedcom) { if (userGedcomAdmin(WT_USER_ID, $ged_id)) { echo - '<li><span><a ', (WT_SCRIPT_NAME=="admin_trees_config.php" && WT_GED_ID==$ged_id ? 'class="current" ' : ''), 'href="admin_trees_config.php?ged='.rawurlencode($gedcom).'">', + '<li><span><a ', (WT_SCRIPT_NAME=="admin_trees_config.php" && WT_GED_ID==$ged_id ? 'class="current" ' : ''), 'href="admin_trees_config.php?ged='.rawurlencode($gedcom).'" title="', + WT_I18N::translate('%s', htmlspecialchars(get_gedcom_setting($ged_id, 'title'))), + '">', WT_I18N::translate('%s', htmlspecialchars(get_gedcom_setting($ged_id, 'title'))), '</a></span></li>'; }
Add hover titles to family tree names, so long names that disappear off the edge of the menu bar can be read.
diff --git a/src/ResultPrinter71.php b/src/ResultPrinter71.php index <HASH>..<HASH> 100755 --- a/src/ResultPrinter71.php +++ b/src/ResultPrinter71.php @@ -68,7 +68,6 @@ if ($low && $high) { if (strpos($exceptionMessage, 'This test did not perform any assertions') !== false) { $exceptionMessage = $this->setMessageColor('risky', 'This test did not perform any assertions.'); } else { - $marker = $this->markers['fail']; if ($this->colors) {
Apply fixes from StyleCI (#<I>)
diff --git a/pendulum/duration.py b/pendulum/duration.py index <HASH>..<HASH> 100644 --- a/pendulum/duration.py +++ b/pendulum/duration.py @@ -24,8 +24,9 @@ def _divide_and_round(a, b): # in Objects/longobject.c. q, r = divmod(a, b) - if isinstance(q, float): - q = int(q) + # The output of divmod() is either a float or an int, + # but we always want it to be an int. + q = int(q) # round up if either r / b > 0.5, or r / b == 0.5 and q is odd. # The expression r / b > 0.5 is equivalent to 2 * r > b if b is
Removed unnecessary "if isinstance" check for speed.
diff --git a/amaascore/transactions/interface.py b/amaascore/transactions/interface.py index <HASH>..<HASH> 100644 --- a/amaascore/transactions/interface.py +++ b/amaascore/transactions/interface.py @@ -340,7 +340,7 @@ class TransactionsInterface(Interface): response.raise_for_status() def position_search(self, asset_manager_id, book_ids=None, account_ids=None, - accounting_types=['Transaction Date'], asset_ids=None, + accounting_types=None, asset_ids=None, position_date=None, include_cash=False, page_no=None, page_size=None): self.logger.info('Search Positions - Asset Manager: %s', asset_manager_id) diff --git a/setup.py b/setup.py index <HASH>..<HASH> 100644 --- a/setup.py +++ b/setup.py @@ -11,7 +11,7 @@ requires = [ setup( name='amaascore', - version='0.6.6', + version='0.6.7', description='Asset Management as a Service - Core SDK', license='Apache License 2.0', url='https://github.com/amaas-fintech/amaas-core-sdk-python',
Removed default for accounting type in position search
diff --git a/consul/rpc.go b/consul/rpc.go index <HASH>..<HASH> 100644 --- a/consul/rpc.go +++ b/consul/rpc.go @@ -244,6 +244,13 @@ RUN_QUERY: // Update the query meta data s.setQueryMeta(m) + // Check if query must be consistent + if b.RequireConsistent { + if err := s.consistentRead(); err != nil { + return err + } + } + // Run the query function err := run()
consul: Adding consistent read enforcement
diff --git a/.dreamfactory.php b/.dreamfactory.php index <HASH>..<HASH> 100644 --- a/.dreamfactory.php +++ b/.dreamfactory.php @@ -1,6 +1,6 @@ <?php /** - * DreamFactory(tm) Core <http://github.com/dreamfactorysoftware/dsp-core> + * DreamFactory(tm) Core <http://github.com/dreamfactorysoftware/df-core> * Copyright 2012-2015 DreamFactory Software, Inc. <support@dreamfactory.com> * * Licensed under the Apache License, Version 2.0 (the "License");
PSR-2 formatting and removing file license header
diff --git a/lib/rails_admin/config/fields/types/serialized.rb b/lib/rails_admin/config/fields/types/serialized.rb index <HASH>..<HASH> 100644 --- a/lib/rails_admin/config/fields/types/serialized.rb +++ b/lib/rails_admin/config/fields/types/serialized.rb @@ -14,7 +14,7 @@ module RailsAdmin def parse_input(params) return unless params[name].is_a?(::String) - params[name] = (params[name].blank? ? nil : (YAML.safe_load(params[name]) || nil)) + params[name] = (params[name].blank? ? nil : (SafeYAML.load(params[name]) || nil)) end end end diff --git a/lib/rails_admin/engine.rb b/lib/rails_admin/engine.rb index <HASH>..<HASH> 100644 --- a/lib/rails_admin/engine.rb +++ b/lib/rails_admin/engine.rb @@ -7,10 +7,7 @@ require 'rack-pjax' require 'rails' require 'rails_admin' require 'remotipart' -require 'safe_yaml' - -SafeYAML::OPTIONS[:suppress_warnings] = true -SafeYAML::OPTIONS[:default_mode] = :unsafe +require 'safe_yaml/load' module RailsAdmin class Engine < Rails::Engine
Do not monkey patch the app's YAML SafeYAML provides a way to avoid monkey-patching the `YAML` object. This should be used to avoid overwriting the application's `YAML`.
diff --git a/maildir_deduplicate/deduplicate.py b/maildir_deduplicate/deduplicate.py index <HASH>..<HASH> 100644 --- a/maildir_deduplicate/deduplicate.py +++ b/maildir_deduplicate/deduplicate.py @@ -62,7 +62,7 @@ class Deduplicate(object): def add_maildir(self, maildir_path): """ Load up a maildir add compute hash for each mail their contain. """ - maildir = Maildir(maildir_path, factory=None) + maildir = Maildir(maildir_path, create=False) # Collate folders by hash. print("Processing {} mails in {}".format(len(maildir), maildir._path)) for mail_id, message in maildir.iteritems():
Input maildirs are read-only.
diff --git a/decidim-dev/lib/decidim/dev/test/rspec_support/translation_helpers.rb b/decidim-dev/lib/decidim/dev/test/rspec_support/translation_helpers.rb index <HASH>..<HASH> 100644 --- a/decidim-dev/lib/decidim/dev/test/rspec_support/translation_helpers.rb +++ b/decidim-dev/lib/decidim/dev/test/rspec_support/translation_helpers.rb @@ -108,6 +108,9 @@ module TranslationHelpers private def fill_in_i18n_fields(field, tab_selector, localized_values) + # Ensure the field is visible in the view to avoid "element has zero size" + # errors + scroll_to(find(tab_selector)) localized_values.each do |locale, value| within tab_selector do click_link I18n.with_locale(locale) { t("name", scope: "locale") } @@ -117,6 +120,9 @@ module TranslationHelpers end def clear_i18n_fields(field, tab_selector, locales) + # Ensure the field is visible in the view to avoid "element has zero size" + # errors + scroll_to(find(tab_selector)) locales.each do |locale| within tab_selector do click_link I18n.with_locale(locale) { t("name", scope: "locale") }
Fix the failing consultations system spec (#<I>)
diff --git a/plugins/communicators/ssh/communicator.rb b/plugins/communicators/ssh/communicator.rb index <HASH>..<HASH> 100644 --- a/plugins/communicators/ssh/communicator.rb +++ b/plugins/communicators/ssh/communicator.rb @@ -97,8 +97,13 @@ module VagrantPlugins @logger.debug("Uploading: #{from} to #{to}") scp_connect do |scp| - # Open file read only to fix issue [GH-1036] - scp.upload!(File.open(from, "r"), to) + if File.directory?(from) + # Recurisvely upload directories + scp.upload!(from, to, :recursive => true) + else + # Open file read only to fix issue [GH-1036] + scp.upload!(File.open(from, "r"), to) + end end rescue RuntimeError => e # Net::SCP raises a runtime error for this so the only way we have
Allow SSH upload to upload directories
diff --git a/Plugin/EventSubscriber.php b/Plugin/EventSubscriber.php index <HASH>..<HASH> 100644 --- a/Plugin/EventSubscriber.php +++ b/Plugin/EventSubscriber.php @@ -11,23 +11,28 @@ namespace Yosymfony\Spress\Core\Plugin; +/** + * Event subscriber. + * + * @author Victor Puertas <vpgugr@gmail.com> + */ class EventSubscriber { private $listener = []; /** - * Add a listener for one event + * Add a listener for one event. * * @param string $eventName - * @param callable $listener + * @param \closure $listener */ - public function addEventListener($eventName, $listener) + public function addEventListener($eventName, \closure $listener) { $this->listener[$eventName] = $listener; } /** - * Get event listeners + * Get event listeners. * * @return array */
Argument 'listener' from addEventListener is a type closure
diff --git a/src/test/java/org/takes/rq/form/RqFormFakeTest.java b/src/test/java/org/takes/rq/form/RqFormFakeTest.java index <HASH>..<HASH> 100644 --- a/src/test/java/org/takes/rq/form/RqFormFakeTest.java +++ b/src/test/java/org/takes/rq/form/RqFormFakeTest.java @@ -30,7 +30,6 @@ import org.hamcrest.Matchers; import org.junit.Test; import org.takes.rq.RqFake; import org.takes.rq.RqForm; -import org.takes.rq.RqPrint; /** * Test case for {@link RqFormFake}. @@ -73,7 +72,6 @@ public final class RqFormFakeTest { key, avalue, akey, aavalue ); - new RqPrint(req).printBody(System.err); MatcherAssert.assertThat( req.param(key), Matchers.hasItems(value, avalue)
(#<I>) Remove debug
diff --git a/src/ConcurrentPhpUtils/CyclicBarrier.php b/src/ConcurrentPhpUtils/CyclicBarrier.php index <HASH>..<HASH> 100644 --- a/src/ConcurrentPhpUtils/CyclicBarrier.php +++ b/src/ConcurrentPhpUtils/CyclicBarrier.php @@ -177,13 +177,6 @@ class CyclicBarrier extends \Threaded ); } - if ($this->isTerminated()) { - $this->breakBarrier(); - throw new Exception\InterruptedException( - 'thread was interrupted' - ); - } - if ($g->broken) { throw new Exception\BrokenBarrierException(); }
check for thread termination in cyclicbarrier
diff --git a/shared/native/notification-listeners.desktop.js b/shared/native/notification-listeners.desktop.js index <HASH>..<HASH> 100644 --- a/shared/native/notification-listeners.desktop.js +++ b/shared/native/notification-listeners.desktop.js @@ -14,14 +14,23 @@ import type {Dispatch} from '../constants/types/flux' // notification listeners, store the sentNotifications map in it. var sentNotifications = {} +// Keep track of the last time we notified and ignore if its the same +let lastLoggedInNotifyUsername = null + // TODO(mm) Move these to their own actions export default function (dispatch: Dispatch, notify: any): incomingCallMapType { return { 'keybase.1.NotifySession.loggedOut': params => { + lastLoggedInNotifyUsername = null notify('Logged out of Keybase') dispatch(logoutDone()) }, 'keybase.1.NotifySession.loggedIn': ({username}, response) => { + if (lastLoggedInNotifyUsername === username) { + return + } + + lastLoggedInNotifyUsername = username notify('Logged in to Keybase as: ' + username) dispatch(getCurrentStatus()) response.result()
don't spam users with login notifies
diff --git a/spyder/plugins/editor/utils/autosave.py b/spyder/plugins/editor/utils/autosave.py index <HASH>..<HASH> 100644 --- a/spyder/plugins/editor/utils/autosave.py +++ b/spyder/plugins/editor/utils/autosave.py @@ -4,7 +4,26 @@ # Licensed under the terms of the MIT License # (see spyder/__init__.py for details) -"""Autosave components for the Editor plugin and the EditorStack widget""" +""" +Autosave components for the Editor plugin and the EditorStack widget + +The autosave system regularly checks the contents of all opened files and saves +a copy in the autosave directory if the contents are different from the +autosave file (if it exists) or original file (if there is no autosave file). + +The mapping between original files and autosave files is stored in the +variable `name_mapping` and saved in the file `pidNNN.txt` in the autosave +directory, where `NNN` stands for the pid. This filename is chosen so that +multiple instances of Spyder can run simultaneously. + +File contents are compared using their hash. The variable `file_hashes` +contains the hash of all files currently open in the editor and all autosave +files. + +On startup, the contents of the autosave directory is checked and if autosave +files are found, the user is asked whether to recover them; +see `spyder/plugins/editor/widgets/recover.py`. +""" # Standard library imports import ast
Editor: Add comment with description of autosave system
diff --git a/pygount/command.py b/pygount/command.py index <HASH>..<HASH> 100644 --- a/pygount/command.py +++ b/pygount/command.py @@ -28,8 +28,11 @@ _HELP_ENCODING = '''encoding to use when reading source code; use "automatic" different fallback encoding than CP1252; use "chardet" to let the chardet package determine the encoding; default: "%(default)s"''' -_HELP_EPILOG = '''By default PATTERNS are shell patterns using *, ? and - ranges like [a-z] as placeholders.''' +_HELP_EPILOG = '''SHELL-PATTERN is a pattern using *, ? and ranges like [a-z] + as placeholders. PATTERNS is a comma separated list of SHELL-PATTERN. The + prefix [regex] indicated that the PATTERNS use regular expression syntax. If + default values are available, [...] indicates that the PATTERNS extend the + existing default values.''' _HELP_FORMAT = 'output format, one of: {0}; default: "%(default)s"'.format( ', '.join(['"' + format + '"' for format in _VALID_FORMATS]))
Improved online help on PATTERNS options.
diff --git a/test/sourcemaps/loaders/_config.js b/test/sourcemaps/loaders/_config.js index <HASH>..<HASH> 100644 --- a/test/sourcemaps/loaders/_config.js +++ b/test/sourcemaps/loaders/_config.js @@ -10,9 +10,9 @@ module.exports = { plugins: [ { load: function ( id ) { - if ( id.endsWith( 'foo.js' ) ) { + if ( /foo.js$/.test( id ) ) { id = id.replace( /foo.js$/, 'bar.js' ); - } else if ( id.endsWith( 'bar.js' ) ) { + } else if ( /bar.js$/.test( id ) ) { id = id.replace( /bar.js$/, 'foo.js' ); } @@ -22,7 +22,7 @@ module.exports = { comments: false // misalign the columns }); - if ( id.endsWith( 'main.js' ) ) { + if ( /main.js$/.test( id ) ) { delete out.map.sources; } else { const slash = out.map.sources[0].lastIndexOf( '/' ) + 1;
Don't use endsWith. Will this fix the <I> build?
diff --git a/pynspect/__init__.py b/pynspect/__init__.py index <HASH>..<HASH> 100644 --- a/pynspect/__init__.py +++ b/pynspect/__init__.py @@ -16,4 +16,4 @@ data structures. """ -__version__ = "0.14" +__version__ = "0.15"
DEPLOY: Increased package version to '<I>' to build new distribution.
diff --git a/tests/test_post_punct.py b/tests/test_post_punct.py index <HASH>..<HASH> 100644 --- a/tests/test_post_punct.py +++ b/tests/test_post_punct.py @@ -39,3 +39,9 @@ def test_three_same_close(close_puncts): assert len(tokens) == 4 assert tokens[0].string == word_str assert tokens[1].string == p + + +def test_double_end_quote(): + assert len(EN.tokenize("Hello''")) == 2 + assert len(EN.tokenize("''")) == 1 +
* Add test for '' in punct
diff --git a/spec/aptly/repo_spec.rb b/spec/aptly/repo_spec.rb index <HASH>..<HASH> 100644 --- a/spec/aptly/repo_spec.rb +++ b/spec/aptly/repo_spec.rb @@ -123,14 +123,6 @@ module Aptly end end - describe "Publish Repos" do - it "should publish an existing repo" do - repo = Aptly.create_repo 'repo_to_publish' - repo.add 'spec/pkgs/pkg1_1.0.1-1_amd64.deb' - repo.publish :dist => 'repo_to_publish' - end - end - describe "Modify Repo" do it "should modify the repo metadata" do repoA = Aptly.create_repo 'modify'
Removed publish test for the time being
diff --git a/lib/puppet/functions/map.rb b/lib/puppet/functions/map.rb index <HASH>..<HASH> 100644 --- a/lib/puppet/functions/map.rb +++ b/lib/puppet/functions/map.rb @@ -125,7 +125,7 @@ Puppet::Functions.create_function(:map) do index = 0 loop do result << yield(index, enum.next) - index = index +1 + index = index + 1 end rescue StopIteration end
(PUP-<I>) Remove '`+' after local variable or literal is interpreted as binary operator' warning
diff --git a/app/controllers/effective/datatables_controller.rb b/app/controllers/effective/datatables_controller.rb index <HASH>..<HASH> 100644 --- a/app/controllers/effective/datatables_controller.rb +++ b/app/controllers/effective/datatables_controller.rb @@ -24,7 +24,7 @@ module Effective private def find_datatable(id) - id = id.to_s.gsub(/-\d{12}\z/, '').gsub('-', '/') + id = id.to_s.gsub(/-+\d{9,12}\z/, '') id.classify.safe_constantize || id.classify.pluralize.safe_constantize end
Fixed find_datatable, take multiple - symbols into account
diff --git a/tcpip/transport/tcp/endpoint.go b/tcpip/transport/tcp/endpoint.go index <HASH>..<HASH> 100644 --- a/tcpip/transport/tcp/endpoint.go +++ b/tcpip/transport/tcp/endpoint.go @@ -1164,9 +1164,12 @@ func (e *endpoint) HandleControlPacket(id stack.TransportEndpointID, typ stack.C // in the send buffer. The number of newly available bytes is v. func (e *endpoint) updateSndBufferUsage(v int) { e.sndBufMu.Lock() - notify := e.sndBufUsed >= e.sndBufSize + notify := e.sndBufUsed >= e.sndBufSize>>1 e.sndBufUsed -= v - notify = notify && e.sndBufUsed < e.sndBufSize + // We only notify when there is half the sndBufSize available after + // a full buffer event occurs. This ensures that we don't wake up + // writers to queue just 1-2 segments and go back to sleep. + notify = notify && e.sndBufUsed < e.sndBufSize>>1 e.sndBufMu.Unlock() if notify {
Change the wakeup policy for waiters. It ensures that we don't wake up waiters everytime a single segment or two are drained from the send queue. After a full sndbuf we let the available space drop to half the sndbuf size before waking up waiters. PiperOrigin-RevId: <I>
diff --git a/pyfakefs/fake_filesystem.py b/pyfakefs/fake_filesystem.py index <HASH>..<HASH> 100644 --- a/pyfakefs/fake_filesystem.py +++ b/pyfakefs/fake_filesystem.py @@ -360,6 +360,7 @@ class FakeFile(object): def set_contents(self, contents, encoding=None): """Sets the file contents and size and increases the modification time. + Also executes the side_effects if available. Args: contents: (str, bytes, unicode) new content of file.
Added mention of side_effects in set_contents docstring
diff --git a/jre_emul/Tests/java/lang/ThrowableTest.java b/jre_emul/Tests/java/lang/ThrowableTest.java index <HASH>..<HASH> 100644 --- a/jre_emul/Tests/java/lang/ThrowableTest.java +++ b/jre_emul/Tests/java/lang/ThrowableTest.java @@ -67,7 +67,7 @@ public class ThrowableTest extends TestCase { testException.printStackTrace(out); out.flush(); String trace = baos.toString("UTF-8"); - assertTrue(trace.contains("[JavaLangThrowableTest testStackTraceWithPrintStream]")); + assertTrue(trace.contains("JavaLangThrowableTest.testStackTraceWithPrintStream()")); } public void testStackTraceWithPrintWriter() throws Exception { @@ -77,6 +77,6 @@ public class ThrowableTest extends TestCase { testException.printStackTrace(out); out.flush(); String trace = sw.toString(); - assertTrue(trace.contains("[JavaLangThrowableTest testStackTraceWithPrintWriter]")); + assertTrue(trace.contains("JavaLangThrowableTest.testStackTraceWithPrintWriter()")); } }
Fixed expected stacktrace output in tests.
diff --git a/index.js b/index.js index <HASH>..<HASH> 100644 --- a/index.js +++ b/index.js @@ -1,7 +1,7 @@ var stream = require('readable-stream') var util = require('util') -var SIGNAL_END = new Buffer(0) +var SIGNAL_END = new Buffer([0]) module.exports = MultiWrite
use none-empty buffer for signalling
diff --git a/setup.py b/setup.py index <HASH>..<HASH> 100644 --- a/setup.py +++ b/setup.py @@ -17,22 +17,6 @@ import sys from setuptools import setup, find_packages -mainscript = "pylon/main.py" - -if sys.platform == "darwin": - extra_opts = {"app": [mainscript], - "setup_requires": ["py2app"], - "options": {"py2app": {"argv_emulation": True, -# "plist": {"LSPrefersPPC": True}, - "packages": ["numpy", "scipy"], - "includes": ["pips", "pyparsing"]}}} -elif sys.platform == "win32": - extra_opts = {"app": [mainscript], - "setup_requires": ["py2exe"]} -else: - extra_opts = {} - - setup(author="Richard Lincoln", author_email="r.w.lincoln@gmail.com", description="Port of MATPOWER to Python.", @@ -47,7 +31,6 @@ setup(author="Richard Lincoln", packages=["pylon", "pylon.readwrite", "pylon.test"],#find_packages(), py_modules=["pips"], test_suite="pylon.test", - zip_safe=True, - **extra_opts) + zip_safe=True) # EOF -------------------------------------------------------------------------
Removing py2exe and py2app dependencies.
diff --git a/tests/integration/states/test_network.py b/tests/integration/states/test_network.py index <HASH>..<HASH> 100644 --- a/tests/integration/states/test_network.py +++ b/tests/integration/states/test_network.py @@ -1,14 +1,10 @@ -# -*- encoding: utf-8 -*- """ :codeauthor: :email: `Justin Anderson <janderson@saltstack.com>` tests.integration.states.network ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ """ -# Python libs -from __future__ import absolute_import, print_function, unicode_literals -# Import salt testing libs from tests.support.case import ModuleCase from tests.support.helpers import destructiveTest, slowTest from tests.support.mixins import SaltReturnAssertsMixin @@ -63,7 +59,7 @@ class NetworkTest(ModuleCase, SaltReturnAssertsMixin): global_settings = self.run_function("ip.get_network_settings") ret = self.run_function("state.sls", mods="network.system", test=True) self.assertIn( - "Global network settings are set to be {0}".format( + "Global network settings are set to be {}".format( "added" if not global_settings else "updated" ), ret[state_key]["comment"],
Drop Py2 and six on tests/integration/states/test_network.py
diff --git a/src/core.js b/src/core.js index <HASH>..<HASH> 100644 --- a/src/core.js +++ b/src/core.js @@ -945,7 +945,7 @@ jQuery.extend({ context = context || document; // !context.createElement fails in IE with an error but returns typeof 'object' - if ( context.createElement === undefined ) + if ( typeof context.createElement === "undefined" ) context = context.ownerDocument || context[0] && context[0].ownerDocument || document; jQuery.each(elems, function(i, elem){
IE doesn't care for boolean checks of .createElement - reverted back to using typeof instead.
diff --git a/morphia/src/main/java/org/mongodb/morphia/DatastoreImpl.java b/morphia/src/main/java/org/mongodb/morphia/DatastoreImpl.java index <HASH>..<HASH> 100644 --- a/morphia/src/main/java/org/mongodb/morphia/DatastoreImpl.java +++ b/morphia/src/main/java/org/mongodb/morphia/DatastoreImpl.java @@ -435,7 +435,7 @@ public class DatastoreImpl implements AdvancedDatastore { final DBObject dbResult = database.command(BasicDBObjectBuilder.start("collstats", collName).get()); if (dbResult.containsField("capped")) { // TODO: check the cap options. - LOG.warning("DBCollection already exists is capped already; doing nothing. " + dbResult); + LOG.debug("DBCollection already exists and is capped already; doing nothing. " + dbResult); } else { LOG.warning("DBCollection already exists with same name(" + collName + ") and is not capped; not creating capped version!");
Downgrade from WARN to DEBUG message about capped collection existing Sample warning being changed to debug level: WARN org.mongodb.morphia.DatastoreImpl: DBCollection already exists is capped already; doing nothing. This should not be a warning as there is no problem. The DBCollection will already exist on every application startup except the first one. Also fixes grammar of the log message. Fixes Morphia issue [#<I>](<URL>)
diff --git a/tests/index.js b/tests/index.js index <HASH>..<HASH> 100644 --- a/tests/index.js +++ b/tests/index.js @@ -676,7 +676,8 @@ describe('inputNumber', () => { }); // https://github.com/ant-design/ant-design/issues/5012 - it('controller InputNumber should be able to input number like 1.00*', () => { + // https://github.com/react-component/input-number/issues/64 + it('controller InputNumber should be able to input number like 1.00* and 1.10*', () => { let num; const Demo = createReactClass({ getInitialState() { @@ -706,6 +707,13 @@ describe('inputNumber', () => { Simulate.blur(inputElement); expect(inputElement.value).to.be('6'); expect(num).to.be(6); + Simulate.focus(inputElement); + Simulate.change(inputElement, { target: { value: '6.10' } }); + expect(inputElement.value).to.be('6.10'); + expect(num).to.be('6.10'); + Simulate.blur(inputElement); + expect(inputElement.value).to.be('6.1'); + expect(num).to.be(6.1); }); it('onChange should not be called when input is not changed', () => {
test: add test for #<I>
diff --git a/app/search_engines/bento_search/google_site_search_engine.rb b/app/search_engines/bento_search/google_site_search_engine.rb index <HASH>..<HASH> 100644 --- a/app/search_engines/bento_search/google_site_search_engine.rb +++ b/app/search_engines/bento_search/google_site_search_engine.rb @@ -99,7 +99,7 @@ class BentoSearch::GoogleSiteSearchEngine 10 end - def self.required_configuation + def self.required_configuration [:api_key, :cx] end
google_site, typo in #required_configuration class method
diff --git a/cmd/torrent/main.go b/cmd/torrent/main.go index <HASH>..<HASH> 100644 --- a/cmd/torrent/main.go +++ b/cmd/torrent/main.go @@ -100,7 +100,9 @@ func addTorrents(client *torrent.Client) error { return nil, xerrors.Errorf("error loading torrent file %q: %s\n", arg, err) } t, err := client.AddTorrent(metaInfo) - return nil, xerrors.Errorf("adding torrent: %w", err) + if err != nil { + return nil, xerrors.Errorf("adding torrent: %w", err) + } return t, nil } }()
fix if statement in `cmd/torrent/main.go` (#<I>)
diff --git a/packages/nexrender-core/src/tasks/render.js b/packages/nexrender-core/src/tasks/render.js index <HASH>..<HASH> 100644 --- a/packages/nexrender-core/src/tasks/render.js +++ b/packages/nexrender-core/src/tasks/render.js @@ -70,8 +70,10 @@ module.exports = (job, settings) => { return new Promise((resolve, reject) => { renderStopwatch = Date.now(); - const instance = spawn(settings.binary, params); const output = []; + const instance = spawn(settings.binary, params, { + env: { PATH: path.dirname(settings.binary) }, + }); instance.on('error', err => reject(new Error(`Error starting aerender process: ${err}`))); instance.stdout.on('data', (data) => output.push(parse(data.toString('utf8'))));
added fix by @ddcrobert from #<I>, focring PATH for arender
diff --git a/core/View.php b/core/View.php index <HASH>..<HASH> 100644 --- a/core/View.php +++ b/core/View.php @@ -50,7 +50,7 @@ class Piwik_View implements Piwik_iView } $this->smarty->template_dir = $smConf->template_dir->toArray(); - array_walk($this->smarty->template_dir, array("Piwik_View","addPiwikPath"), PIWIK_USER_PATH); + array_walk($this->smarty->template_dir, array("Piwik_View","addPiwikPath"), PIWIK_INCLUDE_PATH); $this->smarty->plugins_dir = $smConf->plugins_dir->toArray(); array_walk($this->smarty->plugins_dir, array("Piwik_View","addPiwikPath"), PIWIK_INCLUDE_PATH);
fix 'unable to read resource' error (should have used PIWIK_INCLUDE_PATH here) git-svn-id: <URL>
diff --git a/symbionts/custom-metadata/js/custom-metadata-manager.js b/symbionts/custom-metadata/js/custom-metadata-manager.js index <HASH>..<HASH> 100644 --- a/symbionts/custom-metadata/js/custom-metadata-manager.js +++ b/symbionts/custom-metadata/js/custom-metadata-manager.js @@ -177,13 +177,15 @@ // init the datepicker fields $( '.custom-metadata-field.datepicker' ).find( 'input' ).datepicker({ changeMonth: true, - changeYear: true + changeYear: true, + dateFormat: 'mm/dd/yy' }); // init the datetimepicker fields $( '.custom-metadata-field.datetimepicker' ).find( 'input' ).datetimepicker({ changeMonth: true, - changeYear: true + changeYear: true, + dateFormat: 'mm/dd/yy' }); // init the timepicker fields
Publication date not saving (fixes #<I>) (#<I>) The custom metadata plugin we use formats dates like: `date( 'm/d/Y', $v ) )` This sometimes conflicts with `wp_localize_jquery_ui_datepicker`, espcially when not in english.
diff --git a/setup.py b/setup.py index <HASH>..<HASH> 100644 --- a/setup.py +++ b/setup.py @@ -17,7 +17,11 @@ coffee_files = [ 'struct.coffee', 'class.coffee', 'namespace.coffee', - 'typedef.coffee' + 'typedef.coffee', + 'variable.coffee', + 'function.coffee', + 'field.coffee', + 'constructor.coffee' ] class cldoc_build(build):
Added missing coffee files to setup.py
diff --git a/packages/list-view/lib/list_item_view.js b/packages/list-view/lib/list_item_view.js index <HASH>..<HASH> 100644 --- a/packages/list-view/lib/list_item_view.js +++ b/packages/list-view/lib/list_item_view.js @@ -65,7 +65,9 @@ function rerender() { set(this, 'element', element); - this.transitionTo('inDOM'); + var transitionTo = this._transitionTo ? this._transitionTo : this.transitionTo; + + transitionTo.call(this, 'inDOM'); if (hasChildViews) { this.invokeRecursively(didInsertElementIfNeeded, false);
[fixes #<I>] support both new and old transitionTo method
diff --git a/packages/cli/tests/watch.test.js b/packages/cli/tests/watch.test.js index <HASH>..<HASH> 100644 --- a/packages/cli/tests/watch.test.js +++ b/packages/cli/tests/watch.test.js @@ -89,7 +89,7 @@ describe('should determine the correct port', () => { expect(await determinePort('3999')).toBe(3999); }); - it('should use $PORT in the abscence of --port', async () => { + it('should use $PORT in the absence of --port', async () => { process.env.PORT = '4001'; expect(await determinePort()).toBe(4001); }); @@ -105,14 +105,10 @@ describe('should determine the correct port', () => { }); it('should return an error if requested --port is taken', async () => { - await Promise.all([determinePort(4003), determinePort(4003)]).catch( - error => { - expect(error.message).toMatch( - new RegExp( - /^Another process is already running on port 4003. Please choose a different port./g - ) - ); - } + expect( + Promise.all([determinePort(4003), determinePort(4003)]) + ).rejects.toThrow( + 'Another process is already running on port 4003. Please choose a different port.' ); });
fix silent failing test (#<I>)
diff --git a/library/CM/View/Abstract.js b/library/CM/View/Abstract.js index <HASH>..<HASH> 100644 --- a/library/CM/View/Abstract.js +++ b/library/CM/View/Abstract.js @@ -153,10 +153,9 @@ var CM_View_Abstract = Backbone.View.extend({ * @param {Boolean} [skipTriggerRemove] */ remove: function(skipDomRemoval, skipTriggerRemove) { - this.trigger('destruct'); - if (!skipTriggerRemove) { - this.trigger('remove'); - } + _.each(_.clone(this.getChildren()), function(child) { + child.remove(); + }); if (this.getParent()) { var siblings = this.getParent().getChildren(); @@ -167,12 +166,13 @@ var CM_View_Abstract = Backbone.View.extend({ } } - _.each(_.clone(this.getChildren()), function(child) { - child.remove(); - }); - delete cm.views[this.getAutoId()]; + this.trigger('destruct'); + if (!skipTriggerRemove) { + this.trigger('remove'); + } + if (!skipDomRemoval) { this.$el.remove(); }
Move destruct/remove triggers after removal of children views
diff --git a/src/DataTable/utils/routeDoubleClick.js b/src/DataTable/utils/routeDoubleClick.js index <HASH>..<HASH> 100644 --- a/src/DataTable/utils/routeDoubleClick.js +++ b/src/DataTable/utils/routeDoubleClick.js @@ -1,8 +1,10 @@ import pluralize from "pluralize"; +import { kebabCase } from "lodash"; + export default function routeDoubleClick(row, rowIndex, history) { - const recordType = row["__typename"]; + const recordType = row["__typename"] || ""; const recordId = row["dbId"] || row["id"]; - const route = "/" + pluralize(recordType) + "/" + recordId; + const route = "/" + pluralize(kebabCase(recordType)) + "/" + recordId; history ? history.push(route) : console.warn("react router history not passed to datatable");
update route double click for kebab case routes
diff --git a/src/test/UberTestCase3.java b/src/test/UberTestCase3.java index <HASH>..<HASH> 100644 --- a/src/test/UberTestCase3.java +++ b/src/test/UberTestCase3.java @@ -11,7 +11,7 @@ import groovy.util.AllTestSuite; public class UberTestCase3 extends TestCase { public static Test suite() { - return AllTestSuite.suite("src/test/groovy", "*/**Test.groovy"); + return AllTestSuite.suite("src/test/groovy", "*/**/*Test.groovy"); } // no tests inside (should we have an AbstractGroovyTestCase???)
GROOVY-<I>: UTC3 seems to have been missing some tests git-svn-id: <URL>
diff --git a/examples/simple_app.py b/examples/simple_app.py index <HASH>..<HASH> 100644 --- a/examples/simple_app.py +++ b/examples/simple_app.py @@ -18,9 +18,7 @@ from remi import start, App class MyApp(App): def __init__(self, *args): - kwargs = {k:k for k in ('js_body_end', 'css_head', 'html_head', 'html_body_start', 'html_body_end', 'js_body_start', 'js_head')} - kwargs['js_body_end'] = ('js_body_end1','js_body_end2') - super(MyApp, self).__init__(*args, **kwargs) + super(MyApp, self).__init__(*args) def main(self, name='world'): # the arguments are width - height - layoutOrientationOrizontal
sample_app: rm code accidentally added in #<I>e<I>
diff --git a/lib/ImageHelper.php b/lib/ImageHelper.php index <HASH>..<HASH> 100644 --- a/lib/ImageHelper.php +++ b/lib/ImageHelper.php @@ -308,7 +308,7 @@ class ImageHelper { protected static function process_delete_generated_files( $filename, $ext, $dir, $search_pattern, $match_pattern = null ) { $searcher = '/'.$filename.$search_pattern; $files = glob($dir.$searcher); - if ( $files === false ) { + if ( $files === false || empty($files) ) { return; } foreach ( $files as $found_file ) { diff --git a/tests/test-timber-image-helper.php b/tests/test-timber-image-helper.php index <HASH>..<HASH> 100644 --- a/tests/test-timber-image-helper.php +++ b/tests/test-timber-image-helper.php @@ -72,6 +72,12 @@ $exists = file_exists( $resized_path ); $this->assertTrue( $exists ); } + /** + * @doesNotPerformAssertions + */ + function testDeleteFalseFile() { + TimberImageHelper::delete_generated_files('/etc/www/image.jpg'); + } function testLetterbox() { $file_loc = TestTimberImage::copyTestImage( 'eastern.jpg' );
ref #<I> -- try hitting false to confirm functionality
diff --git a/cmd/viewcore/main.go b/cmd/viewcore/main.go index <HASH>..<HASH> 100644 --- a/cmd/viewcore/main.go +++ b/cmd/viewcore/main.go @@ -286,7 +286,13 @@ func runRoot(cmd *cobra.Command, args []string) { // Create a dummy root to run in shell. root := &cobra.Command{} // Make all subcommands of viewcore available in the shell. - root.AddCommand(cmd.Commands()...) + for _, subcmd := range cmd.Commands() { + if subcmd.Name() == "help" { + root.SetHelpCommand(subcmd) + continue + } + root.AddCommand(subcmd) + } // Also, add exit command to terminate the shell. root.AddCommand(&cobra.Command{ Use: "exit",
cmd/viewcore: dedup 'help' subcommand in interactive mode Available commands will stop printing 'help' subcommand twice. Change-Id: Ibf<I>cda<I>a<I>fa6a<I>b8c<I>a<I>f2ec Reviewed-on: <URL>
diff --git a/mpd.py b/mpd.py index <HASH>..<HASH> 100644 --- a/mpd.py +++ b/mpd.py @@ -23,6 +23,12 @@ ERROR_PREFIX = "ACK " SUCCESS = "OK" NEXT = "list_OK" +try: + # workaround to get unicode strings in all python versions + str = unicode +except NameError: + pass + class MPDError(Exception): pass diff --git a/test.py b/test.py index <HASH>..<HASH> 100755 --- a/test.py +++ b/test.py @@ -151,7 +151,11 @@ class TestMPDClient(unittest.TestCase): self.assertFalse(imple_cmds - avaible_cmds, long_desc) def test_unicode_in_command_args(self): - self.assertIsInstance(self.client.find("file", "☯☾☝♖✽"), list) + if sys.version_info < (3, 0): + arg = "☯☾☝♖✽".decode("utf-8") + else: + arg = "☯☾☝♖✽" + self.assertIsInstance(self.client.find("file",arg), list) if __name__ == '__main__': unittest.main()
Fix crash when sending unicode strings to socket It's only an issue with Python 2: it would try to coerce the Unicode string to ASCII, which will not work unless all characters are part of ASCII. Overwrite str() with unicode() in python 2.x, solve this. Fix issue #4
diff --git a/integration-test/lolex-integration-test.js b/integration-test/lolex-integration-test.js index <HASH>..<HASH> 100644 --- a/integration-test/lolex-integration-test.js +++ b/integration-test/lolex-integration-test.js @@ -48,4 +48,14 @@ describe("withGlobal", function () { clock.uninstall(); }); + + it("Date is instanceof itself", function () { + assert(new jsdomGlobal.Date() instanceof jsdomGlobal.Date); + + var clock = withGlobal.install({target: jsdomGlobal, toFake: timers}); + + assert(new jsdomGlobal.Date() instanceof jsdomGlobal.Date); + + clock.uninstall(); + }); }); diff --git a/src/lolex-src.js b/src/lolex-src.js index <HASH>..<HASH> 100644 --- a/src/lolex-src.js +++ b/src/lolex-src.js @@ -41,7 +41,7 @@ function withGlobal(_global) { _global.clearTimeout(timeoutResult); - var NativeDate = Date; + var NativeDate = _global.Date; var uniqueTimerId = 1; function isNumberFinite(num) {
Access Date on `_global`
diff --git a/lib/qizer.js b/lib/qizer.js index <HASH>..<HASH> 100644 --- a/lib/qizer.js +++ b/lib/qizer.js @@ -10,6 +10,9 @@ module.exports = function (Promise) { }); q.when = function (p) { return ( p && p.then ) ? p : Promise.resolve(p); }; + q.usePolyfill = function () { + Promise = require('./promise-polyfill'); + }; return q;
added .usePolyfill()
diff --git a/lib/loop.js b/lib/loop.js index <HASH>..<HASH> 100644 --- a/lib/loop.js +++ b/lib/loop.js @@ -3,8 +3,6 @@ var EventEmitter = require('events').EventEmitter; var _ = require('lodash'); var clock = require('./clock')(); -var instance; - var start = function( loop, clock ) { return function() { @@ -29,7 +27,6 @@ var createLoop = function( emitter, clock, customizeEvent ) { return function runLoop() { this.rafHandle = raf( runLoop.bind(this) ); - console.log( this.rafHandle ); var dt = clock.delta(); var event = customizeEvent({ @@ -49,7 +46,6 @@ var createLoop = function( emitter, clock, customizeEvent ) { var passThrough = function( a ) { return a; }; module.exports = function configurePoemLoop( properties ) { - var config = _.extend({ emitter: new EventEmitter(), @@ -62,8 +58,6 @@ module.exports = function configurePoemLoop( properties ) { rafHandle: null }); - instance = state; - var loop = createLoop( config.emitter, clock,
Removed some errant debug code
diff --git a/cobra/test/solvers.py b/cobra/test/solvers.py index <HASH>..<HASH> 100644 --- a/cobra/test/solvers.py +++ b/cobra/test/solvers.py @@ -199,8 +199,9 @@ def add_new_test(TestCobraSolver, solver_name, solver): Cone_production.add_metabolites({production_capacity_constraint: cone_production_cost }) Popsicle_production.add_metabolites({production_capacity_constraint: popsicle_production_cost }) - cobra_model.optimize() + cobra_model.optimize(solver=solver_name) self.assertEqual(133, cobra_model.solution.f) + self.assertEqual(33, cobra_model.solution.x_dict["Cone_consumption"]) def solve_infeasible(self): solver.solve(self.infeasible_model)
fix testing of mip solvers
diff --git a/packages/ra-core/src/sideEffect/undo.js b/packages/ra-core/src/sideEffect/undo.js index <HASH>..<HASH> 100644 --- a/packages/ra-core/src/sideEffect/undo.js +++ b/packages/ra-core/src/sideEffect/undo.js @@ -34,7 +34,10 @@ export function* handleUndoRace(undoableAction) { // if not cancelled, redispatch the action, this time immediate, and without success side effect yield put({ ...action, - meta: metaWithoutSuccessSideEffects, + meta: { + ...metaWithoutSuccessSideEffects, + onSuccess: { refresh: true }, + }, }); } else { yield put(showNotification('ra.notification.canceled'));
Force refresh once a server action succeeds Closes #<I>
diff --git a/src/main/java/org/springframework/social/evernote/api/StoreClientHolder.java b/src/main/java/org/springframework/social/evernote/api/StoreClientHolder.java index <HASH>..<HASH> 100644 --- a/src/main/java/org/springframework/social/evernote/api/StoreClientHolder.java +++ b/src/main/java/org/springframework/social/evernote/api/StoreClientHolder.java @@ -1,8 +1,10 @@ package org.springframework.social.evernote.api; +import org.springframework.aop.RawTargetAccess; + /** * @author Tadaya Tsuyukubo */ -public interface StoreClientHolder { +public interface StoreClientHolder extends RawTargetAccess { <T> T getStoreClient(); }
add RawTargetAccess marker to work with proxy object
diff --git a/builder/vsphere/common/config_location.go b/builder/vsphere/common/config_location.go index <HASH>..<HASH> 100644 --- a/builder/vsphere/common/config_location.go +++ b/builder/vsphere/common/config_location.go @@ -3,7 +3,11 @@ package common -import "fmt" +import ( + "fmt" + "path" + "strings" +) type LocationConfig struct { // Name of the new VM to create. @@ -38,5 +42,9 @@ func (c *LocationConfig) Prepare() []error { errs = append(errs, fmt.Errorf("'host' or 'cluster' is required")) } + // clean Folder path and remove leading slash as folders are relative within vsphere + c.Folder = path.Clean(c.Folder) + c.Folder = strings.TrimLeft(c.Folder, "/") + return errs }
clean up folder path so that it is what vsphere expects
diff --git a/test/config.js b/test/config.js index <HASH>..<HASH> 100644 --- a/test/config.js +++ b/test/config.js @@ -1,6 +1,6 @@ require('chai').should(); -describe.only('the ghapi.json config file', function(){ +describe('the ghapi.json config file', function(){ 'use strict'; var Request = require('../lib/utils/request'),
Removing the .only flag from config tests.
diff --git a/fs/inode/dir.go b/fs/inode/dir.go index <HASH>..<HASH> 100644 --- a/fs/inode/dir.go +++ b/fs/inode/dir.go @@ -437,11 +437,15 @@ func (d *DirInode) LookUpChild( o = fileRecord } - // TODO(jacobsa): Update the cache to say file here if fileRecord != nil - panic("TODO") + // Update the cache. + now = time.Now() + if fileRecord != nil { + d.cache.NoteFile(now, name) + } - // TODO(jacobsa): Update the cache to say dir here if dirRecord != nil - panic("TODO") + if dirRecord != nil { + d.cache.NoteDir(now, name) + } return }
Update the type cache in LookUpChild.
diff --git a/db_tests/db_loader_unittest.py b/db_tests/db_loader_unittest.py index <HASH>..<HASH> 100644 --- a/db_tests/db_loader_unittest.py +++ b/db_tests/db_loader_unittest.py @@ -103,6 +103,13 @@ class NrmlModelLoaderDBTestCase(unittest.TestCase): class CsvModelLoaderDBTestCase(unittest.TestCase): + def setUp(self): + csv_file = "ISC_sampledata1.csv" + self.csv_path = helpers.get_data_path(csv_file) + self.db_loader = db_loader.CsvModelLoader(self.csv_path, None, 'eqcat') + self.db_loader._read_model() + self.csv_reader = self.db_loader.csv_reader + def test_csv_to_db_loader_end_to_end(self): """ * Serializes the csv into the database
added missing setUp method, probably merging conflicts has broken something Former-commit-id: <I>d<I>ddd<I>a<I>fd<I>ce8fd7b3c0a<I>e<I>
diff --git a/trie.go b/trie.go index <HASH>..<HASH> 100644 --- a/trie.go +++ b/trie.go @@ -284,6 +284,9 @@ func (p *prefixTrie) remove(network rnet.Network) (RangerEntry, error) { } return entry, nil } + if p.targetBitPosition() < 0 { + return nil, nil + } bit, err := p.targetBitFromIP(network.Number) if err != nil { return nil, err diff --git a/trie_test.go b/trie_test.go index <HASH>..<HASH> 100644 --- a/trie_test.go +++ b/trie_test.go @@ -137,6 +137,16 @@ func TestPrefixTrieRemove(t *testing.T) { }, { rnet.IPv4, + []string{"192.168.0.1/32"}, + []string{"192.168.0.1/24"}, + []string{""}, + []string{"192.168.0.1/32"}, + `0.0.0.0/0 (target_pos:31:has_entry:false) +| 1--> 192.168.0.1/32 (target_pos:-1:has_entry:true)`, + "remove from ranger that contains a single ip block", + }, + { + rnet.IPv4, []string{"1.2.3.4/32", "1.2.3.5/32"}, []string{"1.2.3.5/32"}, []string{"1.2.3.5/32"},
Prevent checking beyond lsb in a network in a remove call (#<I>)
diff --git a/question/type/shortanswer/edit_shortanswer_form.php b/question/type/shortanswer/edit_shortanswer_form.php index <HASH>..<HASH> 100644 --- a/question/type/shortanswer/edit_shortanswer_form.php +++ b/question/type/shortanswer/edit_shortanswer_form.php @@ -68,13 +68,10 @@ class question_edit_shortanswer_form extends question_edit_form { $answers = $data['answer']; $answercount = 0; $maxgrade = false; - foreach ($answers as $key => $answer){ + foreach ($answers as $key => $answer) { $trimmedanswer = trim($answer); if (!empty($trimmedanswer)){ $answercount++; - } - // Check grades - if ($answer != '') { if ($data['fraction'][$key] == 1) { $maxgrade = true; }
Minor improvement to validation code. Merged from MOODLE_<I>_STABLE.
diff --git a/tools/TestProcedureDoc/generateTestCampaignDoc.py b/tools/TestProcedureDoc/generateTestCampaignDoc.py index <HASH>..<HASH> 100644 --- a/tools/TestProcedureDoc/generateTestCampaignDoc.py +++ b/tools/TestProcedureDoc/generateTestCampaignDoc.py @@ -200,7 +200,7 @@ def aggregateTestCaseDoc(testCaseName, testCaseDir, selectedRows, selectedRowsFo if tag == "th": et.SubElement(trElem, tag, {'width':'3%'}).text = 'Result' elif tag == "td": - et.SubElement(trElem, tag).text = ' ' # non-breakable space + et.SubElement(trElem, tag).text = u'\u00A0' # non-breakable space testStepsTable = et.tostring(testStepsTableHtmlTree, 'utf-8') if DUPLICATE_STEPS_PER_TEST_DATA_ROW: contentBeforeSteps = content[:testStepsTableMatch.start(0)]
Issue #<I>: use real non-breakable space, not normal whitespace
diff --git a/test/unit/rubyext_test.rb b/test/unit/rubyext_test.rb index <HASH>..<HASH> 100644 --- a/test/unit/rubyext_test.rb +++ b/test/unit/rubyext_test.rb @@ -22,8 +22,7 @@ module Tire end - should "have a to_json method from Yajl" do - assert defined?(Yajl) + should "have a to_json method from a JSON serialization library" do assert_respond_to( {}, :to_json ) assert_equal '{"one":1}', { :one => 1}.to_json end
[TEST] Do not test for `Yajl` presence (eg. on jRuby)
diff --git a/lark/load_grammar.py b/lark/load_grammar.py index <HASH>..<HASH> 100644 --- a/lark/load_grammar.py +++ b/lark/load_grammar.py @@ -511,12 +511,12 @@ class Grammar: simplify_rule = SimplifyRule_Visitor() compiled_rules = [] - for i, rule_content in enumerate(rules): + for rule_content in rules: name, tree, options = rule_content simplify_rule.visit(tree) expansions = rule_tree_to_text.transform(tree) - for expansion, alias in expansions: + for i, (expansion, alias) in enumerate(expansions): if alias and name.startswith('_'): raise GrammarError("Rule %s is marked for expansion (it starts with an underscore) and isn't allowed to have aliases (alias=%s)" % (name, alias))
Fix Earley non-determinism Rule.order should be set as the index of each expansion with rules of the same name (e.g: a : b # rule.order 1 | c # rule.order 2).
diff --git a/src/test/groovy/security/SignedJarTest.java b/src/test/groovy/security/SignedJarTest.java index <HASH>..<HASH> 100644 --- a/src/test/groovy/security/SignedJarTest.java +++ b/src/test/groovy/security/SignedJarTest.java @@ -40,4 +40,4 @@ public class SignedJarTest extends SecurityTestSupport { executeTest(c, null); } -} \ No newline at end of file +}
Dummy commit on SignedJarTest to see whether BeetleJuice has badly checked out the file or something? git-svn-id: <URL>
diff --git a/livetests.py b/livetests.py index <HASH>..<HASH> 100755 --- a/livetests.py +++ b/livetests.py @@ -52,7 +52,7 @@ def _initialize(api): @pytest.fixture( - scope="module", params=["2.16.22", "3.0.13", "3.1.8", "3.2.3", "3.3.0-rc3"] + scope="module", params=["2.16.23", "3.0.13", "3.1.8", "3.2.3", "3.3.0-rc3"] ) def gerrit_api(request): """Create a Gerrit container for the given version and return an API."""
Set the <I> version in livetests
diff --git a/cli50/__main__.py b/cli50/__main__.py index <HASH>..<HASH> 100644 --- a/cli50/__main__.py +++ b/cli50/__main__.py @@ -46,7 +46,7 @@ def main(): # Check if Docker running try: - stdout = subprocess.check_call(["docker", "info"], stderr=subprocess.DEVNULL, timeout=10) + stdout = subprocess.check_call(["docker", "info"], stderr=subprocess.DEVNULL, stdout=subprocess.DEVNULL, timeout=10) except subprocess.CalledProcessError: sys.exit("Docker not running.") except subprocess.TimeoutExpired: @@ -176,7 +176,8 @@ def main(): print(ports(container)) # Let user interact with container - os.execlp("docker", "docker", "attach", container) + print(subprocess.check_output(["docker", "logs", container]).decode("utf-8"), end="") + os.execvp("docker", ["docker", "attach", container]) except (subprocess.CalledProcessError, OSError): sys.exit(1)
fixed buffering of stdout, removed docker info
diff --git a/test/StoragelessSessionTest/Http/SessionMiddlewareTest.php b/test/StoragelessSessionTest/Http/SessionMiddlewareTest.php index <HASH>..<HASH> 100644 --- a/test/StoragelessSessionTest/Http/SessionMiddlewareTest.php +++ b/test/StoragelessSessionTest/Http/SessionMiddlewareTest.php @@ -170,7 +170,7 @@ final class SessionMiddlewareTest extends PHPUnit_Framework_TestCase ->withCookieParams([ SessionMiddleware::DEFAULT_COOKIE => (string) (new Builder()) ->setExpiration((new \DateTime('+1 day'))->getTimestamp()) - ->set(SessionMiddleware::SESSION_CLAIM, DefaultSessionData::fromTokenData(['foo' => 'bar'])) + ->set(SessionMiddleware::SESSION_CLAIM, DefaultSessionData::newEmptySession()) ->sign($this->getSigner($middleware), $this->getSignatureKey($middleware)) ->getToken() ]);
Correcting test cases for when the `'iat'` claim is not available
diff --git a/strategies/kubernetes.js b/strategies/kubernetes.js index <HASH>..<HASH> 100644 --- a/strategies/kubernetes.js +++ b/strategies/kubernetes.js @@ -410,7 +410,7 @@ const engine = { options.params.variables.push('SOAJS_DEPLOY_HA=kubernetes'); let service = utils.cloneObj(require(__dirname + '/../schemas/kubernetes/service.template.js')); - service.metadata.name = options.params.name; + service.metadata.name = cleanLabel(options.params.name); if (options.params.labels['soajs.service.name'] !== 'controller') { service.metadata.name += '-service'; }
Updated kubernetes service name in deployService(), kubernetes driver
diff --git a/src/Moltin/SDK/Facade/Gateway.php b/src/Moltin/SDK/Facade/Gateway.php index <HASH>..<HASH> 100644 --- a/src/Moltin/SDK/Facade/Gateway.php +++ b/src/Moltin/SDK/Facade/Gateway.php @@ -46,7 +46,7 @@ class Gateway public static function Update($slug, $data) { - return self::$sdk->put('gateway/'.$slug, $data); + return self::$sdk->put('gateways/'.$slug, $data); } public static function Enable($slug)
Facade - Gateway Plural Update
diff --git a/lib/pod/command/lib/archive.rb b/lib/pod/command/lib/archive.rb index <HASH>..<HASH> 100644 --- a/lib/pod/command/lib/archive.rb +++ b/lib/pod/command/lib/archive.rb @@ -26,9 +26,7 @@ module Pod This tool is useful if your primary distribution mechanism is CocoaPods but a significat portion of your userbase does not yet use dependency management. Instead, they receive a closed-source version with manual integration instructions. DESC - self.arguments = [ - CLAide::Argument.new("[NAME]", :optional) - ] + self.arguments = [ ["[NAME]", :optional] ] attr_accessor :spec
Remove direct reference to CLAide::Argument
diff --git a/lib/middleware/nunjucks-configuration/nunjucks-configuration.js b/lib/middleware/nunjucks-configuration/nunjucks-configuration.js index <HASH>..<HASH> 100644 --- a/lib/middleware/nunjucks-configuration/nunjucks-configuration.js +++ b/lib/middleware/nunjucks-configuration/nunjucks-configuration.js @@ -13,6 +13,9 @@ const nunjucksHelpers = require('@ministryofjustice/fb-components/templates/nunj const cloneDeep = require('lodash.clonedeep') +const debug = require('debug') +const error = debug('runner:nunjucks-configuration:error') + let nunjucksAppEnv const nunjucksConfiguration = (app, components = [], options = {}) => { @@ -129,8 +132,7 @@ const getPageOutput = async (pageInstance, context = {}) => { const renderContext = Object.assign({}, context, { page }) nunjucksAppEnv.render(templatePath, renderContext, (err, output) => { if (err) { - // TODO: log error not console.log(err) - // console.log({templatePath, page}) + error(`${templatePath} -> ${err.message}`) reject(err) } Object.keys(sanitizeMatches).forEach(property => {
Add error logging in a place where someone said there should be error logging
diff --git a/deployments.go b/deployments.go index <HASH>..<HASH> 100644 --- a/deployments.go +++ b/deployments.go @@ -81,15 +81,23 @@ func (s *deployerService) Deploy(ctx context.Context, db *gorm.DB, opts DeployOp return r, err } + if err != nil { + return r, err + } + if s, ok := stream.(scheduler.SubscribableStream); ok { for update := range s.Subscribe() { msg := fmt.Sprintf("Status: %s", update.String()) - write(msg, opts.Output) + if err := write(msg, opts.Output); err != nil { + return r, err + } } if err := s.Error(); err != nil { msg := fmt.Sprintf("Error: %s", err.Error()) - write(msg, opts.Output) + if err := write(msg, opts.Output); err != nil { + return r, err + } } }
Handle errors before subscribing to the stream
diff --git a/plugs/message/html/render/about.js b/plugs/message/html/render/about.js index <HASH>..<HASH> 100644 --- a/plugs/message/html/render/about.js +++ b/plugs/message/html/render/about.js @@ -89,6 +89,8 @@ exports.create = function (api) { function isRenderable (msg) { if (msg.value.content.type !== 'about') return if (!ref.isFeed(msg.value.content.about)) return + var c = msg.value.content + if (!c || !c.description || !c.image || !c.name) return return true } }
don't include about messages in feed that can't be rendered currently showing as empty FeedEvent divs
diff --git a/slither/core/declarations/function.py b/slither/core/declarations/function.py index <HASH>..<HASH> 100644 --- a/slither/core/declarations/function.py +++ b/slither/core/declarations/function.py @@ -298,7 +298,7 @@ class Function(metaclass=ABCMeta): # pylint: disable=too-many-public-methods def can_send_eth(self) -> bool: """ - Check if the function can send eth + Check if the function or any internal (not external) functions called by it can send eth :return bool: """ from slither.slithir.operations import Call
improve docstring of Function.can_send_eth
diff --git a/autorun.php b/autorun.php index <HASH>..<HASH> 100644 --- a/autorun.php +++ b/autorun.php @@ -15,6 +15,13 @@ function SimpleTestAutoRunner() { global $SIMPLE_TEST_AUTORUNNER_INITIAL_CLASSES; + //are tests already executed? If yes no autorunning. + if ($ctx = SimpleTest :: getContext()) { + if ($ctx->getTest()) { + return; + } + } + $file = reset(get_included_files()); $diff_classes = array_diff(get_declared_classes(), $SIMPLE_TEST_AUTORUNNER_INITIAL_CLASSES ?
Autorunning only works when scripts are executed directly with PHP, if tests are already included into test group and executed autorunning is skipped
diff --git a/network/datadog_checks/network/network.py b/network/datadog_checks/network/network.py index <HASH>..<HASH> 100644 --- a/network/datadog_checks/network/network.py +++ b/network/datadog_checks/network/network.py @@ -243,6 +243,10 @@ class Network(AgentCheck): # Skip this network interface. return False + # adding the device to the tags as device_name is deprecated + metric_tags = [] if tags is None else tags[:] + metric_tags.append('device:{}'.format(iface)) + expected_metrics = [ 'bytes_rcvd', 'bytes_sent', @@ -257,7 +261,7 @@ class Network(AgentCheck): count = 0 for metric, val in vals_by_metric.iteritems(): - self.rate('system.net.%s' % metric, val, device_name=iface, tags=tags) + self.rate('system.net.%s' % metric, val, tags=metric_tags) count += 1 self.log.debug("tracked %s network metrics for interface %s" % (count, iface))
Adding the device to the tags as device_name is deprecated. (#<I>)
diff --git a/model/src/main/java/com/basistech/rosette/apimodel/Entity.java b/model/src/main/java/com/basistech/rosette/apimodel/Entity.java index <HASH>..<HASH> 100644 --- a/model/src/main/java/com/basistech/rosette/apimodel/Entity.java +++ b/model/src/main/java/com/basistech/rosette/apimodel/Entity.java @@ -85,7 +85,7 @@ public class Entity { /** * @return the DBpediaType */ - private final String dbpediaType; + private final List<String> dbpediaType; /** * @return the PermID
WS-<I>: DBpedia response type is now an ArrayList of Strings.
diff --git a/src/Datagrid/ProxyQuery.php b/src/Datagrid/ProxyQuery.php index <HASH>..<HASH> 100644 --- a/src/Datagrid/ProxyQuery.php +++ b/src/Datagrid/ProxyQuery.php @@ -192,7 +192,7 @@ class ProxyQuery implements ProxyQueryInterface public function execute(array $params = [], $hydrationMode = null) { // NEXT_MAJOR: Remove this check and update method signature to `execute()`. - if ([] !== $params || null !== $hydrationMode) { + if (\func_num_args() > 0) { @trigger_error(sprintf( 'Passing arguments to "%s()" is deprecated since sonata-project/doctrine-orm-admin-bundle 3.x.', __METHOD__,
Deprecate passing arguments to `ProxyQuery::execute()`, regardless its values
diff --git a/routes/api.js b/routes/api.js index <HASH>..<HASH> 100644 --- a/routes/api.js +++ b/routes/api.js @@ -613,12 +613,28 @@ var clientReg = function (req, res, next) { } if (_(params).has('logo_url')) { - // XXX: copy logo? - props.logo_url = params.logo_url; + try { + check(params.logo_url).isUrl(); + props.logo_url = params.logo_url; + } catch (e) { + next(new HTTPError("Invalid logo_url.", 400)); + return; + } } if (_(params).has('redirect_uris')) { props.redirect_uris = params.redirect_uris.split(" "); + if (!props.redirect_uris.every(function(uri) { + try { + check(uri).isUrl(); + return true; + } catch (err) { + return false; + } + })) { + next(new HTTPError("redirect_uris must be space-separated URLs.", 400)); + return; + } } if (type === 'client_associate') {
validate logo_url and redirect_uris
diff --git a/pkg/fab/events/client/client.go b/pkg/fab/events/client/client.go index <HASH>..<HASH> 100755 --- a/pkg/fab/events/client/client.go +++ b/pkg/fab/events/client/client.go @@ -120,12 +120,6 @@ func (c *Client) Close() { func (c *Client) close(force bool) bool { logger.Debug("Attempting to close event client...") - if !c.setStoppped() { - // Already stopped - logger.Debug("Client already stopped") - return true - } - if !force { // Check if there are any outstanding registrations regInfoCh := make(chan *esdispatcher.RegistrationInfo) @@ -144,6 +138,12 @@ func (c *Client) close(force bool) bool { } } + if !c.setStoppped() { + // Already stopped + logger.Debug("Client already stopped") + return true + } + logger.Debug("Stopping client...") c.closeConnectEventChan() @@ -389,6 +389,8 @@ func (c *Client) reconnect() { if err := c.connectWithRetry(c.maxReconnAttempts, c.timeBetweenConnAttempts); err != nil { logger.Warnf("Could not reconnect event client: %s. Closing.", err) c.Close() + } else { + logger.Infof("Event client has reconnected") } }
[FABG-<I>] Fix bug in check for idle event client Set the stopped flag after the check for outstanding registrations.. Change-Id: I3ebb8a4a<I>a<I>b<I>c<I>c<I>bfec8c2a8f
diff --git a/src/pywws/__init__.py b/src/pywws/__init__.py index <HASH>..<HASH> 100644 --- a/src/pywws/__init__.py +++ b/src/pywws/__init__.py @@ -1,3 +1,3 @@ __version__ = '18.4.2' -_release = '1486' -_commit = '7ef35ab' +_release = '1487' +_commit = 'd86023c' diff --git a/src/pywws/service/metoffice.py b/src/pywws/service/metoffice.py index <HASH>..<HASH> 100644 --- a/src/pywws/service/metoffice.py +++ b/src/pywws/service/metoffice.py @@ -36,7 +36,7 @@ logger = logging.getLogger(__package__ + '.' + service_name) class ToService(pywws.service.BaseToService): catchup = 7 fixed_data = {'softwaretype': 'pywws v' + pywws.__version__} - interval = timedelta(seconds=290) + interval = timedelta(seconds=300) logger = logger service_name = service_name template = """
Set metoffice interval to five minutes exactly Even a few seconds less causes the dreaded "duplicate data" messages.
diff --git a/src/main/java/javascalautils/concurrent/FutureCompanion.java b/src/main/java/javascalautils/concurrent/FutureCompanion.java index <HASH>..<HASH> 100644 --- a/src/main/java/javascalautils/concurrent/FutureCompanion.java +++ b/src/main/java/javascalautils/concurrent/FutureCompanion.java @@ -31,8 +31,8 @@ import javascalautils.ThrowableFunction0; * <pre> * import static javascalautils.FutureCompanion.Future; * - * Future&lt;Integer&gt; resultSuccess = Future.(() -&gt; 9 / 3); // The Future will at some point contain: Success(3) - * Future&lt;Integer&gt; resultFailure = Future.(() -&gt; 9 / 0); // The Future will at some point contain: Failure(ArithmeticException) + * Future&lt;Integer&gt; resultSuccess = Future(() -&gt; 9 / 3); // The Future will at some point contain: Success(3) + * Future&lt;Integer&gt; resultFailure = Future(() -&gt; 9 / 0); // The Future will at some point contain: Failure(ArithmeticException) * </pre> * * </blockquote>
corrected javadoc for FutureCompanion
diff --git a/simuvex/storage/file.py b/simuvex/storage/file.py index <HASH>..<HASH> 100644 --- a/simuvex/storage/file.py +++ b/simuvex/storage/file.py @@ -220,6 +220,10 @@ class SimFile(SimStatePlugin): [ o.content for o in others ], merge_conditions, common_ancestor=common_ancestor ) + def widen(self, others): + return self.merge(others, []) + + class SimDialogue(SimFile): """ Emulates a dialogue with a program. Enables us to perform concrete short reads.
Add a dummy implementation for widening SimFiles.
diff --git a/src/Library.php b/src/Library.php index <HASH>..<HASH> 100644 --- a/src/Library.php +++ b/src/Library.php @@ -850,7 +850,7 @@ class Library } if (is_array($value) && isset($merged[$key]) && is_array($merged[$key])) { - $merged[$key] = array_merge_recursive_distinct($merged[$key], $value); + $merged[$key] = self::array_merge_recursive_distinct($merged[$key], $value); } else { $merged[$key] = $value; }
array_merge_recursive_distinct() to self:array_merge_recursive_distinct() in Bolt\Library
diff --git a/releaf-i18n_database/app/controllers/releaf/i18n_database/translations_controller.rb b/releaf-i18n_database/app/controllers/releaf/i18n_database/translations_controller.rb index <HASH>..<HASH> 100644 --- a/releaf-i18n_database/app/controllers/releaf/i18n_database/translations_controller.rb +++ b/releaf-i18n_database/app/controllers/releaf/i18n_database/translations_controller.rb @@ -88,10 +88,12 @@ module Releaf::I18nDatabase } end + def action_views + super.merge(import: :edit) + end + def action_features - { - index: :index, - }.with_indifferent_access + {index: :index}.with_indifferent_access end private
Fix translation import style, by defining import view as edit
diff --git a/lib/autoscaling.js b/lib/autoscaling.js index <HASH>..<HASH> 100644 --- a/lib/autoscaling.js +++ b/lib/autoscaling.js @@ -92,16 +92,18 @@ module.exports = function (logger) { } ]); getParamFromParents(c, 'LoadBalancerName', function (err, loadBalancerName) { + var loadBalancerNames = []; + if (loadBalancerName) { + loadBalancerNames.push(loadBalancerName); + } var params = { AutoScalingGroupName: config.defaultGroupName || groupName, MaxSize: 3, /* required */ MinSize: 1, HealthCheckGracePeriod: 3 * 60, // three minutes, might be 5? - HealthCheckType: 'ELB', // EC2 if a parent ELB could not be found + HealthCheckType: loadBalancerName ? 'ELB' : 'EC2', // EC2 if a parent ELB could not be found LaunchConfigurationName: config.defaultLaunchName || launchName, - LoadBalancerNames: [ - loadBalancerName - ], + LoadBalancerNames: loadBalancerNames, Tags: tags, VPCZoneIdentifier: config.defaultSubnetId };
Support autoscaling groups without an ELB.
diff --git a/setup.py b/setup.py index <HASH>..<HASH> 100755 --- a/setup.py +++ b/setup.py @@ -14,6 +14,7 @@ setup( license='MIT', description='Double entry book keeping in Django', long_description=open('README.rst').read() if exists("README.rst") else "", + include_package_data=True, install_requires=[ 'django>=1.8', 'django-mptt>=0.8',
setting include_package_data=True in setup.py to ensure static files are included