diff
stringlengths
65
26.7k
message
stringlengths
7
9.92k
diff --git a/lib/joint.rb b/lib/joint.rb index <HASH>..<HASH> 100755 --- a/lib/joint.rb +++ b/lib/joint.rb @@ -49,10 +49,6 @@ module Joint @grid ||= Mongo::Grid.new(database) end - def attachments - self.class.attachment_names.map { |name| self.send(name) } - end - private def assigned_attachments @assigned_attachments ||= {} @@ -62,18 +58,12 @@ module Joint @nil_attachments ||= Set.new end - def attachment(name) - self.send(name) - end - # IO must respond to read and rewind def save_attachments assigned_attachments.each_pair do |name, io| next unless io.respond_to?(:read) - # puts "before: #{database['fs.files'].find().to_a.inspect}" - grid.delete(send(name).id) - # puts "after: #{database['fs.files'].find().to_a.inspect}" io.rewind if io.respond_to?(:rewind) + grid.delete(send(name).id) grid.put(io.read, send(name).name, { :_id => send(name).id, :content_type => send(name).type, @@ -88,7 +78,7 @@ module Joint end def destroy_all_attachments - attachments.each { |attachment| grid.delete(attachment.id) } + self.class.attachment_names.map { |name| grid.delete(send(name).id) } end end
Removed attachment and attachments methods. Really not needed.
diff --git a/Controller/CartController.php b/Controller/CartController.php index <HASH>..<HASH> 100644 --- a/Controller/CartController.php +++ b/Controller/CartController.php @@ -121,7 +121,7 @@ class CartController extends BaseFrontController */ protected function getCartEvent() { - $cart = $this->getCart($this->getRequest()); + $cart = $this->getCart($this->getDispatcher(), $this->getRequest()); return new CartEvent($cart); } diff --git a/Controller/CustomerController.php b/Controller/CustomerController.php index <HASH>..<HASH> 100644 --- a/Controller/CustomerController.php +++ b/Controller/CustomerController.php @@ -125,7 +125,7 @@ class CustomerController extends BaseFrontController $this->processLogin($customerCreateEvent->getCustomer()); - $cart = $this->getCart($this->getRequest()); + $cart = $this->getCart($this->getDispatcher(), $this->getRequest()); if ($cart->getCartItems()->count() > 0) { $this->redirectToRoute('cart.view'); } else {
Removes container from all Thelia actions, but Modules (#<I>)
diff --git a/components/hoc/Portal.js b/components/hoc/Portal.js index <HASH>..<HASH> 100644 --- a/components/hoc/Portal.js +++ b/components/hoc/Portal.js @@ -7,6 +7,7 @@ class Portal extends Component { children: PropTypes.node, className: PropTypes.string, container: PropTypes.node, + style: PropTypes.style, } static defaultProps = { @@ -55,7 +56,11 @@ class Portal extends Component { _getOverlay() { if (!this.props.children) return null; - return <div className={this.props.className}>{this.props.children}</div>; + return ( + <div className={this.props.className} style={this.props.style}> + {this.props.children} + </div> + ); } _renderOverlay() {
allows the Portal HOC root element to receive a style props. This allows coordinate runtime positioning of the portal element using top/left/bottom/right values (#<I>)
diff --git a/modules/orionode/lib/cf/apps.js b/modules/orionode/lib/cf/apps.js index <HASH>..<HASH> 100644 --- a/modules/orionode/lib/cf/apps.js +++ b/modules/orionode/lib/cf/apps.js @@ -542,7 +542,7 @@ function bindRoute(req, appTarget){ function uploadBits(req, appTarget){ var cloudAccessToken; var archiveredFilePath; - return target.getAccessToken(req.user.username) + return target.getAccessToken(req.user.username, appTarget) .then(function(token){ cloudAccessToken = token; return archiveTarget(appCache.appStore) diff --git a/modules/orionode/lib/cf/logz.js b/modules/orionode/lib/cf/logz.js index <HASH>..<HASH> 100644 --- a/modules/orionode/lib/cf/logz.js +++ b/modules/orionode/lib/cf/logz.js @@ -41,7 +41,7 @@ module.exports.router = function() { }; return target.cfRequest(null, req.user.username, infoURL, null, null, infoHeader, null, targetRequest); }).then(function(infoData) { - return target.getAccessToken(req.user.username) + return target.getAccessToken(req.user.username, targetRequest) .then(function(cloudAccessToken){ loggingEndpoint = infoData.logging_endpoint;
Bug <I> - Should pass appTarget to all getAccessToken methods.
diff --git a/tests/tests.py b/tests/tests.py index <HASH>..<HASH> 100644 --- a/tests/tests.py +++ b/tests/tests.py @@ -63,6 +63,14 @@ class FilePickerTests(FileUploadTestCase): response = self.client.get('/adminfiles/all/?field=test') self.assertContains(response, 'href="/media/adminfiles/tiny.png"') self.assertContains(response, 'href="/media/adminfiles/somefile.txt') + + def test_browser_links(self): + """ + Test correct rendering of browser links. + + """ + response = self.client.get('/adminfiles/all/?field=test') + self.assertContains(response, 'href="/adminfiles/images/?field=test') def test_images_picker_loads(self): response = self.client.get('/adminfiles/images/?field=test')
add test for issue <I>: Browsers names not showing
diff --git a/packages/backpack-core/config/webpack.config.js b/packages/backpack-core/config/webpack.config.js index <HASH>..<HASH> 100644 --- a/packages/backpack-core/config/webpack.config.js +++ b/packages/backpack-core/config/webpack.config.js @@ -125,7 +125,7 @@ module.exports = options => { 'source-map-support/register' : // It's not under the project, it's linked via lerna. require.resolve('source-map-support/register') - }')`, + }');`, }), // The FriendlyErrorsWebpackPlugin (when combined with source-maps) // gives Backpack its human-readable error messages.
Add semicolon to source-map-support banner to fix 'require() is not a function' error (#<I>)
diff --git a/psiturk/psiturk_config.py b/psiturk/psiturk_config.py index <HASH>..<HASH> 100644 --- a/psiturk/psiturk_config.py +++ b/psiturk/psiturk_config.py @@ -8,6 +8,9 @@ class PsiturkConfig(SafeConfigParser): self.parent.__init__(self, **kwargs) self.localFile = localConfig self.globalFile = os.path.expanduser(globalConfig) + # psiturkConfig contains two additional SafeConfigParser's holding the values + # of the local and global config files. This lets us write to the local or global file + # separately without writing all fields to both. self.localParser = self.parent(**kwargs) self.globalParser = self.parent(**kwargs) @@ -23,9 +26,14 @@ class PsiturkConfig(SafeConfigParser): print "No '.psiturkconfig' file found in your home directory.\nCreating default '.psiturkconfig' file." file_util.copy_file(global_defaults_file, self.globalFile) self.globalParser.read(self.globalFile) + # read default global and local, then user's global and local. This way + # any field not in the user's files will be set to the default value. self.read([global_defaults_file, local_defaults_file, self.globalFile, self.localFile]) def write(self, changeGlobal=False): + """ + write to the user's global or local config file. + """ filename = self.localFile configObject = self.localParser if changeGlobal:
add some comments to PsiturkConfig Might not be clear why things work the way they do otherwise...
diff --git a/src/uki-core/view/focusable.js b/src/uki-core/view/focusable.js index <HASH>..<HASH> 100644 --- a/src/uki-core/view/focusable.js +++ b/src/uki-core/view/focusable.js @@ -57,7 +57,7 @@ uki.view.Focusable = { if (!preCreatedInput) this.bind('mousedown', function(e) { setTimeout(uki.proxy(function() { - this._focusableInput.disabled || this._focusableInput.focus(); + try { this._focusableInput.disabled || this._focusableInput.focus(); } catch (e) {}; }, this), 1); }); }, @@ -73,7 +73,7 @@ uki.view.Focusable = { }, blur: function() { - this._focusableInput.blur() + this._focusableInput.blur(); }, hasFocus: function() {
fix: ie fails to focus sometimes
diff --git a/structr-core/src/main/java/org/structr/common/VersionHelper.java b/structr-core/src/main/java/org/structr/common/VersionHelper.java index <HASH>..<HASH> 100644 --- a/structr-core/src/main/java/org/structr/common/VersionHelper.java +++ b/structr-core/src/main/java/org/structr/common/VersionHelper.java @@ -42,7 +42,7 @@ public class VersionHelper { classPath = System.getProperty("java.class.path"); final Pattern outerPattern = Pattern.compile("(structr-[^:]*\\.jar)"); - final Pattern innerPattern = Pattern.compile("(structr-core|structr-rest|structr-ui|structr)-([^-]*(?:-SNAPSHOT|-rc\\d){0,1})-{0,1}(?:([0-9]{0,12})\\.{0,1}([0-9a-f]{0,6}))\\.jar"); + final Pattern innerPattern = Pattern.compile("(structr-core|structr-rest|structr-ui|structr)-([^-]*(?:-SNAPSHOT|-rc\\d){0,1})-{0,1}(?:([0-9]{0,12})\\.{0,1}([0-9a-f]{0,32}))\\.jar"); final Matcher outerMatcher = outerPattern.matcher(classPath);
Minor: Modifies regex to support <I> characters for short version string.
diff --git a/examples/core/parallelize.js b/examples/core/parallelize.js index <HASH>..<HASH> 100755 --- a/examples/core/parallelize.js +++ b/examples/core/parallelize.js @@ -2,10 +2,10 @@ var sc = require('skale-engine').context(); -sc.parallelize([1, 2, 3, 4], 1) +sc.parallelize([1, 2, 3, 4, 5]) .collect() .toArray(function(err, res) { console.log(res); - console.assert(JSON.stringify(res) === JSON.stringify([1, 2, 3, 4])); + console.assert(JSON.stringify(res) === JSON.stringify([1, 2, 3, 4, 5])); sc.end(); })
examples/parallelize: do not force number of partitions
diff --git a/progressbar/bar.py b/progressbar/bar.py index <HASH>..<HASH> 100644 --- a/progressbar/bar.py +++ b/progressbar/bar.py @@ -45,10 +45,12 @@ class DefaultFdMixin(ProgressBarMixinBase): def update(self, *args, **kwargs): ProgressBarMixinBase.update(self, *args, **kwargs) self.fd.write('\r' + self._format_line()) + self.fd.flush() def finish(self, *args, **kwargs): # pragma: no cover ProgressBarMixinBase.finish(self, *args, **kwargs) self.fd.write('\n') + self.fd.flush() class ResizableMixin(ProgressBarMixinBase):
made sure to flush after writing to stream
diff --git a/spyderlib/widgets/sourcecode/base.py b/spyderlib/widgets/sourcecode/base.py index <HASH>..<HASH> 100644 --- a/spyderlib/widgets/sourcecode/base.py +++ b/spyderlib/widgets/sourcecode/base.py @@ -157,10 +157,12 @@ class CompletionWidget(QListWidget): def focusOutEvent(self, event): event.ignore() + # Don't hide it on Mac when main window loses focus because + # keyboard input is lost # Fixes Issue 1318 - if (sys.platform == "darwin") and \ - (event.reason() != Qt.ActiveWindowFocusReason): - self.hide() + if sys.platform == "darwin": + if event.reason() != Qt.ActiveWindowFocusReason: + self.hide() else: self.hide()
Completion Widget: Fix revision 5a<I>a2fc1c6 because it wasn't working as expected Update Issue <I> Status: Verified - I commited the previous revision without testing, thinking that it would work without problems. - I also added a comment explaining the purpose of the change.
diff --git a/kafka/consumer/__init__.py b/kafka/consumer/__init__.py index <HASH>..<HASH> 100644 --- a/kafka/consumer/__init__.py +++ b/kafka/consumer/__init__.py @@ -1,6 +1,6 @@ from .simple import SimpleConsumer from .multiprocess import MultiProcessConsumer -from .kafka import KafkaConsumer +from .group import KafkaConsumer __all__ = [ 'SimpleConsumer', 'MultiProcessConsumer', 'KafkaConsumer'
Switch to new KafkaConsumer in module imports
diff --git a/graylog2-server/src/main/java/org/graylog2/rest/resources/users/requests/ChangePasswordRequest.java b/graylog2-server/src/main/java/org/graylog2/rest/resources/users/requests/ChangePasswordRequest.java index <HASH>..<HASH> 100644 --- a/graylog2-server/src/main/java/org/graylog2/rest/resources/users/requests/ChangePasswordRequest.java +++ b/graylog2-server/src/main/java/org/graylog2/rest/resources/users/requests/ChangePasswordRequest.java @@ -22,17 +22,20 @@ import com.fasterxml.jackson.annotation.JsonProperty; import com.google.auto.value.AutoValue; import org.hibernate.validator.constraints.NotEmpty; +import javax.annotation.Nullable; + @JsonAutoDetect @AutoValue public abstract class ChangePasswordRequest { @JsonProperty + @Nullable public abstract String oldPassword(); @JsonProperty public abstract String password(); @JsonCreator - public static ChangePasswordRequest create(@JsonProperty("old_password") @NotEmpty String oldPassword, + public static ChangePasswordRequest create(@JsonProperty("old_password") @Nullable String oldPassword, @JsonProperty("password") @NotEmpty String password) { return new AutoValue_ChangePasswordRequest(oldPassword, password); }
Relaxing constraints for old password field that might be null. Fixes Graylog2/graylog2-web-interface#<I>
diff --git a/simuvex/s_format.py b/simuvex/s_format.py index <HASH>..<HASH> 100644 --- a/simuvex/s_format.py +++ b/simuvex/s_format.py @@ -56,7 +56,7 @@ class FormatString(object): i_val = args(argpos) c_val = int(self.parser.state.se.any_int(i_val)) c_val &= (1 << (fmt_spec.size * 8)) - 1 - if fmt_spec.signed: + if fmt_spec.signed and (c_val & (1 << ((fmt_spec.size * 8) - 1))): c_val -= (1 << fmt_spec.size * 8) if fmt_spec.spec_type == 'd':
Only invert the sign of an argument if it is signed
diff --git a/src/main/java/net/bootsfaces/component/selectBooleanCheckbox/SelectBooleanCheckboxRenderer.java b/src/main/java/net/bootsfaces/component/selectBooleanCheckbox/SelectBooleanCheckboxRenderer.java index <HASH>..<HASH> 100644 --- a/src/main/java/net/bootsfaces/component/selectBooleanCheckbox/SelectBooleanCheckboxRenderer.java +++ b/src/main/java/net/bootsfaces/component/selectBooleanCheckbox/SelectBooleanCheckboxRenderer.java @@ -287,7 +287,8 @@ public class SelectBooleanCheckboxRenderer extends CoreRenderer { throws IOException { rw.startElement("input", selectBooleanCheckbox); rw.writeAttribute("name", clientId+"_helper", null); - rw.writeAttribute("value", "oxff", "value"); + rw.writeAttribute("value", "on", "value"); + rw.writeAttribute("checked", "true", "checked"); rw.writeAttribute("type", "hidden", "type"); rw.writeAttribute("style", "display:none", "style"); rw.endElement("input");
Bugfix: you couldn't uncheck a checkbox (probably this error was caused by AngularFaces)
diff --git a/SoftLayer/CLI/dedicatedhost/create_options.py b/SoftLayer/CLI/dedicatedhost/create_options.py index <HASH>..<HASH> 100644 --- a/SoftLayer/CLI/dedicatedhost/create_options.py +++ b/SoftLayer/CLI/dedicatedhost/create_options.py @@ -58,4 +58,4 @@ def cli(env, **kwargs): br_table.add_row([router['hostname']]) tables.append(br_table) - env.fout(formatting.listing(tables, separator='\n')) + env.fout(tables) diff --git a/SoftLayer/CLI/hardware/create_options.py b/SoftLayer/CLI/hardware/create_options.py index <HASH>..<HASH> 100644 --- a/SoftLayer/CLI/hardware/create_options.py +++ b/SoftLayer/CLI/hardware/create_options.py @@ -51,9 +51,7 @@ def cli(env, prices, location=None): tables.append(_port_speed_prices_table(options['port_speeds'], prices)) tables.append(_extras_prices_table(options['extras'], prices)) tables.append(_get_routers(routers)) - - # since this is multiple tables, this is required for a valid JSON object to be rendered. - env.fout(formatting.listing(tables, separator='\n')) + env.fout(tables) def _preset_prices_table(sizes, prices=False):
Change form to print the multiples tables
diff --git a/dump2polarion/dumper_cli.py b/dump2polarion/dumper_cli.py index <HASH>..<HASH> 100644 --- a/dump2polarion/dumper_cli.py +++ b/dump2polarion/dumper_cli.py @@ -129,7 +129,7 @@ def submit_if_ready(args, submit_args, config): return None # TODO: better detection of xunit file that is ready for import needed - if "<testsuites" in xml and "<properties>" not in xml: + if "<testsuites" in xml and 'name="pytest"' in xml: return None if args.no_submit:
Fix pytest junit file detection
diff --git a/lib/merb-core/core_ext/set.rb b/lib/merb-core/core_ext/set.rb index <HASH>..<HASH> 100644 --- a/lib/merb-core/core_ext/set.rb +++ b/lib/merb-core/core_ext/set.rb @@ -26,7 +26,6 @@ module Merb # SimpleSet:: The set after the Array was merged in. def merge(arr) super(arr.inject({}) {|s,x| s[x] = true; s }) - self end # ==== Returns diff --git a/spec/public/abstract_controller/controllers/helpers.rb b/spec/public/abstract_controller/controllers/helpers.rb index <HASH>..<HASH> 100644 --- a/spec/public/abstract_controller/controllers/helpers.rb +++ b/spec/public/abstract_controller/controllers/helpers.rb @@ -1,7 +1,7 @@ module Merb::Test::Fixtures module Abstract - class Testing < Merb::AbstractController + class HelperTesting < Merb::AbstractController self._template_root = File.dirname(__FILE__) / "views" def _template_location(action, type = nil, controller = controller_name) @@ -9,7 +9,7 @@ module Merb::Test::Fixtures end end - class Capture < Testing + class Capture < HelperTesting def index render end @@ -21,7 +21,7 @@ module Merb::Test::Fixtures end end - class Concat < Testing + class Concat < HelperTesting def index render end
Fixes <I> fails
diff --git a/worker/buildbot_worker/scripts/runner.py b/worker/buildbot_worker/scripts/runner.py index <HASH>..<HASH> 100644 --- a/worker/buildbot_worker/scripts/runner.py +++ b/worker/buildbot_worker/scripts/runner.py @@ -95,7 +95,7 @@ class RestartOptions(MakerBase): class UpgradeWorkerOptions(MakerBase): - subcommandFunction = "buildbot_worker.scripts.upgrade_slave.upgradeWorker" + subcommandFunction = "buildbot_worker.scripts.upgrade_worker.upgradeWorker" optFlags = [ ] optParameters = [
fix missed upgrade_slave module rename
diff --git a/tcconfig/tcshow.py b/tcconfig/tcshow.py index <HASH>..<HASH> 100644 --- a/tcconfig/tcshow.py +++ b/tcconfig/tcshow.py @@ -68,7 +68,7 @@ def main(): ).get_tc_parameter() ) except NetworkInterfaceNotFoundError as e: - logger.debug(msgfy.to_debug_message(e)) + logger.warn(e) continue command_history = "\n".join(spr.SubprocessRunner.get_history())
Change a message log level from debug to warning
diff --git a/rrrspec-web/lib/rrrspec/web/api.rb b/rrrspec-web/lib/rrrspec/web/api.rb index <HASH>..<HASH> 100644 --- a/rrrspec-web/lib/rrrspec/web/api.rb +++ b/rrrspec-web/lib/rrrspec/web/api.rb @@ -4,9 +4,12 @@ require 'oj' module RRRSpec module Web + DEFAULT_PER_PAGE = 10 + class API < Grape::API version 'v1', using: :path format :json + set :per_page, DEFAULT_PER_PAGE resource :tasksets do desc "Return active tasksets" @@ -63,6 +66,7 @@ module RRRSpec version 'v2', using: :path format :json formatter :json, OjFormatter + set :per_page, DEFAULT_PER_PAGE rescue_from(ActiveRecord::RecordNotFound) do [404, {}, ['']]
Fix default per_page for api-pagination >= <I> The default per_page value was changed from <I> to <I> since api-pagination <I>.
diff --git a/views/helpers/tinymce.php b/views/helpers/tinymce.php index <HASH>..<HASH> 100644 --- a/views/helpers/tinymce.php +++ b/views/helpers/tinymce.php @@ -97,7 +97,7 @@ class TinymceHelper extends AppHelper { $selector = "data[{$this->__modelFieldPair['model']}][{$this->__modelFieldPair['field']}]"; if (isset($options['class'])) { - $options['class'] .= $selector; + $options['class'] .= ' ' . $selector; } else { $options['class'] = $selector; } @@ -114,12 +114,12 @@ class TinymceHelper extends AppHelper { * @return string An HTML textarea element with TinyMCE */ function textarea($field, $options = array(), $tinyoptions = array()) { - $options['type'] = 'textareas'; + $options['type'] = 'textarea'; $this->__field($field); $selector = "data[{$this->__modelFieldPair['model']}][{$this->__modelFieldPair['field']}]"; if (isset($options['class'])) { - $options['class'] .= $selector; + $options['class'] .= ' ' . $selector; } else { $options['class'] = $selector; }
with options place needed space between current class setting and added and model data selector class
diff --git a/core/Version.php b/core/Version.php index <HASH>..<HASH> 100644 --- a/core/Version.php +++ b/core/Version.php @@ -1,6 +1,6 @@ <?php final class Piwik_Version { - const VERSION = '0.2.14'; + const VERSION = '0.2.16'; }
- I messed up with the version file (really need the build script to sanity check...!!) git-svn-id: <URL>
diff --git a/src/Model/Invoice.php b/src/Model/Invoice.php index <HASH>..<HASH> 100644 --- a/src/Model/Invoice.php +++ b/src/Model/Invoice.php @@ -15,6 +15,7 @@ namespace Nails\Invoice\Model; use Nails\Common\Model\Base; use Nails\Factory; use Nails\Invoice\Exception\InvoiceException; +use Nails\Invoice\Factory\Invoice\Item; class Invoice extends Base { @@ -460,6 +461,10 @@ class Invoice extends Base $aTaxIds = []; foreach ($aData['items'] as &$aItem) { + if ($aItem instanceof Item) { + $aItem = $aItem->toArray(); + } + // Has an ID or is null $aItem['id'] = !empty($aItem['id']) ? (int) $aItem['id'] : null;
Supporting using Factory Items whenc reating invoices
diff --git a/test/test_queue_consumer.py b/test/test_queue_consumer.py index <HASH>..<HASH> 100644 --- a/test/test_queue_consumer.py +++ b/test/test_queue_consumer.py @@ -299,7 +299,5 @@ def test_kill_closes_connections(rabbit_manager, rabbit_config): # kill should close all connections queue_consumer.kill(Exception('test-kill')) - def check_connections_closed(): - connections = rabbit_manager.get_connections() - assert connections is None - assert_stops_raising(check_connections_closed) + connections = rabbit_manager.get_connections() + assert connections is None
no longer need assert_stops_raising wrapper
diff --git a/gobgp/main.go b/gobgp/main.go index <HASH>..<HASH> 100644 --- a/gobgp/main.go +++ b/gobgp/main.go @@ -355,7 +355,7 @@ func (x *ShowNeighborRibCommand) Execute(args []string) error { rt = "ipv6" } } else { - rt = args[1] + rt = args[0] } b := get("neighbor/" + x.remoteIP.String() + "/" + x.resource + "/" + rt)
gobgp: fix showing rib with a specific route family
diff --git a/lib/puppet/pops/validation/checker3_1.rb b/lib/puppet/pops/validation/checker3_1.rb index <HASH>..<HASH> 100644 --- a/lib/puppet/pops/validation/checker3_1.rb +++ b/lib/puppet/pops/validation/checker3_1.rb @@ -126,7 +126,7 @@ class Puppet::Pops::Validation::Checker3_1 case o.left_expr when Model::QualifiedName # allows many keys, but the name should really be a QualifiedReference - acceptor.accept(Issues::DEPRECATED_NAME_AS_TYPE, o, :name => o.value) + acceptor.accept(Issues::DEPRECATED_NAME_AS_TYPE, o, :name => o.left_expr.value) when Model::QualifiedReference # ok, allows many - this is a resource reference
(#<I>) Fix failing validation. Validation of deprecated resource references using QualifiedName (i.e. a lower case bare word) instead of QualifiedReference (i.e. an upper cased bare word) should have accessed the `value` of the instructions `left_expr`, but instead did this on the instruction itself. This fixes one part of the issue #<I> which gives users a better clue how to work around the issue.
diff --git a/plugins/guests/redhat/cap/nfs_client.rb b/plugins/guests/redhat/cap/nfs_client.rb index <HASH>..<HASH> 100644 --- a/plugins/guests/redhat/cap/nfs_client.rb +++ b/plugins/guests/redhat/cap/nfs_client.rb @@ -4,7 +4,8 @@ module VagrantPlugins class NFSClient def self.nfs_client_install(machine) machine.communicate.tap do |comm| - comm.sudo("yum -y install nfs-utils nfs-utils-lib") + comm.sudo("yum -y install nfs-utils nfs-utils-lib avahi") + comm.sudo("/etc/init.d/rpcbind restart; /etc/init.d/nfs restart") end end end
install rpc package while installing nfs client on centos guests
diff --git a/cmd/kubeadm/app/cmd/token.go b/cmd/kubeadm/app/cmd/token.go index <HASH>..<HASH> 100644 --- a/cmd/kubeadm/app/cmd/token.go +++ b/cmd/kubeadm/app/cmd/token.go @@ -92,6 +92,9 @@ func NewCmdToken(out io.Writer, errW io.Writer) *cobra.Command { Use: "delete", Short: "Delete bootstrap tokens on the server.", Run: func(tokenCmd *cobra.Command, args []string) { + if len(args) < 1 { + kubeadmutil.CheckErr(fmt.Errorf("missing subcommand; 'token delete' is missing token of form [\"^([a-z0-9]{6})$\"]")) + } err := RunDeleteToken(out, tokenCmd, args[0]) kubeadmutil.CheckErr(err) },
kubeadm: fix to avoid panic if token not provided Prior to this, kubeadm would panic if no token was provided. This does a check and prints out a more reasonable message.
diff --git a/server/reload.go b/server/reload.go index <HASH>..<HASH> 100644 --- a/server/reload.go +++ b/server/reload.go @@ -1106,8 +1106,17 @@ func (s *Server) reloadAuthorization() { for _, route := range s.routes { routes = append(routes, route) } + var resetCh chan struct{} + if s.sys != nil { + // can't hold the lock as go routine reading it may be waiting for lock as well + resetCh = s.sys.resetCh + } s.mu.Unlock() + if resetCh != nil { + resetCh <- struct{}{} + } + // Close clients that have moved accounts for _, client := range cclients { client.closeConnection(ClientClosed) diff --git a/server/server.go b/server/server.go index <HASH>..<HASH> 100644 --- a/server/server.go +++ b/server/server.go @@ -515,8 +515,6 @@ func (s *Server) configureAccounts() error { s.mu.Unlock() // acquires server lock separately s.addSystemAccountExports(acc) - // can't hold the lock as go routine reading it may be waiting for lock as well - s.sys.resetCh <- struct{}{} s.mu.Lock() } if err != nil {
Move reset of internal client to after the account sublist was moved. This does not avoid the race condition, but makes it less likely to trigger in unit tests.
diff --git a/src/saml2/authn.py b/src/saml2/authn.py index <HASH>..<HASH> 100644 --- a/src/saml2/authn.py +++ b/src/saml2/authn.py @@ -146,7 +146,8 @@ class UsernamePasswordMako(UserAuthnMethod): return resp def _verify(self, pwd, user): - assert is_equal(pwd, self.passwd[user]) + if not is_equal(pwd, self.passwd[user]): + raise ValueError("Wrong password") def verify(self, request, **kwargs): """ @@ -176,7 +177,7 @@ class UsernamePasswordMako(UserAuthnMethod): return_to = create_return_url(self.return_to, _dict["query"][0], **{self.query_param: "true"}) resp = Redirect(return_to, headers=[cookie]) - except (AssertionError, KeyError): + except (ValueError, KeyError): resp = Unauthorized("Unknown user or wrong password") return resp
Quick fix for the authentication bypass due to optimizations #<I>
diff --git a/telethon/telegram_bare_client.py b/telethon/telegram_bare_client.py index <HASH>..<HASH> 100644 --- a/telethon/telegram_bare_client.py +++ b/telethon/telegram_bare_client.py @@ -86,7 +86,7 @@ class TelegramBareClient: if not api_id or not api_hash: raise PermissionError( "Your API ID or Hash cannot be empty or None. " - "Refer to Telethon's README.rst for more information.") + "Refer to Telethon's wiki for more information.") self._use_ipv6 = use_ipv6
Remove reference to README.rst (#<I>)
diff --git a/core/src/main/java/com/google/bitcoin/core/Peer.java b/core/src/main/java/com/google/bitcoin/core/Peer.java index <HASH>..<HASH> 100644 --- a/core/src/main/java/com/google/bitcoin/core/Peer.java +++ b/core/src/main/java/com/google/bitcoin/core/Peer.java @@ -818,7 +818,7 @@ public class Peer { * Returns the elapsed time of the last ping/pong cycle. If {@link com.google.bitcoin.core.Peer#ping()} has never * been called or we did not hear back the "pong" message yet, returns {@link Long#MAX_VALUE}. */ - public long getLastPingTime() { + public synchronized long getLastPingTime() { if (lastPingTimes == null) return Long.MAX_VALUE; return lastPingTimes[lastPingTimes.length - 1]; @@ -829,7 +829,7 @@ public class Peer { * been called or we did not hear back the "pong" message yet, returns {@link Long#MAX_VALUE}. The moving average * window is 5 buckets. */ - public long getPingTime() { + public synchronized long getPingTime() { if (lastPingTimes == null) return Long.MAX_VALUE; long sum = 0;
Lock the ping time accessors correctly.
diff --git a/index.js b/index.js index <HASH>..<HASH> 100644 --- a/index.js +++ b/index.js @@ -69,8 +69,12 @@ module.exports = function(schema) { function defaultOptions(pathname, v) { const ret = { path: pathname, options: { maxDepth: 10 } }; - if (v.ref) { + if (v.ref != null) { ret.model = v.ref; + ret.ref = v.ref; + } + if (v.refPath != null) { + ret.refPath = v.refPath; } return ret; } @@ -107,7 +111,7 @@ function handleObject(value, optionsToUse) { } function handleFunction(fn, options) { - const val = fn.call(this); + const val = fn.call(this, options); processOption.call(this, val, options); }
fix: call function with options and include refPath in options Fix #<I>
diff --git a/icomoon/__init__.py b/icomoon/__init__.py index <HASH>..<HASH> 100644 --- a/icomoon/__init__.py +++ b/icomoon/__init__.py @@ -1,4 +1,4 @@ """ A Django app to deploy wefonts from Icomoon and display them """ -__version__ = '0.4.0' +__version__ = '1.0.0-pre.1'
Bump to <I> pre release 1
diff --git a/compiler/src/Composer/ComposerJsonManipulator.php b/compiler/src/Composer/ComposerJsonManipulator.php index <HASH>..<HASH> 100644 --- a/compiler/src/Composer/ComposerJsonManipulator.php +++ b/compiler/src/Composer/ComposerJsonManipulator.php @@ -103,6 +103,9 @@ final class ComposerJsonManipulator } $phpstanVersion = $json[self::REQUIRE][self::PHPSTAN_PHPSTAN]; + // use exact version + $phpstanVersion = ltrim($phpstanVersion, '^'); + $json[self::REQUIRE]['phpstan/phpstan-src'] = $phpstanVersion; unset($json[self::REQUIRE][self::PHPSTAN_PHPSTAN]);
use extact version in phpstan compiler to rector.phar
diff --git a/Eloquent/Collection.php b/Eloquent/Collection.php index <HASH>..<HASH> 100755 --- a/Eloquent/Collection.php +++ b/Eloquent/Collection.php @@ -6,7 +6,7 @@ use LogicException; use Illuminate\Support\Arr; use Illuminate\Support\Str; use Illuminate\Contracts\Support\Arrayable; -use Illuminate\Database\Eloquent\Relations\Pivot; +use Illuminate\Contracts\Queue\QueueableEntity; use Illuminate\Contracts\Queue\QueueableCollection; use Illuminate\Support\Collection as BaseCollection; @@ -541,7 +541,7 @@ class Collection extends BaseCollection implements QueueableCollection return []; } - return $this->first() instanceof Pivot + return $this->first() instanceof QueueableEntity ? $this->map->getQueueableId()->all() : $this->modelKeys(); }
Fix QueueableCollection relying on Pivot->getQueueableId() instead of QueueableEntity->getQueueableId() Found this issue during development where we have a model that uses binary UUIDs. While the single model serialization works fine, the collection serialization + JSON encoding breaks.
diff --git a/pypeerassets/kutil.py b/pypeerassets/kutil.py index <HASH>..<HASH> 100644 --- a/pypeerassets/kutil.py +++ b/pypeerassets/kutil.py @@ -69,9 +69,11 @@ class Kutil: ).hexdigest()[0:8] return b58encode(step1 + unhexlify(checksum)) - + @staticmethod def check_wif(wif): + '''check if WIF is properly formated.''' + b58_wif = b58decode(wif) check = b58_wif[-4:] checksum = sha256(sha256(b58_wif[:-4]).digest()).digest()[0:4]
added docstring to check_wif method.
diff --git a/index.js b/index.js index <HASH>..<HASH> 100644 --- a/index.js +++ b/index.js @@ -49,7 +49,7 @@ var googleapis = require('googleapis'), return callback(err); } } - + // Cache the response, if caching is on if(cache ) { var fileName = getCacheFileName(args); @@ -159,6 +159,7 @@ module.exports = function(args, callback, settings){ "filters": args.filters, 'dimensions': args.dimensions, "max-results": args.maxResults, + "start-index": args.startIndex, sort: args.sort, auth: oauth2Client }); @@ -182,4 +183,4 @@ module.exports = function(args, callback, settings){ } } }); -}; \ No newline at end of file +};
Added startIndex to gaArgs to allow paging.
diff --git a/primefaces/src/main/resources/META-INF/resources/primefaces/timeline/1-timeline.js b/primefaces/src/main/resources/META-INF/resources/primefaces/timeline/1-timeline.js index <HASH>..<HASH> 100644 --- a/primefaces/src/main/resources/META-INF/resources/primefaces/timeline/1-timeline.js +++ b/primefaces/src/main/resources/META-INF/resources/primefaces/timeline/1-timeline.js @@ -438,8 +438,8 @@ PrimeFaces.widget.Timeline = PrimeFaces.widget.DeferredWidget.extend({ var snap = inst.itemSet.options.snap || null; var scale = inst.body.util.getScale(); var step = inst.body.util.getStep(); - var snappedStart = snap ? snap(xstart, scale, step).toDate() : xstart; - var snappedEnd = snap ? snap(xend, scale, step).toDate() : xend; + var snappedStart = snap ? new Date(snap(xstart, scale, step)) : xstart; + var snappedEnd = snap ? new Date(snap(xend, scale, step)) : xend; var params = []; params.push({
Fix #<I>: Timeline no longer assume moment date from snap (#<I>)
diff --git a/src/python/twitter/pants/targets/internal.py b/src/python/twitter/pants/targets/internal.py index <HASH>..<HASH> 100644 --- a/src/python/twitter/pants/targets/internal.py +++ b/src/python/twitter/pants/targets/internal.py @@ -195,12 +195,6 @@ class InternalTarget(Target): """Subclasses can over-ride to reject invalid dependencies.""" return True - def replace_dependency(self, dependency, replacement): - self.dependencies.discard(dependency) - self.internal_dependencies.discard(dependency) - self.jar_dependencies.discard(dependency) - self.update_dependencies([replacement]) - def _walk(self, walked, work, predicate = None): Target._walk(self, walked, work, predicate) for dep in self.dependencies: @@ -229,5 +223,3 @@ class InternalTarget(Target): self.add_to_exclusives(t.exclusives) elif hasattr(t, "declared_exclusives"): self.add_to_exclusives(t.declared_exclusives) - -
Get rid of unused replace_dependency method. (sapling split of e<I>cd<I>d<I>f0f3c<I>df1bccf0eefde<I>d<I>)
diff --git a/test/publish.spec.js b/test/publish.spec.js index <HASH>..<HASH> 100644 --- a/test/publish.spec.js +++ b/test/publish.spec.js @@ -22,6 +22,6 @@ describe('publish.js', () => { return stream.once('data'); }) .finally(stream.close); - }); + }).timeout(10000); }); }); \ No newline at end of file diff --git a/test/readme.spec.js b/test/readme.spec.js index <HASH>..<HASH> 100644 --- a/test/readme.spec.js +++ b/test/readme.spec.js @@ -15,6 +15,6 @@ describe('readme.js', () => { expect(output).to.match(/Error: Cannot read property 'title'/); }) .finally(stream.close); - }); + }).timeout(10000); }); });
Increase timeout to avoid breaking build (again)
diff --git a/src/API/QueryBuilder.php b/src/API/QueryBuilder.php index <HASH>..<HASH> 100755 --- a/src/API/QueryBuilder.php +++ b/src/API/QueryBuilder.php @@ -208,6 +208,7 @@ class QueryBuilder extends Injectable } } + $count = 1; foreach ($processedSearchFields as $processedSearchField) { switch ($processedSearchField['queryType']) { case 'and': @@ -251,7 +252,6 @@ class QueryBuilder extends Injectable // update to bind params instead of using string concatination $queryArr = []; $valueArr = []; - $count = 1; foreach ($fieldNameArray as $fieldName) { $fieldName = $this->prependFieldNameNamespace($fieldName); foreach ($fieldValueArray as $fieldValue) {
fix a bug when you pass 2 query params one with field=v1||v2||v3 and another query like f1||f2||f3=*a*
diff --git a/src/main/java/org/altbeacon/beacon/powersave/BackgroundPowerSaver.java b/src/main/java/org/altbeacon/beacon/powersave/BackgroundPowerSaver.java index <HASH>..<HASH> 100644 --- a/src/main/java/org/altbeacon/beacon/powersave/BackgroundPowerSaver.java +++ b/src/main/java/org/altbeacon/beacon/powersave/BackgroundPowerSaver.java @@ -44,8 +44,8 @@ public class BackgroundPowerSaver implements Application.ActivityLifecycleCallba LogManager.w(TAG, "BackgroundPowerSaver requires API 18 or higher."); return; } - ((Application)context.getApplicationContext()).registerActivityLifecycleCallbacks(this); beaconManager = BeaconManager.getInstanceForApplication(context); + ((Application)context.getApplicationContext()).registerActivityLifecycleCallbacks(this); } @Override
Prevent crash due to null beaconManager by getting instance before starting power save callbacks
diff --git a/src/rez/utils/colorize.py b/src/rez/utils/colorize.py index <HASH>..<HASH> 100644 --- a/src/rez/utils/colorize.py +++ b/src/rez/utils/colorize.py @@ -193,12 +193,7 @@ def _color(str_, fore_color=None, back_color=None, styles=None): .. _Colorama: https://pypi.python.org/pypi/colorama """ - # TODO: Colorama is documented to work on Windows and trivial test case - # proves this to be the case, but it doesn't work in Rez. If the initialise - # is called in sec/rez/__init__.py then it does work, however as discussed - # in the following comment this is not always desirable. So until we can - # work out why we forcibly turn it off. - if not config.get("color_enabled", False) or platform_.name == "windows": + if not config.get("color_enabled", False): return str_ # lazily init colorama. This is important - we don't want to init at startup,
Remove windows exception from colorize.py
diff --git a/src/Convert/Converters/Gmagick.php b/src/Convert/Converters/Gmagick.php index <HASH>..<HASH> 100644 --- a/src/Convert/Converters/Gmagick.php +++ b/src/Convert/Converters/Gmagick.php @@ -107,7 +107,7 @@ class Gmagick extends AbstractConverter $im->setimageformat('WEBP'); - // Not completely sure if setimageoption() has always been there, so lets check first. #169 + // setimageoption() has not always been there, so check first. #169 if (method_exists($im, 'setimageoption')) { // Finally cracked setting webp options. // See #167
Changed a comment. Closes #<I>
diff --git a/mopidy_musicbox_webclient/static/js/functionsvars.js b/mopidy_musicbox_webclient/static/js/functionsvars.js index <HASH>..<HASH> 100644 --- a/mopidy_musicbox_webclient/static/js/functionsvars.js +++ b/mopidy_musicbox_webclient/static/js/functionsvars.js @@ -238,7 +238,7 @@ function resultsToTables(results, target, uri) { for (i = 0; i < length; i++) { //create album if none extists if (!results[i].album) { - results[i].album = {}; + results[i].album = {"__model__": "Album"}; } //create album uri if there is none if (!results[i].album.uri) {
Better fake up Album model for stricter mopidy validation. (Fixes #<I>). This is a bit of a hack. The better solution is to only send URIs rather than full Track models.
diff --git a/src/Illuminate/Foundation/Console/AppNameCommand.php b/src/Illuminate/Foundation/Console/AppNameCommand.php index <HASH>..<HASH> 100644 --- a/src/Illuminate/Foundation/Console/AppNameCommand.php +++ b/src/Illuminate/Foundation/Console/AppNameCommand.php @@ -59,6 +59,8 @@ class AppNameCommand extends Command { $this->setAuthConfigNamespace(); $this->info('Application namespace set!'); + + $this->call('dump-autoload'); } /**
Dump auto loads after app:name set.
diff --git a/lib/merb-core/logger.rb b/lib/merb-core/logger.rb index <HASH>..<HASH> 100755 --- a/lib/merb-core/logger.rb +++ b/lib/merb-core/logger.rb @@ -161,7 +161,7 @@ module Merb # Close and remove the current log object. def close flush - @log.close if @log.respond_to?(:close) + @log.close if @log.respond_to?(:close) && !@log.tty? @log = nil end @@ -227,4 +227,4 @@ module Merb end -end \ No newline at end of file +end diff --git a/spec/public/logger/logger_spec.rb b/spec/public/logger/logger_spec.rb index <HASH>..<HASH> 100644 --- a/spec/public/logger/logger_spec.rb +++ b/spec/public/logger/logger_spec.rb @@ -102,6 +102,12 @@ describe Merb::Logger do @logger.close end + it "shouldn't call the close method if the log is a terminal" do + @logger.log.should_receive(:tty?).and_return(true) + @logger.log.should_not_receive(:close) + @logger.close + end + it "should set the stored log attribute to nil" do @logger.close @logger.log.should eql(nil) @@ -172,4 +178,4 @@ describe Merb::Logger do end -end \ No newline at end of file +end
Ensure that Merb::Logger doesn't try to close terminal streams.
diff --git a/mapping/sql/all/src/test/java/it/unibz/inf/ontop/spec/mapping/parser/ParserFileTest.java b/mapping/sql/all/src/test/java/it/unibz/inf/ontop/spec/mapping/parser/ParserFileTest.java index <HASH>..<HASH> 100644 --- a/mapping/sql/all/src/test/java/it/unibz/inf/ontop/spec/mapping/parser/ParserFileTest.java +++ b/mapping/sql/all/src/test/java/it/unibz/inf/ontop/spec/mapping/parser/ParserFileTest.java @@ -52,7 +52,7 @@ public class ParserFileTest extends TestCase { public ParserFileTest() { OntopMappingSQLAllConfiguration configuration = OntopMappingSQLAllConfiguration.defaultBuilder() - .jdbcUrl("fake_url") + .jdbcUrl("jdbc:h2:mem:fake") .jdbcUser("fake_user") .jdbcPassword("fake_password") .build();
More realistic JDBC url given to ParserFileTest.
diff --git a/lib/mongo/background_thread.rb b/lib/mongo/background_thread.rb index <HASH>..<HASH> 100644 --- a/lib/mongo/background_thread.rb +++ b/lib/mongo/background_thread.rb @@ -129,7 +129,16 @@ module Mongo # Some driver objects can be reconnected, for backwards compatibiilty # reasons. Clear the thread instance variable to support this cleanly. if @thread.alive? - log_warn("Failed to stop background thread in #{self} in #{(Time.now - start_time).to_i} seconds") + log_warn("Failed to stop the background thread in #{self} in #{(Time.now - start_time).to_i} seconds: #{@thread.inspect} (thread status: #{@thread.status})") + # On JRuby the thread may be stuck in aborting state + # seemingly indefinitely. If the thread is aborting, consider it dead + # for our purposes (we will create a new thread if needed, and + # the background thread monitor will not detect the aborting thread + # as being alive). + if @thread.status == 'aborting' + @thread = nil + @stop_requested = false + end false else @thread = nil diff --git a/lib/mongo/server/monitor.rb b/lib/mongo/server/monitor.rb index <HASH>..<HASH> 100644 --- a/lib/mongo/server/monitor.rb +++ b/lib/mongo/server/monitor.rb @@ -136,7 +136,7 @@ module Mongo # Forward super's return value super.tap do # Important: disconnect should happen after the background thread - # terminated. + # terminates. connection.disconnect! end end
RUBY-<I> Consider threads in aborting state dead (#<I>)
diff --git a/packages/ui-text-area/src/TextArea/styles.js b/packages/ui-text-area/src/TextArea/styles.js index <HASH>..<HASH> 100644 --- a/packages/ui-text-area/src/TextArea/styles.js +++ b/packages/ui-text-area/src/TextArea/styles.js @@ -77,14 +77,11 @@ const generateStyle = (theme, themeOverride, props, state) => { wordWrap: 'break-word', textAlign: 'start', ...fontSizeVariants[size], - '&:focus + span': { + '&:focus + [class$=-textArea__outline]': { transform: 'scale(1)', opacity: 1 }, - '&[aria-invalid]': { - borderColor: componentTheme.errorBorderColor - }, - '&[aria-invalid]:focus, &[aria-invalid]:focus + span': { + '&[aria-invalid], &[aria-invalid]:focus, &[aria-invalid]:focus + [class$=-textArea__outline]': { borderColor: componentTheme.errorBorderColor }, '&::placeholder': {
refactor: make CSS selectors more specific
diff --git a/src/RuleSet/RuleSetDescriptionInterface.php b/src/RuleSet/RuleSetDescriptionInterface.php index <HASH>..<HASH> 100644 --- a/src/RuleSet/RuleSetDescriptionInterface.php +++ b/src/RuleSet/RuleSetDescriptionInterface.php @@ -19,8 +19,6 @@ namespace PhpCsFixer\RuleSet; */ interface RuleSetDescriptionInterface { - public function __construct(); - public function getDescription(): string; public function getName(): string;
Remove __constructor() from RuleSetDescriptionInterface Constructor should be defined by the implementation, not by the interface.
diff --git a/synapse/lib/storm.py b/synapse/lib/storm.py index <HASH>..<HASH> 100644 --- a/synapse/lib/storm.py +++ b/synapse/lib/storm.py @@ -1464,7 +1464,7 @@ class Runtime(Configable): limt = self.getLiftLimitHelp(opts.get('limit')) if isinstance(limt.limit, int) and limt.limit < 0: - raise s_common.BadOperArg(oper='pivottags', name='limit', mesg='limit must be >= 0') + raise s_common.BadOperArg(oper=oper[0], name='limit', mesg='limit must be >= 0') if take: nodes = query.take()
Use correct oper name in raising BadOperArg
diff --git a/evcache-client/src/main/java/com/netflix/evcache/pool/EVCacheClient.java b/evcache-client/src/main/java/com/netflix/evcache/pool/EVCacheClient.java index <HASH>..<HASH> 100644 --- a/evcache-client/src/main/java/com/netflix/evcache/pool/EVCacheClient.java +++ b/evcache-client/src/main/java/com/netflix/evcache/pool/EVCacheClient.java @@ -1121,7 +1121,12 @@ public class EVCacheClient { public boolean shutdown(long timeout, TimeUnit unit) { shutdown = true; - return evcacheMemcachedClient.shutdown(timeout, unit); + try { + return evcacheMemcachedClient.shutdown(timeout, unit); + } catch(Throwable t) { + log.warn("Exception while sutting down", t); + return true; + } } public EVCacheConnectionObserver getConnectionObserver() {
if there is any exception while shutting down we will not propagate it
diff --git a/src/Layers/BasemapLayer.js b/src/Layers/BasemapLayer.js index <HASH>..<HASH> 100644 --- a/src/Layers/BasemapLayer.js +++ b/src/Layers/BasemapLayer.js @@ -204,7 +204,7 @@ export var BasemapLayer = TileLayer.extend({ Util.setOptions(this, tileOptions); - if (this.options.token) { + if (this.options.token && !config.urlTemplate.includes('token=')) { config.urlTemplate += ('?token=' + this.options.token); }
Prevent token repeating in url Fix for #<I>
diff --git a/lib/dm-core/collection.rb b/lib/dm-core/collection.rb index <HASH>..<HASH> 100644 --- a/lib/dm-core/collection.rb +++ b/lib/dm-core/collection.rb @@ -1142,10 +1142,7 @@ module DataMapper # TODO: spec what should happen when none of the resources in self are saved query = relationship.query_for(self) - - if other_query - query.update(other_query) - end + query.update(other_query) if other_query query.model.all(query) end
Cosmetics: use postfix condition in Collection#delegate_to_relationship
diff --git a/lib/flor/unit/storage.rb b/lib/flor/unit/storage.rb index <HASH>..<HASH> 100644 --- a/lib/flor/unit/storage.rb +++ b/lib/flor/unit/storage.rb @@ -191,17 +191,14 @@ module Flor n = Time.now - @db.transaction do - - @db[:flor_messages] - .import( - [ :domain, :exid, :point, :content, - :status, :ctime, :mtime ], - ms.map { |m| - [ Flor.domain(m['exid']), m['exid'], m['point'], to_blob(m), - 'created', n, n ] - }) - end + @db[:flor_messages] + .import( + [ :domain, :exid, :point, :content, + :status, :ctime, :mtime ], + ms.map { |m| + [ Flor.domain(m['exid']), m['exid'], m['point'], to_blob(m), + 'created', n, n ] + }) @unit.wake_executions(ms.collect { |m| m['exid'] }.uniq) end
revert "use transaction in Storage#put_messages" This reverts commit ea2fbfa<I>cb<I>a<I>dc<I>a1c<I>f<I>a8e7.
diff --git a/test/integration/test_runner.py b/test/integration/test_runner.py index <HASH>..<HASH> 100644 --- a/test/integration/test_runner.py +++ b/test/integration/test_runner.py @@ -42,6 +42,7 @@ def test_run_command_with_unicode(rc): if six.PY2: expected = expected.decode('utf-8') rc.command = ['echo', '"utf-8-䉪ቒ칸ⱷ?噂폄蔆㪗輥"'] + rc.env = {"䉪ቒ칸": "蔆㪗輥"} status, exitcode = Runner(config=rc).run() assert status == 'successful' assert exitcode == 0
Adding test for unicode environment
diff --git a/simplesqlite/core.py b/simplesqlite/core.py index <HASH>..<HASH> 100644 --- a/simplesqlite/core.py +++ b/simplesqlite/core.py @@ -1492,7 +1492,7 @@ class SimpleSQLite(object): return [record[0] for record in result] - def __extract_attr_desc_list_from_tabledata(self, table_data, primary_key): + def __extract_attr_descs_from_tabledata(self, table_data, primary_key): if primary_key and primary_key not in table_data.headers: raise ValueError("primary key must be one of the values of attributes") @@ -1545,8 +1545,7 @@ class SimpleSQLite(object): ).normalize() self.create_table( - table_data.table_name, - self.__extract_attr_desc_list_from_tabledata(table_data, primary_key), + table_data.table_name, self.__extract_attr_descs_from_tabledata(table_data, primary_key) ) self.insert_many(table_data.table_name, table_data.value_matrix) if typepy.is_not_empty_sequence(index_attrs):
Refactor: rename a private method
diff --git a/spec/lib/redis_analytics/dashboard_spec.rb b/spec/lib/redis_analytics/dashboard_spec.rb index <HASH>..<HASH> 100644 --- a/spec/lib/redis_analytics/dashboard_spec.rb +++ b/spec/lib/redis_analytics/dashboard_spec.rb @@ -6,24 +6,24 @@ describe Rack::RedisAnalytics::Dashboard do context 'the pretty dashboard' do - before do - Rack::RedisAnalytics.configure do |c| - c.dashboard_endpoint = '/analytics/dashboard' - end + it 'should redirect to visits' do + get '/' + last_response.should be_redirect + # how do we check the redirect location? end it 'should be mapped to configured endpoint' do - get Rack::RedisAnalytics.dashboard_endpoint + get '/' last_response.ok? end it 'should be content-type html' do - get Rack::RedisAnalytics.dashboard_endpoint + get '/' last_response.headers['Content-Type'] == "text/html" end it 'should contain the word Visits' do - get Rack::RedisAnalytics.dashboard_endpoint + get '/' last_response.body.include? "Visits" end
dashboard endpoint is not mandatory, dashboard app should test against '/'
diff --git a/lib/ipc.js b/lib/ipc.js index <HASH>..<HASH> 100644 --- a/lib/ipc.js +++ b/lib/ipc.js @@ -920,14 +920,14 @@ Ipc.prototype.subscribeQueue = function(options, callback) // It keeps a count how many subscribe/unsubscribe calls been made and stops any internal listeners once nobody is // subscribed. This is specific to a queue which relies on polling. // -Ipc.prototype.subscribeQueue = function(options, callback) +Ipc.prototype.unsubscribeQueue = function(options, callback) { if (typeof options == "function") callback = options, options = null; - logger.dev("ipc.subscribeQueue:", options); + logger.dev("ipc.unsubscribeQueue:", options); try { - this.getClient(options).subscribeQueue(options || lib.empty, typeof callback == "function" ? callback : undefined); + this.getClient(options).unsubscribeQueue(options || lib.empty, typeof callback == "function" ? callback : undefined); } catch (e) { - logger.error('ipc.subscribeQueue:', options, e.stack); + logger.error('ipc.unsubscribeQueue:', options, e.stack); } return this; }
fixed unsubscribedQueue
diff --git a/nodeconductor/structure/serializers.py b/nodeconductor/structure/serializers.py index <HASH>..<HASH> 100644 --- a/nodeconductor/structure/serializers.py +++ b/nodeconductor/structure/serializers.py @@ -233,6 +233,14 @@ class ProjectSerializer(core_serializers.RestrictedSerializerMixin, return queryset.select_related('customer').only(*related_fields)\ .prefetch_related('quotas', 'certifications') + def get_fields(self): + fields = super(ProjectSerializer, self).get_fields() + + if self.instance: + fields['certifications'].read_only = True + + return fields + def create(self, validated_data): certifications = validated_data.pop('certifications', []) project = super(ProjectSerializer, self).create(validated_data)
Mark certifications as readonly on project update It is not allowed to update certifications on direct project update through PUT or POST request. /update_certifications method is used for that purpose.
diff --git a/libraries/lithium/tests/cases/util/StringTest.php b/libraries/lithium/tests/cases/util/StringTest.php index <HASH>..<HASH> 100644 --- a/libraries/lithium/tests/cases/util/StringTest.php +++ b/libraries/lithium/tests/cases/util/StringTest.php @@ -366,6 +366,14 @@ class StringTest extends \lithium\test\Unit { $result = String::tokenize('tagA "single tag" tagB', ' ', '"', '"'); $expected = array('tagA', '"single tag"', 'tagB'); $this->assertEqual($expected, $result); + + $result = String::tokenize(array()); + $expected = array(); + $this->assertEqual($expected, $result); + + $result = String::tokenize(null); + $expected = null; + $this->assertEqual($expected, $result); } /**
Adding test coverage for `util\String::tokenize()`
diff --git a/dantil.js b/dantil.js index <HASH>..<HASH> 100644 --- a/dantil.js +++ b/dantil.js @@ -250,7 +250,7 @@ exports.getModuleCallerPathAndLineNumber = function () { * @private * @static * @param {Function} getFrameFunc The function passed the structured stack trace and returns a single stack frame. - * @returns {String} Returns the file path and line number of the frame returned by `getFrameFunc` in the format `filePath:lineNumber`. + * @returns {string} Returns the file path and line number of the frame returned by `getFrameFunc` in the format `filePath:lineNumber`. */ function getFormattedStackFrame(getFrameFunc) { var origStackTraceLimit = Error.stackTraceLimit
Tweak JSDoc to use lowercase for primitive types
diff --git a/lib/jazzy/doc_builder.rb b/lib/jazzy/doc_builder.rb index <HASH>..<HASH> 100644 --- a/lib/jazzy/doc_builder.rb +++ b/lib/jazzy/doc_builder.rb @@ -43,6 +43,7 @@ module Jazzy stdout = SourceKitten.run_sourcekitten(options.xcodebuild_arguments) exitstatus = $?.exitstatus if exitstatus == 0 + warn 'building site' build_docs_for_sourcekitten_output(stdout, options) else warn 'Please pass in xcodebuild arguments using -x'
added 'building site' status message
diff --git a/e2e/visual/webpack.config.js b/e2e/visual/webpack.config.js index <HASH>..<HASH> 100644 --- a/e2e/visual/webpack.config.js +++ b/e2e/visual/webpack.config.js @@ -26,6 +26,12 @@ module.exports = { content: 'mini-html-webpack-template', }, ], + scripts: [ + { + src: + '//polyfill.io/v3/polyfill.min.js?features=Set%2CArray.prototype.%40%40iterator%2CArray.prototype.find', + }, + ], }, body: { raw: '<div id="app"></div>',
chore(e2e): add polyfills to Cartesian application
diff --git a/core.js b/core.js index <HASH>..<HASH> 100644 --- a/core.js +++ b/core.js @@ -3621,14 +3621,13 @@ const _makeWindow = (options = {}, parent = null, top = null) => { }, }, getVRDisplaysSync() { - const result = []; + const result = fakeVrDisplays.slice(); if (nativeMl && nativeMl.IsPresent()) { result.push(_getMlDisplay(window)); } if (nativeVr.VR_IsHmdPresent()) { result.push(_getVrDisplay(window)); } - result.push.apply(result, fakeVrDisplays); return result; }, getVRDisplays() {
Make fake vr dispalys come first in getVRDisplaysSync
diff --git a/tasks/typescript.js b/tasks/typescript.js index <HASH>..<HASH> 100644 --- a/tasks/typescript.js +++ b/tasks/typescript.js @@ -20,12 +20,11 @@ module.exports = function (grunt) { resolvePath:path.resolve, readFile:function (file){ - var content = grunt.file.read(file); + var content = fs.readFileSync(file, 'utf8'); // strip UTF BOM if(content.charCodeAt(0) === 0xFEFF){ content = content.slice(1); } - return content; }, dirName:path.dirname,
fix task failure when typescript looks for files that may be missing typescript seems to look for files by trying to read them, this causes problems as if the grunt.file.read fails it will fail the task.
diff --git a/src/Router/RouterRequest.php b/src/Router/RouterRequest.php index <HASH>..<HASH> 100644 --- a/src/Router/RouterRequest.php +++ b/src/Router/RouterRequest.php @@ -47,9 +47,9 @@ class RouterRequest protected static function checkMethods($value, $method) { $valid = false; - if ($value === 'AJAX' && self::isAjax && $value === $method) { + if ($value === 'AJAX' && self::isAjax() && $value === $method) { $valid = true; - } elseif ($value === 'AJAXP' && self::isAjax && $method === 'POST') { + } elseif ($value === 'AJAXP' && self::isAjax() && $method === 'POST') { $valid = true; } elseif (in_array($value, explode('|', self::$validMethods)) && ($value === $method || $value === 'ANY')) { $valid = true;
Bug fixed on isAjax method.
diff --git a/storage/remote/queue_manager.go b/storage/remote/queue_manager.go index <HASH>..<HASH> 100644 --- a/storage/remote/queue_manager.go +++ b/storage/remote/queue_manager.go @@ -526,7 +526,8 @@ func (t *QueueManager) calculateDesiredShards() int { samplesPendingRate = samplesInRate*samplesKeptRatio - samplesOutRate highestSent = t.highestSentTimestampMetric.Get() highestRecv = highestTimestamp.Get() - samplesPending = (highestRecv - highestSent) * samplesInRate * samplesKeptRatio + delay = highestRecv - highestSent + samplesPending = delay * samplesInRate * samplesKeptRatio ) if samplesOutRate <= 0 { @@ -577,6 +578,12 @@ func (t *QueueManager) calculateDesiredShards() int { } numShards := int(math.Ceil(desiredShards)) + // Do not downshard if we are more than ten seconds back. + if numShards < t.numShards && delay > 10.0 { + level.Debug(t.logger).Log("msg", "Not downsharding due to being too far behind") + return t.numShards + } + if numShards > t.cfg.MaxShards { numShards = t.cfg.MaxShards } else if numShards < t.cfg.MinShards {
Only reduce the number of shards when caught up.
diff --git a/caravel/db_engine_specs.py b/caravel/db_engine_specs.py index <HASH>..<HASH> 100644 --- a/caravel/db_engine_specs.py +++ b/caravel/db_engine_specs.py @@ -56,6 +56,7 @@ class PostgresEngineSpec(BaseEngineSpec): Grain("day", _('day'), "DATE_TRUNC('day', {col})"), Grain("week", _('week'), "DATE_TRUNC('week', {col})"), Grain("month", _('month'), "DATE_TRUNC('month', {col})"), + Grain("quarter", _('quarter'), "DATE_TRUNC('quarter', {col})"), Grain("year", _('year'), "DATE_TRUNC('year', {col})"), )
Add quarter time grain to postgresql (#<I>) The timestamp returned is the start date of the period. Reference: <URL>
diff --git a/lib/SlackBot.js b/lib/SlackBot.js index <HASH>..<HASH> 100755 --- a/lib/SlackBot.js +++ b/lib/SlackBot.js @@ -396,10 +396,11 @@ function Slackbot(configuration) { if (slack_botkit.config.redirectUri) { var redirect_query = ''; - if (redirect_params) + var redirect_uri = slack_botkit.config.redirectUri; + if (redirect_params) { redirect_query += encodeURIComponent(querystring.stringify(redirect_params)); - - var redirect_uri = slack_botkit.config.redirectUri + '?' + redirect_query; + redirect_uri = redirect_uri + '?' + redirect_query; + } url += '&redirect_uri=' + redirect_uri; }
Fix issue with creation of redirectUri when parameters were not included
diff --git a/stream-lib.js b/stream-lib.js index <HASH>..<HASH> 100644 --- a/stream-lib.js +++ b/stream-lib.js @@ -13,7 +13,6 @@ /** * Associative array of lib classes. * @type {{}} - * @property {streamLib.Beat} Beat * @property {streamLib.BufferStream} Buffer * @property {streamLib.Concat} Concat * @property {streamLib.EventStream} Event @@ -25,14 +24,17 @@ * @property {streamLib.Random} Random * @property {streamLib.Sequencer} Sequencer * @property {streamLib.Spawn} Spawn - * @property {streamLib.Sluice} Sluice * @property {streamLib.Unit} Unit * @property {streamLib.UpperCase} UpperCase */ +/* + * @property {streamLib.Beat} Beat private at this time + * @property {streamLib.Sluice} Sluice private at this time + */ var streamLib = { - Beat: require('./lib/beat'), // jsdoc-methods - Buffer: require('./lib/buffer'), // OK - Concat: require('./lib/concat'), // OK + Beat: require('./lib/beat'), + Buffer: require('./lib/buffer'), + Concat: require('./lib/concat'), Event: require('./lib/event'), hex: require('./lib/hex'), LowerCase: require('./lib/lower-case'),
fix required libraries in doc for private ones
diff --git a/python/mxnet/metric.py b/python/mxnet/metric.py index <HASH>..<HASH> 100644 --- a/python/mxnet/metric.py +++ b/python/mxnet/metric.py @@ -3,7 +3,7 @@ """Online evaluation metric module.""" from __future__ import absolute_import - +import math import numpy from . import ndarray @@ -261,9 +261,11 @@ class Perplexity(EvalMetric): pred = pred*(1-ignore) + ignore loss -= ndarray.sum(ndarray.log(ndarray.maximum(1e-10, pred))).asscalar() num += pred.size - self.sum_metric += math.exp(loss/num) - self.num_inst += 1 + self.sum_metric += loss + self.num_inst += num + def get(self): + return (self.name, math.exp(self.sum_metric/self.num_inst)) #################### # REGRESSION METRICS
Compute perplexity by averaging over the document (#<I>) * Compute perplexity by averaging over the document solve the problem that the perplexity is related to the batch size * Update metric.py * Update metric.py
diff --git a/activerecord/lib/active_record/base.rb b/activerecord/lib/active_record/base.rb index <HASH>..<HASH> 100644 --- a/activerecord/lib/active_record/base.rb +++ b/activerecord/lib/active_record/base.rb @@ -463,7 +463,7 @@ module ActiveRecord #:nodoc: # # # You can use the same string replacement techniques as you can with ActiveRecord#find # Post.find_by_sql ["SELECT title FROM posts WHERE author = ? AND created > ?", author_id, start_date] - # > [#<Post:0x36bff9c @attributes={"first_name"=>"The Cheap Man Buys Twice"}>, ...] + # > [#<Post:0x36bff9c @attributes={"title"=>"The Cheap Man Buys Twice"}>, ...] def find_by_sql(sql, binds = []) connection.select_all(sanitize_sql(sql), "#{name} Load", binds).collect! { |record| instantiate(record) } end
fixes a missmatched column in example
diff --git a/tests/test-rest-posts-controller.php b/tests/test-rest-posts-controller.php index <HASH>..<HASH> 100644 --- a/tests/test-rest-posts-controller.php +++ b/tests/test-rest-posts-controller.php @@ -181,10 +181,10 @@ class WP_Test_REST_Posts_Controller extends WP_Test_REST_Post_Type_Controller_Te $this->assertNotEmpty( $tag_link ); $this->assertNotEmpty( $cat_link ); - $tags_url = rest_url( '/wp/v2/post/' . $this->post_id . '/terms/tag' ); + $tags_url = rest_url( '/wp/v2/posts/' . $this->post_id . '/terms/tag' ); $this->assertEquals( $tags_url, $tag_link['href'] ); - $category_url = rest_url( '/wp/v2/post/' . $this->post_id . '/terms/category' ); + $category_url = rest_url( '/wp/v2/posts/' . $this->post_id . '/terms/category' ); $this->assertEquals( $category_url, $cat_link['href'] ); }
Fix typo in post terms url test
diff --git a/api/util_test.go b/api/util_test.go index <HASH>..<HASH> 100644 --- a/api/util_test.go +++ b/api/util_test.go @@ -10,6 +10,10 @@ import ( . "launchpad.net/gocheck" ) +type UtilSuite struct{} + +var _ = Suite(&UtilSuite{}) + func (s *S) TestFileSystem(c *C) { fsystem = &testing.RecordingFs{} c.Assert(filesystem(), DeepEquals, fsystem)
Creating a suite for util test.
diff --git a/src/core/resolve.js b/src/core/resolve.js index <HASH>..<HASH> 100644 --- a/src/core/resolve.js +++ b/src/core/resolve.js @@ -147,8 +147,8 @@ function resolverReducer(resolvers, map) { function requireResolver(name, modulePath) { try { // Try to resolve package with absolute path (/Volumes/....) - if (path.isAbsolute(name)) { - return require(path.resolve(name)); + if (isAbsolute(name)) { + return require(name) } try {
Require module with absolute path without resolving
diff --git a/src/android/BackgroundMode.java b/src/android/BackgroundMode.java index <HASH>..<HASH> 100644 --- a/src/android/BackgroundMode.java +++ b/src/android/BackgroundMode.java @@ -44,7 +44,7 @@ public class BackgroundMode extends CordovaPlugin { private boolean isDisabled = false; // Settings for the notification - static JSONObject settings; + static JSONObject settings = new JSONObject(); // Used to (un)bind the service to with the activity private ServiceConnection connection = new ServiceConnection() {
Fix null pointer exception for settings
diff --git a/spec/mail/encodings_spec.rb b/spec/mail/encodings_spec.rb index <HASH>..<HASH> 100644 --- a/spec/mail/encodings_spec.rb +++ b/spec/mail/encodings_spec.rb @@ -246,8 +246,9 @@ describe Mail::Encodings do mail[:subject].charset = 'koi8-r' wrapped = mail[:subject].wrapped_value unwrapped = Mail::Encodings.value_decode(wrapped) + orginial = original.force_encoding('koi8-r') if RUBY_VERSION >= "1.9" - unwrapped.gsub("Subject: ", "").should == original.force_encoding('koi8-r') + unwrapped.gsub("Subject: ", "").should == original end end
Yeah yeah, I fixed for ruby <I>, but neglected to test with older rubies. I'm a dud! (<URL>)
diff --git a/resolver.go b/resolver.go index <HASH>..<HASH> 100644 --- a/resolver.go +++ b/resolver.go @@ -30,12 +30,8 @@ type Resolver struct { // New initializes a Resolver with the specified cache size. func New(capacity int) *Resolver { r := &Resolver{ - cache: newCache(capacity), - client: &dns.Client{ - DialTimeout: Timeout, - ReadTimeout: Timeout, - WriteTimeout: Timeout, - }, + cache: newCache(capacity), + client: &dns.Client{Timeout: Timeout}, } return r }
Create new resolvers with the default timeout. Previously, the default timeout was used for each operation, which extended the effective timeout to 3x the intended value.
diff --git a/src/main/java/org/xbill/DNS/Zone.java b/src/main/java/org/xbill/DNS/Zone.java index <HASH>..<HASH> 100644 --- a/src/main/java/org/xbill/DNS/Zone.java +++ b/src/main/java/org/xbill/DNS/Zone.java @@ -539,11 +539,9 @@ public class Zone implements Serializable { /** Returns the contents of the Zone in master file format. */ public synchronized String toMasterFile() { - Iterator zentries = data.entrySet().iterator(); StringBuffer sb = new StringBuffer(); nodeToString(sb, originNode); - while (zentries.hasNext()) { - Map.Entry entry = (Map.Entry) zentries.next(); + for (Map.Entry<Name, Object> entry : data.entrySet()) { if (!origin.equals(entry.getKey())) { nodeToString(sb, entry.getValue()); }
Migrate iterator to foreach
diff --git a/minivents.js b/minivents.js index <HASH>..<HASH> 100644 --- a/minivents.js +++ b/minivents.js @@ -1,5 +1,5 @@ function Events(target){ - var events = {}, i, A = Array; + var events = {}; target = target || this /** * On: listen to events @@ -20,7 +20,7 @@ function Events(target){ * Emit: send event, callbacks will be triggered */ target.emit = function(){ - var args = A.apply([], arguments), + var args = Array.apply([], arguments), list = events[args.shift()] || [], i = list.length, j for(j=0;j<i;j++) list[j].f.apply(list[j].c, args)
simplifications - `A` is only used once, so I'd suggest to use the native `Array` instead. - `i` is defined in each method separately, no need to define it on constructor
diff --git a/matrix_client/client.py b/matrix_client/client.py index <HASH>..<HASH> 100644 --- a/matrix_client/client.py +++ b/matrix_client/client.py @@ -393,7 +393,7 @@ class Room(object): self.events.pop(0) for listener in self.listeners: - listener(event) + listener(self, event) def get_events(self): """ Get the most recent events for this room.
client: Pass room as arguement to event callbacks. When we get an event, the room part is striped away before the event callback on the room gets the event. So inside the callback there is no easy way to find in which room the event has happened.
diff --git a/lib/phusion_passenger/platform_info/apache.rb b/lib/phusion_passenger/platform_info/apache.rb index <HASH>..<HASH> 100644 --- a/lib/phusion_passenger/platform_info/apache.rb +++ b/lib/phusion_passenger/platform_info/apache.rb @@ -170,7 +170,7 @@ module PlatformInfo end # The Apache config file supports environment variable # substitution. Ubuntu uses this extensively. - filename.gsub!(/\${(.+?)}/) do |varname| + filename.gsub!(/\$\{(.+?)\}/) do |varname| if value = httpd_infer_envvar($1, options) log "Substituted \"#{varname}\" -> \"#{value}\"" value
Fix regex compatibiliy problem with Ruby <I>
diff --git a/resolwe/flow/managers/workload_connectors/kubernetes.py b/resolwe/flow/managers/workload_connectors/kubernetes.py index <HASH>..<HASH> 100644 --- a/resolwe/flow/managers/workload_connectors/kubernetes.py +++ b/resolwe/flow/managers/workload_connectors/kubernetes.py @@ -498,9 +498,9 @@ class Connector(BaseConnector): # Create kubernetes API every time otherwise it will time out # eventually and raise API exception. try: - kubernetes.config.load_incluster_config() - except kubernetes.config.config_exception.ConfigException: kubernetes.config.load_kube_config() + except kubernetes.config.config_exception.ConfigException: + kubernetes.config.load_incluster_config() batch_api = kubernetes.client.BatchV1Api() core_api = kubernetes.client.CoreV1Api()
Change credentials loading order First try to load credentials from file and then from incluster config.
diff --git a/lib/sup/index.rb b/lib/sup/index.rb index <HASH>..<HASH> 100644 --- a/lib/sup/index.rb +++ b/lib/sup/index.rb @@ -6,7 +6,7 @@ begin require 'chronic' $have_chronic = true rescue LoadError => e - debug "optional 'chronic' library not found; date-time query restrictions disabled" + debug "No 'chronic' gem detected. Install it for date/time query restrictions." $have_chronic = false end
change chronic missing message to be similar to that of ncursesw
diff --git a/benchexec/model.py b/benchexec/model.py index <HASH>..<HASH> 100644 --- a/benchexec/model.py +++ b/benchexec/model.py @@ -91,7 +91,7 @@ def load_task_definition_file(task_def_file): raise BenchExecException("Invalid task definition: " + str(e)) if not task_def: - raise BenchExecException(f"Invalid task definition: empty file {task_def_file}") + raise BenchExecException("Invalid task definition: empty file " + task_def_file) if str(task_def.get("format_version")) not in ["0.1", "1.0"]: raise BenchExecException(
Fix syntax error from <I>a1a<I>a1da1c<I>e5a<I>d<I>e
diff --git a/app/models/agents/email_digest_agent.rb b/app/models/agents/email_digest_agent.rb index <HASH>..<HASH> 100644 --- a/app/models/agents/email_digest_agent.rb +++ b/app/models/agents/email_digest_agent.rb @@ -11,7 +11,7 @@ module Agents used events also relies on the `Keep events` option of the emitting Agent, meaning that if events expire before this agent is scheduled to run, they will not appear in the email. - By default, the will have a `subject` and an optional `headline` before listing the Events. If the Events' + By default, the email will have a `subject` and an optional `headline` before listing the Events. If the Events' payloads contain a `message`, that will be highlighted, otherwise everything in their payloads will be shown.
Add missing word in description of an agent
diff --git a/tests/scripts/test_phy_spikesort.py b/tests/scripts/test_phy_spikesort.py index <HASH>..<HASH> 100644 --- a/tests/scripts/test_phy_spikesort.py +++ b/tests/scripts/test_phy_spikesort.py @@ -21,4 +21,4 @@ def test_quick_start(chdir_tempdir): main('download hybrid_10sec.dat') main('download hybrid_10sec.prm') main('spikesort hybrid_10sec.prm') - main('cluster-manual hybrid_10sec.kwik') + # main('cluster-manual hybrid_10sec.kwik')
Don't open the GUI by default in integration test.
diff --git a/generators/generator-constants.js b/generators/generator-constants.js index <HASH>..<HASH> 100644 --- a/generators/generator-constants.js +++ b/generators/generator-constants.js @@ -8,7 +8,7 @@ const DOCKER_MARIADB = 'mariadb:10.1.16'; const DOCKER_POSTGRESQL = 'postgres:9.5.3'; const DOCKER_MONGODB = 'mongo:3.3.9'; const DOCKER_CASSANDRA = 'cassandra:2.2.7'; -const DOCKER_ELASTICSEARCH = 'elasticsearch:1.7.5'; +const DOCKER_ELASTICSEARCH = 'elasticsearch:2.3.5'; const DOCKER_SONAR = 'sonarqube:5.6-alpine'; const DOCKER_JHIPSTER_CONSOLE = 'jhipster/jhipster-console:v1.3.0'; const DOCKER_JHIPSTER_ELASTICSEARCH = 'jhipster/jhipster-elasticsearch:v1.3.0';
upgrade elasticsearch to <I> (#<I>) Fix #<I>
diff --git a/lib/veewee/definitions.rb b/lib/veewee/definitions.rb index <HASH>..<HASH> 100644 --- a/lib/veewee/definitions.rb +++ b/lib/veewee/definitions.rb @@ -67,7 +67,7 @@ module Veewee git_template = false # Check if the template is a git repo - if template_name.start_with?("git://") + if template_name.start_with?("git://", "git+ssh://", "git+http://") git_template = true end
Support git via SSH and HTTP Simple and obvious patch who workforus® in production
diff --git a/pymatgen/analysis/local_env.py b/pymatgen/analysis/local_env.py index <HASH>..<HASH> 100644 --- a/pymatgen/analysis/local_env.py +++ b/pymatgen/analysis/local_env.py @@ -2489,8 +2489,8 @@ class CrystalNN(NearNeighbors): NNData = namedtuple("nn_data", ["all_nninfo", "cn_weights", "cn_nninfo"]) def __init__(self, weighted_cn=False, cation_anion=False, - distance_cutoffs=(1.25, 2), x_diff_weight=True, - search_cutoff=6, fingerprint_length=None): + distance_cutoffs=(1.25, 2), x_diff_weight=1.0, + search_cutoff=6.0, fingerprint_length=None): """ Initialize CrystalNN with desired paramters.
fix bug in default val (should be float, not bool)
diff --git a/desugarer.go b/desugarer.go index <HASH>..<HASH> 100644 --- a/desugarer.go +++ b/desugarer.go @@ -302,8 +302,8 @@ func desugar(astPtr *astNode, objLevel int) (err error) { return unimplErr case *astLocal: - for _, bind := range ast.binds { - err = desugar(&bind.body, objLevel) + for i := range ast.binds { + err = desugar(&ast.binds[i].body, objLevel) if err != nil { return }
Fix local bind body not being desugared In Go `for i, val := range arr` creates a *copy* so it was changing some temporary value.
diff --git a/grimoire_elk/panels.py b/grimoire_elk/panels.py index <HASH>..<HASH> 100755 --- a/grimoire_elk/panels.py +++ b/grimoire_elk/panels.py @@ -63,7 +63,8 @@ def find_item_json(elastic, type_, item_id): item_json_url = elastic.index_url+"/doc/"+item_id res = requests_ses.get(item_json_url, verify=False) - res.raise_for_status() + if res.status_code == 200 and res.status_code == 404: + res.raise_for_status() item_json = res.json()
[panels] If an item is not found in .kibana don't raise an exception It is normal than in an empty Kibana a dashboard for example does not exists yet. Just raise a requests exception if not found is not the case.
diff --git a/parsimonious/expressions.py b/parsimonious/expressions.py index <HASH>..<HASH> 100644 --- a/parsimonious/expressions.py +++ b/parsimonious/expressions.py @@ -32,18 +32,18 @@ class Expression(object): # http://stackoverflow.com/questions/1336791/dictionary-vs-object-which-is-more-efficient-and-why __slots__ = [] - def parse(self, text): + def parse(self, text, pos=0): """Return a parse tree of ``text``. Initialize the packrat cache and kick off the first ``match()`` call. """ - # The packrat cache. {expr: [length matched at text index 0, - # length matched at text index 1, ...], + # The packrat cache. {(oid, pos): [length matched at text index 0, + # length matched at text index 1, ...], # ...} cache = {} - return self.match(text, 0, cache) + return self.match(text, pos, cache) # TODO: Freak out if the text didn't parse completely: if we didn't get # all the way to the end. @@ -74,7 +74,11 @@ class Expression(object): class Literal(Expression): - """A string literal""" + """A string literal + + Use these if you can; they're the fastest. + + """ __slots__ = ['literal'] def __init__(self, literal):
Support parsing from not-the-beginning of a string.
diff --git a/lib/mongoid/document.rb b/lib/mongoid/document.rb index <HASH>..<HASH> 100644 --- a/lib/mongoid/document.rb +++ b/lib/mongoid/document.rb @@ -266,10 +266,10 @@ module Mongoid #:nodoc: def instantiate(attrs = nil) attributes = attrs || {} if attributes["_id"] - document = allocate - document.instance_variable_set(:@attributes, attributes) - document.setup_modifications - document + allocate.tap do |doc| + doc.instance_variable_set(:@attributes, attributes) + doc.setup_modifications + end else new(attrs) end
Slight refactoring of Document.instantiate
diff --git a/app/helpers/contextual_link_helpers.rb b/app/helpers/contextual_link_helpers.rb index <HASH>..<HASH> 100644 --- a/app/helpers/contextual_link_helpers.rb +++ b/app/helpers/contextual_link_helpers.rb @@ -22,7 +22,12 @@ module ContextualLinkHelpers end def icon_link_to(action, url = nil, options = {}) - classes = ["btn"] + classes = [] + if class_options = options.delete(:class) + classes << class_options.split(' ') + end + + classes << "btn" url ||= {:action => action}
Support passing in a :class param as option in icon_link_to.