diff
stringlengths 65
26.7k
| message
stringlengths 7
9.92k
|
|---|---|
diff --git a/mod/quiz/lib.php b/mod/quiz/lib.php
index <HASH>..<HASH> 100644
--- a/mod/quiz/lib.php
+++ b/mod/quiz/lib.php
@@ -590,7 +590,7 @@ function quiz_get_user_attempts($quizids, $userid, $status = 'finished', $includ
return $DB->get_records_select('quiz_attempts',
"quiz $insql AND userid = :userid" . $previewclause . $statuscondition,
- $params, 'attempt ASC');
+ $params, 'quiz, attempt ASC');
}
/**
|
MDL-<I> quiz: Ensure user attempts are deterministic for testing.
|
diff --git a/lxd/network/network_interface.go b/lxd/network/network_interface.go
index <HASH>..<HASH> 100644
--- a/lxd/network/network_interface.go
+++ b/lxd/network/network_interface.go
@@ -16,6 +16,7 @@ type Network interface {
fillConfig(config map[string]string) error
// Config.
+ ValidateName(name string) error
Validate(config map[string]string) error
Name() string
Type() string
|
lxd/network/network/interfaces: Adds ValidateName
|
diff --git a/src/components/DatePicker/index.js b/src/components/DatePicker/index.js
index <HASH>..<HASH> 100644
--- a/src/components/DatePicker/index.js
+++ b/src/components/DatePicker/index.js
@@ -165,13 +165,11 @@ class DatePickerComponent extends Component {
}
}
-function DatePicker({ locale, ...rest }) {
- return (
- <Consumer>
- {values => <DatePickerComponent locale={getLocale(values, locale)} {...rest} />}
- </Consumer>
- );
-}
+const DatePicker = React.forwardRef(({ locale, ...rest }, ref) => (
+ <Consumer>
+ {values => <DatePickerComponent ref={ref} locale={getLocale(values, locale)} {...rest} />}
+ </Consumer>
+));
DatePicker.propTypes = {
/** Sets the date for the DatePicker programmatically. */
|
fix: warning 'Function components cannot be given refs' on DatePicker component (#<I>)
|
diff --git a/salt/pillar/git_pillar.py b/salt/pillar/git_pillar.py
index <HASH>..<HASH> 100644
--- a/salt/pillar/git_pillar.py
+++ b/salt/pillar/git_pillar.py
@@ -124,15 +124,15 @@ def init(branch, repo_location):
def update(branch, repo_location):
'''
- Execute a git pull on all of the repos
+ Enxure you are on the right branch, and execute a git pull
'''
pid = os.getpid()
repo = init(branch, repo_location)
- origin = repo.remotes[0]
+ repo.git.checkout(branch)
lk_fn = os.path.join(repo.working_dir, 'update.lk')
with open(lk_fn, 'w+') as fp_:
fp_.write(str(pid))
- origin.fetch()
+ repo.git.pull()
try:
os.remove(lk_fn)
except (OSError, IOError):
@@ -188,10 +188,6 @@ def ext_pillar(pillar, repo_string):
if __opts__['pillar_roots'][branch_env] == [repo.working_dir]:
return {}
- git_ = repo.git
-
- git_.checkout(branch)
-
opts = deepcopy(__opts__)
opts['pillar_roots'][branch_env] = [repo.working_dir]
|
Fixing update of repo, it was updating the .git directory, but not the filesystem that is used for the pillar data
|
diff --git a/oauth2/__init__.py b/oauth2/__init__.py
index <HASH>..<HASH> 100644
--- a/oauth2/__init__.py
+++ b/oauth2/__init__.py
@@ -99,7 +99,7 @@ from oauth2.web import Request, Response
from oauth2.tokengenerator import Uuid4
from oauth2.grant import Scope
-VERSION = "0.5.0"
+VERSION = "0.6.0"
class Provider(object):
diff --git a/setup.py b/setup.py
index <HASH>..<HASH> 100644
--- a/setup.py
+++ b/setup.py
@@ -1,6 +1,6 @@
from setuptools import setup
-VERSION = "0.5.0"
+VERSION = "0.6.0"
setup(name="python-oauth2",
version=VERSION,
|
Bumping version to <I>
|
diff --git a/collatex-pythonport/collatex/collatex_core.py b/collatex-pythonport/collatex/collatex_core.py
index <HASH>..<HASH> 100644
--- a/collatex-pythonport/collatex/collatex_core.py
+++ b/collatex-pythonport/collatex/collatex_core.py
@@ -11,6 +11,7 @@ import networkx as nx
from _collections import deque
from networkx.algorithms.dag import topological_sort
from prettytable import PrettyTable
+from textwrap import wrap, fill
class Row(object):
@@ -73,7 +74,7 @@ class AlignmentTable(object):
self.rows.append(row)
for column in self.columns:
if sigil in column.tokens_per_witness:
- row.append(column.tokens_per_witness[sigil])
+ row.append(fill(column.tokens_per_witness[sigil], 20))
else:
row.append("-")
@@ -81,6 +82,7 @@ class AlignmentTable(object):
def print_plain_text(self):
# print the table vertically
x = PrettyTable()
+ x.hrules=1
for row in self.rows:
x.add_column("blah", row.cells)
print(x)
|
Added horizal rulers between rows of the table. Added wrapping of the
text segments in the cells.
|
diff --git a/shared/tracker/index.desktop.js b/shared/tracker/index.desktop.js
index <HASH>..<HASH> 100644
--- a/shared/tracker/index.desktop.js
+++ b/shared/tracker/index.desktop.js
@@ -109,6 +109,7 @@ export default class TrackerRender extends PureComponent<RenderProps> {
>
{this.props.showTeam &&
this.props.showTeam.fqName === team.fqName &&
+ this.props.selectedTeamRect &&
<Box key={team.fqName + 'popup'} style={{zIndex: 50}}>
<ModalPopupComponent
{...this.props}
|
Fix tracker popup jank (#<I>)
|
diff --git a/Doctrineum/Tests/SelfRegisteringType/AbstractSelfRegisteringTypeTest.php b/Doctrineum/Tests/SelfRegisteringType/AbstractSelfRegisteringTypeTest.php
index <HASH>..<HASH> 100644
--- a/Doctrineum/Tests/SelfRegisteringType/AbstractSelfRegisteringTypeTest.php
+++ b/Doctrineum/Tests/SelfRegisteringType/AbstractSelfRegisteringTypeTest.php
@@ -15,6 +15,9 @@ abstract class AbstractSelfRegisteringTypeTest extends TestWithMockery
public function I_can_register_it()
{
$typeClass = $this->getTypeClass();
+ /** @var Type $instance */
+ $instance = (new \ReflectionClass($typeClass))->newInstanceWithoutConstructor();
+ self::assertSame($this->getExpectedTypeName(), $instance->getName(), 'Expected different name of the type');
$typeClass::registerSelf();
self::assertTrue(
Type::hasType($this->getExpectedTypeName()),
|
Test of self registering type is more clear about problem with self registration
|
diff --git a/src/view.js b/src/view.js
index <HASH>..<HASH> 100644
--- a/src/view.js
+++ b/src/view.js
@@ -24,7 +24,9 @@ export default function view (Comp) {
scheduler: () => setState({}),
lazy: true
}),
- []
+ // Adding the original Comp here is necessary to make React Hot Reload work
+ // it does not affect behavior otherwise
+ [Comp]
)
// cleanup the reactive connections after the very last render of the component
|
fix behavior with react hot reload
|
diff --git a/devices.js b/devices.js
index <HASH>..<HASH> 100644
--- a/devices.js
+++ b/devices.js
@@ -229,7 +229,7 @@ const devices = [
description: 'MiJia door & window contact sensor',
supports: 'contact',
fromZigbee: [
- fz.xiaomi_battery_3v, fz.xiaomi_contact, fz.xiaomi_contact_interval, fz.ignore_onoff_change,
+ fz.xiaomi_battery_3v, fz.xiaomi_contact, fz.ignore_onoff_change,
fz.ignore_basic_change,
],
toZigbee: [],
|
Fixes issue #<I> (#<I>)
|
diff --git a/tests/PHPUnit/Integration/HttpTest.php b/tests/PHPUnit/Integration/HttpTest.php
index <HASH>..<HASH> 100644
--- a/tests/PHPUnit/Integration/HttpTest.php
+++ b/tests/PHPUnit/Integration/HttpTest.php
@@ -128,7 +128,7 @@ class HttpTest extends \PHPUnit_Framework_TestCase
/**
* @expectedException \Exception
- * @expectedExceptionMessage curl_exec: SSL certificate problem: Invalid certificate chain.
+ * @expectedExceptionMessage curl_exec: SSL certificate
*/
public function testCurlHttpsFailsWithInvalidCertificate()
{
|
Looser assertion in tests to pass on Travis
|
diff --git a/gutter/client/models.py b/gutter/client/models.py
index <HASH>..<HASH> 100644
--- a/gutter/client/models.py
+++ b/gutter/client/models.py
@@ -310,6 +310,7 @@ class Manager(threading.local):
def __getstate__(self):
inner_dict = vars(self).copy()
+ inner_dict.pop('inputs', False)
inner_dict.pop('storage', False)
return inner_dict
diff --git a/tests/test_integration.py b/tests/test_integration.py
index <HASH>..<HASH> 100644
--- a/tests/test_integration.py
+++ b/tests/test_integration.py
@@ -367,4 +367,18 @@ class TestIntegrationWithRedis(TestIntegration):
@fixture
def manager(self):
- return Manager(storage=RedisDict('gutter-tests', self.redis))
\ No newline at end of file
+ return Manager(storage=RedisDict('gutter-tests', self.redis))
+
+ def test_parent_switch_pickle_input(self):
+ import pickle
+
+ # Passing in module `pickle` as unpicklable input.
+ evil = User(deterministicstring('evil'), pickle)
+ self.manager.input(evil)
+
+ self.manager.autocreate = True
+
+ try:
+ self.manager.active('new:switch')
+ except pickle.PicklingError, e:
+ self.fail('Encountered pickling error: "%s"' % e)
|
Fixed issue where global inputs could get cached for parent switches.
This is a workaround for a bug where an input could be unpicklable, and
auto-creating switches would fail when the manager has an unpicklable
input.
The underlying issue (which still exists) is that Manager.register handles
unsetting Switch.manager before persisting except it does not take into
account parent switches having managers attached still.
|
diff --git a/TYPO3.Flow/Classes/AOP/F3_FLOW3_AOP_EmptyMethodInterceptorBuilder.php b/TYPO3.Flow/Classes/AOP/F3_FLOW3_AOP_EmptyMethodInterceptorBuilder.php
index <HASH>..<HASH> 100644
--- a/TYPO3.Flow/Classes/AOP/F3_FLOW3_AOP_EmptyMethodInterceptorBuilder.php
+++ b/TYPO3.Flow/Classes/AOP/F3_FLOW3_AOP_EmptyMethodInterceptorBuilder.php
@@ -29,9 +29,8 @@ namespace F3\FLOW3\AOP;
*/
/**
- * A AOP method interceptor code builder which generates an empty method as used
- * for introductions without advices delivering the implementation of the introduced
- * method.
+ * A AOP method interceptor code builder which generates an empty method as used for
+ * introductions without advices delivering the implementation of the introduced method.
*
* @package FLOW3
* @subpackage AOP
|
FLOW3:
* weirdest bugfix I ever did in PHP - yes, this comment reformat actually makes a bus error go away.
Original-Commit-Hash: <I>ab8c<I>ba<I>e6dff7ef<I>da<I>d<I>c5f7db8
|
diff --git a/bcbio/variation/strelka2.py b/bcbio/variation/strelka2.py
index <HASH>..<HASH> 100644
--- a/bcbio/variation/strelka2.py
+++ b/bcbio/variation/strelka2.py
@@ -188,8 +188,9 @@ def _af_annotate_and_filter(paired, items, in_file, out_file):
else: # germline?
alt_counts = rec.format('AD')[:,1:] # AD=REF,ALT1,ALT2,...
dp = np.sum(rec.format('AD')[:,0:], axis=1)
- assert np.all(dp > 0), rec
- af = np.true_divide(alt_counts, dp)
+ with np.errstate(divide='ignore', invalid='ignore'): # ignore division by zero and put AF=.0
+ af = np.true_divide(alt_counts, dp)
+ af[~np.isfinite(af)] = .0 # -inf inf NaN -> .0
rec.set_format('AF', af)
if np.any(af[tumor_index] < min_freq):
vcfutils.cyvcf_add_filter(rec, 'MinAF')
|
Strelka2 AF calc: silent div by zero and replace AF=inf with AF=<I>
|
diff --git a/github/__init__.py b/github/__init__.py
index <HASH>..<HASH> 100644
--- a/github/__init__.py
+++ b/github/__init__.py
@@ -46,6 +46,7 @@ from .GithubException import ( # type: ignore
BadCredentialsException,
BadUserAgentException,
GithubException,
+ IncompletableObject,
RateLimitExceededException,
TwoFactorException,
UnknownObjectException,
@@ -73,6 +74,7 @@ __all__ = [
Github,
GithubException,
GithubIntegration,
+ IncompletableObject,
InputFileContent,
InputGitAuthor,
InputGitTreeElement,
diff --git a/tests/Exceptions.py b/tests/Exceptions.py
index <HASH>..<HASH> 100644
--- a/tests/Exceptions.py
+++ b/tests/Exceptions.py
@@ -34,7 +34,6 @@
import pickle
import github
-from github.GithubException import IncompletableObject
from . import Framework
@@ -142,4 +141,4 @@ class SpecificExceptions(Framework.TestCase):
def testIncompletableObject(self):
github.UserKey.UserKey.setCheckAfterInitFlag(False)
obj = github.UserKey.UserKey(None, {}, {}, False)
- self.assertRaises(IncompletableObject, obj._completeIfNeeded)
+ self.assertRaises(github.IncompletableObject, obj._completeIfNeeded)
|
Export IncompletableObject in the github namespace (#<I>)
When IncompletableObject was added, it was only added to
GithubException, and not imported directly into the github namespace
like other exceptions. Correct that, and clean up the resultant now
unrequired import.
|
diff --git a/templates/zebra/index.js b/templates/zebra/index.js
index <HASH>..<HASH> 100644
--- a/templates/zebra/index.js
+++ b/templates/zebra/index.js
@@ -10,6 +10,7 @@
module.exports = (template, modules) => {
// modules: _, Promise, fs, dust, HtmlParser, utils
+ // const { _ } = modules;
const helper = require('./helper')(template, modules);
@@ -25,10 +26,10 @@ module.exports = (template, modules) => {
outline: 'tree', // "flat" | "tree"
collapsed: false,
toolbar: true,
- folded: false,
+ itemsFolded: false,
+ itemsOverflow: 'crop', // "crop" | "shrink"
badges: true, // true | false | <string>
search: true,
- fitItems: 'crop', // "crop" | "shrink"
animations: true
},
symbols: {
@@ -43,6 +44,7 @@ module.exports = (template, modules) => {
},
navbar: {
enabled: true,
+ dark: false,
animations: true,
menu: []
}
@@ -63,6 +65,7 @@ module.exports = (template, modules) => {
helper.setTitle();
helper.setDarkLightLogos();
+ helper.configNavMenu();
});
template.postBuild(() => {
|
refactor itemsOverflow, itemsFolded
|
diff --git a/app/templates/src/main/java/package/config/audit/_AuditEventConverter.java b/app/templates/src/main/java/package/config/audit/_AuditEventConverter.java
index <HASH>..<HASH> 100644
--- a/app/templates/src/main/java/package/config/audit/_AuditEventConverter.java
+++ b/app/templates/src/main/java/package/config/audit/_AuditEventConverter.java
@@ -2,12 +2,12 @@ package <%=packageName%>.config.audit;
import <%=packageName%>.domain.PersistentAuditEvent;
import org.springframework.boot.actuate.audit.AuditEvent;
-import org.springframework.context.annotation.Configuration;
import org.springframework.security.web.authentication.WebAuthenticationDetails;
+import org.springframework.stereotype.Component;
import java.util.*;
-@Configuration
+@Component
public class AuditEventConverter {
/**
|
Refactored the AuditEventConverter to a Spring bean
Fix #<I>
|
diff --git a/src/test/java/common/VersionTest.java b/src/test/java/common/VersionTest.java
index <HASH>..<HASH> 100644
--- a/src/test/java/common/VersionTest.java
+++ b/src/test/java/common/VersionTest.java
@@ -31,6 +31,20 @@ public class VersionTest {
assert oldVersion.compareTo(newVersion) == -1;
assert newVersion.compareTo(oldVersion) == 1;
}
+
+ @Test
+ public void compareSnapshotVersionWithTimestampTest(){
+ String olderVersionString = "0.0.1-SNAPSHOT";
+ String oldTimestamp = "20160401";
+ String newerVersionString = "0.0.1-SNAPSHOT";
+ String newTimestamp = "20160402";
+ Version oldVersion = new Version(olderVersionString);
+ oldVersion.setTimestamp(oldTimestamp);
+ Version newVersion = new Version(newerVersionString);
+ newVersion.setTimestamp(newTimestamp);
+ assert oldVersion.compareTo(newVersion) == -1;
+ assert newVersion.compareTo(oldVersion) == 1;
+ }
@Test
public void compareEqualReleaseVersionTest() {
|
Added compareSnapshotVersionWithTimestampTest
|
diff --git a/tasklib/task.py b/tasklib/task.py
index <HASH>..<HASH> 100644
--- a/tasklib/task.py
+++ b/tasklib/task.py
@@ -99,6 +99,15 @@ class SerializingObject(object):
def deserialize_wait(self, value):
return self.timestamp_deserializer(value)
+ def serialize_annotations(self, value):
+ value = value if value is not None else []
+ serialized_annotations = [annotation.export_data() for annotation in value]
+
+ if serialized_annotations:
+ return '[' + ','.join(serialized_annotations) + ']'
+ else:
+ return ''
+
def deserialize_annotations(self, data):
return [TaskAnnotation(self, d) for d in data] if data else []
|
SerializingObject: Add missing serialize_annotations method
|
diff --git a/lib/handlers/bin.js b/lib/handlers/bin.js
index <HASH>..<HASH> 100644
--- a/lib/handlers/bin.js
+++ b/lib/handlers/bin.js
@@ -25,7 +25,8 @@ module.exports = Observable.extend({
this.renderFiles(req, res);
},
getCustom: function (req, res, next) {
- var overrides = custom[req.subdomain].defaults,
+ var config = custom[req.subdomain],
+ overrides = config.defaults,
_this = this;
this.loadFiles(this.defaultFiles(), req.helpers, function (err, defaults) {
@@ -38,7 +39,7 @@ module.exports = Observable.extend({
defaults[key] = overrides[key];
}
}
- _this.render(req, res, defaults);
+ _this.render(req, res, defaults, config.settings);
});
},
getBin: function (req, res, next) {
|
Allow a custom settings property to be set on the jsbin object
|
diff --git a/src/Kernel/Support/Str.php b/src/Kernel/Support/Str.php
index <HASH>..<HASH> 100644
--- a/src/Kernel/Support/Str.php
+++ b/src/Kernel/Support/Str.php
@@ -89,6 +89,7 @@ class Str
* @throws RuntimeException
*
* @codeCoverageIgnore
+ *
* @throws \Exception
*/
public static function randomBytes($length = 16)
|
Apply fixes from StyleCI (#<I>)
[ci skip] [skip ci]
|
diff --git a/src/SALib/analyze/hdmr.py b/src/SALib/analyze/hdmr.py
index <HASH>..<HASH> 100644
--- a/src/SALib/analyze/hdmr.py
+++ b/src/SALib/analyze/hdmr.py
@@ -496,7 +496,7 @@ def f_test(Y, f0, Y_em, R, alpha, m1, m2, m3, n1, n2, n3, n):
# Number of parameters of proposed model (order dependent)
if i <= n1:
p1 = m1 # 1st order
- elif n1 < i <= n1 + n2:
+ elif n1 < i <= (n1 + n2):
p1 = m2 # 2nd order
else:
p1 = m3 # 3rd order
|
add brackets for n1 + n2
|
diff --git a/Consoloid/OS/File/RemoteClientFile.js b/Consoloid/OS/File/RemoteClientFile.js
index <HASH>..<HASH> 100644
--- a/Consoloid/OS/File/RemoteClientFile.js
+++ b/Consoloid/OS/File/RemoteClientFile.js
@@ -42,7 +42,6 @@ defineClass('Consoloid.OS.File.RemoteClientFile', 'Consoloid.OS.File.FileInterfa
__retrivedFileInfos: function(fileInfos, id, callback)
{
if (!(id in fileInfos)) {
- console.log("ITT", id, fileInfos)
callback("Unknown file");
return;
}
|
Removed random console.log from RemoteClientFile
|
diff --git a/lib/runtime/procs/base.js b/lib/runtime/procs/base.js
index <HASH>..<HASH> 100644
--- a/lib/runtime/procs/base.js
+++ b/lib/runtime/procs/base.js
@@ -28,7 +28,7 @@ var base = Base.extend({
this.stats = {points_in: 0, points_out: 0};
this.last_used_output = DEFAULT_OUT_NAME;
job_id = this.program.id ? '-' + this.program.id : '';
- this.logger_name = 'juttle-procs ' + this.procName + job_id;
+ this.logger_name = 'proc-' + this.procName + job_id;
this.logger = JuttleLogger.getLogger(this.logger_name);
},
|
procs: tweak the logger path for the base proc
|
diff --git a/ndbench-core/src/main/java/com/netflix/ndbench/core/config/IConfiguration.java b/ndbench-core/src/main/java/com/netflix/ndbench/core/config/IConfiguration.java
index <HASH>..<HASH> 100644
--- a/ndbench-core/src/main/java/com/netflix/ndbench/core/config/IConfiguration.java
+++ b/ndbench-core/src/main/java/com/netflix/ndbench/core/config/IConfiguration.java
@@ -119,7 +119,7 @@ public interface IConfiguration {
* grows larger than 1% auto tune triggered rate increases will cease.
*
*/
- @DefaultValue("0.01F")
+ @DefaultValue("0.01")
Float getAutoTuneWriteFailureRatioThreshold();
}
|
take off "F" from floating pnt constant for fast prop
|
diff --git a/drop_sync.rb b/drop_sync.rb
index <HASH>..<HASH> 100755
--- a/drop_sync.rb
+++ b/drop_sync.rb
@@ -1,7 +1,4 @@
require File.expand_path('../dropbox-sdk-ruby-1.6.4/lib/dropbox_sdk', __FILE__)
-require 'pp'
-require 'shellwords'
-require 'open-uri'
class DropSync
|
Removes unnecessary requires/imports
|
diff --git a/tensorboard/plugins/debugger_v2/debugger_v2_plugin_test.py b/tensorboard/plugins/debugger_v2/debugger_v2_plugin_test.py
index <HASH>..<HASH> 100644
--- a/tensorboard/plugins/debugger_v2/debugger_v2_plugin_test.py
+++ b/tensorboard/plugins/debugger_v2/debugger_v2_plugin_test.py
@@ -57,6 +57,7 @@ def _generate_tfdbg_v2_data(
logarithm_times: Optionally take logarithm of the final `x` file _ times
iteratively, in order to produce nans.
"""
+ x = tf.constant([1, 3, 3, 7], dtype=tf.float32)
writer = tf.debugging.experimental.enable_dump_debug_info(
logdir, circular_buffer_size=-1, tensor_debug_mode=tensor_debug_mode
)
@@ -81,7 +82,6 @@ def _generate_tfdbg_v2_data(
times = tf.constant(3, dtype=tf.int32)
return repeated_add(unstack_and_sum(x), times)
- x = tf.constant([1, 3, 3, 7], dtype=tf.float32)
for i in range(3):
assert my_function(x).numpy() == 42.0
|
Move constant creation in debugger_v2_plugin_test (#<I>)
Prepares for a TensorFlow change which will make `tf.constant` run an op, which would otherwise have upset the assertions in this test.
Specifically, it moves the `tf.constant` declaration before `enable_dump_debug_info` which alters
internal behavior of TensorFlow.
|
diff --git a/dblock.go b/dblock.go
index <HASH>..<HASH> 100644
--- a/dblock.go
+++ b/dblock.go
@@ -97,6 +97,7 @@ func GetDBlock(keymr string) (dblock *DBlock, raw []byte, err error) {
// TODO: we need a better api call for dblock by keymr so that API will
// retrun the same as dblock-byheight
+ fmt.Println("SequenceNumber: ", db.Header.SequenceNumber)
return GetDBlockByHeight(db.Header.SequenceNumber)
}
|
added sequence number back to get head call
|
diff --git a/Sockets/Socket.php b/Sockets/Socket.php
index <HASH>..<HASH> 100644
--- a/Sockets/Socket.php
+++ b/Sockets/Socket.php
@@ -33,6 +33,11 @@ class Socket
}
}
+ public function getResource()
+ {
+ return $this->resource;
+ }
+
public function poll()
{
if ($this->selectRead()) {
|
Additional helper to access raw socket resource
|
diff --git a/closures.js b/closures.js
index <HASH>..<HASH> 100644
--- a/closures.js
+++ b/closures.js
@@ -30,7 +30,6 @@ module.exports = function (async, opts) {
)
: timeout
)
- if(timeout !== 0 && timer.unref) timer.unref()
}
return self = {
writing: false,
@@ -55,3 +54,4 @@ but the tests are pretty good.
*/
+
diff --git a/proto.js b/proto.js
index <HASH>..<HASH> 100644
--- a/proto.js
+++ b/proto.js
@@ -33,9 +33,6 @@ Single.prototype._timeout = function (delay) {
this._options.max - (Date.now() - this._ts)
) : delay
)
-
- if(delay !== 0)
- this._timer.unref && this._timer.unref()
}
Single.prototype._written = function () {
@@ -72,3 +69,6 @@ and it's a different distinction from private/public.
_cb is an update.
*/
+
+
+
|
remove unref timers, so that a write will happen before the process exits
|
diff --git a/src/samples/java/ex/UTAO_Sample.java b/src/samples/java/ex/UTAO_Sample.java
index <HASH>..<HASH> 100755
--- a/src/samples/java/ex/UTAO_Sample.java
+++ b/src/samples/java/ex/UTAO_Sample.java
@@ -265,3 +265,22 @@ class GitHubIssue109 {
Object findByUuid(String uuid);
}
}
+
+class GitHubIssue261 {
+ @Test
+ public void fpCallingAnAssert() {
+ AssertHelper261 expect = new AssertHelper261Impl();
+ expect.assertNotSeen();
+ }
+}
+
+interface AssertHelper261 {
+ void assertNotSeen();
+}
+
+class AssertHelper261Impl implements AssertHelper261 {
+
+ @Override
+ public void assertNotSeen() {
+ }
+}
|
add UTAO fp as described by #<I>
|
diff --git a/lib/Doctrine/DBAL/Driver/PDOConnection.php b/lib/Doctrine/DBAL/Driver/PDOConnection.php
index <HASH>..<HASH> 100644
--- a/lib/Doctrine/DBAL/Driver/PDOConnection.php
+++ b/lib/Doctrine/DBAL/Driver/PDOConnection.php
@@ -38,7 +38,10 @@ class PDOConnection extends PDO implements Connection, ServerInfoAwareConnection
public function exec($statement)
{
try {
- return parent::exec($statement);
+ $result = parent::exec($statement);
+ assert($result !== false);
+
+ return $result;
} catch (\PDOException $exception) {
throw new PDOException($exception);
}
|
PDO APIs need additional assertions due to the existing error suppression mode
|
diff --git a/examples/get_user_rooms.php b/examples/get_user_rooms.php
index <HASH>..<HASH> 100644
--- a/examples/get_user_rooms.php
+++ b/examples/get_user_rooms.php
@@ -8,4 +8,3 @@ $chatkit = new Chatkit\Chatkit([
]);
print_r($chatkit->getUserRooms([ 'user_id' => 'ham' ]));
-
|
Remove extra blank line at bottom of getUserRooms example
|
diff --git a/Nextras/Application/UI/SecuredLinksControlTrait.php b/Nextras/Application/UI/SecuredLinksControlTrait.php
index <HASH>..<HASH> 100644
--- a/Nextras/Application/UI/SecuredLinksControlTrait.php
+++ b/Nextras/Application/UI/SecuredLinksControlTrait.php
@@ -65,7 +65,7 @@ trait SecuredLinksControlTrait
parent::signalReceived($signal);
- if ($secured) {
+ if ($secured && !$this->getPresenter()->isAjax()) {
throw new \LogicException("Secured signal '$signal' did not redirect. Possible csrf-token reveal by http referer header.");
}
}
|
Fixed secured signals in ajax. (It doesn't require redirect now)
|
diff --git a/src/js/components/Video.js b/src/js/components/Video.js
index <HASH>..<HASH> 100644
--- a/src/js/components/Video.js
+++ b/src/js/components/Video.js
@@ -311,7 +311,11 @@ export default class Video extends Component {
return (
<div className={classes.join(' ')} onMouseMove={this._onMouseMove}>
- <video ref="video" poster={this.props.poster} autoPlay={this.props.autoPlay ? 'autoplay' : false}>
+ <video ref="video"
+ poster={this.props.poster}
+ autoPlay={this.props.autoPlay ? 'autoplay' : false}
+ loop={this.props.loop ? 'loop' : false}
+ muted={this.props.muted ? 'muted' : false}>
{this.props.children}
</video>
{this.props.showControls ? this._renderControls() : undefined}
@@ -337,10 +341,14 @@ Video.propTypes = {
onClick: PropTypes.func,
allowFullScreen: PropTypes.bool,
autoPlay: PropTypes.bool,
- showControls: PropTypes.bool
+ showControls: PropTypes.bool,
+ muted: PropTypes.bool,
+ loop: PropTypes.bool
};
Video.defaultProps = {
autoPlay: false,
- showControls: true
+ showControls: true,
+ muted: false,
+ loop: false
};
|
Added muted and loop flags as props for Video component.
|
diff --git a/src/Super_Admin_Command.php b/src/Super_Admin_Command.php
index <HASH>..<HASH> 100644
--- a/src/Super_Admin_Command.php
+++ b/src/Super_Admin_Command.php
@@ -194,13 +194,6 @@ class Super_Admin_Command extends WP_CLI_Command {
private static function get_admins() {
// We don't use get_super_admins() because we don't want to mess with the global
- $site_admins = get_site_option( 'site_admins', array('admin') );
-
- // If there are no super admins, return empty array to prevent problems further in the code
- if ( ! $site_admins ) {
- $site_admins = array();
- }
-
- return $site_admins;
+ return (array) get_site_option( 'site_admins', array('admin') );
}
}
|
Change the if clause to a casting for more simple approach
|
diff --git a/lib/clone-schema.js b/lib/clone-schema.js
index <HASH>..<HASH> 100644
--- a/lib/clone-schema.js
+++ b/lib/clone-schema.js
@@ -9,6 +9,8 @@ module.exports = function (schema) {
var clonedPath = {};
clonedPath[key] = path.options;
+ clonedPath[key].unique = false;
+
clonedSchema.add(clonedPath);
});
diff --git a/lib/strategies/collection.js b/lib/strategies/collection.js
index <HASH>..<HASH> 100644
--- a/lib/strategies/collection.js
+++ b/lib/strategies/collection.js
@@ -16,14 +16,6 @@ module.exports = function(schema, options) {
refVersion : Number
});
- //remove uniqueness from the versionedSchema, fix for issue #3
- versionedSchema.eachPath(function (property, propertyConfig) {
- propertyConfig.options.unique = false;
- if (propertyConfig._index && propertyConfig._index.unique) {
- propertyConfig._index.unique = false;
- }
- });
-
// Add reference to model to original schema
schema.statics.VersionedModel = mongoose.model(options.collection, versionedSchema);
|
Pulls turning off unique indices to clone-schema
|
diff --git a/blimpy/io/base_reader.py b/blimpy/io/base_reader.py
index <HASH>..<HASH> 100644
--- a/blimpy/io/base_reader.py
+++ b/blimpy/io/base_reader.py
@@ -216,7 +216,7 @@ class Reader(object):
self._setup_chans()
#create freq array
- i_vals = np.arange(self.chan_start_idx, self.chan_stop_idx)
+ i_vals = np.arange(self.chan_start_idx, self.chan_stop_idx + 1)
freqs = self.header['foff'] * i_vals + f0
return freqs
@@ -279,4 +279,4 @@ class Reader(object):
if selection_size_bytes > self.MAX_DATA_ARRAY_SIZE:
return True
else:
- return False
\ No newline at end of file
+ return False
|
Issue #<I>
Function populate_freqs when calculating the i_vals array, numpy.arange was not given the correct "stop" index value.
See <URL>
|
diff --git a/polysquarelinter/linter.py b/polysquarelinter/linter.py
index <HASH>..<HASH> 100644
--- a/polysquarelinter/linter.py
+++ b/polysquarelinter/linter.py
@@ -37,13 +37,13 @@ from jobstamps import jobstamp
import parmap
+import polysquarelinter.valid_words_dictionary as valid_words_dictionary_helper
+
from polysquarelinter.spelling import (Dictionary,
SpellcheckError,
spellcheck_region,
spellcheckable_and_shadow_contents,
technical_words_from_shadow_contents,)
-import polysquarelinter.valid_words_dictionary as valid_words_dictionary_helper
-
try:
from Queue import Queue
except ImportError:
|
linter: Adjust importer order to satisfy I<I>
|
diff --git a/listing-bundle/src/Resources/contao/ModuleListing.php b/listing-bundle/src/Resources/contao/ModuleListing.php
index <HASH>..<HASH> 100644
--- a/listing-bundle/src/Resources/contao/ModuleListing.php
+++ b/listing-bundle/src/Resources/contao/ModuleListing.php
@@ -304,7 +304,7 @@ class ModuleListing extends Module
/**
* Template variables
*/
- $this->Template->action = ampersand($this->Environment->request);
+ $this->Template->action = $this->getIndexFreeRequest();
$this->Template->details = strlen($this->list_info) ? true : false;
$this->Template->search_label = specialchars($GLOBALS['TL_LANG']['MSC']['search']);
$this->Template->per_page_label = specialchars($GLOBALS['TL_LANG']['MSC']['list_perPage']);
|
[Listing] The front end cache only worked with rewritten URLs (#<I>)
|
diff --git a/setup.py b/setup.py
index <HASH>..<HASH> 100644
--- a/setup.py
+++ b/setup.py
@@ -38,7 +38,7 @@ setup(
'seaborn',
'nanoplotter>=0.30.1',
'nanoget>=1.4.0',
- 'nanomath>=0.17.0'
+ 'nanomath>=0.18.1'
],
package_data={'NanoPlot': []},
package_dir={'nanoplot': 'nanoplot'},
|
make dependent on latest nanomath, which contains a bug fix
|
diff --git a/quaternion.js b/quaternion.js
index <HASH>..<HASH> 100644
--- a/quaternion.js
+++ b/quaternion.js
@@ -493,9 +493,28 @@
parse(P, w, x, y, z);
+ // maybe check for NaN's here?
return Math.abs(P['w'] - this['w']) < EPSILON && Math.abs(P['x'] - this['x']) < EPSILON && Math.abs(P['y'] - this['y']) < EPSILON && Math.abs(P['z'] - this['z']) < EPSILON;
},
/**
+ * Checks if all parts of a quaternion are finite
+ *
+ * @returns {boolean}
+ */
+ 'isFinite': function() {
+
+ return isFinite(this['w']) && isFinite(this['x']) && isFinite(this['y']) && isFinite(this['z']);
+ },
+ /**
+ * Checks if any of the parts of the quaternion is not a number
+ *
+ * @returns {boolean}
+ */
+ 'isNaN': function() {
+
+ return isNaN(this['w']) || isNaN(this['x']) || isNaN(this['y']) || isNaN(this['z']);
+ },
+ /**
* Gets the Quaternion as a well formatted string
*
* @returns {string}
|
Added misc functions isNaN and isFinite
|
diff --git a/cmd2/cmd2.py b/cmd2/cmd2.py
index <HASH>..<HASH> 100644
--- a/cmd2/cmd2.py
+++ b/cmd2/cmd2.py
@@ -3031,7 +3031,7 @@ a..b, a:b, a:, ..b items by indices (inclusive)
# get the output out of the buffer
output = membuf.read()
# and add the regex-escaped output to the transcript
- transcript += output.replace('/', '\/')
+ transcript += output.replace('/', r'\/')
# Restore stdout to its original state
self.stdout = saved_self_stdout
diff --git a/cmd2/transcript.py b/cmd2/transcript.py
index <HASH>..<HASH> 100644
--- a/cmd2/transcript.py
+++ b/cmd2/transcript.py
@@ -106,7 +106,7 @@ class Cmd2TestCase(unittest.TestCase):
self.assertTrue(re.match(expected, result, re.MULTILINE | re.DOTALL), message)
def _transform_transcript_expected(self, s: str) -> str:
- """Parse the string with slashed regexes into a valid regex.
+ r"""Parse the string with slashed regexes into a valid regex.
Given a string like:
|
This just fixes a couple minor lint warnings related to raw strings and escapes
|
diff --git a/lib/stylesheet/css_style_sheet.rb b/lib/stylesheet/css_style_sheet.rb
index <HASH>..<HASH> 100644
--- a/lib/stylesheet/css_style_sheet.rb
+++ b/lib/stylesheet/css_style_sheet.rb
@@ -106,6 +106,7 @@ module Stylesheet
end
def request_content
+ return "" if inline_css?
raise InvalidLocationError unless location && location.valid?
request.get(location.href)
end
diff --git a/spec/css_style_sheet_spec.rb b/spec/css_style_sheet_spec.rb
index <HASH>..<HASH> 100644
--- a/spec/css_style_sheet_spec.rb
+++ b/spec/css_style_sheet_spec.rb
@@ -137,6 +137,14 @@ describe CssStyleSheet do
}.not_to raise_error
end
+ it "doesn't fetch for nil inline styles" do
+ sheet = CssStyleSheet.new(content: nil)
+
+ expect {
+ sheet.css_rules.map {|r| r.content }
+ }.not_to raise_error
+ end
+
end
describe "#css_rules" do
|
don't fetch content for nil inline styles
|
diff --git a/lib/middleware/ai.js b/lib/middleware/ai.js
index <HASH>..<HASH> 100644
--- a/lib/middleware/ai.js
+++ b/lib/middleware/ai.js
@@ -199,13 +199,13 @@ module.exports = function(http) {
// Set up some options
img
- .filter('Triangle')
+ // .filter('Triangle')
// Not sure if these work in GM, but they are IM options
- .define('filter:support=2')
- .define('jpeg:fancy-upsampling=off')
- .unsharp(0.25, 0.25, 8, 0.065)
+ // .define('filter:support=2')
+ // .define('jpeg:fancy-upsampling=off')
+ // .unsharp(0.25, 0.25, 8, 0.065)
// .colors(136)
- .dither(false)
+ // .dither(false)
// .colorspace('sRGB')
.out('-background', bg || (mimetype == 'image/png' ? 'transparent' : 'white'));
|
removing filters, causes blurryness
|
diff --git a/ui/QuerySelect.js b/ui/QuerySelect.js
index <HASH>..<HASH> 100644
--- a/ui/QuerySelect.js
+++ b/ui/QuerySelect.js
@@ -20,7 +20,6 @@ export default class QuerySelect extends Component {
$$(Input, { placeholder })
.ref('input')
.on('focus', this._onFocus)
- .on('blur', this._onBlur)
.on('input', this._onInput)
)
return el
@@ -44,12 +43,6 @@ export default class QuerySelect extends Component {
this._query()
}
- _onBlur (event) {
- // console.log('QuerySelect._onBlur()')
- domHelpers.stop(event)
- this._hideOptions()
- }
-
async _query () {
const { query } = this.props
const queryString = this.refs.input.val()
|
Remove QuerySelect.onBlur().
Popover does auto-closing.
|
diff --git a/lib/linux_admin/network_interface.rb b/lib/linux_admin/network_interface.rb
index <HASH>..<HASH> 100644
--- a/lib/linux_admin/network_interface.rb
+++ b/lib/linux_admin/network_interface.rb
@@ -51,8 +51,10 @@ module LinuxAdmin
@network_conf[:mac] = parse_ip_output(ip_output, %r{link/ether}, 1)
- ip_route_res = Common.run!(Common.cmd("ip"), :params => ["route"])
- @network_conf[:gateway4] = parse_ip_output(ip_route_res.output, /^default/, 2) if ip_route_res.success?
+ [4, 6].each do |version|
+ ip_route_res = Common.run!(Common.cmd("ip"), :params => ["-#{version}", "route"])
+ @network_conf["gateway#{version}".to_sym] = parse_ip_output(ip_route_res.output, /^default/, 2) if ip_route_res.success?
+ end
true
rescue AwesomeSpawn::CommandResultError => e
raise NetworkInterfaceError.new(e.message, e.result)
|
Start parsing ipv6 gateway
|
diff --git a/src/ActionSheet.js b/src/ActionSheet.js
index <HASH>..<HASH> 100644
--- a/src/ActionSheet.js
+++ b/src/ActionSheet.js
@@ -268,7 +268,7 @@ class ActionSheet extends Component {
const pointerEvents = (actionSheetState === ACTION_SHEET_OPENED) ? 'auto' : 'none';
const hidden = actionSheetState === ACTION_SHEET_CLOSED && styles.hidden;
- const contentPosition = (position === 'top')
+ const actionSheetPosition = (position === 'top')
? { top: INITIAL_TOP_POSITION }
: { bottom: INITIAL_BOTTOM_POSITION };
@@ -286,7 +286,7 @@ class ActionSheet extends Component {
pointerEvents={pointerEvents}
/>
<Animated.View
- style={[styles.contentContainer, contentPosition, animations]}
+ style={[styles.contentContainer, actionSheetPosition, animations]}
>
<ScrollView style={[styles.scrollView, scrollView]}>
{this.renderItems()}
|
code refactoring - better naming conversion
|
diff --git a/src/animation/Clip.js b/src/animation/Clip.js
index <HASH>..<HASH> 100644
--- a/src/animation/Clip.js
+++ b/src/animation/Clip.js
@@ -72,7 +72,6 @@ define(
// 重新开始周期
// 抛出而不是直接调用事件直到 stage.update 后再统一调用这些事件
return 'restart';
-
}
// 动画完成将这个控制器标识为待删除
@@ -87,6 +86,8 @@ define(
var time = new Date().getTime();
var remainder = (time - this._startTime) % this._life;
this._startTime = new Date().getTime() - remainder + this.gap;
+
+ this._needsRemove = false;
},
fire : function(eventType, arg) {
for (var i = 0, len = this._targetPool.length; i < len; i++) {
diff --git a/src/tool/area.js b/src/tool/area.js
index <HASH>..<HASH> 100644
--- a/src/tool/area.js
+++ b/src/tool/area.js
@@ -852,7 +852,10 @@ define(
isInsideCircle: isInsideCircle,
isInsideLine: isInsideLine,
isInsideRect: isInsideRect,
- isInsideBrokenLine: isInsideBrokenLine
+ isInsideBrokenLine: isInsideBrokenLine,
+
+ isInsideCubicStroke: isInsideCubicStroke,
+ isInsideQuadraticStroke: isInsideQuadraticStroke
};
}
);
|
暴露 isInsideCubicStroke 和 isInsideQuadraticStroke
|
diff --git a/littlechef/chef.py b/littlechef/chef.py
index <HASH>..<HASH> 100644
--- a/littlechef/chef.py
+++ b/littlechef/chef.py
@@ -147,7 +147,7 @@ def _synchronize_node(configfile, node):
if env.gateway:
ssh_key_file = '.ssh/'+os.path.basename(' '.join(env.ssh_config.lookup(env.host_string)['identityfile']))
extra_opts=""
- ssh_opts+=" "+env.gateway+" ssh -i "+ssh_key_file
+ ssh_opts+=" "+env.gateway+" ssh -o StrictHostKeyChecking=no -i "+ssh_key_file
rsync_project(
env.node_work_path,
|
Disable strict host key checking for last hop nodes.
|
diff --git a/code/DebugBarRequestFilter.php b/code/DebugBarRequestFilter.php
index <HASH>..<HASH> 100644
--- a/code/DebugBarRequestFilter.php
+++ b/code/DebugBarRequestFilter.php
@@ -63,10 +63,10 @@ class DebugBarRequestFilter implements \RequestFilter
}
// Always enable in admin because everything is mostly loaded through ajax
if (DebugBar::config()->ajax || DebugBar::IsAdminUrl()) {
- $headers = json_decode(rawurldecode($debugbar->getDataAsHeaders()));
+ $headers = $debugbar->getDataAsHeaders();;
// Prevent throwing js errors in case header size is too large
- if (!empty($headers['error'])) {
+ if (is_array($headers)) {
$debugbar->sendDataInHeaders();
}
}
|
actually, $headers could be a string or an array
|
diff --git a/pkg/endpoint/endpoint.go b/pkg/endpoint/endpoint.go
index <HASH>..<HASH> 100644
--- a/pkg/endpoint/endpoint.go
+++ b/pkg/endpoint/endpoint.go
@@ -993,9 +993,10 @@ func (e *Endpoint) LogStatusOK(typ StatusType, msg string) {
func (e *Endpoint) logStatusLocked(typ StatusType, code StatusCode, msg string) {
sts := &statusLogMsg{
Status: Status{
- Code: code,
- Msg: msg,
- Type: typ,
+ Code: code,
+ Msg: msg,
+ Type: typ,
+ State: e.state,
},
Timestamp: time.Now().UTC(),
}
diff --git a/pkg/endpoint/status.go b/pkg/endpoint/status.go
index <HASH>..<HASH> 100644
--- a/pkg/endpoint/status.go
+++ b/pkg/endpoint/status.go
@@ -40,9 +40,10 @@ const (
)
type Status struct {
- Code StatusCode `json:"code"`
- Msg string `json:"msg"`
- Type StatusType `json:"status-type"`
+ Code StatusCode `json:"code"`
+ Msg string `json:"msg"`
+ Type StatusType `json:"status-type"`
+ State string `json:"state"`
}
func (sc StatusCode) ColorString() string {
|
endpoint: Store endpoint state in status log
We now store the state of the endpoint when we store a status log. This
can be later exported via the API and used to understand the lifecycle of an
endpoint.
|
diff --git a/presto-blackhole/src/main/java/com/facebook/presto/plugin/blackhole/BlackHoleMetadata.java b/presto-blackhole/src/main/java/com/facebook/presto/plugin/blackhole/BlackHoleMetadata.java
index <HASH>..<HASH> 100644
--- a/presto-blackhole/src/main/java/com/facebook/presto/plugin/blackhole/BlackHoleMetadata.java
+++ b/presto-blackhole/src/main/java/com/facebook/presto/plugin/blackhole/BlackHoleMetadata.java
@@ -78,8 +78,9 @@ public class BlackHoleMetadata
@Override
public List<SchemaTableName> listTables(ConnectorSession session, String schemaNameOrNull)
{
- checkArgument(schemaNameOrNull == null || schemaNameOrNull.equals(SCHEMA_NAME),
- "Only '%s' schema is supported", SCHEMA_NAME);
+ if (schemaNameOrNull != null && !schemaNameOrNull.equals(SCHEMA_NAME)) {
+ return ImmutableList.of();
+ }
return tables.values().stream()
.map(BlackHoleTableHandle::toSchemaTableName)
.collect(toList());
|
Fix listing tables in blackhole connector
Listing tables in a non-existent schema should not be an error.
|
diff --git a/svtyper/version.py b/svtyper/version.py
index <HASH>..<HASH> 100644
--- a/svtyper/version.py
+++ b/svtyper/version.py
@@ -1,2 +1,2 @@
__author__ = "Colby Chiang (colbychiang@wustl.edu)"
-__version__ = "v0.3.0"
+__version__ = "v0.3.1"
|
+ update to <I>
- after code review with @ernfrid
|
diff --git a/ViewErrorBag.php b/ViewErrorBag.php
index <HASH>..<HASH> 100644
--- a/ViewErrorBag.php
+++ b/ViewErrorBag.php
@@ -10,6 +10,17 @@ class ViewErrorBag implements Countable {
* @var array
*/
protected $bags = [];
+
+ /**
+ * Checks if a MessageBag exists.
+ *
+ * @param string $key
+ * @return boolean
+ */
+ public function hasBag($key = "default")
+ {
+ return isset($this->bags[$key]);
+ }
/**
* Get a MessageBag instance from the bags.
|
Add method hasBag to ViewErrorBag
When redirecting withErrors($validator) the edit form can show individual messages. But to show a generic message, something like: please check the red marked field below I don't know anything else but to flash a extra variable. This method would remedy that. Now I could check: $errors->hasBag() to see if the form is a redirect from a post with a errors message bag or a first get for input.
|
diff --git a/update-badges.js b/update-badges.js
index <HASH>..<HASH> 100644
--- a/update-badges.js
+++ b/update-badges.js
@@ -28,7 +28,7 @@ let newRstExchangeTable = rstExchangeTableLines.map (line => {
//-----------------------------------------------------------------------------
-function updateExchangeCountInBadge (fileName) {
+function updateExchangeCount (fileName) {
log.bright.cyan ('Updating exchange count →', fileName.yellow)
|
minor fix in update-badges.js
|
diff --git a/pyvista/plotting/plotting.py b/pyvista/plotting/plotting.py
index <HASH>..<HASH> 100644
--- a/pyvista/plotting/plotting.py
+++ b/pyvista/plotting/plotting.py
@@ -3226,7 +3226,6 @@ class BasePlotter(PickingHelper, WidgetHelper):
If an actor of this name already exists in the rendering window, it
will be replaced by the new actor.
-
shape_color : string or 3 item list, optional. Color of points (if visible).
Either a string, rgb list, or hex color string. For example:
|
fix docstring (#<I>)
|
diff --git a/TYPO3.Flow/Classes/TYPO3/Flow/Persistence/Doctrine/EntityManagerFactory.php b/TYPO3.Flow/Classes/TYPO3/Flow/Persistence/Doctrine/EntityManagerFactory.php
index <HASH>..<HASH> 100644
--- a/TYPO3.Flow/Classes/TYPO3/Flow/Persistence/Doctrine/EntityManagerFactory.php
+++ b/TYPO3.Flow/Classes/TYPO3/Flow/Persistence/Doctrine/EntityManagerFactory.php
@@ -119,7 +119,7 @@ class EntityManagerFactory
$proxyDirectory = Files::concatenatePaths([$this->environment->getPathToTemporaryDirectory(), 'Doctrine/Proxies']);
Files::createDirectoryRecursively($proxyDirectory);
$config->setProxyDir($proxyDirectory);
- $config->setProxyNamespace(Proxies::class);
+ $config->setProxyNamespace('TYPO3\Flow\Persistence\Doctrine\Proxies');
$config->setAutoGenerateProxyClasses(false);
// Set default host to 127.0.0.1 if there is no host configured but a dbname
|
TASK: Use string for "virtual" namespace name
This reverts the use of the ::class constant for the ORM proxy
namespace configuration, since that is not "real" and is not
even a "class" but just a "namespace prefix".
|
diff --git a/lib/npm.js b/lib/npm.js
index <HASH>..<HASH> 100644
--- a/lib/npm.js
+++ b/lib/npm.js
@@ -66,6 +66,10 @@ function changelog(packageName, cb) {
function(err, data) {
var i;
if (data && data.changes) {
+ if (data.changes[0].date > Versions[0].date) {
+ Versions.unshift({ version: 'Upcoming', date: data.changes[0].date});
+ }
+
data.changes.forEach(function(change){
//log('change', change);
if (change) {
|
support upcoming features that are in github but not yet in npm.
|
diff --git a/configuration-lib/src/main/java/com/cisco/oss/foundation/configuration/CentralConfigurationUtil.java b/configuration-lib/src/main/java/com/cisco/oss/foundation/configuration/CentralConfigurationUtil.java
index <HASH>..<HASH> 100644
--- a/configuration-lib/src/main/java/com/cisco/oss/foundation/configuration/CentralConfigurationUtil.java
+++ b/configuration-lib/src/main/java/com/cisco/oss/foundation/configuration/CentralConfigurationUtil.java
@@ -243,6 +243,7 @@ public enum CentralConfigurationUtil {
properties.setProperty("service.configurationLib." + numOfServers + ".port", port);
numOfServers++;
}
+ properties.setProperty("service.configurationLib.http.exposeStatisticsToMonitor", "false");
return properties;
}
|
disable http client monitoring in the special http client used to fetch configuration remotely
|
diff --git a/bakery/views/dates.py b/bakery/views/dates.py
index <HASH>..<HASH> 100644
--- a/bakery/views/dates.py
+++ b/bakery/views/dates.py
@@ -77,8 +77,9 @@ class BuildableYearArchiveView(YearArchiveView, BuildableMixin):
"""
Return the year from the database in the format expected by the URL.
"""
+ year = super(BuildableYearArchiveView, self).get_year()
fmt = self.get_year_format()
- return date(int(self.year), 1, 1).strftime(fmt)
+ return date(int(year), 1, 1).strftime(fmt)
def get_url(self):
"""
|
Fixed get_year on the year archive view
|
diff --git a/middleware.go b/middleware.go
index <HASH>..<HASH> 100644
--- a/middleware.go
+++ b/middleware.go
@@ -66,23 +66,6 @@ func (ms *MiddlewareStack) Use(mw ...MiddlewareFunc) {
/*
a.Middleware.Skip(Authorization, HomeHandler, LoginHandler, RegistrationHandler)
*/
-// NOTE: When skipping Resource handlers, you need to first declare your
-// resource handler as a type of buffalo.Resource for the Skip function to
-// properly recognize and match it.
-/*
- // Works:
- var cr Resource
- cr = &carsResource{&buffaloBaseResource{}}
- g = a.Resource("/cars", cr)
- g.Use(SomeMiddleware)
- g.Middleware.Skip(SomeMiddleware, cr.Show)
-
- // Doesn't Work:
- cr := &carsResource{&buffaloBaseResource{}}
- g = a.Resource("/cars", cr)
- g.Use(SomeMiddleware)
- g.Middleware.Skip(SomeMiddleware, cr.Show)
-*/
func (ms *MiddlewareStack) Skip(mw MiddlewareFunc, handlers ...Handler) {
for _, h := range handlers {
key := funcKey(mw, h)
|
removed out of date middleware skipping docs
|
diff --git a/drivers/overlay/overlay.go b/drivers/overlay/overlay.go
index <HASH>..<HASH> 100644
--- a/drivers/overlay/overlay.go
+++ b/drivers/overlay/overlay.go
@@ -239,6 +239,8 @@ func parseOptions(options []string) (*overlayOptions, error) {
}
key = strings.ToLower(key)
switch key {
+ case ".override_kernel_check", "overlay.override_kernel_check", "overlay2.override_kernel_check":
+ logrus.Warnf("overlay: override_kernel_check option was specified, but is no longer necessary")
case ".mountopt", "overlay.mountopt", "overlay2.mountopt":
o.mountOptions = val
case ".size", "overlay.size", "overlay2.size":
diff --git a/store.go b/store.go
index <HASH>..<HASH> 100644
--- a/store.go
+++ b/store.go
@@ -566,10 +566,10 @@ func GetStore(options StoreOptions) (Store, error) {
}
if options.GraphRoot == "" {
- return nil, ErrIncompleteOptions
+ return nil, errors.Wrap(ErrIncompleteOptions, "no storage root specified")
}
if options.RunRoot == "" {
- return nil, ErrIncompleteOptions
+ return nil, errors.Wrap(ErrIncompleteOptions, "no storage runroot specified")
}
if err := os.MkdirAll(options.RunRoot, 0700); err != nil && !os.IsExist(err) {
|
Make use of overlay.override_kernel_check a warning instead of an error
When we removed all traces of override_kernel_check, we created a
situation where older configuration files would suddenly start causing
us to emit an error at startup. Soften that to a warning, for now at
least.
|
diff --git a/devices/tuya.js b/devices/tuya.js
index <HASH>..<HASH> 100644
--- a/devices/tuya.js
+++ b/devices/tuya.js
@@ -158,6 +158,7 @@ module.exports = [
{modelID: 'TS0601', manufacturerName: '_TZE200_ebwgzdqq'},
{modelID: 'TS0601', manufacturerName: '_TZE200_9i9dt8is'},
{modelID: 'TS0601', manufacturerName: '_TZE200_dfxkcots'},
+ {modelID: 'TS0601', manufacturerName: '_TZE200_swaamsoy'},
],
model: 'TS0601_dimmer',
vendor: 'TuYa',
|
Add _TZE<I>_swaamsoy to TS<I>_dimmer (#<I>)
|
diff --git a/lib/faraday.rb b/lib/faraday.rb
index <HASH>..<HASH> 100644
--- a/lib/faraday.rb
+++ b/lib/faraday.rb
@@ -181,7 +181,12 @@ module Faraday
end
def middleware_mutex(&block)
- (@middleware_mutex ||= Mutex.new).synchronize(&block)
+ @middleware_mutex ||= Mutex.new
+ if @middleware_mutex.locked?
+ block.call
+ else
+ @middleware_mutex.synchronize(&block)
+ end
end
def fetch_middleware(key)
|
Don't let nested mutex deadlock the thread.
|
diff --git a/chromedp_test.go b/chromedp_test.go
index <HASH>..<HASH> 100644
--- a/chromedp_test.go
+++ b/chromedp_test.go
@@ -25,7 +25,6 @@ import (
"github.com/chromedp/cdproto/network"
"github.com/chromedp/cdproto/page"
"github.com/chromedp/cdproto/runtime"
- cdpruntime "github.com/chromedp/cdproto/runtime"
"github.com/chromedp/cdproto/target"
)
@@ -136,7 +135,7 @@ func testAllocateSeparate(tb testing.TB) (context.Context, context.CancelFunc) {
}
ListenBrowser(ctx, func(ev interface{}) {
switch ev := ev.(type) {
- case *cdpruntime.EventExceptionThrown:
+ case *runtime.EventExceptionThrown:
tb.Errorf("%+v\n", ev.ExceptionDetails)
}
})
@@ -423,7 +422,7 @@ func TestLargeEventCount(t *testing.T) {
// without making the test too slow.
first := true
ListenTarget(ctx, func(ev interface{}) {
- if _, ok := ev.(*cdpruntime.EventConsoleAPICalled); ok && first {
+ if _, ok := ev.(*runtime.EventConsoleAPICalled); ok && first {
time.Sleep(50 * time.Millisecond)
first = false
}
|
address ST<I>: package is being imported more than once
issue found by staticcheck (<URL>)
|
diff --git a/http_check/datadog_checks/http_check/http_check.py b/http_check/datadog_checks/http_check/http_check.py
index <HASH>..<HASH> 100644
--- a/http_check/datadog_checks/http_check/http_check.py
+++ b/http_check/datadog_checks/http_check/http_check.py
@@ -74,6 +74,10 @@ class HTTPCheck(NetworkCheck):
# Store tags in a temporary list so that we don't modify the global tags data structure
tags_list = list(tags)
+ url = instance.get('url', None)
+ if url is not None:
+ url = ensure_unicode(url)
+ tags_list.append('url:{}'.format(url))
instance_name = ensure_unicode(self.normalize(instance['name']))
tags_list.append("instance:{}".format(instance_name))
service_checks = []
|
Add url as tag (#<I>)
* Append URL as tag even if sc aren't reporting
* Add url tag after list initialisation
|
diff --git a/lib/engineyard/repo.rb b/lib/engineyard/repo.rb
index <HASH>..<HASH> 100644
--- a/lib/engineyard/repo.rb
+++ b/lib/engineyard/repo.rb
@@ -91,7 +91,7 @@ deploy-time operations. Commit this file to fix this warning.
def remotes
ensure_repository!
- @remotes ||= `git remote -v`.scan(/\t[^\s]+\s/).map { |c| c.strip }
+ @remotes ||= `git remote -v`.scan(/\t[^\s]+\s/).map { |c| c.strip }.uniq
end
def fail_on_no_remotes!
|
unique the remotes, they git duplicated
|
diff --git a/src/utils/clean-cid.js b/src/utils/clean-cid.js
index <HASH>..<HASH> 100644
--- a/src/utils/clean-cid.js
+++ b/src/utils/clean-cid.js
@@ -7,6 +7,9 @@ module.exports = function (cid) {
if (Buffer.isBuffer(cid)) {
cid = bs58.encode(cid)
}
+ if (CID.isCID(cid)) {
+ cid = cid.toBaseEncodedString()
+ }
if (typeof cid !== 'string') {
throw new Error('unexpected cid type: ' + typeof cid)
}
|
feat: add ability to files.cat with a cid instance
License: MIT
|
diff --git a/lib/puppet/version.rb b/lib/puppet/version.rb
index <HASH>..<HASH> 100644
--- a/lib/puppet/version.rb
+++ b/lib/puppet/version.rb
@@ -7,7 +7,7 @@
module Puppet
- PUPPETVERSION = '3.6.0'
+ PUPPETVERSION = '3.6.1'
##
# version is a public API method intended to always provide a fast and
|
(packaging) Update PUPPETVERSION to <I>
|
diff --git a/build/jquery.datetimepicker.full.js b/build/jquery.datetimepicker.full.js
index <HASH>..<HASH> 100644
--- a/build/jquery.datetimepicker.full.js
+++ b/build/jquery.datetimepicker.full.js
@@ -217,7 +217,11 @@ var DateFormatter;
break;
}
}
- if (vDateFlag === true && out.year && out.month && out.day) {
+ if (vDateFlag === true) {
+ // Set month and day to 1 if they are null
+ out.month = out.month || 1;
+ out.day = out.day || 1;
+
out.date = new Date(out.year, out.month - 1, out.day, out.hour, out.min, out.sec, 0);
} else {
if (vTimeFlag !== true) {
|
Insert sensible defaults (1) for out.month and out.day if parsing with format string didn't set them
See issue #<I>
|
diff --git a/lib/utorrent.js b/lib/utorrent.js
index <HASH>..<HASH> 100644
--- a/lib/utorrent.js
+++ b/lib/utorrent.js
@@ -43,7 +43,7 @@ var uTorrentClient = module.exports = function(host, port) {
// Callback used when we call the makeCall() method for first time with a saved token. As the token may have expired, we need to check this and retry with new token if an error occurs.
var retryCallback = function(err, data) {
if(err && err instanceof TokenError) {
- this.fetchToken(function(err) {
+ self.fetchToken(function(err) {
if(err) { callback(err); return; }
self.makeCall(action, params, callback);
|
Use self instead of this. Fix #5
|
diff --git a/doge/core.py b/doge/core.py
index <HASH>..<HASH> 100755
--- a/doge/core.py
+++ b/doge/core.py
@@ -367,7 +367,7 @@ def main():
shibe.setup()
shibe.print_doge()
- except UnicodeEncodeError:
+ except (UnicodeEncodeError, UnicodeDecodeError):
# Some kind of unicode error happened. This is usually because the
# users system does not have a proper locale set up. Try to be helpful
# and figure out what could have gone wrong.
|
wow also unicode decode error catch
|
diff --git a/Debug/TraceableProcessor.php b/Debug/TraceableProcessor.php
index <HASH>..<HASH> 100644
--- a/Debug/TraceableProcessor.php
+++ b/Debug/TraceableProcessor.php
@@ -29,6 +29,14 @@ class TraceableProcessor implements ProcessorInterface
}
/**
+ * @return ProcessorInterface
+ */
+ public function getProcessor()
+ {
+ return $this->processor;
+ }
+
+ /**
* {@inheritdoc}
*/
public function process(ContextInterface $context)
|
BAP-<I>: Config options should be returned only on demand
|
diff --git a/src/resources/assets/react/components/HCForm.js b/src/resources/assets/react/components/HCForm.js
index <HASH>..<HASH> 100644
--- a/src/resources/assets/react/components/HCForm.js
+++ b/src/resources/assets/react/components/HCForm.js
@@ -92,13 +92,13 @@ export default class HCForm extends Component {
this.refs[key].setMultiLanguageValue(item['language_code'], item[keySequence[1]]);
});
}
- else if (value) {
+ else if (value !== null && value !== undefined) {
this.refs[key].setValue(value);
}
}
}
- else if (value) {
+ else if (value !== null && value !== undefined) {
this.refs[key].setValue(value);
}
|
Improved data setting when value is equal to 0
|
diff --git a/eZ/Publish/Core/Persistence/InMemory/Backend.php b/eZ/Publish/Core/Persistence/InMemory/Backend.php
index <HASH>..<HASH> 100644
--- a/eZ/Publish/Core/Persistence/InMemory/Backend.php
+++ b/eZ/Publish/Core/Persistence/InMemory/Backend.php
@@ -509,6 +509,17 @@ class Backend
$value->$propertyName = $propertyValue;
}
}
+ else if ( $type === "Content\\UrlAlias" && $prop === "id" )
+ {
+ // id should be <parent>-<hash>, but as there is no property for link in VO and we need it in handler,
+ // returning everything here
+ // Note: before returning in handler id must be overwritten with <parent>-<hash>
+ $value = array(
+ "id" => $data["id"],
+ "parent" => $data["parent"],
+ "link" => $data["link"],
+ );
+ }
else
{
$value = $data[$prop];
|
Updated: special case for mapping data to UrlAlias->id
|
diff --git a/scripts/app.js b/scripts/app.js
index <HASH>..<HASH> 100644
--- a/scripts/app.js
+++ b/scripts/app.js
@@ -12,7 +12,6 @@ var generateData = require('./generate_data');
var App = React.createClass({
getInitialState() {
- var that = this;
var countries = {
'de': 'Germany',
'fi': 'Finland',
@@ -55,20 +54,20 @@ var App = React.createClass({
formatter: (active) => active && <span>✓</span>,
},
{
- cell: (i) => {
+ cell: ((i) => {
var remove = () => {
// this could go through flux etc.
- delete that.state.data[i];
+ this.state.data.splice(i, 1);
- that.setState({
- data: that.state.data
+ this.setState({
+ data: this.state.data
});
};
return <span>
- <span onClick={remove} style={{cursor: 'pointer'}}>✗</span>
+ <span onClick={remove.bind(this)} style={{cursor: 'pointer'}}>✗</span>
</span>;
- },
+ }).bind(this),
}
]
};
|
Tidy up row deletion
It is better to use splice here (avoids empties in array) and pass
`this` through `bind`.
|
diff --git a/src/components/Picklist/index.js b/src/components/Picklist/index.js
index <HASH>..<HASH> 100644
--- a/src/components/Picklist/index.js
+++ b/src/components/Picklist/index.js
@@ -76,6 +76,7 @@ class Picklist extends Component {
this.outsideClick.startListening(this.containerRef.current, (_, event) => {
if (this.eventTarget !== event.target) {
this.closeMenu();
+ this.handleBlur();
}
});
this.windowScrolling.startListening(this.handleWindowScroll);
@@ -153,6 +154,8 @@ class Picklist extends Component {
}
handleBlur() {
+ const { isOpen } = this.state;
+ if (isOpen) return;
const { onBlur, value } = this.props;
const eventValue = value || null;
onBlur(eventValue);
|
fix: `onBlur` event on Picklist fires on click (#<I>)
* fix: `onBlur` event on Picklist fires on click
* fix: fire onBlur event on outside click
|
diff --git a/auth/rest.go b/auth/rest.go
index <HASH>..<HASH> 100644
--- a/auth/rest.go
+++ b/auth/rest.go
@@ -23,6 +23,10 @@ var (
ErrBadRestToken = errors.New("Could not extract auth token from REST request header")
)
+func BuildRestToken() string {
+ return AuthToken()
+}
+
func ExtractRestToken(header string) (string, error) {
// The expected header value is "Bearer JWT_ToKen"
header = strings.TrimSpace(header)
diff --git a/container/cc_api_proxy.go b/container/cc_api_proxy.go
index <HASH>..<HASH> 100644
--- a/container/cc_api_proxy.go
+++ b/container/cc_api_proxy.go
@@ -42,7 +42,7 @@ func newServicedApiProxy() *servicedApiProxy {
director := func(req *http.Request) {
req.URL.Scheme = "https"
req.URL.Host = "localhost:" + strconv.Itoa(ccApiPort)
- token := auth.AuthToken() // TODO Sign token
+ token := auth.BuildRestToken()
req.Header.Add("Authorization", fmt.Sprintf("Bearer %s", token))
}
tlsConfig := &tls.Config{InsecureSkipVerify: true}
|
Get ready to sign the token for rest calls
|
diff --git a/src/bosh/platform/net/default_network_resolver_test.go b/src/bosh/platform/net/default_network_resolver_test.go
index <HASH>..<HASH> 100644
--- a/src/bosh/platform/net/default_network_resolver_test.go
+++ b/src/bosh/platform/net/default_network_resolver_test.go
@@ -36,6 +36,9 @@ var _ = Describe("defaultNetworkResolver", func() {
ifaceName = "en0"
} else if _, err := gonet.InterfaceByName("eth0"); err == nil {
ifaceName = "eth0"
+ // Travis CI uses venet0 as primary network interface
+ } else if _, err := gonet.InterfaceByName("venet0"); err == nil {
+ ifaceName = "venet0"
} else {
panic("Not sure which interface name to use: en0 and eth0 are not found")
}
|
Include venet0 as possible network interface for happy Travis builds
|
diff --git a/client-vendor/after-body/jquery.clickFeedback/jquery.clickFeedback.js b/client-vendor/after-body/jquery.clickFeedback/jquery.clickFeedback.js
index <HASH>..<HASH> 100644
--- a/client-vendor/after-body/jquery.clickFeedback/jquery.clickFeedback.js
+++ b/client-vendor/after-body/jquery.clickFeedback/jquery.clickFeedback.js
@@ -4,7 +4,7 @@
*/
(function($) {
- document.addEventListener('click', function(event) {
+ document.addEventListener('mousedown', function(event) {
var $elem = $(event.target).closest('.clickFeedback');
if ($elem.length) {
|
Replace click with mousedown in clickFeedback.
|
diff --git a/alot/ui.py b/alot/ui.py
index <HASH>..<HASH> 100644
--- a/alot/ui.py
+++ b/alot/ui.py
@@ -190,7 +190,6 @@ class UI(object):
Use a :class:`commands.globals.ExitCommand` for a clean shutdown.
"""
reactor.stop()
- raise urwid.ExitMainLoop()
def buffer_open(self, buf):
"""register and focus new :class:`~alot.buffers.Buffer`."""
|
don't raise ExitMainLoop exception to exit
apparently, it suffices to stop the twisted
reactor when using TwistedEventLoop.
issue #<I>
|
diff --git a/src/Generators/Queries/PaginateAllQueryGenerator.php b/src/Generators/Queries/PaginateAllQueryGenerator.php
index <HASH>..<HASH> 100644
--- a/src/Generators/Queries/PaginateAllQueryGenerator.php
+++ b/src/Generators/Queries/PaginateAllQueryGenerator.php
@@ -73,8 +73,8 @@ class PaginateAllQueryGenerator
$inputType = sprintf("input %s {%s}", $inputTypeName, implode($arguments, " "));
$inputTypeArgument = sprintf('(input: %s)', $inputTypeName);
- $allQuery = sprintf(' %1$s%2$s: [%3$s]! @all(model: "%3$s")', strtolower($typeName), $inputTypeArgument, $returnType);
- $paginatedQuery = sprintf(' %1$sPaginated%2$s: [%3$s]! @paginate(model: "%3$s")', strtolower($typeName), $inputTypeArgument, $returnType);
+ $allQuery = sprintf(' %1$s%2$s: [%3$s]! @all(model: "%3$s", flatten: true)', strtolower($typeName), $inputTypeArgument, $returnType);
+ $paginatedQuery = sprintf(' %1$sPaginated%2$s: [%3$s]! @paginate(model: "%3$s", flatten: true)', strtolower($typeName), $inputTypeArgument, $returnType);
return new QueriesWithInput([$allQuery, $paginatedQuery], $inputType);
}
|
Flatten @paginate and @all queries
sadly, not yet supported by Lighthouse. Support ticket <URL>
|
diff --git a/fritzconnection/tests/test_fritzconnection.py b/fritzconnection/tests/test_fritzconnection.py
index <HASH>..<HASH> 100644
--- a/fritzconnection/tests/test_fritzconnection.py
+++ b/fritzconnection/tests/test_fritzconnection.py
@@ -126,7 +126,16 @@ def test_write_api_to_cache(file_name, cache_format, datadir):
# 2. save the api data
cache_filename = f"x_tmp_cache_{file_name}"
cache_file = Path(cache_filename)
- cache_file.unlink(missing_ok=True) # in case of artefacts
+
+# TODO: (potentially)
+# code for Python >= 3.8:
+# cache_file.unlink(missing_ok=True) # in case of artefacts
+# code for Python < 3.8:
+ try:
+ cache_file.unlink()
+ except FileNotFoundError:
+ pass # ignore
+
FritzConnection._write_api_to_cache(mock, cache_filename, cache_format)
assert cache_file.exists() is True
# 3. read the api data to another mock
|
python <I>, <I> compatibility issue solved
|
diff --git a/version/version.go b/version/version.go
index <HASH>..<HASH> 100644
--- a/version/version.go
+++ b/version/version.go
@@ -15,6 +15,6 @@
package version
var (
- Version = "2.0.0-rc.2"
+ Version = "2.0.0"
InternalVersion = "2"
)
|
version: bump to <I>
|
diff --git a/lib/index.js b/lib/index.js
index <HASH>..<HASH> 100644
--- a/lib/index.js
+++ b/lib/index.js
@@ -161,7 +161,7 @@ class RpcBlockTracker extends AsyncEventEmitter {
async _initSubscription() {
this._provider.on('data', this._handleNewBlockNotification)
- result = await pify(this._provider.sendAsync || this._provider.send)({
+ let result = await pify(this._provider.sendAsync || this._provider.send)({
jsonrpc: '2.0',
id: new Date().getTime(),
method: 'eth_subscribe',
|
Turns out defining variables is important.
|
diff --git a/shoebot/grammar/grammar.py b/shoebot/grammar/grammar.py
index <HASH>..<HASH> 100644
--- a/shoebot/grammar/grammar.py
+++ b/shoebot/grammar/grammar.py
@@ -69,11 +69,15 @@ class Grammar(object):
if iterations:
if iteration < iterations:
return True
+ elif len(self._namespace) > 0:
+ # Vars have been added in script
+ return True
elif iterations is None:
if self._dynamic:
return True
else:
return False
+ return True
if not self._dynamic:
### TODO... gtk window needs to run in another thread, that will keep
### going until explicitly closed
|
If user adds vars in script then it will run in loop until quit.
Makes sliders in color_example3 work.
|
diff --git a/Command/ImportTranslationsCommand.php b/Command/ImportTranslationsCommand.php
index <HASH>..<HASH> 100644
--- a/Command/ImportTranslationsCommand.php
+++ b/Command/ImportTranslationsCommand.php
@@ -155,9 +155,9 @@ class ImportTranslationsCommand extends ContainerAwareCommand
protected function importComponentTranslationFiles(array $locales, array $domains)
{
$classes = array(
- 'Symfony\Component\Validator\Validator' => '/Resources/translations',
+ 'Symfony\Component\Validator\Validation' => '/Resources/translations',
'Symfony\Component\Form\Form' => '/Resources/translations',
- 'Symfony\Component\Security\Core\Exception\AuthenticationException' => '/../../Resources/translations',
+ 'Symfony\Component\Security\Core\Exception\AuthenticationException' => '/../Resources/translations',
);
$dirs = array();
|
Support for Symfony 3
Note that this commit keep the compatibility with Symfony > <I>
|
diff --git a/pac4j-core/src/main/java/org/pac4j/core/exception/MultipleAccountsFoundException.java b/pac4j-core/src/main/java/org/pac4j/core/exception/MultipleAccountsFoundException.java
index <HASH>..<HASH> 100644
--- a/pac4j-core/src/main/java/org/pac4j/core/exception/MultipleAccountsFoundException.java
+++ b/pac4j-core/src/main/java/org/pac4j/core/exception/MultipleAccountsFoundException.java
@@ -6,7 +6,7 @@ package org.pac4j.core.exception;
* @author Jerome Leleu
* @since 1.8.0
*/
-public class MultipleAccountsFoundException extends CredentialsException {
+public class MultipleAccountsFoundException extends TechnicalException {
private static final long serialVersionUID = 1430582289490541876L;
|
Multiple accounts are an abnormal situation -> TechnicalException
|
diff --git a/src/cs50/sql.py b/src/cs50/sql.py
index <HASH>..<HASH> 100644
--- a/src/cs50/sql.py
+++ b/src/cs50/sql.py
@@ -1,4 +1,5 @@
import datetime
+import decimal
import importlib
import logging
import re
@@ -31,7 +32,6 @@ class SQL(object):
"""
Execute a SQL statement.
"""
-
class UserDefinedType(sqlalchemy.TypeDecorator):
"""
Add support for expandable values, a la https://bitbucket.org/zzzeek/sqlalchemy/issues/3953/expanding-parameter.
@@ -123,8 +123,14 @@ class SQL(object):
# if SELECT (or INSERT with RETURNING), return result set as list of dict objects
if re.search(r"^\s*SELECT", statement, re.I):
- rows = result.fetchall()
- return [dict(row) for row in rows]
+
+ # coerce any decimal.Decimal objects to float objects
+ rows = [dict(row) for row in result.fetchall()]
+ for row in rows:
+ for column in row:
+ if isinstance(row[column], decimal.Decimal):
+ row[column] = float(row[column])
+ return rows
# if INSERT, return primary key value for a newly inserted row
elif re.search(r"^\s*INSERT", statement, re.I):
|
coercing decimal.Decimal objects to float objects for PostgreSQL
|
diff --git a/examples/scribuntoRemoteDebug.js b/examples/scribuntoRemoteDebug.js
index <HASH>..<HASH> 100644
--- a/examples/scribuntoRemoteDebug.js
+++ b/examples/scribuntoRemoteDebug.js
@@ -1,4 +1,4 @@
-var bot = require( 'nodemw' ),
+var Bot = require( 'nodemw' ),
readline = require( 'readline' ),
fs = require( 'fs' ),
rl = readline.createInterface( {
|
Fix unused and undefined vars
|
diff --git a/bundle/Resources/public/js/app.js b/bundle/Resources/public/js/app.js
index <HASH>..<HASH> 100644
--- a/bundle/Resources/public/js/app.js
+++ b/bundle/Resources/public/js/app.js
@@ -298,7 +298,8 @@ $(document).ready(function () {
function LayoutsBox(el) {
this.$el = $(el);
this.csrf = $('meta[name=ngbm-admin-csrf-token]').attr('content');
- this.basePath = $('meta[name=ngbm-admin-base-path]').attr('content') + 'layouts/';
+ this.basePath = $('meta[name=ngbm-admin-base-path]').attr('content');
+ this.basePath += this.basePath.charAt(this.basePath.length - 1) !== '/' ? '/layouts/' : 'layouts/';
this.$content = this.$el.find('.layouts-box-content');
this.$loader = this.$el.find('.layout-loading');
this.fetchedLayouts = false;
|
fix ngbm-base-path - check for / at the end
|
diff --git a/angr/analyses/disassembly.py b/angr/analyses/disassembly.py
index <HASH>..<HASH> 100644
--- a/angr/analyses/disassembly.py
+++ b/angr/analyses/disassembly.py
@@ -572,9 +572,8 @@ class Disassembly(Analysis):
self._func_cache = {}
if function is not None:
- blocks = function.graph.nodes()
# sort them by address, put hooks before nonhooks
- blocks.sort(key=lambda node: (node.addr, not node.is_hook))
+ blocks = sorted(function.graph.nodes(), key=lambda node: (node.addr, not node.is_hook))
for block in blocks:
self.parse_block(block)
|
Disassembly: Fix for NetworkX 2.
|
diff --git a/flask_security/script.py b/flask_security/script.py
index <HASH>..<HASH> 100644
--- a/flask_security/script.py
+++ b/flask_security/script.py
@@ -100,7 +100,7 @@ class AddRoleCommand(_RoleCommand):
class RemoveRoleCommand(_RoleCommand):
- """Add a role to a user"""
+ """Remove a role from a user"""
@commit
def run(self, user_identifier, role_name):
|
Fix RemoveRoleCommand docstring
|
diff --git a/index.ios.js b/index.ios.js
index <HASH>..<HASH> 100644
--- a/index.ios.js
+++ b/index.ios.js
@@ -50,7 +50,7 @@ exports.getContact = function (){
page.presentModalViewControllerAnimated(controller, true);
});
};
-exports.fetchContactsByName = function(searchPredicate){
+exports.getContactsByName = function(searchPredicate){
return new Promise(function (resolve, reject){
var store = new CNContactStore(),
error,
|
Update index.ios.js
Rename fetchContactsByName to getContactsByName.
Rename fetchAllContacts to getAllContacts.
|
diff --git a/discord/ext/commands/bot.py b/discord/ext/commands/bot.py
index <HASH>..<HASH> 100644
--- a/discord/ext/commands/bot.py
+++ b/discord/ext/commands/bot.py
@@ -108,7 +108,7 @@ class BotBase(GroupMixin):
self._help_command = None
self.description = inspect.cleandoc(description) if description else ''
self.owner_id = options.get('owner_id')
- self.owner_ids = options.get('owner_ids', {})
+ self.owner_ids = options.get('owner_ids', set())
if self.owner_id and self.owner_ids:
raise TypeError('Both owner_id and owner_ids are set.')
|
[commands] default Bot.owner_ids to a set
This appears to be a typo, as everywhere else, owner_ids is set to a set.
|
diff --git a/test/snp/template_test.rb b/test/snp/template_test.rb
index <HASH>..<HASH> 100644
--- a/test/snp/template_test.rb
+++ b/test/snp/template_test.rb
@@ -8,5 +8,13 @@ describe Snp::Template do
template.resolve('template.erb').must_equal File.expand_path('~/.snp_templates/template.erb')
end
+
+ it 'uses SNP_PATH environment variable if it is set' do
+ ENV['SNP_PATH'] = '/snp:/etc/snp'
+ File.stubs(:exists?).returns(true)
+
+ template = Snp::Template.new
+ template.resolve('template.erb').must_equal '/snp/template.erb'
+ end
end
end
|
Assert that SNP_PATH is used if set.
|
diff --git a/lib/monadic/maybe.rb b/lib/monadic/maybe.rb
index <HASH>..<HASH> 100644
--- a/lib/monadic/maybe.rb
+++ b/lib/monadic/maybe.rb
@@ -2,12 +2,12 @@ module Monadic
# @api private helps treating `Maybe` like Either in Scala
module ScalaStuff
def map(proc = nil, &block)
- return Maybe(@value.map(&block)) if @value.is_a?(Enumerable)
+ return Maybe(@value.map(&block)) if @value.is_a?(::Enumerable)
return Maybe((proc || block).call(@value))
end
def select(proc = nil, &block)
- return Maybe(@value.select(&block)) if @value.is_a?(Enumerable)
+ return Maybe(@value.select(&block)) if @value.is_a?(::Enumerable)
return Nothing unless (proc || block).call(@value)
return self
end
|
Make sure ::Enumerable is used
|
diff --git a/lib/veritas/relation.rb b/lib/veritas/relation.rb
index <HASH>..<HASH> 100644
--- a/lib/veritas/relation.rb
+++ b/lib/veritas/relation.rb
@@ -122,11 +122,11 @@ module Veritas
def eql?(other)
instance_of?(other.class) &&
header.eql?(other.header) &&
- to_set.eql?(project_relation(other).to_set)
+ to_set == project_relation(other).to_set
end
def hash
- header.hash ^ to_set.hash
+ header.hash ^ to_a.hash
end
private
diff --git a/spec/unit/veritas/relation/hash_spec.rb b/spec/unit/veritas/relation/hash_spec.rb
index <HASH>..<HASH> 100644
--- a/spec/unit/veritas/relation/hash_spec.rb
+++ b/spec/unit/veritas/relation/hash_spec.rb
@@ -9,5 +9,5 @@ describe 'Veritas::Relation#hash' do
it { should be_kind_of(Integer) }
- it { should == @relation.header.hash ^ [].hash }
+ it { should == @relation.header.hash ^ @relation.to_a.hash }
end
|
Fixed failing specs in <I>
* This is due to differences in Set#eql? and Set#hash on <I> and
below, which are caused by broken behaviour in the corresponding
Hash methods.
A ticket was raised with the backports project in case it is possible
to fix this, so this commit can be reverted:
<URL>
|
diff --git a/test/integration_test.rb b/test/integration_test.rb
index <HASH>..<HASH> 100644
--- a/test/integration_test.rb
+++ b/test/integration_test.rb
@@ -81,6 +81,6 @@ class IntegrationTest < Test::Unit::TestCase
it 'does not generate warnings' do
assert_raise(OpenURI::HTTPError) { server.get '/' }
server.get '/app_file'
- assert_empty server.warnings
+ assert_equal [], server.warnings
end
end
\ No newline at end of file
|
there is no assert_equal on <I>
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.