diff
stringlengths 65
26.7k
| message
stringlengths 7
9.92k
|
|---|---|
diff --git a/test/support/helper.js b/test/support/helper.js
index <HASH>..<HASH> 100644
--- a/test/support/helper.js
+++ b/test/support/helper.js
@@ -3,7 +3,10 @@ var path = require('path'),
assert = require('assert'),
crypto = require('crypto'),
sax = require('sax'),
- diff = require('./diff').diff;
+ diff = require('./diff').diff,
+ constants = ((!process.ENOENT) >= 1) ?
+ require('constants') :
+ { ENOENT: process.ENOENT };
var helper = exports;
@@ -150,7 +153,7 @@ exports.rmrf = function rmrf(p) {
}
else fs.unlinkSync(p);
} catch (err) {
- if (err.errno !== process.ENOENT) throw err;
+ if (err.errno !== constants.ENOENT) throw err;
}
};
|
Node <I> compatibility.
|
diff --git a/lib/puppet/util/mode.rb b/lib/puppet/util/mode.rb
index <HASH>..<HASH> 100644
--- a/lib/puppet/util/mode.rb
+++ b/lib/puppet/util/mode.rb
@@ -20,11 +20,17 @@ module Puppet
end
def conf_dir
- which_dir("/etc/puppet", "~/.puppet")
+ which_dir(
+ (Puppet.features.win32? ? File.join(Dir::WINDOWS, "puppet", "etc") : "/etc/puppet"),
+ "~/.puppet"
+ )
end
def var_dir
- which_dir("/var/lib/puppet", "~/.puppet/var")
+ which_dir(
+ (Puppet.features.win32? ? File.join(Dir::WINDOWS, "puppet", "var") : "/var/lib/puppet"),
+ "~/.puppet/var"
+ )
end
def run_dir
|
Resolving conflicts with jes<I>:ticket/master/<I>-settings-mode
Jesse moved the code David was patching; the conflict resolution omits David's
change (since the code isn't there to be changed) and this moves the change to
the new location.
|
diff --git a/lib/chef/resource/lwrp_base.rb b/lib/chef/resource/lwrp_base.rb
index <HASH>..<HASH> 100644
--- a/lib/chef/resource/lwrp_base.rb
+++ b/lib/chef/resource/lwrp_base.rb
@@ -102,10 +102,6 @@ class Chef
run_context ? run_context.node : nil
end
- def lazy(&block)
- DelayedEvaluator.new(&block)
- end
-
protected
def loaded_lwrps
|
Remove now-unused function (already implemented by Chef::Resource)
|
diff --git a/spec/spec_helper.rb b/spec/spec_helper.rb
index <HASH>..<HASH> 100644
--- a/spec/spec_helper.rb
+++ b/spec/spec_helper.rb
@@ -1,6 +1,7 @@
# Configure Rails Envinronment
ENV["RAILS_ENV"] = "test"
require File.expand_path("../dummy/config/environment.rb", __FILE__)
+SPEC_ROOT = File.dirname(__FILE__)
require 'rspec/rails'
|
Defined the SPEC_ROOT constant for the specs that use it
|
diff --git a/xwiki-commons-core/xwiki-commons-crypto/xwiki-platform-crypto-common/src/main/java/org/xwiki/crypto/internal/digest/BouncyCastleDigest.java b/xwiki-commons-core/xwiki-commons-crypto/xwiki-platform-crypto-common/src/main/java/org/xwiki/crypto/internal/digest/BouncyCastleDigest.java
index <HASH>..<HASH> 100644
--- a/xwiki-commons-core/xwiki-commons-crypto/xwiki-platform-crypto-common/src/main/java/org/xwiki/crypto/internal/digest/BouncyCastleDigest.java
+++ b/xwiki-commons-core/xwiki-commons-crypto/xwiki-platform-crypto-common/src/main/java/org/xwiki/crypto/internal/digest/BouncyCastleDigest.java
@@ -76,12 +76,14 @@ public class BouncyCastleDigest implements Digest
@Override
public FilterInputStream getInputStream(InputStream is)
{
+ digest.reset();
return new DigestInputStream(is, digest);
}
@Override
public OutputStream getOutputStream()
{
+ digest.reset();
return new org.bouncycastle.crypto.io.DigestOutputStream(digest);
}
|
XWIKI-<I>: New Crypto Service API
- Properly reset digest as documented in comments
|
diff --git a/state/apiserver/usermanager/usermanager.go b/state/apiserver/usermanager/usermanager.go
index <HASH>..<HASH> 100644
--- a/state/apiserver/usermanager/usermanager.go
+++ b/state/apiserver/usermanager/usermanager.go
@@ -6,7 +6,7 @@ package usermanager
import (
"fmt"
- "github.com/loggo/loggo"
+ "github.com/juju/loggo"
"launchpad.net/juju-core/state"
"launchpad.net/juju-core/state/api/params"
|
Fix import; github.com/loggo/loggo moved to /juju/loggo.
|
diff --git a/Tone/shim/WaveShaperNode.js b/Tone/shim/WaveShaperNode.js
index <HASH>..<HASH> 100644
--- a/Tone/shim/WaveShaperNode.js
+++ b/Tone/shim/WaveShaperNode.js
@@ -1,6 +1,6 @@
define(["../core/Tone", "../shim/AudioContext"], function(Tone){
- if (Tone.supported){
+ if (Tone.supported && !Tone.global.AudioContext.prototype._native_createWaveShaper){
//fixes safari only bug which is still present in 11
var ua = navigator.userAgent.toLowerCase();
|
test if waveshaper shim is already installed
|
diff --git a/src/server/pkg/deploy/assets/assets.go b/src/server/pkg/deploy/assets/assets.go
index <HASH>..<HASH> 100644
--- a/src/server/pkg/deploy/assets/assets.go
+++ b/src/server/pkg/deploy/assets/assets.go
@@ -30,7 +30,7 @@ var (
// that hasn't been released, and which has been manually applied
// to the official v3.2.7 release.
etcdImage = "quay.io/coreos/etcd:v3.3.5"
- grpcProxyImage = "pachyderm/grpc-proxy:0.4.3"
+ grpcProxyImage = "pachyderm/grpc-proxy:0.4.4"
dashName = "dash"
workerImage = "pachyderm/worker"
pauseImage = "gcr.io/google_containers/pause-amd64:3.0"
|
Update GRPC Proxy version to <I>
|
diff --git a/vendor/seahorse/lib/seahorse/client/http/headers.rb b/vendor/seahorse/lib/seahorse/client/http/headers.rb
index <HASH>..<HASH> 100644
--- a/vendor/seahorse/lib/seahorse/client/http/headers.rb
+++ b/vendor/seahorse/lib/seahorse/client/http/headers.rb
@@ -1,6 +1,26 @@
module Seahorse
module Client
module Http
+
+ # Provides a Hash-like interface for HTTP headers. Header names
+ # are treated indifferently as lower-cased strings. Header values
+ # are cast to strings.
+ #
+ # headers = Http::Headers.new
+ # headers['Content-Length'] = 100
+ # headers[:Authorization] = 'Abc'
+ #
+ # headers.keys
+ # #=> ['content-length', 'authorization']]
+ #
+ # headers.values
+ # #=> ['100', 'Abc']
+ #
+ # You can get the header values as a vanilla hash by calling {#to_h}:
+ #
+ # headers.to_h
+ # #=> { 'content-length' => '100', 'authorization' => 'Abc' }
+ #
class Headers
include Enumerable
|
Documented the Seahorse::Client::Http::Headers class.
|
diff --git a/stix2patterns/pattern.py b/stix2patterns/pattern.py
index <HASH>..<HASH> 100644
--- a/stix2patterns/pattern.py
+++ b/stix2patterns/pattern.py
@@ -34,6 +34,12 @@ class Pattern(object):
self.__parse_tree = self.__do_parse(pattern_str)
def inspect(self):
+ """
+ Inspect a pattern. This gives information regarding the sorts of
+ operations, content, etc in use in the pattern.
+
+ :return: Pattern information
+ """
inspector = stix2patterns.inspector.InspectionListener()
antlr4.ParseTreeWalker.DEFAULT.walk(inspector, self.__parse_tree)
|
Added a missing docstring
|
diff --git a/lib/socketLogic.js b/lib/socketLogic.js
index <HASH>..<HASH> 100644
--- a/lib/socketLogic.js
+++ b/lib/socketLogic.js
@@ -150,6 +150,7 @@ function socketLogic (socket, secure, skynet){
socket.on('unsubscribe', function(data, fn) {
console.log('leaving room ', data.uuid);
socket.leave(data.uuid);
+ socket.leave(data.uuid + "_bc");
// Emit API request from device to room for subscribers
getDevice(socket, function(err, device){
if(err){ return; }
|
added leave bc room on unsubscribe websocket api
|
diff --git a/src/experimentalcode/erich/utilities/tree/rtree/RTreeChooseLeaf.java b/src/experimentalcode/erich/utilities/tree/rtree/RTreeChooseLeaf.java
index <HASH>..<HASH> 100644
--- a/src/experimentalcode/erich/utilities/tree/rtree/RTreeChooseLeaf.java
+++ b/src/experimentalcode/erich/utilities/tree/rtree/RTreeChooseLeaf.java
@@ -49,4 +49,4 @@ public class RTreeChooseLeaf implements InsertionStrategy {
assert (best > -1);
return best;
}
-}
+}
\ No newline at end of file
|
Cleanup RTree code. Working on-disk operation now. :-)
|
diff --git a/salt/master.py b/salt/master.py
index <HASH>..<HASH> 100644
--- a/salt/master.py
+++ b/salt/master.py
@@ -2211,7 +2211,11 @@ class ClearFuncs(object):
if save_load_func:
try:
- self.mminion.returners[fstr](clear_load['jid'], clear_load, minions=minions)
+ returner_args = [clear_load['jid'], clear_load]
+ returner_kwargs = {}
+ if 'minions' in salt.utils.args.get_function_argspec(self.mminion.returners[fstring]).args:
+ returner_kwargs['minions'] = minions
+ self.mminion.returners[fstr](*returner_args, **returner_kwargs)
except Exception:
log.critical(
'The specified returner threw a stack trace:\n',
|
don't break save_load backwards compat
|
diff --git a/lib/writer/xelatex.js b/lib/writer/xelatex.js
index <HASH>..<HASH> 100644
--- a/lib/writer/xelatex.js
+++ b/lib/writer/xelatex.js
@@ -35,6 +35,15 @@ function formatBlock(block) {
};
var formatImage = function(spans) {
+ if (spans.length > 0 && spans[0][0] === 'url') {
+ var url = spans[0][1];
+ var str =
+'\\begin{figure}[H]\n' +
+'\\centering\n' +
+'\\includegraphics{' + url + '}\n' +
+'\\end{figure}';
+ return str;
+ }
return formatSpans(spans);
};
|
[xelatex] Implement image formatting.
|
diff --git a/cosmic_ray/interceptors/__init__.py b/cosmic_ray/interceptors/__init__.py
index <HASH>..<HASH> 100644
--- a/cosmic_ray/interceptors/__init__.py
+++ b/cosmic_ray/interceptors/__init__.py
@@ -0,0 +1,5 @@
+# An interceptor is a callable that is called at the end of the "init" command.
+#
+# Interceptors are passed the initialized WorkDB, and they are able to do
+# things like mark certain mutations as skipped (i.e. so that they are never
+# performed).
|
Added docstring describing what an "interceptor" is.
|
diff --git a/lib/arel/visitors/to_sql.rb b/lib/arel/visitors/to_sql.rb
index <HASH>..<HASH> 100644
--- a/lib/arel/visitors/to_sql.rb
+++ b/lib/arel/visitors/to_sql.rb
@@ -229,9 +229,9 @@ module Arel
def visit_Arel_Nodes_SelectCore o, collector
collector << "SELECT"
- maybe_visit o.top, collector
+ collector = maybe_visit o.top, collector
- maybe_visit o.set_quantifier, collector
+ collector = maybe_visit o.set_quantifier, collector
unless o.projections.empty?
collector << SPACE
@@ -265,7 +265,7 @@ module Arel
end
end
- maybe_visit o.having, collector
+ collector = maybe_visit o.having, collector
unless o.windows.empty?
collector << WINDOW
|
Completes <I>e<I> in reusing `maybe_visit`
:sweat: I don't know why the tests did not fail, but to keep
the same syntax as before, `collector =` is required.
Maybe `visit` changes `collector` in-place, so the result is the
same, but since I'm not sure about the side effects, I think this
PR is needed to. Sorry! :sweat:
|
diff --git a/gwpy/plotter/decorators.py b/gwpy/plotter/decorators.py
index <HASH>..<HASH> 100644
--- a/gwpy/plotter/decorators.py
+++ b/gwpy/plotter/decorators.py
@@ -36,10 +36,13 @@ def auto_refresh(f, *args, **kwargs):
def axes_method(f, *args, **kwargs):
figure = args[0]
axes = [ax for ax in figure.axes]
+ if len(axes) == 0:
+ raise RuntimeError("No axes found for which '%s' is applicable"
+ % f.__name__)
if len(axes) != 1:
- raise ValueError("{0} only applicable for a Plot with a single set "
- "of data axes. With multiple data axes, you should "
- "access the {0} method of the relevant Axes (stored "
- "in ``Plot.axes``) directly".format(f.__name__))
+ raise RuntimeError("{0} only applicable for a Plot with a single set "
+ "of data axes. With multiple data axes, you should "
+ "access the {0} method of the relevant Axes (stored "
+ "in ``Plot.axes``) directly".format(f.__name__))
axesf = getattr(axes[0], f.__name__)
return axesf(*args[1:], **kwargs)
|
axes_method decorator: changed exeption type
- now throws RuntimeError if len(fig.axes) <= 1
|
diff --git a/setup.py b/setup.py
index <HASH>..<HASH> 100644
--- a/setup.py
+++ b/setup.py
@@ -22,7 +22,6 @@ setup(
author_email="jdherman8@gmail.com",
license=open('LICENSE.md').read(),
install_requires=[
- "docopt",
"numpy",
"scipy",
"scikit-learn",
|
seems docopt is not used anywhere
|
diff --git a/cider/_sh.py b/cider/_sh.py
index <HASH>..<HASH> 100644
--- a/cider/_sh.py
+++ b/cider/_sh.py
@@ -141,7 +141,8 @@ def mkdir_p(path):
def collapseuser(path):
home_dir = os.environ.get("HOME", pwd.getpwuid(os.getuid()).pw_dir)
if os.path.samefile(home_dir, commonpath([path, home_dir])):
- return os.path.join("~", os.path.relpath(path, home_dir))
+ relpath = os.path.relpath(path, home_dir)
+ return os.path.join("~", relpath) if relpath != "." else "~"
return path
|
Fix bug in collapseuser: $HOME should expand to "~", not "~/."
|
diff --git a/src/com/diffplug/common/base/Consumers.java b/src/com/diffplug/common/base/Consumers.java
index <HASH>..<HASH> 100644
--- a/src/com/diffplug/common/base/Consumers.java
+++ b/src/com/diffplug/common/base/Consumers.java
@@ -16,6 +16,7 @@
package com.diffplug.common.base;
import java.util.function.Consumer;
+import java.util.function.Function;
import java.util.function.Supplier;
/** Helper functions for manipulating {@link Consumer}. */
@@ -25,11 +26,15 @@ public class Consumers {
return value -> {};
}
+ /** The equivalent of {@link Function#compose}, but for Consumer. */
+ public static <T, R> Consumer<T> compose(Function<? super T, ? extends R> function, Consumer<? super R> consumer) {
+ return value -> consumer.accept(function.apply(value));
+ }
+
/**
* A Consumer which always passes its its input to whatever Consumer is supplied by target.
* <p>
- * By passing something mutable, such as a {@link Box}, as
- * the input, you can redirect the returned consumer.
+ * By passing something mutable, such as a {@link Box}, you can redirect the returned consumer.
*/
public static <T> Consumer<T> redirectable(Supplier<Consumer<T>> target) {
return value -> target.get().accept(value);
|
Added Consumers.compose().
|
diff --git a/src/Composer/Command/DependsCommand.php b/src/Composer/Command/DependsCommand.php
index <HASH>..<HASH> 100644
--- a/src/Composer/Command/DependsCommand.php
+++ b/src/Composer/Command/DependsCommand.php
@@ -17,6 +17,7 @@ use Composer\Package\Link;
use Composer\Package\PackageInterface;
use Composer\Repository\ArrayRepository;
use Composer\Repository\CompositeRepository;
+use Composer\Repository\PlatformRepository;
use Composer\Plugin\CommandEvent;
use Composer\Plugin\PluginEvents;
use Symfony\Component\Console\Input\InputInterface;
@@ -61,9 +62,11 @@ EOT
$commandEvent = new CommandEvent(PluginEvents::COMMAND, 'depends', $input, $output);
$composer->getEventDispatcher()->dispatch($commandEvent->getName(), $commandEvent);
+ $platformOverrides = $composer->getConfig()->get('platform') ?: array();
$repo = new CompositeRepository(array(
new ArrayRepository(array($composer->getPackage())),
$composer->getRepositoryManager()->getLocalRepository(),
+ new PlatformRepository(array(), $platformOverrides),
));
$needle = $input->getArgument('package');
|
Allow depend command to show results for platform packages, fixes #<I>, fixes #<I>
|
diff --git a/lib/sensu/client.rb b/lib/sensu/client.rb
index <HASH>..<HASH> 100644
--- a/lib/sensu/client.rb
+++ b/lib/sensu/client.rb
@@ -136,18 +136,10 @@ module Sensu
:check => check
})
extension = @extensions[:checks][check[:name]]
- begin
- extension.run do |output, status|
- check[:output] = output
- check[:status] = status
- publish_result(check)
- end
- rescue => error
- @logger.error('check extension error', {
- :extension => extension,
- :error => error.to_s,
- :backtrace => error.backtrace.join("\n")
- })
+ extension.run do |output, status|
+ check[:output] = output
+ check[:status] = status
+ publish_result(check)
end
end
|
[hacks] removed check extension run rescue, almost useless, threads man
|
diff --git a/tests/unit/geometry/ImportedTest.py b/tests/unit/geometry/ImportedTest.py
index <HASH>..<HASH> 100644
--- a/tests/unit/geometry/ImportedTest.py
+++ b/tests/unit/geometry/ImportedTest.py
@@ -27,8 +27,8 @@ class ImportedTest:
assert 'throat.endpoints' not in geo.keys()
assert 'throat.conduit_lengths' not in geo.keys()
assert 'throat.length' in geo.models.keys()
- assert 'throat.endpoints' in geo.models.keys()
- assert 'throat.conduit_lengths' in geo.models.keys()
+ assert 'throat.diffusive_size_factors' in geo.models.keys()
+ assert 'throat.hydraulic_size_factors' in geo.models.keys()
def test_with_added_pores(self):
net = op.network.Cubic(shape=[3, 3, 3])
|
updating Imported class to use new flow factors
|
diff --git a/src/Rebing/GraphQL/Support/SelectFields.php b/src/Rebing/GraphQL/Support/SelectFields.php
index <HASH>..<HASH> 100644
--- a/src/Rebing/GraphQL/Support/SelectFields.php
+++ b/src/Rebing/GraphQL/Support/SelectFields.php
@@ -169,7 +169,22 @@ class SelectFields {
$foreignKey = $parentTable ? ($parentTable . '.' . $foreignKey) : $foreignKey;
- if(is_a($relation, BelongsTo::class) || is_a($relation, MorphTo::class))
+ if(is_a($relation, MorphTo::class))
+ {
+ $foreignKeyType = $relation->getMorphType();
+ $foreignKeyType = $parentTable ? ($parentTable . '.' . $foreignKeyType) : $foreignKeyType;
+
+ if( ! in_array($foreignKey, $select))
+ {
+ $select[] = $foreignKey;
+ }
+
+ if( ! in_array($foreignKeyType, $select))
+ {
+ $select[] = $foreignKeyType;
+ }
+ }
+ elseif(is_a($relation, BelongsTo::class))
{
if( ! in_array($foreignKey, $select))
{
|
Fix MorphTo (#<I>)
* Fix MorphTo
MorphTo requires foreign key and foreign morph type
I tested and works
* Update SelectFields.php
|
diff --git a/packages/vaex-hdf5/vaex/hdf5/_version.py b/packages/vaex-hdf5/vaex/hdf5/_version.py
index <HASH>..<HASH> 100644
--- a/packages/vaex-hdf5/vaex/hdf5/_version.py
+++ b/packages/vaex-hdf5/vaex/hdf5/_version.py
@@ -1,2 +1,2 @@
-__version_tuple__ = (0, 1, 4, None, None)
-__version__ = '0.1.4'
+__version_tuple__ = (0, 2, 0)
+__version__ = '0.2.0'
|
Release <I> of vaex-hdf5
|
diff --git a/src/sap.m/test/sap/m/demokit/basicTemplate/webapp/controller/App.controller.js b/src/sap.m/test/sap/m/demokit/basicTemplate/webapp/controller/App.controller.js
index <HASH>..<HASH> 100644
--- a/src/sap.m/test/sap/m/demokit/basicTemplate/webapp/controller/App.controller.js
+++ b/src/sap.m/test/sap/m/demokit/basicTemplate/webapp/controller/App.controller.js
@@ -1,10 +1,13 @@
sap.ui.define([
- "sap/ui/core/mvc/Controller"
-], function(Controller) {
+ "sap/ui/core/mvc/Controller",
+ "sap/ui/demo/basicTemplate/model/formatter"
+], function(Controller, formatter) {
"use strict";
return Controller.extend("sap.ui.demo.basicTemplate.controller.App", {
+ formatter: formatter,
+
onInit: function () {
}
|
[INTERNAL] sap.m.demo.basicTemplate: Add a formatter reference
The App controller should have a reference to the formatter
Change-Id: I<I>fe<I>c8c<I>addfc<I>e2d1fb<I>dd2c<I>d
|
diff --git a/src/components/calendar/Calendar.js b/src/components/calendar/Calendar.js
index <HASH>..<HASH> 100644
--- a/src/components/calendar/Calendar.js
+++ b/src/components/calendar/Calendar.js
@@ -201,6 +201,24 @@ export class Calendar extends Component {
else
this.renderTooltip();
}
+
+ if (!this.props.onViewDateChange && !this.viewStateChanged) {
+ let propValue = this.props.value;
+ if (Array.isArray(propValue)) {
+ propValue = propValue[0];
+ }
+
+ let prevPropValue = prevProps.value;
+ if (Array.isArray(prevPropValue)) {
+ prevPropValue = prevPropValue[0];
+ }
+
+ if ((!prevPropValue && propValue) || (propValue && propValue.getTime() !== prevPropValue.getTime())) {
+ this.setState({
+ viewDate: (this.props.viewDate || propValue || new Date())
+ });
+ }
+ }
}
componentWillUnmount() {
@@ -596,6 +614,7 @@ export class Calendar extends Component {
});
}
else {
+ this.viewStateChanged = true;
this.setState({
viewDate: value
});
|
Fixed #<I> - Calendar Overlay doesnt open with current date after value update
|
diff --git a/src/main/java/water/api/Predict.java b/src/main/java/water/api/Predict.java
index <HASH>..<HASH> 100644
--- a/src/main/java/water/api/Predict.java
+++ b/src/main/java/water/api/Predict.java
@@ -33,8 +33,8 @@ public class Predict extends Request2 {
if( model instanceof Model )
fr = (( Model)model).score(data);
else fr = ((OldModel)model).score(data);
+ fr = new Frame(prediction,fr._names,fr.vecs()); // Jam in the frame key
fr.unlock();
- UKV.put(prediction, fr);
return Inspect2.redirect(this, prediction.toString());
} catch( Throwable t ) {
Log.err(t);
diff --git a/src/main/java/water/fvec/Frame.java b/src/main/java/water/fvec/Frame.java
index <HASH>..<HASH> 100644
--- a/src/main/java/water/fvec/Frame.java
+++ b/src/main/java/water/fvec/Frame.java
@@ -252,7 +252,7 @@ public class Frame extends Lockable<Frame> {
public final String[] names() { return _names; }
public int numCols() { return vecs().length; }
- public long numRows(){ return anyVec().length();}
+ public long numRows() { return anyVec()==null ? 0 : anyVec().length(); }
// Number of columns when categoricals expanded.
// Note: One level is dropped in each categorical col.
|
Remove debugging code
And inject Frame key in predict
|
diff --git a/alphalens/tears.py b/alphalens/tears.py
index <HASH>..<HASH> 100644
--- a/alphalens/tears.py
+++ b/alphalens/tears.py
@@ -20,7 +20,7 @@ import matplotlib.gridspec as gridspec
from itertools import product
-@plotting_context
+@p.plotting_context
def create_factor_tear_sheet(factor,
prices,
sectors=None,
|
BUG import plotting context from plotting
|
diff --git a/main.js b/main.js
index <HASH>..<HASH> 100644
--- a/main.js
+++ b/main.js
@@ -27,7 +27,7 @@ Hsm = module.exports = function Hsm(server){
};
function onRequest(req,res){
- var i,href,event,u,en,pn,path,e,h;
+ var i,href,event,u,en,path,e,h;
h = this[hsm];
e = h[emitter];
@@ -44,18 +44,15 @@ function onRequest(req,res){
url: u
};
- en = req.method + ' ' + (pn = u.pathname);
+ en = req.method + ' ' + u.pathname;
if(h.listeners(en)) return e.give(en,event);
- if(h.listeners(pn)) return e.give(pn,event);
path = u.pathname.split('/');
path.pop();
while(path.length){
- en = (req.method + ' ' + (pn = path.join('/'))).trim();
+ en = path.join('/');
if(h.listeners(en)) return e.give(en,event);
- if(h.listeners(pn)) return e.give(pn,event);
-
path.pop();
}
|
Now individual urls and paths are treated in a different way
|
diff --git a/bundles/org.eclipse.orion.client.ui/web/plugins/webEditingPlugin.js b/bundles/org.eclipse.orion.client.ui/web/plugins/webEditingPlugin.js
index <HASH>..<HASH> 100644
--- a/bundles/org.eclipse.orion.client.ui/web/plugins/webEditingPlugin.js
+++ b/bundles/org.eclipse.orion.client.ui/web/plugins/webEditingPlugin.js
@@ -282,7 +282,8 @@ define([
match: "\\b(?:" + keywords.JSKeywords.join("|") + ")\\b",
name: "KEYWORD"
}, {
- match: "'.*?(?:'|$)",
+ id: "string_singleQuote",
+ match: "'(?:\\\\.|[^'])*(?:'|$)",
name: "STRING"
}, {
begin: "'[^'\\n]*\\\\\n",
@@ -320,13 +321,12 @@ define([
{
include: "orion.c-like"
}, {
+ include: "orion.js#string_singleQuote"
+ }, {
id: keywords,
match: "\\b(?:true|false|null)\\b",
name: "KEYWORD"
}, {
- match: "'.*?(?:'|$)",
- name: "STRING"
- }, {
/* override c-like#comment_singleline */
id: "comment_singleline"
}, {
|
Bug <I> - Single quoted strings containing escaped quote are not highlighted properly
|
diff --git a/owslib/csw.py b/owslib/csw.py
index <HASH>..<HASH> 100644
--- a/owslib/csw.py
+++ b/owslib/csw.py
@@ -201,6 +201,7 @@ class CatalogueServiceWeb:
else:
# construct request
node0 = etree.Element(util.nspath_eval('csw:GetRecords', namespaces))
+ node0.set('xmlns:ows', namespaces['ows'])
node0.set('outputSchema', outputschema)
node0.set('outputFormat', format)
node0.set('version', self.version)
|
force ows namespace decl (for validating CSW servers and owslib clients using xml.etree)
|
diff --git a/libgit/browser_file.go b/libgit/browser_file.go
index <HASH>..<HASH> 100644
--- a/libgit/browser_file.go
+++ b/libgit/browser_file.go
@@ -60,17 +60,22 @@ func (bf *browserFile) ReadAt(p []byte, off int64) (n int, err error) {
_ = r.Close()
}()
- // Skip past the data we don't care about, one chunk at a time.
dataToSkip := off
+ bufSize := dataToSkip
+ if bufSize > bf.maxBufSize {
+ bufSize = bf.maxBufSize
+ }
+ buf := make([]byte, bufSize)
+
+ // Skip past the data we don't care about, one chunk at a time.
for dataToSkip > 0 {
- bufSize := dataToSkip
- if bufSize > bf.maxBufSize {
- bufSize = bf.maxBufSize
+ toRead := int64(len(buf))
+ if dataToSkip < toRead {
+ toRead = dataToSkip
}
- buf := make([]byte, dataToSkip)
// Throwaway data.
- n, err := r.Read(buf)
+ n, err := r.Read(buf[:toRead])
if err != nil {
return 0, err
}
|
browser_file: fix buffer issues with ReadAt
Suggested by songgao.
Issue: #<I>
|
diff --git a/activerecord/lib/active_record/connection_adapters/abstract/schema_statements.rb b/activerecord/lib/active_record/connection_adapters/abstract/schema_statements.rb
index <HASH>..<HASH> 100644
--- a/activerecord/lib/active_record/connection_adapters/abstract/schema_statements.rb
+++ b/activerecord/lib/active_record/connection_adapters/abstract/schema_statements.rb
@@ -859,7 +859,7 @@ module ActiveRecord
ActiveRecord::SchemaMigration.create_table
end
- def assume_migrated_upto_version(version, migrations_paths = ActiveRecord::Migrator.migrations_paths)
+ def assume_migrated_upto_version(version, migrations_paths)
migrations_paths = Array(migrations_paths)
version = version.to_i
sm_table = quote_table_name(ActiveRecord::Migrator.schema_migrations_table_name)
|
Don't set the default argument
It is always passed in
|
diff --git a/forms.go b/forms.go
index <HASH>..<HASH> 100644
--- a/forms.go
+++ b/forms.go
@@ -53,7 +53,7 @@ func helper(opts tags.Options, help HelperContext, fn func(opts tags.Options) he
hn = n.(string)
delete(opts, "var")
}
- if opts["errors"] == nil {
+ if opts["errors"] == nil && help.Context.Value("errors") != nil {
opts["errors"] = help.Context.Value("errors")
}
form := fn(opts)
|
fixed issue with errors showing in html by accident
|
diff --git a/lib/Rx/Observable/BaseObservable.php b/lib/Rx/Observable/BaseObservable.php
index <HASH>..<HASH> 100644
--- a/lib/Rx/Observable/BaseObservable.php
+++ b/lib/Rx/Observable/BaseObservable.php
@@ -468,7 +468,7 @@ abstract class BaseObservable implements ObservableInterface
function ($error) use ($d) {
$d->reject($error);
},
- function () use ($d, $value) {
+ function () use ($d, &$value) {
$d->resolve($value);
}
|
Make sure toPromise value is passed by reference
|
diff --git a/tests/extmod/ujson_loads.py b/tests/extmod/ujson_loads.py
index <HASH>..<HASH> 100644
--- a/tests/extmod/ujson_loads.py
+++ b/tests/extmod/ujson_loads.py
@@ -6,6 +6,8 @@ except:
def my_print(o):
if isinstance(o, dict):
print('sorted dict', sorted(o.items()))
+ elif isinstance(o, float):
+ print('%.3f' % o)
else:
print(o)
|
tests: Make printing of floats hopefully more portable.
|
diff --git a/cassandra/connection.py b/cassandra/connection.py
index <HASH>..<HASH> 100644
--- a/cassandra/connection.py
+++ b/cassandra/connection.py
@@ -984,6 +984,8 @@ class ConnectionHeartbeat(Thread):
else:
connection.reset_idle()
else:
+ log.debug("Cannot send heartbeat message on connection (%s) to %s",
+ id(connection), connection.host)
# make sure the owner sees this defunt/closed connection
owner.return_connection(connection)
self._raise_if_stopped()
|
Add a debug message when the connection heartbeat failed due to a closed connection
|
diff --git a/lib/clean.js b/lib/clean.js
index <HASH>..<HASH> 100644
--- a/lib/clean.js
+++ b/lib/clean.js
@@ -273,9 +273,13 @@ var CleanCSS = {
}
});
- // empty elements
- if (options.removeEmpty)
- replace(/[^\}]+?\{\}/g, '');
+ if (options.removeEmpty) {
+ // empty elements
+ replace(/[^\{\}]+\{\}/g, '');
+
+ // empty @media declarations
+ replace(/@media [^\{]+\{\}/g, '');
+ }
// remove universal selector when not needed (*#id, *.class etc)
replace(/\*([\.#:\[])/g, '$1');
diff --git a/test/unit-test.js b/test/unit-test.js
index <HASH>..<HASH> 100644
--- a/test/unit-test.js
+++ b/test/unit-test.js
@@ -644,6 +644,14 @@ vows.describe('clean-units').addBatch({
'just a semicolon': [
'div { ; }',
''
+ ],
+ 'inside @media': [
+ "@media screen { .test {} } .test1 { color: green; }",
+ ".test1{color:green}"
+ ],
+ 'inside not empty @media': [
+ "@media screen { .test {} .some { display:none } }",
+ "@media screen{.some{display:none}}"
]
}, { removeEmpty: true }),
'skip empty elements': cssContext({
|
Fixes #<I> - removing empty selectors from media query.
|
diff --git a/framework/core/src/Forum/Content/Index.php b/framework/core/src/Forum/Content/Index.php
index <HASH>..<HASH> 100644
--- a/framework/core/src/Forum/Content/Index.php
+++ b/framework/core/src/Forum/Content/Index.php
@@ -75,10 +75,14 @@ class Index
$params = [
'sort' => $sort && isset($sortMap[$sort]) ? $sortMap[$sort] : '',
- 'filter' => compact('q'),
+ 'filter' => [],
'page' => ['offset' => ($page - 1) * 20, 'limit' => 20]
];
+ if ($q) {
+ $params['filter']['q'] = $q;
+ }
+
$apiDocument = $this->getApiDocument($request->getAttribute('actor'), $params);
$defaultRoute = $this->settings->get('default_route');
|
Fix Index content, only use search when applicable.
|
diff --git a/clearly/safe_compiler.py b/clearly/safe_compiler.py
index <HASH>..<HASH> 100644
--- a/clearly/safe_compiler.py
+++ b/clearly/safe_compiler.py
@@ -66,7 +66,7 @@ def safe_compile_text(txt):
except ValueError:
if isinstance(node, ast.Name):
return node.id
- return repr(node)
+ return 'unsupported: {}'.format(type(node))
try:
txt = ast.parse(txt, mode='eval')
|
chore(clearly) mark unsupported nodes
|
diff --git a/packages/patternfly-4/react-core/src/components/AboutModal/examples/SimpleAboutModal.js b/packages/patternfly-4/react-core/src/components/AboutModal/examples/SimpleAboutModal.js
index <HASH>..<HASH> 100644
--- a/packages/patternfly-4/react-core/src/components/AboutModal/examples/SimpleAboutModal.js
+++ b/packages/patternfly-4/react-core/src/components/AboutModal/examples/SimpleAboutModal.js
@@ -31,7 +31,7 @@ class SimpleAboutModal extends React.Component {
brandImageSrc={brandImg}
brandImageAlt="Patternfly Logo"
logoImageSrc={logoImg}
- logoImageAlt="AboutModal Logo"
+ logoImageAlt="Patternfly Logo"
heroImageSrc={heroImg}
>
<TextContent>
|
docs(AboutModal): update logo alt text to Patternfly Logo (#<I>)
|
diff --git a/slim/Request.php b/slim/Request.php
index <HASH>..<HASH> 100644
--- a/slim/Request.php
+++ b/slim/Request.php
@@ -185,7 +185,7 @@ class Request {
* @return The cookie value, or NULL if cookie not set
*/
public function cookie($name) {
- return isset($_COOKIE[$name]) ? $_COOKIE['name'] : null;
+ return isset($_COOKIE[$name]) ? $_COOKIE[$name] : null;
}
/***** HELPERS *****/
|
Fixing bug in Request::cookie
|
diff --git a/src/Utility/Import.php b/src/Utility/Import.php
index <HASH>..<HASH> 100644
--- a/src/Utility/Import.php
+++ b/src/Utility/Import.php
@@ -370,22 +370,18 @@ class Import
$pathInfo = pathinfo($this->_request->data('file.name'));
- $filename = $pathInfo['filename'];
- // add current timestamp
$time = new Time();
- $filename .= ' ' . $time->i18nFormat('yyyy-MM-dd HH:mm:ss');
- // add extensions
- $filename .= '.' . $pathInfo['extension'];
+ $timestamp = $time->i18nFormat('yyyy-MM-dd HH:mm:ss');
- $uploadPath .= $filename;
+ $path = $uploadPath . $timestamp . ' ' . $pathInfo['filename'] . '.' . $pathInfo['extension'];
- if (!move_uploaded_file($this->_request->data('file.tmp_name'), $uploadPath)) {
+ if (!move_uploaded_file($this->_request->data('file.tmp_name'), $path)) {
$this->_flash->error(__('Unable to upload file to the specified directory.'));
return '';
}
- return $uploadPath;
+ return $path;
}
/**
|
Prefix timestamp on filename (task #<I>)
|
diff --git a/docs/src/app/core.js b/docs/src/app/core.js
index <HASH>..<HASH> 100644
--- a/docs/src/app/core.js
+++ b/docs/src/app/core.js
@@ -607,6 +607,7 @@
var line = 0;
var lineFix;
var scopeNS;
+ var jsDocsName;
var parts = resource.text
.replace(/\r\n|\n\r|\r/g, '\n')
.replace(/\/\*+(\s*@cut.+\*)?\//g, '')
@@ -616,6 +617,9 @@
lineFix = 0;
if (idx % 2)
{
+ if (jsDocsName = code.match(/@name\s+([a-z0-9_\$\.]+)/i))
+ jsDocsName = jsDocsName[1];
+
if (code.match(/@annotation/))
{
skipDeclaration = true;
@@ -660,7 +664,7 @@
var name = m[3];
lineFix = (m[1].match(/\n/g) || []).length;
- createJsDocEntity(jsdoc[jsdoc.length - 1], ns + '.' + (clsPrefix ? clsPrefix + '.prototype.' : '') + name);
+ createJsDocEntity(jsdoc[jsdoc.length - 1], jsDocsName || ns + '.' + (clsPrefix ? clsPrefix + '.prototype.' : '') + name);
if (isClass)
clsPrefix = name;
|
add support for @name in jsDocs
|
diff --git a/setup.py b/setup.py
index <HASH>..<HASH> 100644
--- a/setup.py
+++ b/setup.py
@@ -2,7 +2,7 @@ from setuptools import setup
setup (
name='jinja2-highlight',
- version='0.2.2',
+ version='0.3',
description='Jinja2 extension to highlight source code using Pygments',
keywords = 'syntax highlighting',
author='Tasos Latsas',
|
make release <I> to include readme file in package
|
diff --git a/ui/plugins/pinboard.js b/ui/plugins/pinboard.js
index <HASH>..<HASH> 100644
--- a/ui/plugins/pinboard.js
+++ b/ui/plugins/pinboard.js
@@ -46,6 +46,7 @@ treeherder.controller('PinboardCtrl',
}
$scope.classification.who = $scope.user.email;
thPinboard.save($scope.classification);
+ $rootScope.selectedJob = null;
} else {
thNotify.send("must be logged in to classify jobs", "danger");
}
|
unselect job after saving for pinned jobs
|
diff --git a/voice.go b/voice.go
index <HASH>..<HASH> 100644
--- a/voice.go
+++ b/voice.go
@@ -165,12 +165,16 @@ func (v *VoiceConnection) Close() {
v.Ready = false
v.speaking = false
+ v.log(LogInformational, "past lock")
if v.close != nil {
+ v.log(LogInformational, "closing v.close")
close(v.close)
v.close = nil
}
+ v.log(LogInformational, "past closing v.close")
if v.udpConn != nil {
+ v.log(LogInformational, "closing udp")
err := v.udpConn.Close()
if err != nil {
log.Println("error closing udp connection: ", err)
@@ -178,13 +182,16 @@ func (v *VoiceConnection) Close() {
v.udpConn = nil
}
+ v.log(LogInformational, "past closing udp")
if v.wsConn != nil {
+ v.log(LogInformational, "closing wsConn")
err := v.wsConn.Close()
if err != nil {
log.Println("error closing websocket connection: ", err)
}
v.wsConn = nil
}
+ v.log(LogInformational, "all done, returning")
}
// AddHandler adds a Handler for VoiceSpeakingUpdate events.
|
Added lots of temp logs into voice close func
|
diff --git a/mongo/oplog.go b/mongo/oplog.go
index <HASH>..<HASH> 100644
--- a/mongo/oplog.go
+++ b/mongo/oplog.go
@@ -102,8 +102,12 @@ func (t *OplogTailer) loop() error {
// idsForLastTimestamp records the unique operation ids that have
// been reported for the most recently reported oplog
// timestamp. This is used to avoid re-reporting oplog entries
- // when the iterator is restarted. It's possible for there to be
- // many oplog entries for a given timestamp.
+ // when the iterator is restarted. These timestamps are unique for
+ // a given mongod but when there's multiple replicaset members
+ // it's possible for there to be multiple oplog entries for a
+ // given timestamp.
+ //
+ // See: http://docs.mongodb.org/v2.4/reference/bson-types/#timestamps
var idsForLastTimestamp []int64
for {
|
mongo: clarified description of idsForLastTimestamp
|
diff --git a/src/howler.core.js b/src/howler.core.js
index <HASH>..<HASH> 100644
--- a/src/howler.core.js
+++ b/src/howler.core.js
@@ -819,9 +819,9 @@
if (sound._node) {
if (self._webAudio) {
- // make sure the sound has been created
- if (!sound._node.bufferSource) {
- return self;
+ // Make sure the sound has been created.
+ if (sound._node.bufferSource) {
+ continue;
}
if (typeof sound._node.bufferSource.stop === 'undefined') {
@@ -890,9 +890,8 @@
if (sound._node) {
if (self._webAudio) {
- // make sure the sound's AudioBufferSourceNode has been created
+ // Make sure the sound's AudioBufferSourceNode has been created.
if (sound._node.bufferSource) {
-
if (typeof sound._node.bufferSource.stop === 'undefined') {
sound._node.bufferSource.noteOff(0);
} else {
|
Fix group pause issue
Thanks #<I>
|
diff --git a/lib/govspeak/html_validator.rb b/lib/govspeak/html_validator.rb
index <HASH>..<HASH> 100644
--- a/lib/govspeak/html_validator.rb
+++ b/lib/govspeak/html_validator.rb
@@ -18,7 +18,7 @@ class Govspeak::HtmlValidator
# Make whitespace in html tags consistent
def normalise_html(html)
- Nokogiri::HTML.parse(html).to_s
+ Nokogiri::HTML5.fragment(html).to_s
end
def govspeak_to_html
|
Use Nokogiri::HTML5#fragment for normalising html
This will use the Nokogump and the Gumbo HTML5 parser for HTML
normalisation, but as this is already required by Sanitize this
should be ok. Changing `parse => fragment` should have no effect
and will stip out superfluous elements such as html, head and body.
|
diff --git a/salt/loader.py b/salt/loader.py
index <HASH>..<HASH> 100644
--- a/salt/loader.py
+++ b/salt/loader.py
@@ -1243,7 +1243,8 @@ class LazyLoader(salt.utils.lazy.LazyDict):
except OSError:
pass
else:
- files = pycache_files + files
+ pycache_files.extend(files)
+ files = pycache_files
for filename in files:
try:
dirname, basename = os.path.split(filename)
|
Optimization: don't allocate a new list to concatenate
|
diff --git a/lib/watir-webdriver/elements/font.rb b/lib/watir-webdriver/elements/font.rb
index <HASH>..<HASH> 100644
--- a/lib/watir-webdriver/elements/font.rb
+++ b/lib/watir-webdriver/elements/font.rb
@@ -8,10 +8,4 @@ module Watir
FontCollection.new(self, extract_selector(args).merge(:tag_name => "font"))
end
end # Container
-
- class FontCollection < ElementCollection
- def element_class
- Font
- end
- end # FontCollection
end # Watir
\ No newline at end of file
|
Don't define FontCollection twice
|
diff --git a/benchexec/tools/symbiotic.py b/benchexec/tools/symbiotic.py
index <HASH>..<HASH> 100644
--- a/benchexec/tools/symbiotic.py
+++ b/benchexec/tools/symbiotic.py
@@ -144,6 +144,8 @@ class Tool(OldSymbiotic):
return result.RESULT_FALSE_FREE
elif line.startswith('RESULT: false(valid-memtrack)'):
return result.RESULT_FALSE_MEMTRACK
+ elif line.startswith('RESULT: false(valid-memcleanup)'):
+ return result.RESULT_FALSE_MEMCLEANUP
elif line.startswith('RESULT: false(no-overflow)'):
return result.RESULT_FALSE_OVERFLOW
elif line.startswith('RESULT: false(termination)'):
|
symbiotic: parse results for memcleanup property
|
diff --git a/js/bitfinex2.js b/js/bitfinex2.js
index <HASH>..<HASH> 100644
--- a/js/bitfinex2.js
+++ b/js/bitfinex2.js
@@ -315,7 +315,7 @@ module.exports = class bitfinex2 extends bitfinex {
}
fetchMarkets () {
- return this.load_markets();
+ return this.loadMarkets ();
}
parseTicker (ticker, market = undefined) {
|
Fix spacing and camelCase method
|
diff --git a/yowsup/layers/protocol_messages/protocolentities/protomessage.py b/yowsup/layers/protocol_messages/protocolentities/protomessage.py
index <HASH>..<HASH> 100644
--- a/yowsup/layers/protocol_messages/protocolentities/protomessage.py
+++ b/yowsup/layers/protocol_messages/protocolentities/protomessage.py
@@ -34,7 +34,7 @@ class ProtomessageProtocolEntity(MessageProtocolEntity):
def toProtocolTreeNode(self):
node = super(ProtomessageProtocolEntity, self).toProtocolTreeNode()
- node.addChild(ProtoProtocolEntity(self.proto.SerializeToString()).toProtocolTreeNode())
+ node.addChild(ProtoProtocolEntity(self._proto.SerializeToString()).toProtocolTreeNode())
return node
|
[fix] fix protomessage.toProtocolTreeNode
It was using .proto which is overridden by subclasses to their
directly related child proto message, while protomessage should
deal with the parent Message (._proto)
|
diff --git a/lib/day.rb b/lib/day.rb
index <HASH>..<HASH> 100644
--- a/lib/day.rb
+++ b/lib/day.rb
@@ -15,9 +15,12 @@ module Day
class Ru
# getting class variables from 'data' folder contents
- Dir.glob('../data/*.yml') do |yml|
+ prev_dir = Dir.pwd
+ Dir.chdir(File.join(File.dirname(__FILE__), '..', 'data'))
+ Dir.glob('*.yml') do |yml|
class_variable_set "@@#{yml.gsub('.yml', '')}".to_sym, YAML::load(File.read(yml))
end
+ Dir.chdir prev_dir
# TODO: - string to utf8 if Ruby version > 1.9
# - convert to lowercase with Unicode gem
|
change dir to previous after initialize class variables
|
diff --git a/web/index.php b/web/index.php
index <HASH>..<HASH> 100755
--- a/web/index.php
+++ b/web/index.php
@@ -29,8 +29,8 @@ class scoilnetExample {
"api_key" => "d0d588d94c05b3e1e4e37159f1cf5458f645193f5b45f092874d5747628ce8a3",
];
- $this->defaultConfig = array('school_discipline' => '40,50');
-
+ // $this->defaultConfig = array('school_discipline' => '40,50');
+ $this->defaultConfig = array();
$this->scoilnetClient = new \OAuth2\ScoilnetClient($config);
}
|
Update code to support preselected facet values
|
diff --git a/angr/simos.py b/angr/simos.py
index <HASH>..<HASH> 100644
--- a/angr/simos.py
+++ b/angr/simos.py
@@ -613,7 +613,10 @@ class SimLinux(SimOS):
for reloc in binary.relocs:
if reloc.symbol is None or reloc.resolvedby is None:
continue
- if reloc.resolvedby.type != 'STT_GNU_IFUNC':
+ try:
+ if reloc.resolvedby.elftype != 'STT_GNU_IFUNC':
+ continue
+ except AttributeError:
continue
gotaddr = reloc.addr + binary.rebase_addr
gotvalue = self.proj.loader.memory.read_addr_at(gotaddr)
|
Update for CLE api changes, check explicit elf symbol
|
diff --git a/src/customizer.js b/src/customizer.js
index <HASH>..<HASH> 100644
--- a/src/customizer.js
+++ b/src/customizer.js
@@ -64,8 +64,8 @@ var Customizer = extend(EventEmitter, /** @lends Customizer# */ {
_.extend(this, _.pick(options, optionKeys));
- if (!this._optimizer) {
- this._optimizer = new ConfigurationOptimizer(this.deviceAddress);
+ if (!this.optimizer) {
+ this.optimizer = new ConfigurationOptimizer(this.deviceAddress);
}
},
@@ -84,11 +84,11 @@ var Customizer = extend(EventEmitter, /** @lends Customizer# */ {
},
_getInitialConfiguration: function(oldConfig) {
- return this._optimizer.getInitialConfiguration(oldConfig);
+ return this.optimizer.getInitialConfiguration(oldConfig);
},
_optimizeConfiguration: function(oldConfig) {
- return this._optimizer.optimizeConfiguration(oldConfig);
+ return this.optimizer.optimizeConfiguration(oldConfig);
},
});
|
Fix bug regarding wrong `optimizer` prop in Customizer.
|
diff --git a/nion/swift/test/DocumentController_test.py b/nion/swift/test/DocumentController_test.py
index <HASH>..<HASH> 100644
--- a/nion/swift/test/DocumentController_test.py
+++ b/nion/swift/test/DocumentController_test.py
@@ -124,6 +124,8 @@ class TestDocumentControllerClass(unittest.TestCase):
display_panel = DisplayPanel.DisplayPanel(document_controller, dict())
display_panel.set_displayed_data_item(data_item)
self.assertIsNotNone(weak_data_item())
+ display_panel.close()
+ display_panel.canvas_item.close()
document_controller.close()
document_controller = None
data_item = None
|
Minor garbage collection test improvement (be sure to release data panel).
|
diff --git a/jax/version.py b/jax/version.py
index <HASH>..<HASH> 100644
--- a/jax/version.py
+++ b/jax/version.py
@@ -12,4 +12,4 @@
# See the License for the specific language governing permissions and
# limitations under the License.
-__version__ = "0.1.52"
+__version__ = "0.1.53"
|
update version for pypi
|
diff --git a/widgets/TbActiveForm.php b/widgets/TbActiveForm.php
index <HASH>..<HASH> 100644
--- a/widgets/TbActiveForm.php
+++ b/widgets/TbActiveForm.php
@@ -376,7 +376,7 @@ class TbActiveForm extends CActiveForm
));
echo '</div>';
echo '<div class="span4">';
- $this->widget('bootstrap.widgets.TbBootTimepicker', array(
+ $this->widget('bootstrap.widgets.TbTimepicker', array(
'htmlOptions'=>$options['time']['htmlOptions'],
'options'=>isset($options['time']['options'])?$options['time']['options']:array(),
'events'=>isset($options['time']['events'])?$options['time']['events']:array(),
|
This method needs refactoring... fixing typo bug for the moment
|
diff --git a/config/karma.conf.js b/config/karma.conf.js
index <HASH>..<HASH> 100644
--- a/config/karma.conf.js
+++ b/config/karma.conf.js
@@ -30,7 +30,7 @@ module.exports = function (config) {
// - Safari (only Mac; has to be installed with `npm install karma-safari-launcher`)
// - PhantomJS
// - IE (only Windows; has to be installed with `npm install karma-ie-launcher`)
- browsers: ['PhantomJS'],
+ browsers: ['Chrome'],
customLaunchers: {
Chrome_travis_ci: {
base: 'Chrome',
|
Update karma.conf.js
|
diff --git a/src/main/java/com/buschmais/jqassistant/commandline/task/ServerTask.java b/src/main/java/com/buschmais/jqassistant/commandline/task/ServerTask.java
index <HASH>..<HASH> 100644
--- a/src/main/java/com/buschmais/jqassistant/commandline/task/ServerTask.java
+++ b/src/main/java/com/buschmais/jqassistant/commandline/task/ServerTask.java
@@ -4,8 +4,8 @@ import com.buschmais.jqassistant.commandline.CliExecutionException;
import com.buschmais.jqassistant.core.plugin.api.PluginRepositoryException;
import com.buschmais.jqassistant.core.store.api.Store;
import com.buschmais.jqassistant.core.store.impl.EmbeddedGraphStore;
-import com.buschmais.jqassistant.scm.neo4jserver.api.Server;
-import com.buschmais.jqassistant.scm.neo4jserver.impl.ExtendedCommunityNeoServer;
+import com.buschmais.jqassistant.neo4jserver.api.Server;
+import com.buschmais.jqassistant.neo4jserver.impl.ExtendedCommunityNeoServer;
import org.apache.commons.cli.CommandLine;
import org.apache.commons.cli.Option;
import org.apache.commons.cli.OptionBuilder;
|
Fixed import statements after updating the dependencies to jQAssistant projects.
|
diff --git a/src/main/java/org/minimalj/frontend/editor/WizardStep.java b/src/main/java/org/minimalj/frontend/editor/WizardStep.java
index <HASH>..<HASH> 100644
--- a/src/main/java/org/minimalj/frontend/editor/WizardStep.java
+++ b/src/main/java/org/minimalj/frontend/editor/WizardStep.java
@@ -10,8 +10,6 @@ public interface WizardStep<T> {
public String getTitle();
- public String getDescription();
-
public T createObject();
public Form<T> createForm();
|
WizardStep: removed getDescription. Not used anywhere
|
diff --git a/src/LeagueAPI/LeagueAPI.php b/src/LeagueAPI/LeagueAPI.php
index <HASH>..<HASH> 100644
--- a/src/LeagueAPI/LeagueAPI.php
+++ b/src/LeagueAPI/LeagueAPI.php
@@ -1988,6 +1988,9 @@ class LeagueAPI
*/
public function getStaticChampion( int $champion_id, bool $extended = false, string $locale = 'en_US', string $version = null ): StaticData\StaticChampionDto
{
+ if ($champion_id == -1)
+ return new StaticData\StaticChampionDto(["id" => -1, "name" => "None"], $this);
+
$result = $this->_makeStaticCall("RiotAPI\\DataDragonAPI\\DataDragonAPI::getStaticChampionByKey", $champion_id, $locale, $version);
if ($extended && $result)
{
|
Workaroud for Match StaticData linking in case of "None" bans (#<I>)
|
diff --git a/views/js/controller/TaoEventLog/show.js b/views/js/controller/TaoEventLog/show.js
index <HASH>..<HASH> 100644
--- a/views/js/controller/TaoEventLog/show.js
+++ b/views/js/controller/TaoEventLog/show.js
@@ -88,7 +88,12 @@ define([
sortable: true,
filterable: true,
transform: function(roles, row) {
- var list = roles ? roles.split(',') : [''];
+ var list = [''];
+
+ if (roles) {
+ list = roles.split(',');
+ }
+
row.roles_list = list.join('<br>');
return list.shift();
|
Simplified rule in roles tranformer handler
|
diff --git a/tasks/coffee.js b/tasks/coffee.js
index <HASH>..<HASH> 100644
--- a/tasks/coffee.js
+++ b/tasks/coffee.js
@@ -44,8 +44,10 @@ module.exports = function(grunt) {
}
});
- grunt.log.writeln(actionCounts.fileCreated + ' files created.');
- grunt.log.writeln(actionCounts.mapCreated + ' source map files created.');
+ grunt.log.ok(actionCounts.fileCreated + ' files created.');
+ if (actionCounts.mapCreated > 0) {
+ grunt.log.ok(actionCounts.mapCreated + ' source map files created.');
+ }
});
|
Switch to "log.ok". Only show source map log if maps are created.
|
diff --git a/setup.py b/setup.py
index <HASH>..<HASH> 100644
--- a/setup.py
+++ b/setup.py
@@ -31,6 +31,7 @@ class BuildExt(build_ext):
setup(
name='toolkit',
version='0.0.1',
+ install_requires = ['numpy', 'scikit-learn'],
author='Princeton Neuroscience Institute and Intel Corporation',
author_email='bryn.keller@intel.com',
url='https://github.com/IntelPNI/toolkit',
|
Add numpy and scikit-learn dependencies in setup.py
|
diff --git a/maven/src/main/java/org/owasp/dependencycheck/maven/BaseDependencyCheckMojo.java b/maven/src/main/java/org/owasp/dependencycheck/maven/BaseDependencyCheckMojo.java
index <HASH>..<HASH> 100644
--- a/maven/src/main/java/org/owasp/dependencycheck/maven/BaseDependencyCheckMojo.java
+++ b/maven/src/main/java/org/owasp/dependencycheck/maven/BaseDependencyCheckMojo.java
@@ -183,7 +183,7 @@ public abstract class BaseDependencyCheckMojo extends AbstractMojo implements Ma
* The output directory. This generally maps to "target".
*/
@SuppressWarnings("CanBeFinal")
- @Parameter(defaultValue = "${project.build.directory}", required = true)
+ @Parameter(defaultValue = "${project.build.directory}", required = true, property = "outputDirectory")
private File outputDirectory;
/**
* This is a reference to the >reporting< sections
|
Allow outputDirectory to be set from a user-property on the commandline using -DoutputDirectory
|
diff --git a/test/esp/credentials_test.rb b/test/esp/credentials_test.rb
index <HASH>..<HASH> 100644
--- a/test/esp/credentials_test.rb
+++ b/test/esp/credentials_test.rb
@@ -4,13 +4,13 @@ module ESP
class CredentialsTest < ActiveSupport::TestCase
context ESP::Credentials do
setup do
+ ESP::Credentials.access_key_id = nil
+ ESP::Credentials.secret_access_key = nil
@original_access_key_id = ENV['ESP_ACCESS_KEY_ID']
@original_secret_access_key = ENV['ESP_SECRET_ACCESS_KEY']
end
teardown do
- ESP::Credentials.access_key_id = nil
- ESP::Credentials.secret_access_key = nil
ENV['ESP_ACCESS_KEY_ID'] = @original_access_key_id
ENV['ESP_SECRET_ACCESS_KEY'] = @original_secret_access_key
end
|
Putting the cart before the horse.
|
diff --git a/pyvisa/rname.py b/pyvisa/rname.py
index <HASH>..<HASH> 100644
--- a/pyvisa/rname.py
+++ b/pyvisa/rname.py
@@ -184,7 +184,7 @@ class ResourceName(object):
rn.user = resource_name
return rn
except ValueError as ex:
- raise InvalidResourceName.bad_syntax(subclass.syntax,
+ raise InvalidResourceName.bad_syntax(subclass._visa_syntax,
resource_name, ex)
raise InvalidResourceName('Could not parse %s: unknown interface type'
|
Fixed bug in rname error reporting
|
diff --git a/lib/moodlelib.php b/lib/moodlelib.php
index <HASH>..<HASH> 100644
--- a/lib/moodlelib.php
+++ b/lib/moodlelib.php
@@ -440,7 +440,7 @@ function clean_param($param, $type) {
case PARAM_URL: // allow safe ftp, http, mailto urls
include_once($CFG->dirroot . '/lib/validateurlsyntax.php');
- if (!empty($param) && validateUrlSyntax($param, 's?H?S?F?E?u-P-a?I?p-f?q?r?')) {
+ if (!empty($param) && validateUrlSyntax($param, 's?H?S?F?E?u-P-a?I?p?f?q?r?')) {
// all is ok, param is respected
} else {
$param =''; // not really ok
|
MDL-<I> URL check is too restrictive, allow port
|
diff --git a/lib/ronin/network/http.rb b/lib/ronin/network/http.rb
index <HASH>..<HASH> 100644
--- a/lib/ronin/network/http.rb
+++ b/lib/ronin/network/http.rb
@@ -144,6 +144,10 @@ module Ronin
# Request Class an UnknownRequest exception will be raised.
#
def HTTP.request(options={})
+ unless options[:method]
+ raise(ArgumentError,"the :method option must be specified",caller)
+ end
+
name = options[:method].to_s.capitalize
unless Net::HTTP.const_defined?(name)
diff --git a/spec/network/http_spec.rb b/spec/network/http_spec.rb
index <HASH>..<HASH> 100644
--- a/spec/network/http_spec.rb
+++ b/spec/network/http_spec.rb
@@ -187,5 +187,11 @@ describe Network::HTTP do
req.class.should == Net::HTTP::Unlock
end
+
+ it "should raise an ArgumentError when :method is not specified" do
+ lambda {
+ Network::HTTP.request()
+ }.should raise_error(ArgumentError)
+ end
end
end
|
Make sure HTTP.request receives a :method option.
|
diff --git a/test/unit/effects.js b/test/unit/effects.js
index <HASH>..<HASH> 100644
--- a/test/unit/effects.js
+++ b/test/unit/effects.js
@@ -2133,7 +2133,11 @@ asyncTest( ".finish() is applied correctly when multiple elements were animated
ok( elems.eq( 0 ).queue().length, "non-empty queue for preceding element" );
ok( elems.eq( 2 ).queue().length, "non-empty queue for following element" );
elems.stop( true );
- start();
+
+ // setTimeout needed in order to avoid setInterval/setTimeout execution bug in FF
+ window.setTimeout(function() {
+ start();
+ }, 1000 );
}, 100 );
});
|
Fix test for #<I> ticket. Close gh-<I>
|
diff --git a/setup.py b/setup.py
index <HASH>..<HASH> 100755
--- a/setup.py
+++ b/setup.py
@@ -36,7 +36,7 @@ please refer to the `srp module documentation`_.
'''
setup(name = 'srp',
- version = '1.0.18',
+ version = '1.0.19',
description = 'Secure Remote Password',
author = 'Tom Cocagne',
author_email = 'tom.cocagne@gmail.com',
|
Updated version to <I>
|
diff --git a/ecell4/util/decorator.py b/ecell4/util/decorator.py
index <HASH>..<HASH> 100644
--- a/ecell4/util/decorator.py
+++ b/ecell4/util/decorator.py
@@ -219,10 +219,7 @@ class ReactionRulesCallback(Callback):
else:
raise RuntimeError, 'an invalid object was given [%s]' % (repr(obj))
-def get_model(is_netfree=False):
- global SPECIES_ATTRIBUTES
- global REACTION_RULES
-
+def get_model(is_netfree=False, without_reset=False):
if is_netfree:
m = ecell4.core.NetfreeModel()
else:
@@ -233,9 +230,17 @@ def get_model(is_netfree=False):
for rr in REACTION_RULES:
m.add_reaction_rule(rr)
+ if not without_reset:
+ reset_model()
+
+ return m
+
+def reset_model():
+ global SPECIES_ATTRIBUTES
+ global REACTION_RULES
+
SPECIES_ATTRIBUTES = []
REACTION_RULES = []
- return m
reaction_rules = functools.partial(ParseDecorator, ReactionRulesCallback)
species_attributes = functools.partial(ParseDecorator, SpeciesAttributesCallback)
|
get_model() does not always clear its state
|
diff --git a/napalm/ios.py b/napalm/ios.py
index <HASH>..<HASH> 100644
--- a/napalm/ios.py
+++ b/napalm/ios.py
@@ -122,7 +122,7 @@ class IOSDriver(NetworkDriver):
new_file_full = self.gen_full_path(filename=new_file, file_system=new_file_system)
cmd = 'show archive config differences {} {}'.format(base_file_full, new_file_full)
- diff = self.device.send_command(cmd, delay_factor=1)
+ diff = self.device.send_command(cmd, delay_factor=1.5)
diff = self.normalize_compare_config(diff)
return diff.strip()
|
Increasing delay_factor for config compare
|
diff --git a/lib/haml/exec.rb b/lib/haml/exec.rb
index <HASH>..<HASH> 100644
--- a/lib/haml/exec.rb
+++ b/lib/haml/exec.rb
@@ -319,7 +319,15 @@ END
::Sass::Plugin.on_creating_directory {|dirname| puts_action :directory, :green, dirname}
::Sass::Plugin.on_deleting_css {|filename| puts_action :delete, :yellow, filename}
::Sass::Plugin.on_compilation_error do |error, _, _|
- raise error unless error.is_a?(::Sass::SyntaxError)
+ unless error.is_a?(::Sass::SyntaxError)
+ if error.is_a?(Errno::ENOENT) && error.message =~ /^No such file or directory - (.*)$/ && $1 == @args[1]
+ flag = @options[:update] ? "--update" : "--watch"
+ error.message << "\n Did you mean: sass #{flag} #{@args[0]}:#{@args[1]}"
+ end
+
+ raise error
+ end
+
puts_action :error, :red, "#{error.sass_filename} (Line #{error.sass_line}: #{error.message})"
end
|
[Sass] Intelligently detect errors in --update/--watch usage.
|
diff --git a/agent/local/state.go b/agent/local/state.go
index <HASH>..<HASH> 100644
--- a/agent/local/state.go
+++ b/agent/local/state.go
@@ -1175,6 +1175,9 @@ func (l *State) SyncChanges() error {
defer l.Unlock()
// Sync the node level info if we need to.
+ // At the start to guarantee sync even if services or checks fail,
+ // which is more likely because there are more syncs happening for them.
+
if l.nodeInfoInSync {
l.logger.Debug("Node info in sync")
} else {
@@ -1183,10 +1186,6 @@ func (l *State) SyncChanges() error {
}
}
- // We will do node-level info syncing at the end, since it will get
- // updated by a service or check sync anyway, given how the register
- // API works.
-
// Sync the services
// (logging happens in the helper methods)
for id, s := range l.services {
|
Update node info sync comment (#<I>)
|
diff --git a/version.js b/version.js
index <HASH>..<HASH> 100644
--- a/version.js
+++ b/version.js
@@ -1,3 +1,3 @@
if (enyo && enyo.version) {
- enyo.version.onyx = "2.4.0-pre.1";
+ enyo.version.onyx = "2.4.0-pre.2";
}
|
Update version string to <I>-pre<I>
|
diff --git a/pull_into_place/structures.py b/pull_into_place/structures.py
index <HASH>..<HASH> 100644
--- a/pull_into_place/structures.py
+++ b/pull_into_place/structures.py
@@ -160,7 +160,7 @@ def read_and_calculate(workspace, pdb_paths):
score_table_pattern = re.compile(
r'^[A-Z]{3}(?:_[A-Z])?' # Residue name with optional tautomer.
r'(?::[A-Za-z_]+)?' # Optional patch type.
- r'_([1-9]+) ' # Residue number preceded by underscore.
+ r'_([0-9]+) ' # Residue number preceded by underscore.
) # The terminal space is important to match
# the full residue number.
|
Recognize residue numbers with 0's.
|
diff --git a/typedload/dataloader.py b/typedload/dataloader.py
index <HASH>..<HASH> 100644
--- a/typedload/dataloader.py
+++ b/typedload/dataloader.py
@@ -433,8 +433,21 @@ def _unionload(l: Loader, value, type_) -> Any:
exceptions = []
- # Try all types
+ # Give a score to the types, [ (score, type), ... ]
+ scored: List[Tuple[int, Type]] = []
for t in args:
+ if (type(value) == list and is_list(t)) or \
+ (type(value) == dict and is_dict(t)) or \
+ (type(value) == frozenset and is_frozenset(t)) or \
+ (type(value) == set and is_set(t)) or \
+ (type(value) == tuple and is_tuple(t)):
+ score = 1
+ else:
+ score = 0
+ scored.append((score, t))
+
+ # Try all types
+ for _, t in sorted(scored, key= lambda x: x[0], reverse=True):
try:
return l.load(value, t, annotation=Annotation(AnnotationType.UNION, t))
except Exception as e:
|
Implement iterable scoring in unions
For example, if the value is a list and there is a list in the
possibilities of the union, give that a score of 1, and try it
before the other possibilities.
|
diff --git a/flasgger/marshmallow_apispec.py b/flasgger/marshmallow_apispec.py
index <HASH>..<HASH> 100644
--- a/flasgger/marshmallow_apispec.py
+++ b/flasgger/marshmallow_apispec.py
@@ -82,6 +82,9 @@ class SwaggerView(MethodView):
def convert_schemas(d, definitions=None):
"""
Convert Marshmallow schemas to dict definitions
+
+ Also updates the optional definitions argument with any definitions
+ entries contained within the schema.
"""
if Schema is None:
raise RuntimeError('Please install marshmallow and apispec')
@@ -115,7 +118,8 @@ def convert_schemas(d, definitions=None):
else:
new[k] = v
- if len(definitions.keys()) > 0:
- new['definitions'] = definitions
+ # This key is not permitted anywhere except the very top level.
+ if 'definitions' in new:
+ del new['definitions']
return new
diff --git a/flasgger/utils.py b/flasgger/utils.py
index <HASH>..<HASH> 100644
--- a/flasgger/utils.py
+++ b/flasgger/utils.py
@@ -124,6 +124,7 @@ def get_specs(rules, ignore_verbs, optional_fields, sanitizer):
swag.update(
convert_schemas(apispec_swag, apispec_definitions)
)
+ swag['definitions'] = apispec_definitions
swagged = True
|
Fix erroneous extra definitions objects
Fixes #<I>
|
diff --git a/lib/DocblockResolver.php b/lib/DocblockResolver.php
index <HASH>..<HASH> 100644
--- a/lib/DocblockResolver.php
+++ b/lib/DocblockResolver.php
@@ -17,7 +17,9 @@ class DocblockResolver
}
if (preg_match('#inheritdoc#i', $node->getLeadingCommentAndWhitespaceText())) {
- return $class->parent()->methods()->get($node->getName())->type();
+ if ($class->parent()) {
+ return $class->parent()->methods()->get($node->getName())->type();
+ }
}
return Type::unknown();
|
TODO: Added test for inheritdoc
|
diff --git a/agents/lib/instance/right_script_provider.rb b/agents/lib/instance/right_script_provider.rb
index <HASH>..<HASH> 100644
--- a/agents/lib/instance/right_script_provider.rb
+++ b/agents/lib/instance/right_script_provider.rb
@@ -77,7 +77,9 @@ class Chef
# 3. Fork and wait
@mutex.synchronize do
- RightScale.popen25(sc_filename.gsub(' ', '\\ '), self, :on_read_stdout, :on_exit)
+ cmd = sc_filename.gsub(' ', '\\ ')
+ #RightScale.popen25(cmd, self, :on_read_stdout, :on_exit)
+ RightScale.popen3(cmd, self, :on_read_stdout, :on_read_stderr, :on_exit)
@exited_event.wait(@mutex)
end
|
Refs #<I> - Switch back to popen3 (it seems to cause less trouble).
|
diff --git a/lib/fluent/plugin/in_syslog.rb b/lib/fluent/plugin/in_syslog.rb
index <HASH>..<HASH> 100644
--- a/lib/fluent/plugin/in_syslog.rb
+++ b/lib/fluent/plugin/in_syslog.rb
@@ -80,16 +80,7 @@ module Fluent::Plugin
desc 'The prefix of the tag. The tag itself is generated by the tag prefix, facility level, and priority.'
config_param :tag, :string
desc 'The transport protocol used to receive logs.(udp, tcp)'
- config_param :protocol_type, default: :udp do |val|
- case val.downcase
- when 'tcp'
- :tcp
- when 'udp'
- :udp
- else
- raise Fluent::ConfigError, "syslog input protocol type should be 'tcp' or 'udp'"
- end
- end
+ config_param :protocol_type, :enum, list: [:tcp, :udp], default: :udp
desc 'If true, add source host to event record.'
config_param :include_source_host, :bool, default: false
desc 'Specify key of source host when include_source_host is true.'
@@ -149,6 +140,7 @@ module Fluent::Plugin
return
end
+ pri ||= record.delete('pri')
record[@source_host_key] = addr[2] if @include_source_host
emit(pri, time, record)
end
|
fix bug to miss to get priority from parsers with_priority enabled
|
diff --git a/patroni/__init__.py b/patroni/__init__.py
index <HASH>..<HASH> 100644
--- a/patroni/__init__.py
+++ b/patroni/__init__.py
@@ -159,7 +159,10 @@ class Patroni(object):
self.api.shutdown()
except Exception:
logger.exception('Exception during RestApi.shutdown')
- self.ha.shutdown()
+ try:
+ self.ha.shutdown()
+ except Exception:
+ logger.exception('Exception during Ha.shutdown')
self.logger.shutdown()
diff --git a/tests/test_patroni.py b/tests/test_patroni.py
index <HASH>..<HASH> 100644
--- a/tests/test_patroni.py
+++ b/tests/test_patroni.py
@@ -174,6 +174,7 @@ class TestPatroni(unittest.TestCase):
@patch.object(Thread, 'join', Mock())
def test_shutdown(self):
self.p.api.shutdown = Mock(side_effect=Exception)
+ self.p.ha.shutdown = Mock(side_effect=Exception)
self.p.shutdown()
def test_check_psycopg2(self):
|
Handle exception from Ha.shutdown (#<I>)
During the shutdown Patroni is trying to update its status in the DCS.
If the DCS is inaccessible an exception might be raised. Lack of exception handling prevents logger thread from stopping.
Fixes <URL>
|
diff --git a/core/src/main/java/org/springframework/security/config/OrderedFilterBeanDefinitionDecorator.java b/core/src/main/java/org/springframework/security/config/OrderedFilterBeanDefinitionDecorator.java
index <HASH>..<HASH> 100644
--- a/core/src/main/java/org/springframework/security/config/OrderedFilterBeanDefinitionDecorator.java
+++ b/core/src/main/java/org/springframework/security/config/OrderedFilterBeanDefinitionDecorator.java
@@ -119,5 +119,9 @@ public class OrderedFilterBeanDefinitionDecorator implements BeanDefinitionDecor
public String getBeanName() {
return beanName;
}
+
+ public String toString() {
+ return getClass() + "[ delegate=" + delegate + "; order=" + getOrder() + "]";
+ }
}
}
|
Added better toString() method to OrderedFilterDecorator to make it report the delegate filter information.
|
diff --git a/tests/Stubs/DecoratedAtom.php b/tests/Stubs/DecoratedAtom.php
index <HASH>..<HASH> 100644
--- a/tests/Stubs/DecoratedAtom.php
+++ b/tests/Stubs/DecoratedAtom.php
@@ -6,11 +6,6 @@ class DecoratedAtom implements HasPresenter
{
public $myProperty = "bazinga";
- /**
- * Get the presenter class.
- *
- * @return string The class path to the presenter.
- */
public function getPresenterClass()
{
return DecoratedAtomPresenter::class;
|
Ditched a docblock
|
diff --git a/test/lib/wed/key_test.js b/test/lib/wed/key_test.js
index <HASH>..<HASH> 100644
--- a/test/lib/wed/key_test.js
+++ b/test/lib/wed/key_test.js
@@ -25,7 +25,7 @@ describe("key", function () {
var k = key.makeKey(1);
assert.equal(k.which, 1);
assert.equal(k.keyCode, 1);
- assert.equal(k.charCode, 0);
+ assert.equal(k.charCode, 1);
assert.equal(k.ctrlKey, false);
assert.equal(k.altKey, false);
assert.equal(k.metaKey, false);
@@ -85,7 +85,7 @@ describe("key", function () {
it("matches a keypress key", function () {
var k = key.makeKey(1);
assert.isTrue(k.matchesEvent({which: 1, keyCode: 1,
- charCode: 0,
+ charCode: 1,
ctrlKey: false, altKey: false,
metaKey: false,
type: "keypress"}));
@@ -94,7 +94,7 @@ describe("key", function () {
it("returns false when not matching an event", function () {
var k = key.makeCtrlKey(1);
assert.isFalse(k.matchesEvent({which: 1, keyCode: 1,
- charCode: 0,
+ charCode: 1,
ctrlKey: false, altKey: false,
metaKey: false}));
});
|
Bugfix: recent key changes made this test fail.
|
diff --git a/secretservice/secretservice.go b/secretservice/secretservice.go
index <HASH>..<HASH> 100644
--- a/secretservice/secretservice.go
+++ b/secretservice/secretservice.go
@@ -313,6 +313,9 @@ func (s *SecretService) PromptAndWait(prompt dbus.ObjectPath) (paths *dbus.Varia
var result PromptCompletedResult
select {
case signal := <-s.signalCh:
+ if signal == nil {
+ continue
+ }
if signal.Name != "org.freedesktop.Secret.Prompt.Completed" {
continue
}
|
continue on nil signal in secretservice prompt waiter (#<I>)
|
diff --git a/internal/services/batch/batch_application_data_source.go b/internal/services/batch/batch_application_data_source.go
index <HASH>..<HASH> 100644
--- a/internal/services/batch/batch_application_data_source.go
+++ b/internal/services/batch/batch_application_data_source.go
@@ -58,9 +58,8 @@ func dataSourceBatchApplicationRead(d *pluginsdk.ResourceData, meta interface{})
ctx, cancel := timeouts.ForRead(meta.(*clients.Client).StopContext, d)
defer cancel()
- resourceGroup := d.Get("resource_group_name").(string)
- name := d.Get("name").(string)
- accountName := d.Get("account_name").(string)
+ subscriptionId := meta.(*clients.Client).Account.SubscriptionId
+ id := parse.NewApplicationID(subscriptionId, d.Get("resource_group_name").(string), d.Get("account_name").(string), d.Get("name").(string))
resp, err := client.Get(ctx, resourceGroup, accountName, name)
if err != nil {
|
Use ID parser to build the Application ID
|
diff --git a/markov_clustering/mcl.py b/markov_clustering/mcl.py
index <HASH>..<HASH> 100644
--- a/markov_clustering/mcl.py
+++ b/markov_clustering/mcl.py
@@ -81,7 +81,8 @@ def add_self_loops(matrix, loop_value):
def prune(matrix, threshold):
"""
- Prune the matrix so that very small edges are removed
+ Prune the matrix so that very small edges are removed.
+ The maximum value in each column is never pruned.
:param matrix: The matrix to be pruned
:param threshold: The value below which edges will be removed
@@ -95,6 +96,12 @@ def prune(matrix, threshold):
pruned = matrix.copy()
pruned[pruned < threshold] = 0
+ # keep max value in each column. same behaviour for dense/sparse
+ num_cols = matrix.shape[1]
+ row_indices = matrix.argmax(axis=0).reshape((num_cols,))
+ col_indices = np.arange(num_cols)
+ pruned[row_indices, col_indices] = matrix[row_indices, col_indices]
+
return pruned
|
make sure columns are not zeroed entirely while pruning
|
diff --git a/lib/foreman_remote_execution_core/fake_script_runner.rb b/lib/foreman_remote_execution_core/fake_script_runner.rb
index <HASH>..<HASH> 100644
--- a/lib/foreman_remote_execution_core/fake_script_runner.rb
+++ b/lib/foreman_remote_execution_core/fake_script_runner.rb
@@ -1,5 +1,6 @@
module ForemanRemoteExecutionCore
class FakeScriptRunner < ForemanTasksCore::Runner::Base
+ DEFAULT_REFRESH_INTERVAL = 1
@data = []
|
Fixes #<I> - Added DEFAULT_REFRESH_INTERVAL constant
|
diff --git a/lib/offsite_payments/integrations/payu_in.rb b/lib/offsite_payments/integrations/payu_in.rb
index <HASH>..<HASH> 100755
--- a/lib/offsite_payments/integrations/payu_in.rb
+++ b/lib/offsite_payments/integrations/payu_in.rb
@@ -42,7 +42,7 @@ module OffsitePayments #:nodoc:
:address1 => 'address1',
:address2 => 'address2',
:state => 'state',
- :zip => 'zip',
+ :zip => 'zipcode',
:country => 'country'
# Which tab you want to be open default on PayU
|
update payu_in.rb
corrected zip parameter to from zip to zipcode
|
diff --git a/src/Composer/Command/RequireCommand.php b/src/Composer/Command/RequireCommand.php
index <HASH>..<HASH> 100644
--- a/src/Composer/Command/RequireCommand.php
+++ b/src/Composer/Command/RequireCommand.php
@@ -206,6 +206,8 @@ EOT
);
} catch (\Exception $e) {
if ($this->newlyCreated) {
+ $this->revertComposerFile(false);
+
throw new \RuntimeException('No composer.json present in the current directory ('.$this->file.'), this may be the cause of the following exception.', 0, $e);
}
|
Fix new file being leftover if require in new dir fails to resolve requirements
|
diff --git a/app/helpers/enjoy/powered_helper.rb b/app/helpers/enjoy/powered_helper.rb
index <HASH>..<HASH> 100644
--- a/app/helpers/enjoy/powered_helper.rb
+++ b/app/helpers/enjoy/powered_helper.rb
@@ -1,5 +1,5 @@
module Enjoy::PoweredHelper
- def render_powered_block
+ def render_enjoy_powered_block
content_tag :div, class: 'powered' do
ret = []
ret << content_tag(:span, class: 'powered') do
diff --git a/template.rb b/template.rb
index <HASH>..<HASH> 100644
--- a/template.rb
+++ b/template.rb
@@ -325,8 +325,14 @@ inject_into_file 'app/models/user.rb', before: /^end/ do <<-TEXT
def self.generate_first_admin_user
if User.all.count == 0
- _email_pass = 'admin@#{app_name.downcase}.ru'
- User.create(roles: ["admin"], email: _email_pass, password: _email_pass, password_confirmation: _email_pass)
+ _email_pass = 'admin@#{app_name.dasherize.downcase}.ru'
+ if User.create(roles: ["admin"], email: _email_pass, password: _email_pass, password_confirmation: _email_pass)
+ puts "User with email and password '\#{_email_pass}' was created!"
+ else
+ puts 'error'
+ end
+ else
+ puts 'error'
end
end
|
fix for generate user; helper rename for enjoy compatibility
|
diff --git a/hazelcast/src/main/java/com/hazelcast/spi/impl/operationparker/impl/WaitSet.java b/hazelcast/src/main/java/com/hazelcast/spi/impl/operationparker/impl/WaitSet.java
index <HASH>..<HASH> 100644
--- a/hazelcast/src/main/java/com/hazelcast/spi/impl/operationparker/impl/WaitSet.java
+++ b/hazelcast/src/main/java/com/hazelcast/spi/impl/operationparker/impl/WaitSet.java
@@ -63,7 +63,7 @@ public class WaitSet implements LiveOperationsTracker, Iterable<WaitSetEntry> {
@Override
public void populate(LiveOperations liveOperations) {
for (WaitSetEntry entry : queue) {
- // we need to read out the data from the BlockedOperation; not from the ParkerOperation-container.
+ // we need to read out the data from the BlockedOperation; not from the WaitSetEntry
Operation operation = entry.getOperation();
liveOperations.add(operation.getCallerAddress(), operation.getCallId());
}
|
Minor doc fix in WaitSet (#<I>)
was refering to and old structure name
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.