diff
stringlengths 65
26.7k
| message
stringlengths 7
9.92k
|
|---|---|
diff --git a/leaflet-search.js b/leaflet-search.js
index <HASH>..<HASH> 100644
--- a/leaflet-search.js
+++ b/leaflet-search.js
@@ -499,6 +499,13 @@ L.Control.Search = L.Control.extend({
if ((sel = this._input.selection) && sel.empty) {
sel.empty();
}
+ else if (sel = this._input.createTextRange()) {
+ sel.collapse(true);
+ var end = this._input.value.length;
+ sel.moveStart('character', end);
+ sel.moveEnd('character', end);
+ sel.select();
+ }
else {
if (this._input.getSelection) {
this._input.getSelection().removeAllRanges();
|
Deselecting of text in hideAutoType now works in IE8.
|
diff --git a/PHPCI/Model/Build/GithubBuild.php b/PHPCI/Model/Build/GithubBuild.php
index <HASH>..<HASH> 100644
--- a/PHPCI/Model/Build/GithubBuild.php
+++ b/PHPCI/Model/Build/GithubBuild.php
@@ -78,6 +78,7 @@ class GithubBuild extends RemoteGitBuild
$http->setHeaders($headers);
$res = $http->request('POST', $url, json_encode($params));
+ var_dump($res);
}
|
Adding some github debug stuff
|
diff --git a/src/Panda/Http/Request.php b/src/Panda/Http/Request.php
index <HASH>..<HASH> 100644
--- a/src/Panda/Http/Request.php
+++ b/src/Panda/Http/Request.php
@@ -34,6 +34,7 @@ class Request extends SymfonyRequest
* information we gan get.
*
* @return Request
+ * @throws \LogicException
*/
public static function capture()
{
@@ -48,6 +49,7 @@ class Request extends SymfonyRequest
* @param SymfonyRequest $request
*
* @return Request
+ * @throws \LogicException
*/
public static function createRequest(SymfonyRequest $request)
{
|
Add @throw tags in Request docblocks
|
diff --git a/test/integration/features/step_definitions/view-steps.js b/test/integration/features/step_definitions/view-steps.js
index <HASH>..<HASH> 100644
--- a/test/integration/features/step_definitions/view-steps.js
+++ b/test/integration/features/step_definitions/view-steps.js
@@ -246,7 +246,7 @@ this.Then(/^я не увижу элемент "([^"]*)" с текстом "([^"]
actText = element.findAllChildrenByType('Label')[0].getDisplayValue();
}
- if(actText != elementText){
+ if(actText.trim() != elementText){
next();
}else{
next(new Error(elementName + ' was found!'));
@@ -285,7 +285,7 @@ this.Then(/^я увижу элемент "([^"]*)" с текстом "([^"]*)"$/
actText = element.findAllChildrenByType('Label')[0].getDisplayValue();
}
- chai.assert.equal(actText, elementText);
+ chai.assert.equal(actText.trim(), elementText);
next();
}catch(err){
next(err);
|
add trim function for text into step definition (integration tests)
|
diff --git a/compiler/prelude.go b/compiler/prelude.go
index <HASH>..<HASH> 100644
--- a/compiler/prelude.go
+++ b/compiler/prelude.go
@@ -490,6 +490,25 @@ var go$structType = function(fields) {
this[fields[i][0]] = arguments[i];
}
});
+ // collect methods for anonymous fields
+ var i, j;
+ for (i = 0; i < fields.length; i++) {
+ var field = fields[i];
+ if (field[1] === "") {
+ var methods = field[3].methods;
+ for (j = 0; j < methods.length; j++) {
+ var m = methods[j].slice(0, 6).concat([i]);
+ typ.methods.push(m);
+ typ.Ptr.methods.push(m);
+ }
+ if (field[3].kind === "Struct") {
+ var methods = field[3].Ptr.methods;
+ for (j = 0; j < methods.length; j++) {
+ typ.Ptr.methods.push(methods[j].slice(0, 6).concat([i]));
+ }
+ }
+ }
+ }
typ.init(fields);
go$structTypes[string] = typ;
}
|
collect methods for anonymous fields of anonymous structs
|
diff --git a/helpers/ha.py b/helpers/ha.py
index <HASH>..<HASH> 100644
--- a/helpers/ha.py
+++ b/helpers/ha.py
@@ -74,7 +74,7 @@ class Ha:
self.state_handler.follow_the_leader(self.fetch_current_leader())
return "no action. i am a secondary and i am following a leader"
else:
- if not self.state_handler.is_running():
+ if not self.state_handler.is_running(): # XXX is_running == is_healthy
self.state_handler.start()
return "postgresql was stopped. starting again."
return "no action. not healthy enough to do anything."
|
Track list of already existing physical replication slots
Drop replication slot when it was removed from etcd.
Execute pg_create_physical_replication_slot only when something new appeared in etcd.
|
diff --git a/src/components/App.js b/src/components/App.js
index <HASH>..<HASH> 100644
--- a/src/components/App.js
+++ b/src/components/App.js
@@ -40,7 +40,11 @@ const SelectAnimation = ({ value, onAnimate }) => (
justifyContent: "center"
})}
>
- <select onChange={onAnimate} value={value} {...css({ marginRight: "10" })}>
+ <select
+ value={value}
+ onChange={onAnimate}
+ {...css({ width: "100", height: "25" })}
+ >
{Object.keys(animations).map(a => (
<option key={`animation-${a}`}>{a}</option>
))}
|
refactor the style of the <select> component
|
diff --git a/src/Database/Dialect/SqlserverDialectTrait.php b/src/Database/Dialect/SqlserverDialectTrait.php
index <HASH>..<HASH> 100644
--- a/src/Database/Dialect/SqlserverDialectTrait.php
+++ b/src/Database/Dialect/SqlserverDialectTrait.php
@@ -99,9 +99,9 @@ trait SqlserverDialectTrait
protected function _pagingSubquery($original, $limit, $offset)
{
$field = '_cake_paging_._cake_page_rownum_';
+ $order = $original->clause('order') ?: new OrderByExpression('(SELECT NULL)');
$query = clone $original;
- $order = $query->clause('order') ?: new OrderByExpression('NULL');
$query->select([
'_cake_page_rownum_' => new UnaryExpression('ROW_NUMBER() OVER', $order)
])->limit(null)
|
Fix incorrect default order by clause.
Instead of NULL, the ORDER BY for SQLServer needs to be a select
statement. For compatibility with SQLServer<I> this statement needs to
be wrapped in parentheses as well.
No new tests were added as a number of tests are currently failing, but
we didn't know because AppVeyor is failing due to incorrect dependencies
being installed.
Refs #<I>
|
diff --git a/fabric-client/events/consumer/consumer.go b/fabric-client/events/consumer/consumer.go
index <HASH>..<HASH> 100644
--- a/fabric-client/events/consumer/consumer.go
+++ b/fabric-client/events/consumer/consumer.go
@@ -240,7 +240,7 @@ func (ec *eventsClient) Start() error {
serverClient := ehpb.NewEventsClient(conn)
ec.stream, err = serverClient.Chat(context.Background())
if err != nil {
- return fmt.Errorf("Could not create client conn to %s", ec.peerAddress)
+ return fmt.Errorf("Could not create client conn to %s (%v)", ec.peerAddress, err)
}
if err = ec.register(ies); err != nil {
|
[FAB-<I>]return detailed event hub connection error
suggest we return more detailed connection error message when
connecting with event hub
Change-Id: I0d7c<I>f<I>bf9a8fc<I>ea<I>e<I>e<I>
|
diff --git a/wkhtmltopdf/utils.py b/wkhtmltopdf/utils.py
index <HASH>..<HASH> 100644
--- a/wkhtmltopdf/utils.py
+++ b/wkhtmltopdf/utils.py
@@ -297,13 +297,14 @@ def make_absolute_paths(content):
if not x['root'].endswith('/'):
x['root'] += '/'
- occur_pattern = '''["|']({0}.*?)["|']'''
+ occur_pattern = '''(["|']{0}.*?["|'])'''
occurences = re.findall(occur_pattern.format(x['url']), content)
occurences = list(set(occurences)) # Remove dups
for occur in occurences:
- content = content.replace(occur,
+ content = content.replace(occur, '"%s"' % (
pathname2fileurl(x['root']) +
- occur[len(x['url']):])
+ occur[1 + len(x['url']): -1]))
+
return content
|
capture quotes in URL rewrite regular expression, fixes #<I>
|
diff --git a/openquake/commands/compare.py b/openquake/commands/compare.py
index <HASH>..<HASH> 100644
--- a/openquake/commands/compare.py
+++ b/openquake/commands/compare.py
@@ -112,10 +112,10 @@ class Comparator(object):
what += '?imt=' + imt
aw = extractor.get(what)
arrays = numpy.zeros((len(self.extractors), len(sids), 1))
- arrays[0] = getattr(aw, imt)[sids]
+ arrays[0, :, 0] = getattr(aw, imt)[sids]
extractor.close()
for e, extractor in enumerate(self.extractors[1:], 1):
- arrays[e] = getattr(extractor.get(what), imt)[sids]
+ arrays[e, :, 0] = getattr(extractor.get(what), imt)[sids]
extractor.close()
return arrays # shape (C, N, 1)
|
Fixed compare avg_gmf [ci skip]
|
diff --git a/setup.py b/setup.py
index <HASH>..<HASH> 100644
--- a/setup.py
+++ b/setup.py
@@ -7,8 +7,8 @@ setup(
name='proso-apps',
version=version,
description='General library for applications in PROSO projects',
- author='Jan Papousek',
- author_email='jan.papousek@gmail.com',
+ author='Jan Papousek, Vit Stanislav',
+ author_email='jan.papousek@gmail.com, slaweet@seznam.cz',
namespace_packages = ['proso', 'proso.django'],
include_package_data = True,
packages=[
@@ -31,6 +31,7 @@ setup(
install_requires=[
'Django>=1.6,<1.7',
'django-debug-toolbar>=1.1',
+ 'django-flatblocks>=0.8',
'django-ipware>=0.0.8',
'django-lazysignup>=0.12.2',
'django-social-auth>=0.7.28',
|
update setup.py according to proso_client
|
diff --git a/DynamicActiveQuery.php b/DynamicActiveQuery.php
index <HASH>..<HASH> 100644
--- a/DynamicActiveQuery.php
+++ b/DynamicActiveQuery.php
@@ -130,7 +130,7 @@ class DynamicActiveQuery extends \yii\db\ActiveQuery
$type
= "binary$l|char$l|date|datetime$l|decimal$l|double$l|int(eger)?"
. "|signed(?: inte(eger)?)?|time$l|unsigned(?: inte(eger)?)?";
- $pattern = "{ < ($start $cont* (?: \\. $cont+)*) (?: \\| ($type))? > }ux";
+ $pattern = "{ \\{ ($start $cont* (?: \\. $cont+)*) (?: \\| ($type))? \\} }ux";
$i = 0;
$sql = preg_replace_callback($pattern, $callback, $sql);
|
changed dyn-col syntax for better sql compat
|
diff --git a/includes/session.php b/includes/session.php
index <HASH>..<HASH> 100644
--- a/includes/session.php
+++ b/includes/session.php
@@ -470,6 +470,8 @@ if (!defined('WT_THEME_DIR')) {
if (!$THEME_DIR && isset($_SESSION['theme_dir']) && in_array($_SESSION['theme_dir'], get_theme_names())) {
$THEME_DIR=$_SESSION['theme_dir'];
}
+ } else {
+ $THEME_DIR='';
}
if (!$THEME_DIR) {
// User cannot choose (or has not chosen) a theme.
|
Fix undefined $THEME_DIR where not $ALLOW_USER_THEMES
|
diff --git a/app/controllers/alchemy/admin/dashboard_controller.rb b/app/controllers/alchemy/admin/dashboard_controller.rb
index <HASH>..<HASH> 100644
--- a/app/controllers/alchemy/admin/dashboard_controller.rb
+++ b/app/controllers/alchemy/admin/dashboard_controller.rb
@@ -42,7 +42,6 @@ module Alchemy
# Get alchemy versions from rubygems or github, if rubygems failes.
def get_alchemy_versions
# first we try rubygems.org
- logger.info "\nquery rubygems\n"
response = query_rubygems
if response.code == "200"
alchemy_versions = JSON.parse(response.body)
@@ -50,7 +49,6 @@ module Alchemy
else
# rubygems.org not available?
# then we try github
- logger.info "\nquery github\n"
response = query_github
if response.code == "200"
alchemy_tags = JSON.parse(response.body)
|
Removes logging from update checker.
|
diff --git a/src/jwplayer.hlsjs.js b/src/jwplayer.hlsjs.js
index <HASH>..<HASH> 100644
--- a/src/jwplayer.hlsjs.js
+++ b/src/jwplayer.hlsjs.js
@@ -468,6 +468,8 @@ function HlsProv(id){
// XXX pavelki: hack to remove pending segments
delete hls.bufferController.segments;
this.attached = false;
+ // XXX yurij: remove when detachMedia->bufferring issue fixed
+ this.setState('paused');
return video;
};
this.setState = function(state){
|
revert of zeetv/resume_waiting_ms fix due to invalid stats issue
|
diff --git a/setup.py b/setup.py
index <HASH>..<HASH> 100755
--- a/setup.py
+++ b/setup.py
@@ -46,14 +46,14 @@ class setup_tests_runner(command):
setup(
name='pyclustering',
packages=find_packages(),
- version='0.9.3.1',
+ version='0.10.0',
description='pyclustring is a python data mining library',
long_description=load_readme(),
url='https://github.com/annoviko/pyclustering',
project_urls={
'Homepage': 'https://pyclustering.github.io/',
'Repository': 'https://github.com/annoviko/pyclustering',
- 'Documentation': 'https://pyclustering.github.io/docs/0.9.3/html/index.html',
+ 'Documentation': 'https://pyclustering.github.io/docs/0.10.0/html/index.html',
'Bug Tracker': 'https://github.com/annoviko/pyclustering/issues'
},
license='GNU Public License',
|
[.][Release] Update version <I>.
|
diff --git a/salt/ssh/__init__.py b/salt/ssh/__init__.py
index <HASH>..<HASH> 100644
--- a/salt/ssh/__init__.py
+++ b/salt/ssh/__init__.py
@@ -180,7 +180,12 @@ class Single(multiprocessing.Process):
ret = self.shell.exec_cmd(cmd)
if ret.startswith('deploy'):
self.deploy()
- return json.loads(self.cmd(self.arg_str))
+ return json.loads(
+ # XXX: Remove the next pylint declaration when pylint 0.29
+ # comes out. More information:
+ # http://hustoknow.blogspot.pt/2013/06/pylint.html
+ self.cmd(self.arg_str) # pylint: disable=E1121
+ )
try:
data = json.loads(ret)
return {self.id: data['local']}
|
Work around pylint bug of wrongly reporting too many arguments.
More info on <URL>
|
diff --git a/lib/flipper/adapters/dalli.rb b/lib/flipper/adapters/dalli.rb
index <HASH>..<HASH> 100644
--- a/lib/flipper/adapters/dalli.rb
+++ b/lib/flipper/adapters/dalli.rb
@@ -92,7 +92,7 @@ module Flipper
private
def key_for(feature)
- feature
+ feature.to_s
end
end
end
|
Get explicit about key used for dalli
Deep in dalli, it was doing feature.to_s so now we just do this in flipper in case dalli ever stops doing that.
|
diff --git a/index.js b/index.js
index <HASH>..<HASH> 100644
--- a/index.js
+++ b/index.js
@@ -61,9 +61,14 @@ module.exports = function hook (modules, options, onrequire) {
}
}
- if (hook.cache[filename]) return exports // abort if module have already been processed
- hook.cache[filename] = exports
+ // only call onrequire the first time a module is loaded
+ if (!hook.cache.hasOwnProperty(filename)) {
+ // ensure that the cache entry is assigned a value before calling
+ // onrequire, in case calling onrequire requires the same module.
+ hook.cache[filename] = exports
+ hook.cache[filename] = onrequire(exports, name, basedir)
+ }
- return onrequire(exports, name, basedir)
+ return hook.cache[filename]
}
}
diff --git a/test/test.js b/test/test.js
index <HASH>..<HASH> 100644
--- a/test/test.js
+++ b/test/test.js
@@ -93,6 +93,19 @@ test('cache', function (t) {
t.end()
})
+test('replacement value', function (t) {
+ var replacement = {}
+
+ hook(['url'], function (exports, name, basedir) {
+ return replacement
+ })
+
+ t.deepEqual(require('url'), replacement)
+ t.deepEqual(require('url'), replacement)
+
+ t.end()
+})
+
test('circular', function (t) {
t.plan(2)
|
Make cache value replaceable (#2)
|
diff --git a/tests/test_templatetags.py b/tests/test_templatetags.py
index <HASH>..<HASH> 100644
--- a/tests/test_templatetags.py
+++ b/tests/test_templatetags.py
@@ -10,6 +10,7 @@ Tests for `django-sheets` models module.
import os
import httpretty
+from io import open
from django import template
from django.test import SimpleTestCase
|
use io.open in tests for py<I> compat
|
diff --git a/eZ/Publish/Core/Persistence/Legacy/Content/Search/Gateway/SortClauseHandler.php b/eZ/Publish/Core/Persistence/Legacy/Content/Search/Gateway/SortClauseHandler.php
index <HASH>..<HASH> 100644
--- a/eZ/Publish/Core/Persistence/Legacy/Content/Search/Gateway/SortClauseHandler.php
+++ b/eZ/Publish/Core/Persistence/Legacy/Content/Search/Gateway/SortClauseHandler.php
@@ -65,7 +65,9 @@ abstract class SortClauseHandler
* @param int $number
* @return void
*/
- abstract public function applyJoin( ezcQuerySelect $query, SortClause $sortClause, $number );
+ public function applyJoin( ezcQuerySelect $query, SortClause $sortClause, $number )
+ {
+ }
/**
* Returns the quoted sort column name
|
Changed: unabstracting applyJoin() by default: no additional join
|
diff --git a/src/Strava/API/Service/REST.php b/src/Strava/API/Service/REST.php
index <HASH>..<HASH> 100644
--- a/src/Strava/API/Service/REST.php
+++ b/src/Strava/API/Service/REST.php
@@ -64,7 +64,6 @@ class REST implements ServiceInterface
{
// Workaround for export methods getRouteAsGPX, getRouteAsTCX:
if (is_string($response)) {
- // @phpstan-ignore-next-line
return $response;
}
|
fix phpstan errors caused by type hint changes
|
diff --git a/src/android/AudioInputReceiver.java b/src/android/AudioInputReceiver.java
index <HASH>..<HASH> 100644
--- a/src/android/AudioInputReceiver.java
+++ b/src/android/AudioInputReceiver.java
@@ -141,6 +141,7 @@ public class AudioInputReceiver extends Thread {
int numReadBytes = 0;
byte audioBuffer[] = new byte[readBufferSize];
synchronized(this) {
+ URI finalUrl = fileUrl; // even if the member changes, we use what we were originally given
recorder.startRecording();
try
@@ -165,7 +166,7 @@ public class AudioInputReceiver extends Thread {
}
} // loop
os.close();
- File wav = new File(fileUrl);
+ File wav = new File(finalUrl);
addWavHeader(audioFile, wav);
audioFile.delete();
message = handler.obtainMessage();
@@ -189,7 +190,7 @@ public class AudioInputReceiver extends Thread {
recorder.release();
recorder = null;
- }
+ } // syncrhonized
} // recording to fileUrl
}
|
Android: Ensure the file URL used for recording is the URL given by the event when recording finishes.
|
diff --git a/tools/run_tests/python_utils/jobset.py b/tools/run_tests/python_utils/jobset.py
index <HASH>..<HASH> 100755
--- a/tools/run_tests/python_utils/jobset.py
+++ b/tools/run_tests/python_utils/jobset.py
@@ -302,6 +302,7 @@ class Job(object):
self._retries += 1
self.result.num_failures += 1
self.result.retries = self._timeout_retries + self._retries
+ # NOTE: job is restarted regardless of jobset's max_time setting
self.start()
else:
self._state = _FAILURE
@@ -344,6 +345,7 @@ class Job(object):
if self._spec.kill_handler:
self._spec.kill_handler(self)
self._process.terminate()
+ # NOTE: job is restarted regardless of jobset's max_time setting
self.start()
else:
message('TIMEOUT', '%s [pid=%d, time=%.1fsec]' % (self._spec.shortname, self._process.pid, elapsed), stdout(), do_newline=True)
|
explain retries and jobset.max_time setting
|
diff --git a/fastai/vision/widgets.py b/fastai/vision/widgets.py
index <HASH>..<HASH> 100644
--- a/fastai/vision/widgets.py
+++ b/fastai/vision/widgets.py
@@ -37,7 +37,7 @@ def _update_children(
# Cell
def carousel(
- children:(list,tuple)=(), # `Box` objects to display in a carousel
+ children:tuple=(), # `Box` objects to display in a carousel
**layout
) -> Box: # An `ipywidget`'s carousel
"A horizontally scrolling carousel"
|
Update fastai/vision/widgets.py
Updated carusel function docment
|
diff --git a/proto/qan/qan.go b/proto/qan/qan.go
index <HASH>..<HASH> 100644
--- a/proto/qan/qan.go
+++ b/proto/qan/qan.go
@@ -63,6 +63,7 @@ type QueryLog struct {
Start_ts time.Time
Query_count float32
Query_time_sum float32
+ Query_time_avg float32
}
type QueryRank struct {
|
Added Query_time_avg to extand sparkline
|
diff --git a/common/config/main.php b/common/config/main.php
index <HASH>..<HASH> 100644
--- a/common/config/main.php
+++ b/common/config/main.php
@@ -1,7 +1,7 @@
<?php
$config = [
'name' => 'Feehi CMS',
- 'version' => '0.1.2',
+ 'version' => '0.1.3',
'vendorPath' => dirname(dirname(__DIR__)) . '/vendor',
'aliases' => [
'@bower' => '@vendor/bower-asset',
|
udpate version to <I>
|
diff --git a/activerecord/lib/active_record/base.rb b/activerecord/lib/active_record/base.rb
index <HASH>..<HASH> 100644
--- a/activerecord/lib/active_record/base.rb
+++ b/activerecord/lib/active_record/base.rb
@@ -890,7 +890,7 @@ module ActiveRecord #:nodoc:
end
def find_sti_class(type_name)
- if type_name.blank? || !columns_hash.include?(inheritance_column)
+ if type_name.nil? || !columns_hash.include?(inheritance_column)
self
else
begin
|
type_name is never a blank string, so use faster .nil? call
|
diff --git a/src/Query/Builder.php b/src/Query/Builder.php
index <HASH>..<HASH> 100644
--- a/src/Query/Builder.php
+++ b/src/Query/Builder.php
@@ -474,7 +474,7 @@ final class Builder
if ($operator == null) {
$operator = '='; // @default=equal
}
- $query = '?? '. $operator .' '. ($params instanceof Identifier ? '??' : $escapeOperator ?: '?');
+ $query = '?? '. $operator .' '. ($params instanceof Identifier ? '??' : ($escapeOperator ?: '?'));
$queryParams = [$field, $params];
} else {
// eg: ['id' => 1]
|
Query\Builder: fix unparenthesized ternary.
|
diff --git a/setup.py b/setup.py
index <HASH>..<HASH> 100644
--- a/setup.py
+++ b/setup.py
@@ -11,7 +11,7 @@ setup(
license='MIT',
url='https://github.com/rhempel/ev3dev-lang-python',
include_package_data=True,
- py_modules=['ev3dev'],
+ packages=['ev3dev'],
install_requires=['Pillow']
)
|
Use packages clause in setup.py instead of py_modules
Otherwise setup looks for ev3dev.py, does not find it and installs
nothing. Forgot to copy this from @EricPobot's changes.
|
diff --git a/src/Store.php b/src/Store.php
index <HASH>..<HASH> 100644
--- a/src/Store.php
+++ b/src/Store.php
@@ -6,25 +6,15 @@ use Sven\FileConfig\Drivers\Driver;
class Store
{
- /**
- * @var \Sven\FileConfig\File
- */
+ /** @var \Sven\FileConfig\File */
protected $file;
- /**
- * @var array
- */
+ /** @var array */
protected $config;
- /**
- * @var \Sven\FileConfig\Drivers\Driver
- */
+ /** @var \Sven\FileConfig\Drivers\Driver */
protected $driver;
- /**
- * @param \Sven\FileConfig\File $file
- * @param \Sven\FileConfig\Drivers\Driver $driver
- */
public function __construct(File $file, Driver $driver)
{
$this->file = $file;
|
Get rid of unnecessary docblocks
|
diff --git a/tests/VerbalExpressions/PHPVerbalExpressions/VerbalExpressionsTest.php b/tests/VerbalExpressions/PHPVerbalExpressions/VerbalExpressionsTest.php
index <HASH>..<HASH> 100644
--- a/tests/VerbalExpressions/PHPVerbalExpressions/VerbalExpressionsTest.php
+++ b/tests/VerbalExpressions/PHPVerbalExpressions/VerbalExpressionsTest.php
@@ -560,8 +560,7 @@ class VerbalExpressionsTest extends PHPUnit_Framework_TestCase
/**
* @depends testGetRegex
*/
- public function testReplace()
- {
+ public function testReplace() {
$regex = new VerbalExpressions();
$regex->add('foo');
|
adding in a quick change to verify that psr-2 violations trigger a failed travis build
|
diff --git a/src/test/java/org/cactoos/map/MergedTest.java b/src/test/java/org/cactoos/map/MergedTest.java
index <HASH>..<HASH> 100644
--- a/src/test/java/org/cactoos/map/MergedTest.java
+++ b/src/test/java/org/cactoos/map/MergedTest.java
@@ -59,20 +59,6 @@ public final class MergedTest {
}
@Test
- public void behavesAsMap() {
- new Assertion<>(
- "Must behave as a map",
- new Merged<Integer, Integer>(
- new MapOf<Integer, Integer>(
- new MapEntry<>(0, -1),
- new MapEntry<>(1, 1)
- )
- ),
- new BehavesAsMap<>(1, 1)
- ).affirm();
- }
-
- @Test
public void createsMapFromMaps() {
new Assertion<>(
"Must merge a few maps",
|
(#<I>) Remove redundant test
|
diff --git a/lib/rake/sprocketstask.rb b/lib/rake/sprocketstask.rb
index <HASH>..<HASH> 100644
--- a/lib/rake/sprocketstask.rb
+++ b/lib/rake/sprocketstask.rb
@@ -49,6 +49,9 @@ module Rake
#
attr_accessor :assets
+ # Number of old assets to keep.
+ attr_accessor :keep
+
# Logger to use during rake tasks. Defaults to using stderr.
#
# t.logger = Logger.new($stdout)
@@ -78,6 +81,7 @@ module Rake
@environment = lambda { Sprockets::Environment.new(Dir.pwd) }
@logger = Logger.new($stderr)
@logger.level = Logger::INFO
+ @keep = 2
yield self if block_given?
@@ -105,7 +109,7 @@ module Rake
desc name == :assets ? "Clean old assets" : "Clean old #{name} assets"
task "clean_#{name}" do
with_logger do
- manifest.clean
+ manifest.clean(keep)
end
end
|
Add option for number of assets to keep
Fixes #<I>
|
diff --git a/spring/src/test/java/org/jtransfo/spring/domain/BeanValidationConvertInterceptor.java b/spring/src/test/java/org/jtransfo/spring/domain/BeanValidationConvertInterceptor.java
index <HASH>..<HASH> 100644
--- a/spring/src/test/java/org/jtransfo/spring/domain/BeanValidationConvertInterceptor.java
+++ b/spring/src/test/java/org/jtransfo/spring/domain/BeanValidationConvertInterceptor.java
@@ -31,12 +31,12 @@ public class BeanValidationConvertInterceptor implements ConvertInterceptor {
T res = next.convert(source, target, isTargetTo, tags);
if (!isTargetTo) { // only validate on the domain objects, not on transfer objects
BindingResult bindingResult = new MapBindingResult(new HashMap(), "");
- validator.validate(target, bindingResult);
+ validator.validate(res, bindingResult);
if (bindingResult.hasErrors()) {
Set<ConstraintViolation<?>> violations = new HashSet<ConstraintViolation<?>>();
for (ObjectError error : bindingResult.getAllErrors()) {
violations.add(new ConstraintViolationImpl(error.getDefaultMessage(), error.getDefaultMessage(),
- target.getClass(), target, target, target,
+ res.getClass(), res, res, res,
PathImpl.createPathFromString(error.getObjectName()),
null, null));
}
|
#<I> and #<I> should validate result from chain, not original target
|
diff --git a/provision/docker/image.go b/provision/docker/image.go
index <HASH>..<HASH> 100644
--- a/provision/docker/image.go
+++ b/provision/docker/image.go
@@ -50,7 +50,10 @@ func migrateImages() error {
if nodeErr, ok := err.(cluster.DockerNodeError); ok {
baseErr = nodeErr.BaseError()
}
- if err != nil && err != storage.ErrNoSuchImage && baseErr != docker.ErrNoSuchImage {
+ if err != nil {
+ if err == storage.ErrNoSuchImage || baseErr == docker.ErrNoSuchImage {
+ continue
+ }
return err
}
if registry != "" {
|
provision/docker: if image is not available we shouldnt try to push it
|
diff --git a/server.js b/server.js
index <HASH>..<HASH> 100644
--- a/server.js
+++ b/server.js
@@ -964,7 +964,10 @@ cache(function(data, match, sendBadge) {
try {
var data = JSON.parse(buffer);
var version = data.version;
- var license = data.license;
+ var license;
+ if (typeof data.license === 'string') {
+ license = data.license;
+ } else { license = data.license.type; }
var platforms = Object.keys(data.platforms).join(' | ');
version = version.replace(/^v/, "");
if (type === 'v') {
|
CocoaPods license can be a hashtable.
Containing the `type` field for license information.
Fixes #<I>.
|
diff --git a/lib/cloud_crowd/models/job.rb b/lib/cloud_crowd/models/job.rb
index <HASH>..<HASH> 100644
--- a/lib/cloud_crowd/models/job.rb
+++ b/lib/cloud_crowd/models/job.rb
@@ -100,7 +100,7 @@ module CloudCrowd
# This job is splittable if its Action has a +split+ method.
def splittable?
- self.action_class.public_instance_methods.include? 'split'
+ self.action_class.public_instance_methods.include?(:split)
end
# This job is done splitting if it's finished with its splitting work units.
@@ -110,7 +110,7 @@ module CloudCrowd
# This job is mergeable if its Action has a +merge+ method.
def mergeable?
- self.processing? && self.action_class.public_instance_methods.include?('merge')
+ self.processing? && self.action_class.public_instance_methods.include?(:merge)
end
# Retrieve the class for this Job's Action.
|
Fixed split and merge method checking for <I>
|
diff --git a/Bundle/WidgetMapBundle/Entity/WidgetMap.php b/Bundle/WidgetMapBundle/Entity/WidgetMap.php
index <HASH>..<HASH> 100644
--- a/Bundle/WidgetMapBundle/Entity/WidgetMap.php
+++ b/Bundle/WidgetMapBundle/Entity/WidgetMap.php
@@ -212,6 +212,7 @@ class WidgetMap
*/
public function setReplaced($replaced)
{
+ $replaced->addSubstitute($this);
$this->replaced = $replaced;
}
@@ -371,7 +372,14 @@ class WidgetMap
}
/**
- * @param mixed $substitutes
+ * @param WidgetMap $substitute
+ */
+ public function addSubstitute(WidgetMap $substitute)
+ {
+ $this->substitutes->add($substitute);
+ }
+ /**
+ * @param [WidgetMap] $substitutes
*/
public function setSubstitutes($substitutes)
{
|
set substitute when set a parent to a widget
|
diff --git a/salt/modules/iptables.py b/salt/modules/iptables.py
index <HASH>..<HASH> 100644
--- a/salt/modules/iptables.py
+++ b/salt/modules/iptables.py
@@ -466,15 +466,15 @@ def _has_check():
else:
return False
elif __grains__['os'] == 'Ubuntu':
- if __grains__['osrelease'] > 10.04:
- return False
- else:
+ if __grains__['osrelease'] == '10.04':
return True
- elif __grains__['os'] == 'Debian':
- if __grains__['osrelease'] > 6:
- return False
else:
+ return False
+ elif __grains__['os'] == 'Debian':
+ if __grains__['osrelease'].split('.')[0] == '6':
return True
+ else:
+ return False
elif __salt__['cmd.run']('iptables -h').find('--check') == -1:
return True
else:
|
Fix up debian and ubuntu checks
|
diff --git a/chef-config/lib/chef-config/config.rb b/chef-config/lib/chef-config/config.rb
index <HASH>..<HASH> 100644
--- a/chef-config/lib/chef-config/config.rb
+++ b/chef-config/lib/chef-config/config.rb
@@ -436,8 +436,6 @@ module ChefConfig
end
default :rest_timeout, 300
- default :yum_timeout, 900
- default :yum_lock_timeout, 30
default :solo, false
# Are we running in old Chef Solo legacy mode?
|
Remove unused yum_timeout and yum_lock_timeout configs
These haven't been used since we refactored the yum provider
|
diff --git a/Flickr4Java/src/main/java/com/flickr4java/flickr/photos/PhotoUtils.java b/Flickr4Java/src/main/java/com/flickr4java/flickr/photos/PhotoUtils.java
index <HASH>..<HASH> 100644
--- a/Flickr4Java/src/main/java/com/flickr4java/flickr/photos/PhotoUtils.java
+++ b/Flickr4Java/src/main/java/com/flickr4java/flickr/photos/PhotoUtils.java
@@ -78,6 +78,7 @@ public final class PhotoUtils {
photo.setMedia(photoElement.getAttribute("media"));
photo.setMediaStatus(photoElement.getAttribute("media_status"));
photo.setPathAlias(photoElement.getAttribute("pathalias"));
+ photo.setViews(photoElement.getAttribute("views"));
Element peopleElement = (Element) photoElement.getElementsByTagName("people").item(0);
if(peopleElement != null){
|
Reinstated "views" element
|
diff --git a/lib/request.js b/lib/request.js
index <HASH>..<HASH> 100644
--- a/lib/request.js
+++ b/lib/request.js
@@ -28,6 +28,8 @@ Request.prototype.put = function(path, data, cb) {
Request.prototype.completeRequest = function(method, path, cb, data) {
+ logger.info('Requesting Data from: https://' + this.hostname + path);
+
var https = require('https'),
dataString = JSON.stringify(data),
options = {
|
Added debugging to show the location of the request
|
diff --git a/merlin/interfaces.py b/merlin/interfaces.py
index <HASH>..<HASH> 100644
--- a/merlin/interfaces.py
+++ b/merlin/interfaces.py
@@ -30,7 +30,7 @@ class IValidator(Interface):
"""
A validator for a step in an exercise.
"""
- def validate(userStore, submission):
+ def validate(submission, userStore):
"""
Validates a submission using the context of a user store.
"""
|
Flip order of userStore and submission in IValidator
|
diff --git a/lib/findJsModulesFor.js b/lib/findJsModulesFor.js
index <HASH>..<HASH> 100644
--- a/lib/findJsModulesFor.js
+++ b/lib/findJsModulesFor.js
@@ -169,11 +169,11 @@ function findJsModulesFor(config, pathToCurrentFile, variableName) {
let matchedModules = [];
+ matchedModules.push(...findEnvironmentCoreModules(config, variableName));
+ matchedModules.push(...findImportsFromPackageJson(config, variableName));
matchedModules.push(
...findImportsFromLocalFiles(config, variableName, pathToCurrentFile)
);
- matchedModules.push(...findEnvironmentCoreModules(config, variableName));
- matchedModules.push(...findImportsFromPackageJson(config, variableName));
// If you have overlapping lookup paths, you might end up seeing the same
// module to import twice. In order to dedupe these, we remove the module
|
Find imports from local files last
This order now matches the order that imports will be grouped in, which
I think gives some nice symmetry. Since this list is sorted next anyway,
the order that we do this in shouldn't make any difference to the user.
|
diff --git a/client/jetpack-connect/site-type.js b/client/jetpack-connect/site-type.js
index <HASH>..<HASH> 100644
--- a/client/jetpack-connect/site-type.js
+++ b/client/jetpack-connect/site-type.js
@@ -35,14 +35,12 @@ class JetpackSiteType extends Component {
<MainWrapper isWide>
<div className="jetpack-connect__step">
<FormattedHeader
- headerText={ translate( 'High performance. Solid security. Your site, just better.' ) }
+ headerText={ translate( 'What are we building today?' ) }
subHeaderText={ translate(
- 'To get started, tell us a little bit about your site goals.'
+ 'Choose the best starting point for your site. You can add or change features later.'
) }
/>
- <FormattedHeader headerText={ translate( 'What kind of site do you have?' ) } />
-
<SiteTypeForm submitForm={ this.handleSubmit } />
<WpcomColophon />
|
Improve the copy of the NUX header, in alignment with the wpcom one. (#<I>)
|
diff --git a/delayed/delayed_test.go b/delayed/delayed_test.go
index <HASH>..<HASH> 100644
--- a/delayed/delayed_test.go
+++ b/delayed/delayed_test.go
@@ -27,5 +27,7 @@ func TestDelayed(t *testing.T) {
}
func TestDelayedAll(t *testing.T) {
- dstest.SubtestAll(t, New(datastore.NewMapDatastore(), delay.Fixed(time.Millisecond)))
+ // Delay for virtually no time, we just want to make sure this works correctly, not that it
+ // delays anything.
+ dstest.SubtestAll(t, New(datastore.NewMapDatastore(), delay.Fixed(time.Nanosecond)))
}
|
test: faster delaystore test
We don't _actually_ need to delay here. The basic subtests don't even
know that things should be delayed.
|
diff --git a/test/tools/runner/index.js b/test/tools/runner/index.js
index <HASH>..<HASH> 100644
--- a/test/tools/runner/index.js
+++ b/test/tools/runner/index.js
@@ -98,3 +98,8 @@ after(() => mock.cleanup());
require('./plugins/deferred');
require('./plugins/session_leak_checker');
require('./plugins/client_leak_checker');
+
+// configure mocha and chai
+require('mocha-sinon');
+const chai = require('chai');
+chai.use(require('sinon-chai'));
|
chore: add sinon-chai and mocha-chai for all tests
|
diff --git a/lib/with_model/version.rb b/lib/with_model/version.rb
index <HASH>..<HASH> 100644
--- a/lib/with_model/version.rb
+++ b/lib/with_model/version.rb
@@ -1,3 +1,3 @@
module WithModel
- VERSION = "0.2.5"
+ VERSION = "0.2.6"
end
|
Bumps version to cut new version of gem.
|
diff --git a/malaffinity/exceptions.py b/malaffinity/exceptions.py
index <HASH>..<HASH> 100644
--- a/malaffinity/exceptions.py
+++ b/malaffinity/exceptions.py
@@ -17,7 +17,7 @@ class MALAffinityException(Exception): # noqa: D204
class NoAffinityError(MALAffinityException): # noqa: D204, D205, D400
"""
Raised when either the shared rated anime between the base user
- and another user is less than 10, the user does not have any rated
+ and another user is less than 11, the user does not have any rated
anime, or the standard deviation of either users' scores is zero.
"""
pass
|
Correct incorrect information in `NoAffinityError` docstring
Incorrectly stated that the minimum number of shared, rated anime needed to calculate affinity was <I>, when it's actually <I>
|
diff --git a/src/es/validation.php b/src/es/validation.php
index <HASH>..<HASH> 100644
--- a/src/es/validation.php
+++ b/src/es/validation.php
@@ -177,5 +177,6 @@ return [
'time' => 'hora',
'subject' => 'asunto',
'message' => 'mensaje',
+ 'price' => 'precio',
],
];
|
[es] - Add price translation to validation file.
|
diff --git a/lib/cinchize.rb b/lib/cinchize.rb
index <HASH>..<HASH> 100644
--- a/lib/cinchize.rb
+++ b/lib/cinchize.rb
@@ -199,6 +199,8 @@ module Cinchize
pidfile = Daemons::PidFile.new dir, app_name
return false if pidfile.pid.nil?
return Process.kill(0, pidfile.pid) != 0
+ rescue Errno::ESRCH => e
+ return false
end
end
end
|
rescues if there's no pid to query about status
|
diff --git a/request/amplify.request.js b/request/amplify.request.js
index <HASH>..<HASH> 100644
--- a/request/amplify.request.js
+++ b/request/amplify.request.js
@@ -101,7 +101,7 @@ amplify.request.types.ajax = function( defnSettings ) {
});
}
- $.ajax({
+ $.ajax($.extend( {}, defnSettings, {
url: url,
type: defnSettings.type,
data: data,
@@ -123,7 +123,7 @@ amplify.request.types.ajax = function( defnSettings ) {
return ret && amplify.publish( "request.before.ajax",
defnSettings, settings, ajaxSettings, xhr );
}
- });
+ }) );
};
};
|
Request: Pass all definition settings through to jQuery.ajax().
|
diff --git a/admin/lang.php b/admin/lang.php
index <HASH>..<HASH> 100644
--- a/admin/lang.php
+++ b/admin/lang.php
@@ -179,11 +179,14 @@
echo "<TABLE WIDTH=\"100%\" CELLPADDING=2 CELLSPACING=3 BORDER=0>";
foreach ($enstring as $key => $envalue) {
$envalue = nl2br(htmlentities($envalue));
+ $envalue = str_replace("\$a","<B>\$a</B>", $envalue); // Make variables bold
+ // TODO: It would be nice if all the $a->something variables were bold too
+
echo "<TR>";
echo "<TD WIDTH=20% BGCOLOR=\"$THEME->cellheading\" NOWRAP VALIGN=TOP>$key</TD>";
echo "<TD WIDTH=40% BGCOLOR=\"$THEME->cellheading\" VALIGN=TOP>$envalue</TD>";
- $value = str_replace("\\","",$string[$key]); // Delete all slashes
+ $value = str_replace("\\","",$string[$key]); // Delete all slashes
$value = htmlentities($value);
if ($editable) {
echo "<TD WIDTH=40% VALIGN=TOP>";
|
Make $a bold so it's easier to see
|
diff --git a/tools/nni_cmd/launcher.py b/tools/nni_cmd/launcher.py
index <HASH>..<HASH> 100644
--- a/tools/nni_cmd/launcher.py
+++ b/tools/nni_cmd/launcher.py
@@ -287,7 +287,7 @@ def launch_experiment(args, experiment_config, mode, config_file_name, experimen
nni_config.set_config('restServerPid', rest_process.pid)
# Deal with annotation
if experiment_config.get('useAnnotation'):
- path = os.path.join(tempfile.gettempdir(), 'nni', 'annotation')
+ path = os.path.join(tempfile.gettempdir(), os.environ['USER'], 'nni', 'annotation')
if not os.path.isdir(path):
os.makedirs(path)
path = tempfile.mkdtemp(dir=path)
|
fix permision deny (#<I>)
|
diff --git a/chartpress.py b/chartpress.py
index <HASH>..<HASH> 100755
--- a/chartpress.py
+++ b/chartpress.py
@@ -237,10 +237,6 @@ def build_images(prefix, images, tag=None, commit_range=None, push=False, chart_
if skip_build:
continue
- if tag is None and commit_range and not path_touched(*paths, commit_range=commit_range):
- print(f"Skipping {name}, not touched in {commit_range}")
- continue
-
template_namespace = {
'LAST_COMMIT': last_commit,
'TAG': image_tag,
|
remove duplicate Skipping-build logic
caused by a merge
|
diff --git a/app/Services/EmailService.php b/app/Services/EmailService.php
index <HASH>..<HASH> 100644
--- a/app/Services/EmailService.php
+++ b/app/Services/EmailService.php
@@ -120,7 +120,7 @@ class EmailService
*
* @return Swift_Transport
*/
- private function transport(): Swift_Transport
+ protected function transport(): Swift_Transport
{
switch (Site::getPreference('SMTP_ACTIVE')) {
case 'sendmail':
|
#<I> - allow EmailService::transport() to be modified
|
diff --git a/lib/row.js b/lib/row.js
index <HASH>..<HASH> 100644
--- a/lib/row.js
+++ b/lib/row.js
@@ -126,13 +126,12 @@ Row.prototype.nameSlice = function(start, end){
/**
* Slices out columns based ont their index
- * @param {Number} start The starting index for the columns slice
- * @param {Number} end The ending index for the columns slice
+ * @param {Number} start Required. An integer that specifies where to start the selection (The first columns has an index of 0). You can also use negative numbers to select from the end of the row
+ * @param {Number} end Optional. An integer that specifies where to end the selection. If omitted, slice() selects all elements from the start position and to the end of the row
* @returns {Row} Row with the sliced out columns
*/
Row.prototype.slice = function(start, end){
start = start || 0;
- end = end || this.length - 1;
var matches = Array.prototype.slice.call(this, start, end);
return new Row({ key:this.key, columns:matches }, this._schema);
|
fixed the way row slices and put better docs
|
diff --git a/ELiDE/layout.py b/ELiDE/layout.py
index <HASH>..<HASH> 100644
--- a/ELiDE/layout.py
+++ b/ELiDE/layout.py
@@ -207,7 +207,13 @@ class ELiDELayout(FloatLayout):
addclosefunc = BoxLayout(orientation='horizontal', size_hint_y=0.05)
addfuncbut = Button(text='New')
addclosefunc.add_widget(addfuncbut)
- closefuncbut = Button(text='Close')
+
+ def dismiss(*args):
+ self._popover.remove_widget(self._funcs_ed_window)
+ self._popover.dismiss()
+ del self._popover
+
+ closefuncbut = Button(text='Close', on_press=dismiss)
addclosefunc.add_widget(closefuncbut)
@self.engine.on_time
|
make it possible to close the funcs editor
|
diff --git a/jicimagelib/image.py b/jicimagelib/image.py
index <HASH>..<HASH> 100644
--- a/jicimagelib/image.py
+++ b/jicimagelib/image.py
@@ -217,10 +217,11 @@ class ImageProxy(object):
@property
def image(self):
"""Return image as numpy.ndarray."""
- tif = TIFF.open(self.fpath, 'r')
- ar = tif.read_image()
- tif.close()
- return ar
+ return Image.from_file(self.fpath)
+# tif = TIFF.open(self.fpath, 'r')
+# ar = tif.read_image()
+# tif.close()
+# return ar
class ImageCollection(list):
"""Class for storing related images."""
|
Refactored code so that ImageProxy.image is a jicimagelib.image.Image.
|
diff --git a/genomepy/genome.py b/genomepy/genome.py
index <HASH>..<HASH> 100644
--- a/genomepy/genome.py
+++ b/genomepy/genome.py
@@ -281,14 +281,14 @@ class Genome(Fasta):
Ns as values
"""
if not self._gap_sizes:
- gap_file = self.filename + ".sizes"
+ gaps_file = re.sub(".fa(.gz)?$", "", self.filename) + ".gaps.bed"
# generate gap file if not found
- if not os.path.exists(gap_file):
- generate_gap_bed(self.filename, gap_file)
+ if not os.path.exists(gaps_file):
+ generate_gap_bed(self.filename, gaps_file)
self._gap_sizes = {}
- with open(gap_file) as f:
+ with open(gaps_file) as f:
for line in f:
chrom, start, end = line.strip().split("\t")
start, end = int(start), int(end)
|
fix #<I> (#<I>)
|
diff --git a/styx-scheduler-service/src/main/java/com/spotify/styx/flyte/FlyteAdminClientRunner.java b/styx-scheduler-service/src/main/java/com/spotify/styx/flyte/FlyteAdminClientRunner.java
index <HASH>..<HASH> 100644
--- a/styx-scheduler-service/src/main/java/com/spotify/styx/flyte/FlyteAdminClientRunner.java
+++ b/styx-scheduler-service/src/main/java/com/spotify/styx/flyte/FlyteAdminClientRunner.java
@@ -221,7 +221,7 @@ public class FlyteAdminClientRunner implements FlyteRunner {
// TODO: add tracing
tryTerminateDanglingFlyteExecutions();
} catch (Throwable t) {
- LOG.warn("Error while terminating dangling flyte executions", t);
+ LOG.error("Error while terminating dangling flyte executions", t);
}
}
@@ -234,6 +234,8 @@ public class FlyteAdminClientRunner implements FlyteRunner {
for (var domain : project.getDomainsList()) {
String paginationToken = null;
do {
+ //TODO: explore using filters for listing only running executions
+ // or at least listing only the ones newer than some threshold
var executions =
flyteAdminClient.listExecutions(project.getId(), domain.getId(), 100, paginationToken, "");
executions.getExecutionsList().stream()
|
Add TODO for exploring using filters
also increase the log level from warn to error
|
diff --git a/src/Symfony/Component/VarDumper/Dumper/HtmlDumper.php b/src/Symfony/Component/VarDumper/Dumper/HtmlDumper.php
index <HASH>..<HASH> 100644
--- a/src/Symfony/Component/VarDumper/Dumper/HtmlDumper.php
+++ b/src/Symfony/Component/VarDumper/Dumper/HtmlDumper.php
@@ -129,7 +129,7 @@ var refStyle = doc.createElement('style'),
e.addEventListener(n, cb, false);
};
-doc.documentElement.firstChild.appendChild(refStyle);
+(doc.documentElement.firstElementChild || doc.documentElement.children[0]).appendChild(refStyle);
if (!doc.addEventListener) {
addEventListener = function (element, eventName, callback) {
|
[VarDumper] fixed HtmlDumper to target specific the head tag
|
diff --git a/thumbor/detectors/__init__.py b/thumbor/detectors/__init__.py
index <HASH>..<HASH> 100644
--- a/thumbor/detectors/__init__.py
+++ b/thumbor/detectors/__init__.py
@@ -48,10 +48,10 @@ class CascadeLoaderDetector(BaseDetector):
image,
self.__class__.cascade,
cv.CreateMemStorage(0),
- scaleFactor=1.1,
- minNeighbors=3,
+ scale_factor=1.1,
+ min_neighbors=3,
flags=cv.CV_HAAR_DO_CANNY_PRUNING,
- minSize=(20, 20)
+ min_size=(20, 20)
)
return faces
|
upz i used the names from <I> version, now its correct
|
diff --git a/src/Storage/DatabaseEntriesRepository.php b/src/Storage/DatabaseEntriesRepository.php
index <HASH>..<HASH> 100644
--- a/src/Storage/DatabaseEntriesRepository.php
+++ b/src/Storage/DatabaseEntriesRepository.php
@@ -111,11 +111,15 @@ class DatabaseEntriesRepository implements Contract, ClearableRepository, Prunab
$this->storeExceptions($exceptions);
- $this->table('telescope_entries')->insert($entries->map(function ($entry) {
- $entry->content = json_encode($entry->content);
+ $table = $this->table('telescope_entries');
- return $entry->toArray();
- })->toArray());
+ $entries->chunk(1000)->each(function ($chunked) use ($table) {
+ $table->insert($chunked->map(function ($entry) {
+ $entry->content = json_encode($entry->content);
+
+ return $entry->toArray();
+ })->toArray());
+ });
$this->storeTags($entries->pluck('tags', 'uuid'));
}
|
prevent heavy memory usage by saving query-log-entries in chunks into the db
|
diff --git a/core/src/main/java/io/undertow/channels/FixedLengthStreamSinkChannel.java b/core/src/main/java/io/undertow/channels/FixedLengthStreamSinkChannel.java
index <HASH>..<HASH> 100644
--- a/core/src/main/java/io/undertow/channels/FixedLengthStreamSinkChannel.java
+++ b/core/src/main/java/io/undertow/channels/FixedLengthStreamSinkChannel.java
@@ -341,9 +341,7 @@ public final class FixedLengthStreamSinkChannel implements StreamSinkChannel, Pr
private void exitWrite(long oldVal, long consumed) {
long newVal = oldVal - consumed;
state = newVal;
- if (allAreSet(newVal, FLAG_CLOSE_COMPLETE)) {
- // closed while we were in flight. Call the listener.
- callClosed();
+ if (anyAreSet(oldVal, MASK_COUNT) && allAreClear(newVal, MASK_COUNT)) {
callFinish();
}
}
|
Fix bug in FixedLengthStreamSinkChannel that was breaking persistent connections
|
diff --git a/examples/text-classification/run_xnli.py b/examples/text-classification/run_xnli.py
index <HASH>..<HASH> 100755
--- a/examples/text-classification/run_xnli.py
+++ b/examples/text-classification/run_xnli.py
@@ -332,13 +332,15 @@ def main():
# Training
if training_args.do_train:
+ checkpoint = None
if last_checkpoint is not None:
- model_path = last_checkpoint
+ checkpoint = last_checkpoint
elif os.path.isdir(model_args.model_name_or_path):
- model_path = model_args.model_name_or_path
- else:
- model_path = None
- train_result = trainer.train(model_path=model_path)
+ # Check the config from that potential checkpoint has the right number of labels before using it as a
+ # checkpoint.
+ if AutoConfig.from_pretrained(model_args.model_name_or_path).num_labels == num_labels:
+ checkpoint = model_args.model_name_or_path
+ train_result = trainer.train(resume_from_checkpoint=checkpoint)
metrics = train_result.metrics
max_train_samples = (
data_args.max_train_samples if data_args.max_train_samples is not None else len(train_dataset)
|
model_path should be ignored as the checkpoint path (#<I>)
* model_path is refered as the path of the trainer, and should be ignored as the checkpoint path.
* Improved according to Sgugger's comment.
|
diff --git a/anytemplate/tests/import_errors.py b/anytemplate/tests/import_errors.py
index <HASH>..<HASH> 100644
--- a/anytemplate/tests/import_errors.py
+++ b/anytemplate/tests/import_errors.py
@@ -17,4 +17,12 @@ class Test(unittest.TestCase):
self.assertFalse(cls in globals())
self.assertFalse(getattr(anytemplate.globals, cls) is None)
+ def test_20_engines(self):
+ for mod in ("Cheetah", "jinja2", "mako", "tenjin", "pystache"):
+ sys.modules[mod] = None
+ import anytemplate.engine
+
+ self.assertTrue(sys.modules[mod] is None)
+ self.assertFalse(anytemplate.engine is None)
+
# vim:sw=4:ts=4:et:
|
enhancement: add some more test cases to check import errors
|
diff --git a/pymc3/distributions/transforms.py b/pymc3/distributions/transforms.py
index <HASH>..<HASH> 100644
--- a/pymc3/distributions/transforms.py
+++ b/pymc3/distributions/transforms.py
@@ -128,7 +128,7 @@ class SumTo1(Transform):
name = "sumto1"
def backward(self, y):
- return T.concatenate([y, 1-sum(y, keepdims=True)])
+ return T.concatenate([y, 1 - T.sum(y, keepdims=True)])
def forward(self, x):
return x[:-1]
|
BUG use ``sum`` from Theano in ``SumTo1``
|
diff --git a/src/bidmanager.js b/src/bidmanager.js
index <HASH>..<HASH> 100644
--- a/src/bidmanager.js
+++ b/src/bidmanager.js
@@ -277,8 +277,8 @@ exports.executeCallback = function (timedOut) {
processCallbacks([externalOneTimeCallback]);
}
finally {
- $$PREBID_GLOBAL$$.clearAuction();
externalOneTimeCallback = null;
+ $$PREBID_GLOBAL$$.clearAuction();
}
}
};
|
delete the callback before calling clearAuction (#<I>)
fixes #<I>
|
diff --git a/generated/google/apis/artifactregistry_v1beta1.rb b/generated/google/apis/artifactregistry_v1beta1.rb
index <HASH>..<HASH> 100644
--- a/generated/google/apis/artifactregistry_v1beta1.rb
+++ b/generated/google/apis/artifactregistry_v1beta1.rb
@@ -26,7 +26,7 @@ module Google
# @see https://cloud.google.com/artifacts/docs/
module ArtifactregistryV1beta1
VERSION = 'V1beta1'
- REVISION = '20200612'
+ REVISION = '20200701'
# View and manage your data across Google Cloud Platform services
AUTH_CLOUD_PLATFORM = 'https://www.googleapis.com/auth/cloud-platform'
diff --git a/generated/google/apis/bigquery_v2.rb b/generated/google/apis/bigquery_v2.rb
index <HASH>..<HASH> 100644
--- a/generated/google/apis/bigquery_v2.rb
+++ b/generated/google/apis/bigquery_v2.rb
@@ -25,7 +25,7 @@ module Google
# @see https://cloud.google.com/bigquery/
module BigqueryV2
VERSION = 'V2'
- REVISION = '20200617'
+ REVISION = '20200625'
# View and manage your data in Google BigQuery
AUTH_BIGQUERY = 'https://www.googleapis.com/auth/bigquery'
|
Autogenerated update (<I>-<I>-<I>)
Update:
- artifactregistry_v1beta1
- bigquery_v2
|
diff --git a/lib/mshoplib/tests/MShop/Service/Provider/Decorator/CostsTest.php b/lib/mshoplib/tests/MShop/Service/Provider/Decorator/CostsTest.php
index <HASH>..<HASH> 100644
--- a/lib/mshoplib/tests/MShop/Service/Provider/Decorator/CostsTest.php
+++ b/lib/mshoplib/tests/MShop/Service/Provider/Decorator/CostsTest.php
@@ -18,21 +18,6 @@ class MShop_Service_Provider_Decorator_CostsTest extends MW_Unittest_Testcase
private $_mockProvider;
- /**
- * Runs the test methods of this class.
- *
- * @access public
- * @static
- */
- public static function main()
- {
- require_once 'PHPUnit/TextUI/TestRunner.php';
-
- $suite = new PHPUnit_Framework_TestSuite('MShop_Service_Provider_Decorator_OrderCheckTest');
- $result = PHPUnit_TextUI_TestRunner::run($suite);
- }
-
-
protected function setUp()
{
$this->_context = TestHelper::getContext();
|
Removes unnecessary method in unit test class
|
diff --git a/modules/instance-switcher.php b/modules/instance-switcher.php
index <HASH>..<HASH> 100644
--- a/modules/instance-switcher.php
+++ b/modules/instance-switcher.php
@@ -65,8 +65,8 @@ if ( ! class_exists('InstanceSwitcher') ) {
*/
public static function assets() {
if ( is_user_logged_in() || Helpers::is_staging() ) {
- wp_enqueue_script('seravo', plugins_url('../js/instance-switcher.js', __FILE__), array( 'jquery' ), Helpers::seravo_plugin_version(), false);
- wp_enqueue_style('seravo', plugins_url('../style/instance-switcher.css', __FILE__), null, Helpers::seravo_plugin_version(), 'all');
+ wp_enqueue_script('seravo_instance_switcher', plugins_url('../js/instance-switcher.js', __FILE__), array( 'jquery' ), Helpers::seravo_plugin_version(), false);
+ wp_enqueue_style('seravo_instance_switcher', plugins_url('../style/instance-switcher.css', __FILE__), null, Helpers::seravo_plugin_version(), 'all');
}
}
|
Rename instance switcher asset handles
Only using 'seravo' as handle caused some problems
so they are now named properly.
|
diff --git a/test/helpers/createPeers.js b/test/helpers/createPeers.js
index <HASH>..<HASH> 100644
--- a/test/helpers/createPeers.js
+++ b/test/helpers/createPeers.js
@@ -8,7 +8,7 @@ module.exports = function(count) {
function createPeer() {
var peer = new EventEmitter();
- peer.send = function(data) {
+ peer.write = function(data) {
// emit data on the other peers
allPeers.filter(function(other) {
return other !== peer;
|
Renamed send --> write
|
diff --git a/src/qtism/data/storage/xml/XmlDocument.php b/src/qtism/data/storage/xml/XmlDocument.php
index <HASH>..<HASH> 100644
--- a/src/qtism/data/storage/xml/XmlDocument.php
+++ b/src/qtism/data/storage/xml/XmlDocument.php
@@ -213,7 +213,10 @@ class XmlDocument extends QtiDocument
}
}
- if (@call_user_func_array([$doc, $loadMethod], [$data, LIBXML_COMPACT | LIBXML_NONET | LIBXML_XINCLUDE | LIBXML_PARSEHUGE])) {
+ if (@call_user_func_array(
+ [$doc, $loadMethod],
+ [$data, LIBXML_COMPACT | LIBXML_NONET | LIBXML_XINCLUDE | LIBXML_BIGLINES | LIBXML_PARSEHUGE])
+ ) {
// Infer the QTI version.
try {
// Prefers the version contained in the XML payload if valid.
|
added LIBXML_BIGLINES | LIBXML_PARSEHUGE to work with big files
|
diff --git a/testing/acceptance_test.py b/testing/acceptance_test.py
index <HASH>..<HASH> 100644
--- a/testing/acceptance_test.py
+++ b/testing/acceptance_test.py
@@ -1288,3 +1288,6 @@ def test_no_brokenpipeerror_message(pytester: Pytester) -> None:
ret = popen.wait()
assert popen.stderr.read() == b""
assert ret == 1
+
+ # Cleanup.
+ popen.stderr.close()
|
testing: fix ResourceWarning in broken-pipe test
|
diff --git a/vendor/plugins/refinery/lib/refinery/application_controller.rb b/vendor/plugins/refinery/lib/refinery/application_controller.rb
index <HASH>..<HASH> 100644
--- a/vendor/plugins/refinery/lib/refinery/application_controller.rb
+++ b/vendor/plugins/refinery/lib/refinery/application_controller.rb
@@ -98,8 +98,8 @@ protected
private
def store_current_location!
if admin?
- session[:refinery_return_to] = request.path
- else
+ session[:refinery_return_to] = request.path if request.get? and !request.xhr? # don't want to redirect to AJAX or POST/PUT/DELETE urls
+ elsif request.path !~ /wymiframe|\/system.*/
session[:website_return_to] = request.path
end
end
|
Add exceptions to the return to code.
|
diff --git a/blueprints/ember-eureka/index.js b/blueprints/ember-eureka/index.js
index <HASH>..<HASH> 100644
--- a/blueprints/ember-eureka/index.js
+++ b/blueprints/ember-eureka/index.js
@@ -40,7 +40,7 @@ module.exports = {
// return this.addAddonsToProject({
// packages: [
- // {name: 'ember-moment', target: '4.0.1'},
+ // {name: 'ember-moment', target: '4.1.0'},
// {name: 'emberx-select', target: '2.0.1'},
// {name: 'emberek-selectize', target: 'git://github.com/namlook/emberek-selectize.git#v0.0.3'},
// {name: 'eureka-mixin-actionable-widget', target: 'git://github.com/namlook/eureka-mixin-actionable-widget.git#v0.0.2'},
|
upgrade to ember-moment@<I>
|
diff --git a/src/com/google/javascript/jscomp/Tracer.java b/src/com/google/javascript/jscomp/Tracer.java
index <HASH>..<HASH> 100644
--- a/src/com/google/javascript/jscomp/Tracer.java
+++ b/src/com/google/javascript/jscomp/Tracer.java
@@ -967,7 +967,7 @@ final class Tracer {
/** Remove any ThreadTrace associated with the current thread */
static void clearThreadTrace() {
- traces.set(null);
+ traces.remove();
}
/**
|
Remove Tracer thread local storage when cleaning up.
fixes issue <I>
R=acleung,nicksantos
DELTA=1 (0 added, 0 deleted, 1 changed)
Revision created by MOE tool push_codebase.
MOE_MIGRATION=<I>
git-svn-id: <URL>
|
diff --git a/JJG/Ping.php b/JJG/Ping.php
index <HASH>..<HASH> 100644
--- a/JJG/Ping.php
+++ b/JJG/Ping.php
@@ -184,25 +184,22 @@ class Ping {
}
exec($exec_string, $output, $return);
- // Strip empty lines (make results more uniform across OS versions).
- $output = array_filter($output);
-
- //Reorder indexes from 0,
- $output = array_values($output);
+ // Strip empty lines and reorder the indexes from 0 (to make results more
+ // uniform across OS versions).
+ $output = array_values(array_filter($output));
// If the result line in the output is not empty, parse it.
if (!empty($output[1])) {
-
- // $array = explode(' ', $output[1]);
+ // Search for a 'time' value in the result line.
$response = preg_match("/time(?:=|<)(?<time>[\.0-9]+)(?:|\s)ms/", $output[1], $matches);
- if($response > 0 && isset($matches['time']))
+ // If there's a result and it's greater than 0, return the latency.
+ if ($response > 0 && isset($matches['time'])) {
$latency = round($matches['time']);
-
+ }
}
return $latency;
-
}
/**
|
PR #<I>: Code style and comment cleanup.
|
diff --git a/host.go b/host.go
index <HASH>..<HASH> 100644
--- a/host.go
+++ b/host.go
@@ -403,7 +403,7 @@ func (h *Host) Create(name string) error {
func (h *Host) Provision() error {
// "local" providers use b2d; no provisioning necessary
switch h.Driver.DriverName() {
- case "none", "virtualbox", "vmwarefusion", "vmwarevsphere", "openstack":
+ case "none", "virtualbox", "vmwarefusion", "vmwarevsphere":
return nil
}
|
Provision OpenStack instances with Docker
Since <I>f<I>, Machine doesn't check anymore if Docker is installed
in the created instances, which breaks the compatibility between
<I>-rc5 and <I> when using Machine with some cloud providers
like RunAbove.com.
|
diff --git a/oscrypto/_tls.py b/oscrypto/_tls.py
index <HASH>..<HASH> 100644
--- a/oscrypto/_tls.py
+++ b/oscrypto/_tls.py
@@ -254,7 +254,7 @@ def _parse_tls_records(data):
data_len = len(data)
while pointer < data_len:
# Don't try to parse any more once the ChangeCipherSpec is found
- if data[pointer:pointer + 1] == '\x14':
+ if data[pointer:pointer + 1] == b'\x14':
break
length = int_from_bytes(data[pointer + 3:pointer + 5])
yield (
|
Fix detection of ChangeCipherSpec message during TLS record parsing
|
diff --git a/src/Cartalyst/Sentry/Sentry.php b/src/Cartalyst/Sentry/Sentry.php
index <HASH>..<HASH> 100644
--- a/src/Cartalyst/Sentry/Sentry.php
+++ b/src/Cartalyst/Sentry/Sentry.php
@@ -354,10 +354,17 @@ class Sentry {
* Returns the current user being
* used by Sentry, if any.
*
+ * @param bool $check
* @return Cartalyst\Sentry\Users\UserInterface
*/
- public function getUser()
+ public function getUser($check = false)
{
+ // We will lazily attempt to load our user
+ if ($check === true and $this->user === null)
+ {
+ $this->check();
+ }
+
return $this->user;
}
diff --git a/tests/SentryTest.php b/tests/SentryTest.php
index <HASH>..<HASH> 100644
--- a/tests/SentryTest.php
+++ b/tests/SentryTest.php
@@ -404,4 +404,12 @@ class SentryTest extends PHPUnit_Framework_TestCase {
$this->assertTrue($registeredUser->isActivated());
}
+ public function testGetUserWithCheck()
+ {
+ $sentry = m::mock('Cartalyst\Sentry\Sentry[check]');
+ $sentry->shouldReceive('check')->once();
+ $sentry->getUser();
+ $sentry->getUser(true);
+ }
+
}
|
Allowing Sentry::getUser(true) to check for the user as well as being an accessor.
|
diff --git a/trustmanager/X509FileStore.go b/trustmanager/X509FileStore.go
index <HASH>..<HASH> 100644
--- a/trustmanager/X509FileStore.go
+++ b/trustmanager/X509FileStore.go
@@ -58,12 +58,8 @@ func (s X509FileStore) AddCert(cert *x509.Certificate) error {
}
var filename string
- if cert.Subject.CommonName != "" {
- filename = path.Join(s.baseDir, cert.Subject.CommonName+certExtension)
- } else {
- fingerprint := FingerprintCert(cert)
- filename = path.Join(s.baseDir, string(fingerprint)+certExtension)
- }
+ fingerprint := string(FingerprintCert(cert))
+ filename = path.Join(s.baseDir, cert.Subject.CommonName, fingerprint+certExtension)
if err := s.addNamedCert(cert, filename); err != nil {
return err
|
Changing the path certificates get stored in
|
diff --git a/librosa/util/decorators.py b/librosa/util/decorators.py
index <HASH>..<HASH> 100644
--- a/librosa/util/decorators.py
+++ b/librosa/util/decorators.py
@@ -5,9 +5,8 @@
import warnings
from decorator import decorator
-from numba import jit as optional_jit
-__all__ = ['moved', 'deprecated', 'optional_jit']
+__all__ = ['moved', 'deprecated']
def moved(moved_from, version, version_removed):
|
removed optional_jit decorator, should have been purged in <I> (#<I>)
|
diff --git a/src/main/org/openscience/cdk/atomtype/CDKAtomTypeMatcher.java b/src/main/org/openscience/cdk/atomtype/CDKAtomTypeMatcher.java
index <HASH>..<HASH> 100644
--- a/src/main/org/openscience/cdk/atomtype/CDKAtomTypeMatcher.java
+++ b/src/main/org/openscience/cdk/atomtype/CDKAtomTypeMatcher.java
@@ -440,9 +440,11 @@ public class CDKAtomTypeMatcher implements IAtomTypeMatcher {
IAtom neighbor = cBond.getConnectedAtom(carbon);
if ("O".equals(neighbor.getSymbol())) {
oxygenCount++;
- if (cBond.getOrder() == IBond.Order.SINGLE && neighbor.getFormalCharge() == -1) {
+ IBond.Order order = cBond.getOrder();
+ Integer charge = neighbor.getFormalCharge();
+ if (order == IBond.Order.SINGLE && charge != null && charge == -1) {
singleBondedNegativeOxygenCount++;
- } else if (cBond.getOrder() == IBond.Order.DOUBLE) {
+ } else if (order == IBond.Order.DOUBLE) {
doubleBondedOxygenCount++;
}
}
|
Applied patch from cdk<I>.x:
Fixed a NPE
|
diff --git a/src/main/java/de/btobastian/javacord/entities/impl/ImplServer.java b/src/main/java/de/btobastian/javacord/entities/impl/ImplServer.java
index <HASH>..<HASH> 100644
--- a/src/main/java/de/btobastian/javacord/entities/impl/ImplServer.java
+++ b/src/main/java/de/btobastian/javacord/entities/impl/ImplServer.java
@@ -487,7 +487,7 @@ public class ImplServer implements Server {
logger.debug("Trying to ban an user from server {} (user id: {}, delete days: {})",
ImplServer.this, userId, deleteDays);
HttpResponse<JsonNode> response = Unirest
- .put("https://discordapp.com/api/guilds/:guild_id/bans/" + userId
+ .put("https://discordapp.com/api/guilds/" + getId() + "/bans/" + userId
+ "?delete-message-days=" + deleteDays)
.header("authorization", api.getToken())
.asJson();
|
Fix ImplServer#banUser(String, int)
Fixed an issue where banUser wasn't getting the guild id properly
|
diff --git a/opc/__init__.py b/opc/__init__.py
index <HASH>..<HASH> 100644
--- a/opc/__init__.py
+++ b/opc/__init__.py
@@ -191,7 +191,9 @@ class OPCN2:
sleep(10e-3)
# read the histogram
- for i in range(62):
+ numBytes = 58 if self.firmware in [16, 17] else 62
+
+ for i in range(numBytes):
r = self.cnxn.xfer([0x00])[0]
resp.append(r)
diff --git a/setup.py b/setup.py
index <HASH>..<HASH> 100644
--- a/setup.py
+++ b/setup.py
@@ -1,6 +1,6 @@
#!/usr/bin/env python3
-__version__ = '0.0.8'
+__version__ = '0.0.9'
from distutils.core import setup
|
more bug fixes for firm <I>
|
diff --git a/symphony/lib/toolkit/class.general.php b/symphony/lib/toolkit/class.general.php
index <HASH>..<HASH> 100755
--- a/symphony/lib/toolkit/class.general.php
+++ b/symphony/lib/toolkit/class.general.php
@@ -930,7 +930,7 @@
public function getMimeType($file) {
if (!empty($file)) {
// in PHP 5.3 we can use 'finfo'
- if (version_compare(PHP_VERSION, '5.3.0', '>=')) {
+ if (PHP_VERSION_ID >= 50300) {
$finfo = finfo_open(FILEINFO_MIME_TYPE);
$mime_type = finfo_file($finfo, $file);
finfo_close($finfo);
|
Use constant defined by Symphony for PHP version check
|
diff --git a/app/Http/Controllers/Dashboard/MetricController.php b/app/Http/Controllers/Dashboard/MetricController.php
index <HASH>..<HASH> 100644
--- a/app/Http/Controllers/Dashboard/MetricController.php
+++ b/app/Http/Controllers/Dashboard/MetricController.php
@@ -79,7 +79,7 @@ class MetricController extends Controller
$metricData['calc_type'],
$metricData['display_chart'],
$metricData['places'],
- $metricData['view']
+ $metricData['default_view']
));
} catch (ValidationException $e) {
return Redirect::route('dashboard.metrics.add')
|
Update MetricController.php
Fixed a wrong key identifier in createMetricAction method.
|
diff --git a/js/opusFlux/opusFlux.js b/js/opusFlux/opusFlux.js
index <HASH>..<HASH> 100644
--- a/js/opusFlux/opusFlux.js
+++ b/js/opusFlux/opusFlux.js
@@ -69,7 +69,8 @@
var els = {};
if(($('.OpusFlux-Page').last().hasClass('is-active') && direction == 'forwards')
- || ($('.OpusFlux-Page').first().hasClass('is-active') && direction == 'back')) {
+ || ($('.OpusFlux-Page').first().hasClass('is-active') && direction == 'back')
+ || $('.OpusFlux-Page.is-animating').length > 3) {
return
}
|
Limit number of pages turns at one time to 2
|
diff --git a/endpoints/register.js b/endpoints/register.js
index <HASH>..<HASH> 100644
--- a/endpoints/register.js
+++ b/endpoints/register.js
@@ -65,7 +65,7 @@ class Authentication extends Endpoint {
refresh_token: null,
last_ip: []
}
- this.db.collection('users').insertOne(user)
+ await this.db.collection('users').insertOne(user)
auth.saveIP.bind(this)(user.user_key, ip, 'register', true)
return user.user_key
|
fix: Wait for actual user insertion before returning response
|
diff --git a/jogger-core/src/main/java/org/jogger/test/MockRequest.java b/jogger-core/src/main/java/org/jogger/test/MockRequest.java
index <HASH>..<HASH> 100644
--- a/jogger-core/src/main/java/org/jogger/test/MockRequest.java
+++ b/jogger-core/src/main/java/org/jogger/test/MockRequest.java
@@ -183,11 +183,21 @@ public class MockRequest extends AbstractRequest {
public Map<String, String> getHeaders() {
return headers;
}
+
+ public MockRequest setHeaders(Map<String, String> headers) {
+ this.headers = headers;
+ return this;
+ }
@Override
public String getHeader(String name) {
return headers.get(name);
}
+
+ public MockRequest setHeader(String name, String value) {
+ headers.put(name, value);
+ return this;
+ }
@Override
public FileItem[] getFiles() {
|
Modify MockRequest to add capabilities for header modification
|
diff --git a/test/test_query.rb b/test/test_query.rb
index <HASH>..<HASH> 100644
--- a/test/test_query.rb
+++ b/test/test_query.rb
@@ -2,7 +2,6 @@ require_relative 'helper'
# Test query DSL
class QueryTest < Minitest::Test
-
def setup
Bicho.client = nil
end
|
rubocop: Extra empty line detected at class body beginning
|
diff --git a/src/View/Helper/FormHelper.php b/src/View/Helper/FormHelper.php
index <HASH>..<HASH> 100644
--- a/src/View/Helper/FormHelper.php
+++ b/src/View/Helper/FormHelper.php
@@ -217,10 +217,13 @@ class FormHelper extends Helper
$label = "";
if (!is_null($options['label'])) {
- if ($fieldHasErrors) {
- $options['class'] .= " error ";
- }
- $label .= $this->generateLabel($options);
+ $labelOptions = array(
+ "id" => $options["id"],
+ "class" => $fieldHasErrors ? "error" : "",
+ "label" => $options["label"],
+ );
+
+ $label .= $this->generateLabel($labelOptions);
}
unset($options['label']);
@@ -408,7 +411,7 @@ class FormHelper extends Helper
*/
protected function generateLabel($options)
{
- return sprintf('<label for="%s">%s</label>', $options['id'], $options['label']);
+ return sprintf('<label for="%s" class="%s">%s</label>', $options['id'], $options['class'], $options['label']);
}
/**
|
Added error class to generated label also
|
diff --git a/disque/disque.go b/disque/disque.go
index <HASH>..<HASH> 100644
--- a/disque/disque.go
+++ b/disque/disque.go
@@ -132,11 +132,11 @@ func (c *RedisClient) Add(r AddRequest) (string, error) {
}
if r.Retry > 0 {
- args = args.Add("DELAY", int64(r.Retry.Seconds()))
+ args = args.Add("RETRY", int64(r.Retry.Seconds()))
}
if r.TTL > 0 {
- args = args.Add("DELAY", int64(r.TTL.Seconds()))
+ args = args.Add("TTL", int64(r.TTL.Seconds()))
}
if r.Maxlen > 0 {
|
fixed job add serialization to redis
|
diff --git a/fabfile.py b/fabfile.py
index <HASH>..<HASH> 100644
--- a/fabfile.py
+++ b/fabfile.py
@@ -46,7 +46,8 @@ def _all():
'waterfall': 'inasafe-test.localhost',
'spur': 'inasafe-test.localhost',
'maps.linfiniti.com': 'inasafe-test.linfiniti.com',
- 'linfiniti': 'inasafe-crisis.linfiniti.com'}
+ 'linfiniti': 'inasafe-crisis.linfiniti.com'
+ 'hostname': 'experimental.inasafe.org'}
with hide('output'):
env.user = env.run('whoami')
env.hostname = env.run('hostname')
|
Added shiva to hosts lists in fabfile
|
diff --git a/test/grunt-karma-test.js b/test/grunt-karma-test.js
index <HASH>..<HASH> 100644
--- a/test/grunt-karma-test.js
+++ b/test/grunt-karma-test.js
@@ -2,12 +2,14 @@ describe('grunt-karma', function(){
describe('one', function(){
it('should be awesome', function(){
+ console.log('one');
expect('foo').to.be.a('string');
});
});
describe('two', function(){
it('should be equally awesome', function(){
+ console.log('two');
expect('woot').to.be.a('string');
});
});
|
test: add log for sake of checking grep
|
diff --git a/src/lib/DictionaryType.php b/src/lib/DictionaryType.php
index <HASH>..<HASH> 100644
--- a/src/lib/DictionaryType.php
+++ b/src/lib/DictionaryType.php
@@ -22,7 +22,7 @@ class DictionaryType
return $severity === E_WARNING
? $message === 'Illegal offset type'
: preg_match('/^Resource ID#([0-9]+) used as offset, casting to integer \\(\\1\\)$/', $message);
- }, E_WARNING | E_STRICT);
+ }, E_WARNING | (PHP_MAJOR_VERSION === 5 ? E_STRICT : E_NOTICE));
$array = iterator_to_array($array);
restore_error_handler();
}
|
Suppress E_NOTICE error instead of E_STRICT for indexing by a resource
All of the E_STRICT notices have been reclassified to other levels since PHP <I>.
See <URL>
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.