hash stringlengths 40 40 | diff stringlengths 131 26.7k | message stringlengths 7 694 | project stringlengths 5 67 | split stringclasses 1 value | diff_languages stringlengths 2 24 |
|---|---|---|---|---|---|
cc32cb8a3b122a26d66bdc280703743039929a62 | diff --git a/src/v2/core/state.js b/src/v2/core/state.js
index <HASH>..<HASH> 100644
--- a/src/v2/core/state.js
+++ b/src/v2/core/state.js
@@ -56,7 +56,9 @@ module.exports = class State {
dereferenceObject(object) {
_.forOwn(object, (value, key) => {
- object[key] = this.dereference(value);
+ if (_.isString(value)) {
+ object[key] = this.dereference(value);
+ }
});
return object; | Attempt to fix usher overzealous dereferencing of objects | findmypast_usher | train | js |
62798413da0e096719fd24cc731b1b1abec7f368 | diff --git a/src/Model/Environment.php b/src/Model/Environment.php
index <HASH>..<HASH> 100644
--- a/src/Model/Environment.php
+++ b/src/Model/Environment.php
@@ -56,6 +56,23 @@ class Environment extends Resource
}
/**
+ * Get the public URL for the environment.
+ *
+ * @throws \Exception
+ *
+ * @return string
+ */
+ public function getUrl()
+ {
+ if (!$this->hasLink('public-url')) {
+ $id = $this->data['id'];
+ throw new \Exception("The environment $id does not have a Public URL.");
+ }
+
+ return $this->getLink('public-url');
+ }
+
+ /**
* Branch (create a new environment).
*
* @param string $title The title of the new environment. | Add getUrl method for environments. | platformsh_platformsh-client-php | train | php |
f4d12d60fa81b578520e159bfd4845212c179ac1 | diff --git a/oandapyV20/__init__.py b/oandapyV20/__init__.py
index <HASH>..<HASH> 100644
--- a/oandapyV20/__init__.py
+++ b/oandapyV20/__init__.py
@@ -1,3 +1,7 @@
+import logging
+from .oandapyV20 import API
+from .exceptions import V20Error
+
__title__ = "OANDA REST V20 API Wrapper"
__version__ = "0.4.0"
__author__ = "Feite Brekeveld"
@@ -8,7 +12,6 @@ __copyright__ = "Copyright 2016 - 2017 Feite Brekeveld"
VERSION = __version__
# Set default logging handler to avoid "No handler found" warnings.
-import logging
try:
from logging import NullHandler
except ImportError:
@@ -18,5 +21,7 @@ except ImportError:
logging.getLogger(__name__).addHandler(NullHandler())
-from .oandapyV20 import API
-from .exceptions import V20Error
+__all__ = (
+ 'API',
+ 'V20Error'
+) | moved imports to top, __all__ added | hootnot_oanda-api-v20 | train | py |
ee5ff9322705a45a4591f4b93471e60b9b1625a6 | diff --git a/opal/corelib/regexp.rb b/opal/corelib/regexp.rb
index <HASH>..<HASH> 100644
--- a/opal/corelib/regexp.rb
+++ b/opal/corelib/regexp.rb
@@ -34,6 +34,10 @@ class Regexp < `RegExp`
if (parts.length == 0) {
return /(?!)/;
}
+ // return fast if there's only one element
+ if (parts.length == 1 && parts[0].$$is_regexp) {
+ return parts[0];
+ }
// cover the 2 arrays passed as arguments case
is_first_part_array = parts[0].$$is_array;
if (parts.length > 1 && is_first_part_array) { | Return fast from Regexp.union with a single regexp | opal_opal | train | rb |
17ab43c33f2cc2e8334208f98fae36474da4f922 | diff --git a/src/Silverpop/EngagePod.php b/src/Silverpop/EngagePod.php
index <HASH>..<HASH> 100644
--- a/src/Silverpop/EngagePod.php
+++ b/src/Silverpop/EngagePod.php
@@ -290,7 +290,7 @@ class EngagePod {
"VALUE" => $columns[$key],
);
}
- $data["Envelope"]["Body"]["SelectRecipeientData"]["COLUMN"] = $column_data;
+ $data["Envelope"]["Body"]["SelectRecipientData"]["COLUMN"] = $column_data;
}
$response = $this->_request($data); | fixed typo on line <I> of EngagePod.php | simpleweb_SilverpopPHP | train | php |
75c6269764d779c7df53bfa8caeeccac87162456 | diff --git a/src/angularjs-dropdown-multiselect.js b/src/angularjs-dropdown-multiselect.js
index <HASH>..<HASH> 100644
--- a/src/angularjs-dropdown-multiselect.js
+++ b/src/angularjs-dropdown-multiselect.js
@@ -289,6 +289,9 @@ directiveModule.directive('ngDropdownMultiselect', ['$filter', '$document', '$co
$scope.selectedModel.push(finalObj);
$scope.externalEvents.onItemSelect(finalObj);
if ($scope.settings.closeOnSelect) $scope.open = false;
+ if ($scope.settings.selectionLimit > 0 && $scope.selectedModel.length === $scope.settings.selectionLimit) {
+ $scope.externalEvents.onMaxSelectionReached();
+ }
}
}; | Implementation for onMaxSelectionReached | dotansimha_angularjs-dropdown-multiselect | train | js |
7c4128ed5105e8d354e94940e9c0fd7cd7846132 | diff --git a/lib/active_admin/base_controller/authorization.rb b/lib/active_admin/base_controller/authorization.rb
index <HASH>..<HASH> 100644
--- a/lib/active_admin/base_controller/authorization.rb
+++ b/lib/active_admin/base_controller/authorization.rb
@@ -113,7 +113,9 @@ module ActiveAdmin
redirect_backwards_or_to_root
end
- format.csv { render body: error, status: :unauthorized }
+ body = ActiveAdmin::Dependency.rails5? ? :body : :text
+
+ format.csv { render body => error, status: :unauthorized }
format.json { render json: { error: error }, status: :unauthorized }
format.xml { render xml: "<error>#{error}</error>", status: :unauthorized }
end
diff --git a/spec/unit/authorization/index_overriding_spec.rb b/spec/unit/authorization/index_overriding_spec.rb
index <HASH>..<HASH> 100644
--- a/spec/unit/authorization/index_overriding_spec.rb
+++ b/spec/unit/authorization/index_overriding_spec.rb
@@ -5,7 +5,8 @@ describe Admin::PostsController, 'Index overriding', type: :controller do
controller.instance_eval do
def index
super do
- render body: 'Rendered from passed block' and return
+ body = ActiveAdmin::Dependency.rails5? ? :body : :text
+ render body => 'Rendered from passed block' and return
end
end
end | still call `render text:` on Rails < 5 | activeadmin_activeadmin | train | rb,rb |
7367df67bda377df435d6473eb7adc37870cce21 | diff --git a/webwhatsapi/__init__.py b/webwhatsapi/__init__.py
index <HASH>..<HASH> 100755
--- a/webwhatsapi/__init__.py
+++ b/webwhatsapi/__init__.py
@@ -105,7 +105,7 @@ class WhatsAPIDriver(object):
return self.driver.execute_script('return window.localStorage;')
def set_local_storage(self, data):
- self.driver.execute_script(''.join(["window.localStorage.setItem('{}', '{}');".format(k, v)
+ self.driver.execute_script(''.join(["window.localStorage.setItem('{}', '{}');".format(k, v.replace("\n","\\n") if isinstance(v, str) else v)
for k, v in data.items()]))
def save_firefox_profile(self, remove_old=False):
@@ -365,7 +365,7 @@ class WhatsAPIDriver(object):
unread_messages = []
for raw_message_group in raw_message_groups:
chat = factory_chat(raw_message_group, self)
- messages = [factory_message(message, self) for message in raw_message_group['messages']]
+ messages = list(filter(None.__ne__,[factory_message(message, self) for message in raw_message_group['messages']]))
messages.sort(key=lambda message: message.timestamp)
unread_messages.append(MessageGroup(chat, messages)) | Fix for issue #<I> and #<I> (#<I>)
* Fix for issue :<URL> | mukulhase_WebWhatsapp-Wrapper | train | py |
87826133bf4d8e83edba50e7fc1c0adc0e818e8d | diff --git a/src/main/java/com/stratio/cucumber/aspects/ReplacementAspect.java b/src/main/java/com/stratio/cucumber/aspects/ReplacementAspect.java
index <HASH>..<HASH> 100644
--- a/src/main/java/com/stratio/cucumber/aspects/ReplacementAspect.java
+++ b/src/main/java/com/stratio/cucumber/aspects/ReplacementAspect.java
@@ -213,8 +213,10 @@ public class ReplacementAspect {
// we want to use value previously saved
String prop = ThreadProperty.get(attribute);
-
- newVal = newVal.replace(placeholder, prop);
+
+ if (prop != null) {
+ newVal = newVal.replace(placeholder, prop);
+ }
}
return newVal;
@@ -257,4 +259,4 @@ public class ReplacementAspect {
return newVal;
}
-}
\ No newline at end of file
+} | not to make replacement when value is null
Aoid replacing variable when value is null | Stratio_bdt | train | java |
4473f454cad3762f5d85765c6945f0023822fc2e | diff --git a/src/Symfony/Bundle/FrameworkBundle/Kernel/MicroKernelTrait.php b/src/Symfony/Bundle/FrameworkBundle/Kernel/MicroKernelTrait.php
index <HASH>..<HASH> 100644
--- a/src/Symfony/Bundle/FrameworkBundle/Kernel/MicroKernelTrait.php
+++ b/src/Symfony/Bundle/FrameworkBundle/Kernel/MicroKernelTrait.php
@@ -39,7 +39,7 @@ trait MicroKernelTrait
* ->controller('App\Controller\AdminController::dashboard')
* ;
*/
- abstract protected function configureRoutes(RoutingConfigurator $routes);
+ //abstract protected function configureRoutes(RoutingConfigurator $routes);
/**
* Configures the container.
@@ -58,7 +58,7 @@ trait MicroKernelTrait
*
* $c->parameters()->set('halloween', 'lot of fun');
*/
- abstract protected function configureContainer(ContainerConfigurator $c);
+ //abstract protected function configureContainer(ContainerConfigurator $c);
/**
* {@inheritdoc} | [FrameworkBundle] don't use abstract methods in MicroKernelTrait, their semantics changed in PHP 8 | symfony_symfony | train | php |
07024254cfa47f0261dcba4d37bd0d69f48c2095 | diff --git a/pycbc/ahope/splittable_utils.py b/pycbc/ahope/splittable_utils.py
index <HASH>..<HASH> 100644
--- a/pycbc/ahope/splittable_utils.py
+++ b/pycbc/ahope/splittable_utils.py
@@ -5,7 +5,7 @@ import logging
from pycbc.ahope.ahope_utils import *
from pycbc.ahope.jobsetup_utils import *
-def setup_splittable_workflow(workflow, tmplt_banks, out_dir):
+def setup_splittable_workflow(workflow, tmplt_banks, out_dir=None):
'''
Setup matched filter section of ahope workflow.
FIXME: ADD MORE DOCUMENTATION | option to splittable setup to not supply an output directory | gwastro_pycbc | train | py |
5ff9c64468373144113bf83b6678b6ec87543b50 | diff --git a/addon/routes/course-visualize-instructor.js b/addon/routes/course-visualize-instructor.js
index <HASH>..<HASH> 100644
--- a/addon/routes/course-visualize-instructor.js
+++ b/addon/routes/course-visualize-instructor.js
@@ -36,12 +36,7 @@ export default class CourseVisualizeInstructorRoute extends Route {
async afterModel({ course }) {
const sessions = (await course.sessions).toArray();
- return await all([
- course.school,
- map(sessions, (s) => s.sessionType),
- map(sessions, (s) => s.getAllInstructors()),
- map(sessions, (s) => s.getTotalSumDuration()),
- ]);
+ return await all([course.school, map(sessions, (s) => s.sessionType)]);
}
beforeModel(transition) { | rm unnecessary data loading steps in the afterModel() hook.
we're already loading/processing those data points in model(). | ilios_common | train | js |
96af93c79a039fe0a6f2b4ae7d7ce03bd33974b2 | diff --git a/chwrapper/__init__.py b/chwrapper/__init__.py
index <HASH>..<HASH> 100644
--- a/chwrapper/__init__.py
+++ b/chwrapper/__init__.py
@@ -1,5 +1,5 @@
__all__ = [".services.search.Search"]
-__version__ = "0.1.0"
+__version__ = "0.2.0"
from chwrapper.services.base import Service
from chwrapper.services.search import Search
diff --git a/docs/conf.py b/docs/conf.py
index <HASH>..<HASH> 100644
--- a/docs/conf.py
+++ b/docs/conf.py
@@ -60,9 +60,9 @@ author = 'James Gardiner'
# built documents.
#
# The short X.Y version.
-version = '0.1'
+version = '0.2'
# The full version, including alpha/beta/rc tags.
-release = '0.1'
+release = '0.2.0'
# The language for content autogenerated by Sphinx. Refer to documentation
# for a list of supported languages.
diff --git a/setup.py b/setup.py
index <HASH>..<HASH> 100644
--- a/setup.py
+++ b/setup.py
@@ -6,7 +6,7 @@ def readme():
return f.read()
setup(name='chwrapper',
- version='0.1.1',
+ version='0.2.0',
description='A simple wrapper around the Companies House API',
long_description=readme(),
url='http://github.com/jamesgardiner/chwrapper', | Bumped version number to <I> | JamesGardiner_chwrapper | train | py,py,py |
0627cea06c9701f90629a33a1592b62581231f19 | diff --git a/core/src/main/java/hudson/model/Hudson.java b/core/src/main/java/hudson/model/Hudson.java
index <HASH>..<HASH> 100644
--- a/core/src/main/java/hudson/model/Hudson.java
+++ b/core/src/main/java/hudson/model/Hudson.java
@@ -3070,11 +3070,11 @@ public final class Hudson extends Node implements ItemGroup<TopLevelItem>, Stapl
* Checks if container uses UTF-8 to decode URLs. See
* http://hudson.gotdns.com/wiki/display/HUDSON/Tomcat#Tomcat-i18n
*/
- public FormValidation doCheckURIEncoding(StaplerRequest request, @QueryParameter String value) throws IOException {
+ public FormValidation doCheckURIEncoding(StaplerRequest request, StaplerResponse response) throws IOException {
request.setCharacterEncoding("UTF-8");
// expected is non-ASCII String
final String expected = "\u57f7\u4e8b";
- value = fixEmpty(value);
+ final String value = fixEmpty(request.getParameter("value"));
if (!expected.equals(value))
return FormValidation.warningWithMarkup(Messages.Hudson_NotUsesUTF8ToDecodeURL());
return FormValidation.ok(); | Don't use @QueryParameter with doCheckURIEncoding, as then stapler reads
the parameter before the request.setCharacterEncoding() call in this method
(which results in a warning in the webserver log with SJSWS7).
git-svn-id: <URL> | jenkinsci_jenkins | train | java |
edfade4bc285a13c47f2f389001fb231db6e2e9b | diff --git a/modules/casper.js b/modules/casper.js
index <HASH>..<HASH> 100644
--- a/modules/casper.js
+++ b/modules/casper.js
@@ -740,6 +740,12 @@ Casper.prototype.fill = function fill(selector, vals, submit) {
var method = (form.getAttribute('method') || "GET").toUpperCase();
var action = form.getAttribute('action') || "unknown";
__utils__.log('submitting form to ' + action + ', HTTP ' + method, 'info');
+ var event = document.createEvent('Event');
+ event.initEvent('submit', true, true);
+ if (!form.dispatchEvent(event)) {
+ __utils__.log('unable to submit form', 'warning');
+ return;
+ }
if (typeof form.submit === "function") {
form.submit();
} else { | better form submission in fill() by using events | casperjs_casperjs | train | js |
b91d59057031d71d9f51f017d2962b8ec5a90a93 | diff --git a/src/Dexie.js b/src/Dexie.js
index <HASH>..<HASH> 100644
--- a/src/Dexie.js
+++ b/src/Dexie.js
@@ -1463,8 +1463,8 @@ export default function Dexie(dbName, options) {
if (this._locked()) {
return new Promise((resolve, reject) => {
- self._blockedFuncs.push([() => {
- self._promise(mode, fn, bWriteLock).then(resolve, reject);
+ this._blockedFuncs.push([() => {
+ this._promise(mode, fn, bWriteLock).then(resolve, reject);
}, PSD]);
}); | Whoops, used self instead of this. | dfahlander_Dexie.js | train | js |
14f1da35a8a3e707024b59101d3f1373c49424ca | diff --git a/lib/ov.rb b/lib/ov.rb
index <HASH>..<HASH> 100644
--- a/lib/ov.rb
+++ b/lib/ov.rb
@@ -136,8 +136,19 @@ module Ov
end
end
+ #
+ # return all defined with +let+ methods.
+ #
+ def multimethods()
+ owner = need_owner()
+ owner.send(:__overload_methods).map do |method|
+ [method.name, method.types] if method.owner == owner
+ end.compact
+ end
+
+
private
- def need_owner
+ def need_owner #:nodoc:
if self.class == Module
self
elsif self.respond_to?(:ancestors) && self == ancestors.first | method for return all defined methods with signatures | fntz_ov | train | rb |
a3e86d8eca5e12a4975f9b1cbf571d1a7282d913 | diff --git a/src/context-parser.js b/src/context-parser.js
index <HASH>..<HASH> 100644
--- a/src/context-parser.js
+++ b/src/context-parser.js
@@ -398,7 +398,7 @@ function Parser (config, listeners) {
}
// run through the input stream with input pre-processing
- this.config.enableInputPreProcessing = (config.enableInputPreProcessing === undefined || config.enableInputPreProcessing)? true:false;
+ this.config.enableInputPreProcessing = (config.enableInputPreProcessing === undefined || config.enableInputPreProcessing === false)? false:true;
this.config.enableInputPreProcessing && this.on('preWalk', InputPreProcessing);
// fix parse errors before they're encountered in walk()
this.config.enableCanonicalization = (config.enableCanonicalization === undefined || config.enableCanonicalization === false)? false:true;
@@ -485,7 +485,7 @@ Parser.prototype.fork = function() {
*/
Parser.prototype.contextualize = function (input, endsWithEOF) {
this.setInitState(this.getInitState());
- if (this.config.enableCanonicalization) { // only Canonicalization will modify the input stream
+ if (this.config.enableInputPreProcessing || this.config.enableCanonicalization) {
input = input.split('');
FastParser.prototype.contextualize.call(this, input, endsWithEOF);
return input.join(''); | input pre processing and null replacement need the array split and join | yahoo_context-parser | train | js |
d71092864fd9693b2762b862212573ef2f0917cb | diff --git a/src/test/test_pipe.py b/src/test/test_pipe.py
index <HASH>..<HASH> 100644
--- a/src/test/test_pipe.py
+++ b/src/test/test_pipe.py
@@ -138,6 +138,28 @@ def test_pipe_reduce():
except TypeError as e:
assert e.message == 'A reducer must have input.'
+
+def test_pipe_chain():
+ import string
+ register_default_types()
+
+ @pipe.reduce
+ def count(accu, data):
+ return accu + 1
+
+ @pipe.filter
+ def low_pass(data, threshold):
+ return data <= threshold
+
+ count_low_pass = low_pass(10) | count(init=0)
+
+ ans = run(range(1,100) | count_low_pass)
+ assert ans == 10
+
+ ans = run(range(1,100) | count_low_pass(20))
+ assert ans == 20
+
+
def test_pipe_type_registration():
unregister_all_types() | Add testcase for command chaining. | GaryLee_cmdlet | train | py |
74f56a720ae4d6629aa303b6b1cdb9b8e5daa5d1 | diff --git a/html2asketch/nodeToSketchLayers.js b/html2asketch/nodeToSketchLayers.js
index <HASH>..<HASH> 100644
--- a/html2asketch/nodeToSketchLayers.js
+++ b/html2asketch/nodeToSketchLayers.js
@@ -104,7 +104,7 @@ export default async function nodeToSketchLayers(node) {
letterSpacing,
color,
textTransform,
- textDecorationStyle,
+ textDecorationLine,
textAlign,
justifyContent,
display,
@@ -231,7 +231,7 @@ export default async function nodeToSketchLayers(node) {
fontWeight: parseInt(fontWeight, 10),
color,
textTransform,
- textDecoration: textDecorationStyle,
+ textDecoration: textDecorationLine,
textAlign: display === 'flex' || display === 'inline-flex' ? justifyContent : textAlign
}); | Fix line-through text decoration (#<I>)
* :bug: Fix line-through compted style
* :bug: Use textDecorationLine
On Chrome, textDecoration contains the line, the color and the style
Sketch seems to only support the line attribute (line-through or
underline) | brainly_html-sketchapp | train | js |
ff9de3586a6bff5d2f716b4fbb175391ddd969fe | diff --git a/plugins/providers/docker/action.rb b/plugins/providers/docker/action.rb
index <HASH>..<HASH> 100644
--- a/plugins/providers/docker/action.rb
+++ b/plugins/providers/docker/action.rb
@@ -10,7 +10,12 @@ module VagrantPlugins
def self.action_run_command
Vagrant::Action::Builder.new.tap do |b|
b.use ConfigValidate
- b.use HostMachine
+
+ b.use Call, IsState, :host_state_unknown do |env, b2|
+ if env[:result]
+ raise "Invalid usage"
+ end
+ end
b.use Call, IsState, :not_created do |env, b2|
if env[:result] | providers/docker: run_command doesn't need to actual setup host machine | hashicorp_vagrant | train | rb |
0e29ebde2a6f600aa5ca33103f304f19f0ccf706 | diff --git a/tests/checker/test_http.py b/tests/checker/test_http.py
index <HASH>..<HASH> 100644
--- a/tests/checker/test_http.py
+++ b/tests/checker/test_http.py
@@ -174,8 +174,8 @@ class TestHttp (HttpServerTest):
self.direct(url, resultlines, recursionlevel=1)
def obfuscate_test (self):
- import os
- if os.name != "posix":
+ import os, sys
+ if os.name != "posix" and sys.platform != 'linux2':
return
host = "www.golem.de"
ip = iputil.resolve_host(host).pop() | Run obfuscated IP test only on linux. | wummel_linkchecker | train | py |
8818e790f960740e990451a98852341bd9c13d14 | diff --git a/apiserver/facades/client/application/application.go b/apiserver/facades/client/application/application.go
index <HASH>..<HASH> 100644
--- a/apiserver/facades/client/application/application.go
+++ b/apiserver/facades/client/application/application.go
@@ -286,6 +286,7 @@ func (api *APIBase) Deploy(args params.ApplicationsDeploy) (params.ErrorResults,
(arg.CharmOrigin.ID == "" && arg.CharmOrigin.Hash != "")) {
err := errors.BadRequestf("programming error, Deploy, neither CharmOrigin ID nor Hash can be set before a charm is downloaded. See CharmHubRepository GetDownloadURL.")
result.Results[i].Error = apiservererrors.ServerError(err)
+ continue
}
err := deployApplication(
api.backend, | do not continue if there is an error, jump to the next app | juju_juju | train | go |
7a588d0e2ade8d991fe069d3abb7737377d7a5c1 | diff --git a/imgaug/random.py b/imgaug/random.py
index <HASH>..<HASH> 100644
--- a/imgaug/random.py
+++ b/imgaug/random.py
@@ -8,10 +8,14 @@ import six.moves as sm
# Check if numpy is version 1.17 or later. In that version, the new random
# number interface was added.
+# Note that a valid version number can also be "1.18.0.dev0+285ab1d",
+# in which the last component cannot easily be converted to an int. Hence we
+# only pick the first two components.
IS_NEW_NP_RNG_STYLE = False
-np_version = list(map(int, np.__version__.split(".")))
+np_version = list(map(int, np.__version__.split(".")[0:2]))
if np_version[0] > 1 or np_version[1] >= 17:
IS_NEW_NP_RNG_STYLE = True
+IS_OLD_NP_RNG_STYLE = not IS_NEW_NP_RNG_STYLE
# We instantiate a current/global random state here once. | Fix sometimes failing NP <I> check | aleju_imgaug | train | py |
24ba31624a26a080a9d5dd492a4998002200448c | diff --git a/src/XR.js b/src/XR.js
index <HASH>..<HASH> 100644
--- a/src/XR.js
+++ b/src/XR.js
@@ -133,7 +133,7 @@ class XRSession extends EventTarget {
return Promise.resolve(this._frameOfReference);
}
getInputSources() {
- return this._inputSources;
+ return this._inputSources.filter(inputSource => inputSource._connected);
}
requestAnimationFrame(fn) {
if (this.device.onrequestanimationframe) { | Make XR getInputSources only return connected input sources | exokitxr_exokit | train | js |
67471e8f8bcf1eca24fbe17921296461c435cc7f | diff --git a/ajax-form.js b/ajax-form.js
index <HASH>..<HASH> 100644
--- a/ajax-form.js
+++ b/ajax-form.js
@@ -117,7 +117,11 @@
interceptSubmit.call(this);
+ this.submit = function(){
+ this.fire('submit');
+ };
+
listenForAjaxComplete.call(this);
}
};
-}());
\ No newline at end of file
+}()); | feat($ajax-form): #<I> - Ensure form `submit()` method is overridden. | rnicholus_ajax-form | train | js |
63614d2ab25da3eacbc6eb0c4e64b0ffec1fcc26 | diff --git a/lems/model/component.py b/lems/model/component.py
index <HASH>..<HASH> 100644
--- a/lems/model/component.py
+++ b/lems/model/component.py
@@ -425,7 +425,7 @@ class Children(LEMSBase):
Exports this object into a LEMS XML object
"""
- return '<{2} name="{0}" type="{1}"/>'.format(self.name, self.type, 'Children' if self.multiple else 'Child')
+ return '<{3} name="{0}" type="{1}" description="{2}"/>'.format(self.name, self.type, self.description, 'Children' if self.multiple else 'Child')
class Text(LEMSBase):
""" | feat: include description in Child and Children XML export | LEMS_pylems | train | py |
3ebe5c77a6d8c4f7dc4c26362253967301c3330c | diff --git a/master/buildbot/schedulers/forcesched.py b/master/buildbot/schedulers/forcesched.py
index <HASH>..<HASH> 100644
--- a/master/buildbot/schedulers/forcesched.py
+++ b/master/buildbot/schedulers/forcesched.py
@@ -323,13 +323,13 @@ class InheritBuildParameter(ChoiceStringParameter):
class WorkerChoiceParameter(ChoiceStringParameter):
- """A parameter that lets the buildslave name be explicitly chosen.
+ """A parameter that lets the worker name be explicitly chosen.
This parameter works in conjunction with 'buildbot.process.builder.enforceChosenWorker',
which should be added as the 'canStartBuild' parameter to the Builder.
The "anySentinel" parameter represents the sentinel value to specify that
- there is no buildslave preference.
+ there is no worker preference.
"""
anySentinel = '-any-'
label = 'Worker'
@@ -340,8 +340,8 @@ class WorkerChoiceParameter(ChoiceStringParameter):
ChoiceStringParameter.__init__(self, name, **kwargs)
def updateFromKwargs(self, kwargs, **unused):
- slavename = self.getFromKwargs(kwargs)
- if slavename == self.anySentinel:
+ workername = self.getFromKwargs(kwargs)
+ if workername == self.anySentinel:
# no preference, so dont set a parameter at all
return
ChoiceStringParameter.updateFromKwargs(self, kwargs=kwargs, **unused) | rename locally used "slave" in forcesched | buildbot_buildbot | train | py |
b95a6052cc4662417651d06b12919acce1c58a31 | diff --git a/server/src/main/java/org/jboss/as/server/Server.java b/server/src/main/java/org/jboss/as/server/Server.java
index <HASH>..<HASH> 100644
--- a/server/src/main/java/org/jboss/as/server/Server.java
+++ b/server/src/main/java/org/jboss/as/server/Server.java
@@ -82,7 +82,6 @@ public class Server {
private void launchProcessManagerSlave() {
this.processManagerSlave = ProcessManagerSlaveFactory.getInstance().getProcessManagerSlave(environment, messageHandler);
Thread t = new Thread(this.processManagerSlave.getController(), "Server Process");
- t.setDaemon(true);
t.start();
} | [JBAS-<I>] Fix a bunch of classpath problems
was: 3abd<I>cc2acbc<I>bb<I>c<I>f<I>e<I>bd<I>cf | wildfly_wildfly-core | train | java |
aea1c5265540db2a336e54a2325e0664b7cac291 | diff --git a/lib/firefox/webdriver/firefoxDelegate.js b/lib/firefox/webdriver/firefoxDelegate.js
index <HASH>..<HASH> 100644
--- a/lib/firefox/webdriver/firefoxDelegate.js
+++ b/lib/firefox/webdriver/firefoxDelegate.js
@@ -24,6 +24,13 @@ class FirefoxDelegate {
async onStartIteration() {}
async onStopIteration(runner, index) {
+ if (this.firefoxConfig.collectMozLog) {
+ await rename(
+ `${this.baseDir}/moz_log.txt`,
+ `${this.baseDir}/moz_log-${index}.txt`
+ );
+ }
+
if (this.skipHar) {
return;
}
@@ -76,13 +83,6 @@ class FirefoxDelegate {
} else {
log.info('You need Firefox 60 (or later) to get the HAR.');
}
-
- if (this.firefoxConfig.collectMozLog) {
- await rename(
- `${this.baseDir}/moz_log.txt`,
- `${this.baseDir}/moz_log-${index}.txt`
- );
- }
}
async onStopRun(result) { | first fix mozlog, then the HAR (when HAR is turned off) | sitespeedio_browsertime | train | js |
105db166853da7b36fecf796880b7ff44a83f510 | diff --git a/findbugs/src/java/edu/umd/cs/findbugs/detect/InefficientMemberAccess.java b/findbugs/src/java/edu/umd/cs/findbugs/detect/InefficientMemberAccess.java
index <HASH>..<HASH> 100644
--- a/findbugs/src/java/edu/umd/cs/findbugs/detect/InefficientMemberAccess.java
+++ b/findbugs/src/java/edu/umd/cs/findbugs/detect/InefficientMemberAccess.java
@@ -62,7 +62,7 @@ public class InefficientMemberAccess extends BytecodeScanningDetector implements
if (!methodName.startsWith(ACCESS_PREFIX))
return;
try {
- varSlot = Integer.valueOf(methodName.substring(ACCESS_PREFIX.length()));
+ varSlot = Integer.parseInt(methodName.substring(ACCESS_PREFIX.length()));
}
catch (NumberFormatException nfe) {
return; | don't autobox if you don't have to
git-svn-id: <URL> | spotbugs_spotbugs | train | java |
55c3288c09abeed2a5ba65837c7a8167fa9a1515 | diff --git a/lib/manager/resolve.js b/lib/manager/resolve.js
index <HASH>..<HASH> 100644
--- a/lib/manager/resolve.js
+++ b/lib/manager/resolve.js
@@ -66,7 +66,7 @@ async function resolvePackageFiles(config) {
);
}
if (packageFile.npmrc) {
- logger.info('Found .npmrc');
+ logger.info({ packageFile: packageFile.packageFile }, 'Found .npmrc');
if (
packageFile.npmrc.match(/\${NPM_TOKEN}/) &&
!config.global.exposeEnv
@@ -87,7 +87,7 @@ async function resolvePackageFiles(config) {
upath.join(path.dirname(packageFile.packageFile), '.yarnrc')
);
if (packageFile.yarnrc) {
- logger.info('Found .yarnrc');
+ logger.info({ packageFile: packageFile.packageFile }, 'Found .yarnrc');
} else {
delete packageFile.yarnrc;
} | chore: log filename for .npmrc and .yarnrc | renovatebot_renovate | train | js |
81ce718f12d35e16d0a196c374dd6780baeb54e1 | diff --git a/lib/json_reference.rb b/lib/json_reference.rb
index <HASH>..<HASH> 100644
--- a/lib/json_reference.rb
+++ b/lib/json_reference.rb
@@ -1,5 +1,5 @@
-require "json_pointer"
require "uri"
+require_relative "json_pointer"
module JsonReference
class Reference
@@ -14,6 +14,7 @@ module JsonReference
if uri && !uri.empty?
@uri = URI.parse(uri)
end
+ @pointer ||= ""
else
@pointer = ref
end | Fix small gotcha in JSON reference for when there is a URL but no pointer | brandur_json_schema | train | rb |
c4a11fed59c29c1fe80d4a88c437c5b8d7e7f55f | diff --git a/lib/classes/PluginManager.js b/lib/classes/PluginManager.js
index <HASH>..<HASH> 100644
--- a/lib/classes/PluginManager.js
+++ b/lib/classes/PluginManager.js
@@ -99,12 +99,11 @@ class PluginManager {
loadPlugins(plugins) {
plugins.forEach(plugin => {
+ const servicePath = this.serverless.config.servicePath;
+ const pluginPath = plugin.startsWith('./') ? path.join(servicePath, plugin) : plugin;
+ let Plugin;
try {
- const servicePath = this.serverless.config.servicePath;
- const pluginPath = plugin.startsWith('./') ? path.join(servicePath, plugin) : plugin;
- const Plugin = require(pluginPath); // eslint-disable-line global-require
-
- this.addPlugin(Plugin);
+ Plugin = require(pluginPath); // eslint-disable-line global-require
} catch (error) {
if (this.cliCommands[0] === 'plugin') {
return;
@@ -124,6 +123,7 @@ class PluginManager {
}
throw error;
}
+ this.addPlugin(Plugin);
});
} | Cover only plugin load with error handler | serverless_serverless | train | js |
5f66726c54da2152c9d2b3d2f3264e9020e20651 | diff --git a/lib/environment.js b/lib/environment.js
index <HASH>..<HASH> 100644
--- a/lib/environment.js
+++ b/lib/environment.js
@@ -357,7 +357,7 @@ Environment.prototype.namespace = function namespace(filepath) {
}
// cleanup extension and normalize path for differents OS
- var ns = path.normalize(filepath.replace(new RegExp(path.extname(filepath) + '$'), ''));
+ var ns = path.normalize(filepath.replace(new RegExp(escapeStrRe(path.extname(filepath)) + '$'), ''));
// Sort lookups by length so biggest are removed first
var lookups = _(this.lookups).map(path.normalize).sortBy('length').value().reverse(); | Make namespace resolution safer
* Instead of blindly turning a file extension into a RegExp, we now
escape the input using `escape-string-regexp`. Since it was already
in use, it was a non-issue.
* This is a follow up to #<I>. #<I> fixed the immediate problem but left
yeoman-environment in the same state it was before. This should make
namespace resolution safer. | yeoman_environment | train | js |
7dbcda5485f4481430c1e0b7673f6221cf567222 | diff --git a/tests/test_mesh.py b/tests/test_mesh.py
index <HASH>..<HASH> 100644
--- a/tests/test_mesh.py
+++ b/tests/test_mesh.py
@@ -76,7 +76,7 @@ class MeshTests(g.unittest.TestCase):
self.assertTrue(hasattr(r, 'intersection'))
# some memory issues only show up when you copy the mesh a bunch
- for i in range(300):
+ for i in range(100):
c = mesh.copy()
def test_fill_holes(self): | reduced number of copies for travis | mikedh_trimesh | train | py |
56a7f1ab3c8240d14c710cbffca401757c405c8f | diff --git a/plugins/candela/girder_candela/__init__.py b/plugins/candela/girder_candela/__init__.py
index <HASH>..<HASH> 100644
--- a/plugins/candela/girder_candela/__init__.py
+++ b/plugins/candela/girder_candela/__init__.py
@@ -19,7 +19,7 @@ from girder.plugin import getPlugin, GirderPlugin
class CandelaPlugin(GirderPlugin):
DISPLAY_NAME = 'Candela Visualization'
- NPM_PACKAGE_NAME = '@girder/candela'
+ CLIENT_SOURCE_PATH = 'web_client'
def load(self, info):
getPlugin('item_tasks').load(info) | Automatically inspect npm package names for plugins
This change removes the NPM_PACKAGE_NAME property on the GirderPlugin
class. Instead, plugin developers must explicitly set the path to the
web client package and the npm package name will be inferred. Advanced
usage (such as fetching the package from npm) is still supported by
overriding the `npmPackages` method. | Kitware_candela | train | py |
83dc3966e759a9e858a77b75d8487287e77729d9 | diff --git a/audio/internal/go2cpp/player_js.go b/audio/internal/go2cpp/player_js.go
index <HASH>..<HASH> 100644
--- a/audio/internal/go2cpp/player_js.go
+++ b/audio/internal/go2cpp/player_js.go
@@ -121,10 +121,10 @@ func (p *Player) Play() {
var runloop bool
if !p.v.Truthy() {
p.v = p.context.v.Call("createPlayer", p.onWritten)
- p.v.Set("volume", p.volume)
runloop = true
}
+ p.v.Set("volume", p.volume)
p.v.Call("play")
// Prepare the first data as soon as possible, or the audio can get stuck.
@@ -192,11 +192,11 @@ func (p *Player) SetVolume(volume float64) {
p.cond.L.Lock()
defer p.cond.L.Unlock()
+ p.volume = volume
if !p.v.Truthy() {
return
}
p.v.Set("volume", volume)
- p.volume = volume
}
func (p *Player) UnplayedBufferSize() int64 { | audio/internal/go2cpp: Bug fix: Set the volume whenever the player state is | hajimehoshi_ebiten | train | go |
dcdfb263a30c012ed2be081a56418b612aa584dd | diff --git a/src/WorkerPool.js b/src/WorkerPool.js
index <HASH>..<HASH> 100644
--- a/src/WorkerPool.js
+++ b/src/WorkerPool.js
@@ -68,7 +68,6 @@ class WorkerPool {
info.runningWorkers++
this.fcn(worker, ...taskArgs).then(({ webWorker, ...result }) => {
- info.postponed = false
this.workerQueue.push(webWorker)
info.runningWorkers--
info.results[resultIndex] = result
@@ -100,7 +99,10 @@ class WorkerPool {
} else {
// Try again later.
info.postponed = true
- setTimeout(() => this.addTask(info.index, resultIndex, taskArgs), 50)
+ setTimeout(() => {
+ info.postponed = false
+ this.addTask(info.index, resultIndex, taskArgs)
+ }, 50)
}
}
} | fix(WorkerPool): info.postponed at timeout completion
This is a correct / robust follow-up to
<I>b<I>f0c<I>a<I>d<I>a<I>d4c<I>a<I>e<I> | InsightSoftwareConsortium_itk-js | train | js |
e0d51c9f31151ec3f5f0a891363a7d2c548862f7 | diff --git a/networking_arista/ml2/arista_ml2.py b/networking_arista/ml2/arista_ml2.py
index <HASH>..<HASH> 100644
--- a/networking_arista/ml2/arista_ml2.py
+++ b/networking_arista/ml2/arista_ml2.py
@@ -629,9 +629,9 @@ class AristaRPCWrapperJSON(AristaRPCWrapperBase):
data = {
'name': 'keystone',
'authUrl': self._keystone_url(),
- 'user': self.keystone_conf.admin_user,
- 'password': self.keystone_conf.admin_password,
- 'tenant': self.keystone_conf.admin_tenant_name
+ 'user': self.keystone_conf.admin_user or "",
+ 'password': self.keystone_conf.admin_password or "",
+ 'tenant': self.keystone_conf.admin_tenant_name or ""
}
self._send_api_request(path, 'POST', [data]) | Allow empty fields for Keystone.
Currently if there are empty identity auth fields for Keystone we send None and the API returns an error as these fields are required. Now we convert None to the empty string, "".
Change-Id: I6d<I>d4c<I>c<I>fe<I>d2ab<I>ea9c<I>ef<I>
Closes-Bug: #<I> | openstack_networking-arista | train | py |
59154d4745c872a1e50f0519b47e332cf11c6f03 | diff --git a/pylint/checkers/spelling.py b/pylint/checkers/spelling.py
index <HASH>..<HASH> 100644
--- a/pylint/checkers/spelling.py
+++ b/pylint/checkers/spelling.py
@@ -53,9 +53,6 @@ except ImportError:
class WikiWordFilter: # type: ignore
...
- def get_tokenizer(_):
- ...
-
class Filter: # type: ignore
def _skip(self, word):
raise NotImplementedError
@@ -63,6 +60,11 @@ except ImportError:
class Chunker: # type: ignore
pass
+ def get_tokenizer(
+ tag=None, chunkers=None, filters=None
+ ): # pylint: disable=unused-argument
+ return Filter()
+
if enchant is not None:
br = enchant.Broker()
@@ -74,7 +76,7 @@ if enchant is not None:
else:
dicts = "none"
dict_choices = [""]
- instr = " To make it work, install the python-enchant package."
+ instr = " To make it work, install the 'python-enchant' package."
class WordsWithDigigtsFilter(Filter): | Fix kwargs is not a supported in function get_tokenizer | PyCQA_pylint | train | py |
66622332766a9f0192ab82fb29d32355673f68d7 | diff --git a/src/Seld/JsonLint/JsonParser.php b/src/Seld/JsonLint/JsonParser.php
index <HASH>..<HASH> 100644
--- a/src/Seld/JsonLint/JsonParser.php
+++ b/src/Seld/JsonLint/JsonParser.php
@@ -134,6 +134,8 @@ class JsonParser
*/
public function parse($input, $flags = 0)
{
+ $this->failOnBOM($input);
+
$this->flags = $flags;
$this->stack = array(0);
@@ -449,4 +451,13 @@ class JsonParser
return $token;
}
+
+ private function failOnBOM($input)
+ {
+ // UTF-8 ByteOrderMark sequence
+ $bom = pack("CCC", 0xef, 0xbb, 0xbf);
+ if (substr($input, 0, 3) == $bom) {
+ $this->parseError("BOM detected. Make sure your input doesn't include a Byte-Order-Mark!");
+ }
+ }
} | added BOM detection and subsequent parseError. | Seldaek_jsonlint | train | php |
e9a7b01df14b8f21bcf9cc0665a6d4c62a91431f | diff --git a/sources/scalac/Global.java b/sources/scalac/Global.java
index <HASH>..<HASH> 100644
--- a/sources/scalac/Global.java
+++ b/sources/scalac/Global.java
@@ -297,7 +297,7 @@ public class Global {
// go to next phase to print symbols with their new type
boolean next = currentPhase.next != null;
if (next) currentPhase = currentPhase.next;
- currentPhase.print(this);
+ (next ? currentPhase.prev : currentPhase).print(this);
if (next) currentPhase = currentPhase.prev;
}
if (currentPhase.descriptor.hasGraphFlag())
@@ -333,7 +333,7 @@ public class Global {
// go to next phase to print symbols with their new type
boolean next = currentPhase.next != null;
if (next) currentPhase = currentPhase.next;
- currentPhase.print(this);
+ (next ? currentPhase.prev : currentPhase).print(this);
if (next) currentPhase = currentPhase.prev;
}
if (currentPhase.descriptor.hasGraphFlag()) | - Add fix to use right phase to print tree | scala_scala | train | java |
064a145097790d07bf32e94a36931694b65dfb26 | diff --git a/tools/pyboard.py b/tools/pyboard.py
index <HASH>..<HASH> 100755
--- a/tools/pyboard.py
+++ b/tools/pyboard.py
@@ -673,10 +673,17 @@ def main():
action="store_false",
dest="follow",
)
- cmd_parser.add_argument(
- "--no-exclusive",
+ group = cmd_parser.add_mutually_exclusive_group()
+ group.add_argument(
+ "--exclusive",
action="store_true",
- help="Do not try to open the serial device for exclusive access.",
+ default=True,
+ help="Open the serial device for exclusive access [default]",
+ )
+ group.add_argument(
+ "--no-exclusive",
+ action="store_false",
+ dest="exclusive",
)
cmd_parser.add_argument(
"-f",
@@ -691,7 +698,7 @@ def main():
# open the connection to the pyboard
try:
pyb = Pyboard(
- args.device, args.baudrate, args.user, args.password, args.wait, not args.no_exclusive
+ args.device, args.baudrate, args.user, args.password, args.wait, args.exclusive
)
except PyboardError as er:
print(er) | tools/pyboard.py: Add --exclusive to match --no-exclusive. | micropython_micropython | train | py |
d0463571575067b9d29d9cce3756a18171837115 | diff --git a/webroot/js/mobile.js b/webroot/js/mobile.js
index <HASH>..<HASH> 100644
--- a/webroot/js/mobile.js
+++ b/webroot/js/mobile.js
@@ -275,12 +275,14 @@ foodcoopshop.Mobile = {
// button renamings
var regexp = new RegExp(foodcoopshop.LocalizedJs.mobile.showAllProducts);
- $('.manufacturer-wrapper div.third-column a.btn').each(function (btn) {
+ $('.manufacturer-wrapper div.third-column a.btn').each(function () {
$(this).html($(this).html().replace(regexp, foodcoopshop.LocalizedJs.mobile.show));
});
$('.blog-post-wrapper div.third-column a.btn').html(foodcoopshop.LocalizedJs.mobile.show);
$('.entity-wrapper .btn').each(function() {
- $(this).html($(this).find('i').after($(this).text()));
+ if (!$(this).find('i').hasClass('fa-times')) { // delivery break?
+ $(this).html($(this).find('i').after($(this).text()));
+ }
});
$('#cart .btn-success').html('<i class="fas fa-shopping-cart"></i>'); | mobile: show "lieferpause" in button to be clearer | foodcoopshop_foodcoopshop | train | js |
f9c2bf1c74424ea71885bf37c49a6f638ce5bb82 | diff --git a/jsp/src/main/java/org/ops4j/pax/web/jsp/JSPServlet.java b/jsp/src/main/java/org/ops4j/pax/web/jsp/JSPServlet.java
index <HASH>..<HASH> 100644
--- a/jsp/src/main/java/org/ops4j/pax/web/jsp/JSPServlet.java
+++ b/jsp/src/main/java/org/ops4j/pax/web/jsp/JSPServlet.java
@@ -16,16 +16,16 @@
*/
package org.ops4j.pax.web.jsp;
-import javax.servlet.http.HttpServlet;
+import org.apache.jasper.servlet.JspServlet;
/**
- * TODO
+ * TODO
*
* @author Alin Dreghiciu
* @since 0.3.0, January 07, 2008
*/
public class JSPServlet
- extends HttpServlet
+ extends JspServlet
{
} | Temporary, use directly jasper servlet. For testing purpose. | ops4j_org.ops4j.pax.web | train | java |
690386653f738104a933d83576c549755cbb4519 | diff --git a/ezp/Persistence/Storage/Legacy/Tests/Content/Type/Gateway/EzcDatabaseTest.php b/ezp/Persistence/Storage/Legacy/Tests/Content/Type/Gateway/EzcDatabaseTest.php
index <HASH>..<HASH> 100644
--- a/ezp/Persistence/Storage/Legacy/Tests/Content/Type/Gateway/EzcDatabaseTest.php
+++ b/ezp/Persistence/Storage/Legacy/Tests/Content/Type/Gateway/EzcDatabaseTest.php
@@ -193,8 +193,6 @@ class EzcDatabaseTest extends TestCase
* @return void
* @covers ezp\Persistence\Storage\Legacy\Content\Type\Gateway\EzcDatabase::loadTypeData
* @covers ezp\Persistence\Storage\Legacy\Content\Type\Gateway\EzcDatabase::selectColumns
- * @covers ezp\Persistence\Storage\Legacy\Content\Type\Gateway\EzcDatabase::createTableColumnAlias
- * @covers ezp\Persistence\Storage\Legacy\Content\Type\Gateway\EzcDatabase::qualifiedIdentifier
*/
public function testLoadTypeData()
{ | Fixed: @covers left from removed function | ezsystems_ezpublish-kernel | train | php |
cf837c62f8f7e37ad677074b1eca9a1e6ceacdba | diff --git a/src/wormling/phparia/Node/Node.php b/src/wormling/phparia/Node/Node.php
index <HASH>..<HASH> 100644
--- a/src/wormling/phparia/Node/Node.php
+++ b/src/wormling/phparia/Node/Node.php
@@ -743,7 +743,11 @@ class Node
*/
public function saySound($soundName)
{
- $this->prompts->add("sound:$soundName");
+ if (count(preg_split('/:/', $soundName)) > 1) {
+ $this->prompts->add("$soundName");
+ } else {
+ $this->prompts->add("sound:$soundName");
+ }
return $this;
} | Allow ARI sound urls in saySound (defaulting to sound:)
* Fix to playback recording properly from a node | wormling_phparia | train | php |
b7acec6da901c0a208dd7ff2e3bcb1d1a7c3c363 | diff --git a/setup.py b/setup.py
index <HASH>..<HASH> 100755
--- a/setup.py
+++ b/setup.py
@@ -17,7 +17,7 @@ setup(
scripts=[],
data_files=[],
url='https://github.com/philippelt/netatmo-api-python',
- download_url='https://github.com/philippelt/netatmo-api-python/tarball/1.3.3',
+ download_url='https://github.com/philippelt/netatmo-api-python/tarball/v1.3.3.tar.gz',
license='GPL V3',
description='Simple API to access Netatmo weather station data from any python script.'
) | Typo in downloadurl for pip | philippelt_netatmo-api-python | train | py |
8696c17cc00011653a7cf959e69140dc1f2d3f69 | diff --git a/lib/roo/excelx.rb b/lib/roo/excelx.rb
index <HASH>..<HASH> 100644
--- a/lib/roo/excelx.rb
+++ b/lib/roo/excelx.rb
@@ -184,14 +184,14 @@ module Roo
# Note: this is only available within the Excelx class
def excelx_type(row, col, sheet = nil)
key = normalize(row, col)
- safe_send(sheet_for(sheet).cells[key], :excelx_type)
+ safe_send(sheet_for(sheet).cells[key], :cell_type)
end
# returns the internal value of an excelx cell
# Note: this is only available within the Excelx class
def excelx_value(row, col, sheet = nil)
key = normalize(row, col)
- safe_send(sheet_for(sheet).cells[key], :excelx_value)
+ safe_send(sheet_for(sheet).cells[key], :cell_value)
end
# returns the internal format of an excel cell | Remove some deprecation warnings | roo-rb_roo | train | rb |
a205556f00e7b785676caa2341cb269e7ca3f81f | diff --git a/src/models/Subscription/ActualUserSubscription.php b/src/models/Subscription/ActualUserSubscription.php
index <HASH>..<HASH> 100644
--- a/src/models/Subscription/ActualUserSubscription.php
+++ b/src/models/Subscription/ActualUserSubscription.php
@@ -39,6 +39,7 @@ class ActualUserSubscription
$this->actualSubscription = $this->subscriptionsRepository->actualUserSubscription($this->user->getId());
if (!$this->actualSubscription) {
+ $this->nextSubscription = false;
return;
} | set next subscription to false if user doesnt have actual subscription
remp/crm#<I> | remp2020_crm-subscriptions-module | train | php |
c61a7310fc54db5aab8323fcb890446cb51ed879 | diff --git a/remote_api/remote_api.go b/remote_api/remote_api.go
index <HASH>..<HASH> 100644
--- a/remote_api/remote_api.go
+++ b/remote_api/remote_api.go
@@ -132,8 +132,14 @@ func (rm *rawMessage) Unmarshal(buf []byte) error {
}
func requestSupported(service, method string) bool {
- // Only allow datastore_v3 for now, or AllocateIds for datastore_v4.
- return service == "datastore_v3" || (service == "datastore_v4" && method == "AllocateIds")
+ // This list of supported services is taken from SERVICE_PB_MAP in remote_api_services.py
+ switch service {
+ case "app_identity_service", "blobstore", "capability_service", "channel", "datastore_v3",
+ "datastore_v4", "file", "images", "logservice", "mail", "matcher", "memcache", "remote_datastore",
+ "remote_socket", "search", "modules", "system", "taskqueue", "urlfetch", "user", "xmpp":
+ return true
+ }
+ return false
}
// Methods to satisfy proto.Message. | Open up remote_api to forward requests for more services.
This aligns the set of supported services for the Go runtime with
those supported by the python runtime.
Change-Id: I9f<I>e<I>aefb<I>e<I>d<I>c8d6b<I>da3b<I> | golang_appengine | train | go |
ca9f28c37cda6f62a9e82e44397b5515672aa387 | diff --git a/lib/container.js b/lib/container.js
index <HASH>..<HASH> 100644
--- a/lib/container.js
+++ b/lib/container.js
@@ -1,5 +1,7 @@
// Load modules.
-var path = require('canonical-path')
+var EventEmitter = require('events')
+ , util = require('util')
+ , path = require('canonical-path')
, FactorySpec = require('./patterns/factory')
, ConstructorSpec = require('./patterns/constructor')
, LiteralSpec = require('./patterns/literal')
@@ -27,6 +29,7 @@ var path = require('canonical-path')
* @api public
*/
function Container() {
+ EventEmitter.call(this);
this._spec = {};
this._sources = {};
this._order = [];
@@ -36,6 +39,8 @@ function Container() {
this.resolver(require('./resolvers/id')());
}
+util.inherits(Container, EventEmitter);
+
/**
* Create an object.
*
@@ -90,7 +95,9 @@ Container.prototype.create = function(id, parent) {
throw new Error("Unable to create component '" + id + "'");
}
- return comp.create(this);
+ var obj = comp.create(this);
+ this.emit('create', obj, comp);
+ return obj;
}
Container.prototype.specs = function() { | Emit create events for lifecycle hooks. | jaredhanson_electrolyte | train | js |
52a8e672bfbcc0a6c2548387ed21963ba6874572 | diff --git a/index.js b/index.js
index <HASH>..<HASH> 100755
--- a/index.js
+++ b/index.js
@@ -6,7 +6,6 @@ var StreamToBuffer = require("stream-to-buffer");
var FileType = require("file-type");
var EXIFParser = require("exif-parser");
var URLRegEx = require("url-regex");
-var Request = require('request').defaults({ encoding: null });
// polyfill Promise for Node < 0.12
var Promise = Promise || require('es6-promise').Promise;
@@ -354,21 +353,6 @@ Jimp.limit255 = function(n) {
return n;
}
-
-/**
- * Calculates the hammering distance of two images based on their perceptual hash
- * @param img1 a Jimp image to compare
- * @param img2 a Jimp image to compare
- * @returns a number ranging from 0 to 1, 0 means they are believed to be identical
- */
-Jimp.distance = function (img1, img2) {
- var phash = new ImagePHash();
- var hash1 = phash.getHash(img1);
- var hash2 = phash.getHash(img2);
- return phash.distance(hash1, hash2);
-}
-
-
// An object representing a bitmap in memory, comprising:
// - data: a buffer of the bitmap data
// - width: the width of the image in pixels | Remove Requests dependency and image diffing from index.js. This removes Crypto, which drastically reduces the size of the output javascript and allows the result to work in a web worker, even in Firefox where a bug prevents use of cryptographic functions in web workers. | oliver-moran_jimp | train | js |
c6458016972d4026e2f9ce913067262a9df3636e | diff --git a/qiskit/tools/jupyter/library.py b/qiskit/tools/jupyter/library.py
index <HASH>..<HASH> 100644
--- a/qiskit/tools/jupyter/library.py
+++ b/qiskit/tools/jupyter/library.py
@@ -54,18 +54,17 @@ th {
text-align: left;
padding: 5px 5px 5px 5px;
width: 100%;
- background-color: #3700BE;
+ background-color: #988AFC;
color: #fff;
- font-size: 16px;
- border-left: 2px solid #3700BE;
+ font-size: 14px;
+ border-left: 2px solid #988AFC;
}
td {
- font-family: "IBM Plex Mono", monospace;
text-align: left;
padding: 5px 5px 5px 5px;
width: 100%;
- font-size: 13px;
+ font-size: 12px;
font-weight: medium;
} | Fix styling that conflicted with docs (#<I>) | Qiskit_qiskit-terra | train | py |
2f4f2c56ab158a3ab07c1988aeda5948f6ec6310 | diff --git a/server/commands/client/clientHelpers.js b/server/commands/client/clientHelpers.js
index <HASH>..<HASH> 100644
--- a/server/commands/client/clientHelpers.js
+++ b/server/commands/client/clientHelpers.js
@@ -1,7 +1,7 @@
import R from 'ramda'
export const formatClient = (client) => {
- return `- {green-fg}[${client.ip}]{/} ${client.name} <${client.version}>`
+ return `- {green-fg}[${client.ip}]{/} ${client.name} <${client.userAgent}> <${client.version}>`
}
export const updateClients = (context) => {
diff --git a/server/index.js b/server/index.js
index <HASH>..<HASH> 100644
--- a/server/index.js
+++ b/server/index.js
@@ -32,7 +32,7 @@ io.on('connection', (socket) => {
const socketInfo = {
socket: socket,
ip: socket.request.connection.remoteAddress == '::1' ? 'localhost' : socket.request.connection.remoteAddress,
- userAgent: socket.request.headers['user-agent']
+ userAgent: socket.request.headers['user-agent'] || 'Unknown'
}
const clientInfo = { | Display client.userAgent and fallbacks to 'Unknown' | infinitered_reactotron | train | js,js |
4069fb2fc8c22811ebf1aaf81c664f83c306c42a | diff --git a/library/src/com/sothree/slidinguppanel/ViewDragHelper.java b/library/src/com/sothree/slidinguppanel/ViewDragHelper.java
index <HASH>..<HASH> 100644
--- a/library/src/com/sothree/slidinguppanel/ViewDragHelper.java
+++ b/library/src/com/sothree/slidinguppanel/ViewDragHelper.java
@@ -1006,6 +1006,9 @@ public class ViewDragHelper {
final int pointerCount = MotionEventCompat.getPointerCount(ev);
for (int i = 0; i < pointerCount && mInitialMotionX != null && mInitialMotionY != null; i++) {
final int pointerId = MotionEventCompat.getPointerId(ev, i);
+ if (pointerId >= mInitialMotionX.length || pointerId >= mInitialMotionY.length) {
+ continue;
+ }
final float x = MotionEventCompat.getX(ev, i);
final float y = MotionEventCompat.getY(ev, i);
final float dx = x - mInitialMotionX[pointerId]; | Fixed a array out of bounds in ViewDragHelper | umano_AndroidSlidingUpPanel | train | java |
5ba1f9a7abde1e98b67782014aa6d5606de096d6 | diff --git a/contao/html/js/vanillaGeneral.js b/contao/html/js/vanillaGeneral.js
index <HASH>..<HASH> 100644
--- a/contao/html/js/vanillaGeneral.js
+++ b/contao/html/js/vanillaGeneral.js
@@ -159,7 +159,7 @@ function GeneralTableDnD()
req += '&after=' + insertAfter
req += '&isAjax=1'
- var href = GeneralEnvironment.getDom().getContaoBase();
+ // var href = GeneralEnvironment.getDom().getContaoBase();
GeneralEnvironment.getAjax().sendGet(href + req, false, null);
} | Do NOT use the contao base URL for ajax requests. | contao-community-alliance_dc-general | train | js |
45c3f20c1644301b5db3698d5f3a07823ed0a43f | diff --git a/ext_emconf.php b/ext_emconf.php
index <HASH>..<HASH> 100644
--- a/ext_emconf.php
+++ b/ext_emconf.php
@@ -5,7 +5,7 @@ $EM_CONF[$_EXTKEY] = [
'author' => 'Maik Kempe',
'author_email' => 'mkempe@bitaculous.com',
'author_company' => 'Bitaculous - It\'s all about the bits, baby!',
- 'category' => 'be',
+ 'category' => 'fe',
'state' => 'stable',
'version' => '1.1.0',
'createDirs' => '', | [➠] Updated extension category. | t3v_t3v_navigations | train | php |
e6baf9f92d976a9ce67efe1ceb27cde973dbd726 | diff --git a/src/CameraKitCameraScreen.js b/src/CameraKitCameraScreen.js
index <HASH>..<HASH> 100644
--- a/src/CameraKitCameraScreen.js
+++ b/src/CameraKitCameraScreen.js
@@ -247,6 +247,10 @@ export default class CameraScreen extends Component {
this.setState({ captured: true, imageCaptured: image, captureImages: _.concat(this.state.captureImages, image) });
}
+ if (this.props.onBottomButtonPressed) {
+ this.props.onBottomButtonPressed({ type: 'capture', image })
+ }
+
}
onRatioButtonPressed() { | add event when capture button pressed after image captured | wix_react-native-camera-kit | train | js |
c707bdc6db2e179d0eaaa0b8c1645f4944461398 | diff --git a/packages/rsvp/lib/main.js b/packages/rsvp/lib/main.js
index <HASH>..<HASH> 100644
--- a/packages/rsvp/lib/main.js
+++ b/packages/rsvp/lib/main.js
@@ -1598,7 +1598,7 @@ define("rsvp/promise/all",
```
@method all
- @for RSVP.Promise
+ @for Ember.RSVP.Promise
@param {Array} entries array of promises
@param {String} label optional string for labeling the promise.
Useful for tooling. | [DOC release] Show RSVP.Promise preamble. | emberjs_ember.js | train | js |
0cffcd1eca2e439e0ae8abd40be9b64497ede814 | diff --git a/lib/Cake/Utility/Folder.php b/lib/Cake/Utility/Folder.php
index <HASH>..<HASH> 100644
--- a/lib/Cake/Utility/Folder.php
+++ b/lib/Cake/Utility/Folder.php
@@ -328,7 +328,7 @@ class Folder {
public static function addPathElement($path, $element) {
$element = (array)$element;
array_unshift($element, rtrim($path, DS));
- return implode(DS, $element)
+ return implode(DS, $element);
}
/** | Added missing semi-colon in return | cakephp_cakephp | train | php |
7d8e9469cedd47f557292d51473e7e07f0d554c7 | diff --git a/rapidoid-buffer/src/main/java/org/rapidoid/data/Ranges.java b/rapidoid-buffer/src/main/java/org/rapidoid/data/Ranges.java
index <HASH>..<HASH> 100644
--- a/rapidoid-buffer/src/main/java/org/rapidoid/data/Ranges.java
+++ b/rapidoid-buffer/src/main/java/org/rapidoid/data/Ranges.java
@@ -20,6 +20,8 @@ package org.rapidoid.data;
* #L%
*/
+import java.util.Map;
+
import org.rapidoid.annotation.Authors;
import org.rapidoid.annotation.Since;
import org.rapidoid.buffer.Buf;
@@ -108,4 +110,16 @@ public class Ranges {
return count == 0;
}
+ public Map<String, String> toMap(Bytes bytes, int from, int to, String separator) {
+ Map<String, String> map = U.map();
+
+ for (int i = from; i <= to; i++) {
+ String s = ranges[i].str(bytes);
+ String[] kv = s.split(separator, 2);
+ map.put(kv[0], kv.length > 1 ? kv[1] : "");
+ }
+
+ return map;
+ }
+
} | Implemented ranges-to-map coverter. | rapidoid_rapidoid | train | java |
caded7d354d262a9a9eda7a946c1a476fd9fd3df | diff --git a/lib/search_object.rb b/lib/search_object.rb
index <HASH>..<HASH> 100644
--- a/lib/search_object.rb
+++ b/lib/search_object.rb
@@ -3,4 +3,7 @@ require "search_object/helper"
require "search_object/search"
module SearchObject
+ def self.module
+ Search
+ end
end
diff --git a/spec/search_object/search_spec.rb b/spec/search_object/search_spec.rb
index <HASH>..<HASH> 100644
--- a/spec/search_object/search_spec.rb
+++ b/spec/search_object/search_spec.rb
@@ -4,7 +4,7 @@ module SearchObject
describe Search do
def new_search(default_scope = [], filters = {}, &block)
search_class = Class.new do
- include Search
+ include SearchObject.module
scope { default_scope } | Hide SearchObject::Search behind a caller name
Also this will be helpful in the future when plugin and their options will be passed to the SearchObject.module | RStankov_SearchObject | train | rb,rb |
71cf7f6a2bfbd8750417a751bd652c144772945d | diff --git a/lib/formatters.js b/lib/formatters.js
index <HASH>..<HASH> 100644
--- a/lib/formatters.js
+++ b/lib/formatters.js
@@ -88,12 +88,11 @@ function formatDevTrace(level, context, message, args, err) {
str = colors.red.bold(level);
break;
}
- str += ' ';
+ str += ' ' + mainMessage;
if (isErrorLoggingWithoutMessage) {
- str += colorize(colors.gray, serializeErr(err).toString(printStack));
+ str += colorize(colors.gray, serializeErr(err).toString(printStack).substr(mainMessage.length));
} else {
- str += mainMessage;
if (err) {
str += '\n' + colorize(colors.gray, serializeErr(err).toString(printStack));
} | [[FIX]] Highlight first error line in dev format | telefonicaid_logops | train | js |
08477a22d754751655f4108ae2cffb0a73031ac4 | diff --git a/source/rafcon/gui/views/logging_console.py b/source/rafcon/gui/views/logging_console.py
index <HASH>..<HASH> 100644
--- a/source/rafcon/gui/views/logging_console.py
+++ b/source/rafcon/gui/views/logging_console.py
@@ -38,7 +38,10 @@ class LoggingConsoleView(View):
self.text_view.set_buffer(self.filtered_buffer)
- self.text_view.set_border_width(10)
+ self.text_view.set_border_window_size(Gtk.TextWindowType.LEFT, 10)
+ self.text_view.set_border_window_size(Gtk.TextWindowType.RIGHT, 10)
+ self.text_view.set_border_window_size(Gtk.TextWindowType.TOP, 10)
+ self.text_view.set_border_window_size(Gtk.TextWindowType.BOTTOM, 10)
self._enables = {}
self._auto_scroll_handler_id = None | fix(logging_console): Fix #<I> by changing border width settings
Use set_border_window_size instead of set_border_width to set the
padding for TextView. | DLR-RM_RAFCON | train | py |
b59e22a260e5224bd42ea4c730b5c4cc93ec978c | diff --git a/hazelcast-jet-core/src/test/java/com/hazelcast/jet/impl/metrics/ReadMetricsTest.java b/hazelcast-jet-core/src/test/java/com/hazelcast/jet/impl/metrics/ReadMetricsTest.java
index <HASH>..<HASH> 100644
--- a/hazelcast-jet-core/src/test/java/com/hazelcast/jet/impl/metrics/ReadMetricsTest.java
+++ b/hazelcast-jet-core/src/test/java/com/hazelcast/jet/impl/metrics/ReadMetricsTest.java
@@ -54,7 +54,7 @@ public class ReadMetricsTest extends JetTestSupport {
assertFalse(result.collections().isEmpty());
assertTrue(
StreamSupport.stream(result.collections().get(0).spliterator(), false)
- .anyMatch(m -> m.key().equals("[metric=os.processCpuLoad]"))
+ .anyMatch(m -> m.key().equals("[metric=cluster.size]"))
);
// immediate next call should not return empty result | Use a different metric as os.processCpuLoad is missing in JDK 9 | hazelcast_hazelcast | train | java |
cdcffeb1a21e54840a0dcc793a3b21087ed587eb | diff --git a/admin.php b/admin.php
index <HASH>..<HASH> 100644
--- a/admin.php
+++ b/admin.php
@@ -1277,6 +1277,10 @@ function old_paths() {
WT_ROOT.'themes/minimal/images/fscreen.png',
WT_ROOT.'themes/webtrees/images/fscreen.png',
WT_ROOT.'themes/xenea/images/fscreen.png',
+ // Removed in 1.2.7
+ WT_ROOT.'login_register.php',
+ WT_ROOT.'modules_v3/top10_givnnames/help_text.php',
+ WT_ROOT.'modules_v3/top10_surnames/help_text.php',
WT_ROOT.'themes/clouds/images/center.png',
WT_ROOT.'themes/colors/images/center.png',
WT_ROOT.'themes/fab/images/center.png', | Update admin list of old/deleted files | fisharebest_webtrees | train | php |
58c8650acc7a9a11763f9b3ac15fa06b9d73e89e | diff --git a/simulator/src/main/java/com/hazelcast/simulator/coordinator/Coordinator.java b/simulator/src/main/java/com/hazelcast/simulator/coordinator/Coordinator.java
index <HASH>..<HASH> 100644
--- a/simulator/src/main/java/com/hazelcast/simulator/coordinator/Coordinator.java
+++ b/simulator/src/main/java/com/hazelcast/simulator/coordinator/Coordinator.java
@@ -260,9 +260,11 @@ public final class Coordinator {
clusterLayout.getClientWorkerCount());
remoteClient.createWorkers(clusterLayout, true);
- WorkerData firstWorker = componentRegistry.getFirstWorker();
- LOGGER.info(format("Worker for global test phases will be %s (%s)", firstWorker.getAddress(),
- firstWorker.getSettings().getWorkerType()));
+ if (componentRegistry.workerCount() > 0) {
+ WorkerData firstWorker = componentRegistry.getFirstWorker();
+ LOGGER.info(format("Worker for global test phases will be %s (%s)", firstWorker.getAddress(),
+ firstWorker.getSettings().getWorkerType()));
+ }
long elapsed = getElapsedSeconds(started);
echo(HORIZONTAL_RULER); | Fixed test failure in CoordinatorRunTestSuiteTest due to empty worker list. | hazelcast_hazelcast-simulator | train | java |
4dc5c65ded6e71a61a00a8e0b7a4ec03d50fc26e | diff --git a/test/extended/util/test.go b/test/extended/util/test.go
index <HASH>..<HASH> 100644
--- a/test/extended/util/test.go
+++ b/test/extended/util/test.go
@@ -244,11 +244,6 @@ func createTestingNS(baseName string, c kclientset.Interface, labels map[string]
allowAllNodeScheduling(c, ns.Name)
}
- // some tests assume they can schedule to all nodes
- if testNameContains("Granular Checks: Pods") {
- allowAllNodeScheduling(c, ns.Name)
- }
-
return ns, err
} | Allow all node scheduling for more tests | openshift_origin | train | go |
76c58490fa58d82f2bfc53680d8ba57b30a22706 | diff --git a/lib/cloud_crowd/models/work_unit.rb b/lib/cloud_crowd/models/work_unit.rb
index <HASH>..<HASH> 100644
--- a/lib/cloud_crowd/models/work_unit.rb
+++ b/lib/cloud_crowd/models/work_unit.rb
@@ -54,19 +54,18 @@ module CloudCrowd
# Round robin through the nodes and units, sending the unit if the node
# is able to process it.
- while (node = available_nodes.shift) && (unit = work_units.shift) do
- if node.actions.include?(unit.action)
- if node.send_work_unit(unit)
- available_nodes.push(node) unless node.busy?
- next
+ work_units.each do |unit|
+ available_nodes.each do |node|
+ if node.actions.include? unit.action
+ if node.send_work_unit unit
+ work_units.delete unit
+ available_nodes.delete node if node.busy?
+ break
+ end
end
end
- work_units.push(unit)
end
- # If there are both units and nodes left over, try again.
- next if work_units.any? && available_nodes.any?
-
# If we still have units at this point, or we're fresh out of nodes,
# that means we're done.
return if work_units.any? || available_nodes.empty? | another try at fixing the inner loop. | documentcloud_cloud-crowd | train | rb |
c7587f1e45d07df9e0ae1bb9bbfe7f1155436e7d | diff --git a/index.js b/index.js
index <HASH>..<HASH> 100644
--- a/index.js
+++ b/index.js
@@ -341,7 +341,7 @@ function getFileTests(fileName, options) {
function canImport(fileName, caller, options) {
if (fileName === caller) return false;
- let _fileName = path.basename(fileName);
+ let _fileName = getFileTests(fileName, options);
if (options.includes) return (_.intersection(options.includes, _fileName).length > 0);
if (options.excludes) return (_.intersection(options.includes, _fileName).length === 0);
return true; | Fix bug
Was not actually do the include/exclude. | Whitebolt_require-extra | train | js |
219eb17b509cf5fd700f07f755ba05c8e330d675 | diff --git a/lib/writer/xelatex.js b/lib/writer/xelatex.js
index <HASH>..<HASH> 100644
--- a/lib/writer/xelatex.js
+++ b/lib/writer/xelatex.js
@@ -238,6 +238,13 @@ var header =
'\\usepackage[colorlinks,urlcolor=blue,filecolor=blue,linkcolor=black,citecolor=black]{hyperref}\n' +
'\\usepackage[all]{hypcap}\n' +
'\\urlstyle{same}\n' +
+ '\n' +
+ '% automatic font selection for some common scripts\n' +
+ '\\usepackage[Latin, Cyrillics, Greek, CJK, Arabics, Hebrew]{ucharclasses}\n' +
+ '\\setDefaultTransitions{\\fontspec{Times New Roman}}{}\n' +
+ '\\setTransitionsForCJK{\\fontspec{Heiti SC Light}}{}\n' +
+ '\\setTransitionsForArabics{\\fontspec{Lateef}}{}\n' +
+ '\\setTransitionTo{Hebrew}{\\fontspec{New Peninim MT}}\n' +
'\n' +
'% for RTL scripts\n' +
'\\usepackage{bidi}\n' + | [xelatex] Select fonts for several popular scripts automatically.
Reuires “ucharclasses” package. | sheremetyev_texts.js | train | js |
4434e6b14e183cbcb57258f012a659eabc64fb6e | diff --git a/spec/diffy_spec.rb b/spec/diffy_spec.rb
index <HASH>..<HASH> 100644
--- a/spec/diffy_spec.rb
+++ b/spec/diffy_spec.rb
@@ -85,8 +85,8 @@ describe Diffy::Diff do
it "works for :html_simple" do
output = Diffy::Diff.new("foo\nbar\nbang\n", "foo\nbang\n", :include_diff_info => true ).to_s(:html_simple)
output.split("\n").should include( " <li class=\"diff-block-info\"><span>@@ -1,3 +1,2 @@</span></li>" )
- output.should match( "<li class=\"diff-comment\"><span>---")
- output.should match( "<li class=\"diff-comment\"><span>+++")
+ output.should include( "<li class=\"diff-comment\"><span>---")
+ output.should include( "<li class=\"diff-comment\"><span>+++")
end
end
end | fix test in <I>, match with the +++ causes a problem in <I> | samg_diffy | train | rb |
c0305eb58eeb08e007b97edb5c7c73e9a2c01cc8 | diff --git a/spec/persistence_spec.rb b/spec/persistence_spec.rb
index <HASH>..<HASH> 100644
--- a/spec/persistence_spec.rb
+++ b/spec/persistence_spec.rb
@@ -12,11 +12,11 @@ describe 'persistence' do
end
it "serializes data" do
- lambda{@tasks.serialize_to_file('test.dat')}.should.not.raise
+ lambda{PersistTask.serialize_to_file('test.dat')}.should.not.raise
end
it 'reads persisted model data' do
- @tasks.serialize_to_file('test.dat')
+ PersistTask.serialize_to_file('test.dat')
PersistTask.delete_all
@@ -36,7 +36,7 @@ describe 'persistence' do
columns :name => :string
end
@foo = Foo.create(:name=> 'Bob')
- @foo.serialize_to_file('test.dat')
+ Foo.serialize_to_file('test.dat')
@foo.should.not.respond_to :address
@@ -61,7 +61,7 @@ describe 'persistence' do
columns :name => :string, :desc => :string
end
@foo = Foo.create(:name=> 'Bob', :desc => 'who cares anyway?')
- @foo.serialize_to_file('test.dat')
+ Foo.serialize_to_file('test.dat')
@foo.should.respond_to :desc | Changed to reflect change of serialize_to_file from instance to class method. | sxross_MotionModel | train | rb |
cd0c969281bde1d11586acacb77584807eaa98ce | diff --git a/test/test_mini_fb.rb b/test/test_mini_fb.rb
index <HASH>..<HASH> 100644
--- a/test/test_mini_fb.rb
+++ b/test/test_mini_fb.rb
@@ -1,7 +1,10 @@
require 'test/unit'
require 'uri'
require 'yaml'
+require 'rubygems'
require 'active_support'
+require 'active_support/core_ext/object'
+require 'active_support/core_ext/string/starts_ends_with'
require '../lib/mini_fb'
class MiniFBTests < Test::Unit::TestCase | add additional 'require' statements to make tests compatible with active_support <I> | appoxy_mini_fb | train | rb |
464befc2d436678c5d66f3595fa85052d58e5004 | diff --git a/example/statusicon/statusicon.go b/example/statusicon/statusicon.go
index <HASH>..<HASH> 100644
--- a/example/statusicon/statusicon.go
+++ b/example/statusicon/statusicon.go
@@ -23,7 +23,7 @@ func main() {
si.SetTitle("StatusIcon Example")
si.SetTooltipMarkup("StatusIcon Example")
si.Connect("popup-menu", func(cbx *glib.CallbackContext) {
- nm.Popup(nil, nil, gtk.StatusIconPositionMenu, si, uint(cbx.Args(0)), uint(cbx.Args(1)))
+ nm.Popup(nil, nil, gtk.StatusIconPositionMenu, si, uint(cbx.Args(0)), uint32(cbx.Args(1)))
})
println(` | fix cast to uint<I>. related issue #<I> | mattn_go-gtk | train | go |
2f694d97e7d9ca353e673ea8de012f071b495a5b | diff --git a/code/models/ElementContent.php b/code/models/ElementContent.php
index <HASH>..<HASH> 100644
--- a/code/models/ElementContent.php
+++ b/code/models/ElementContent.php
@@ -21,8 +21,6 @@ class ElementContent extends BaseElement
{
$styles = $this->config()->get('styles');
- $fields = parent::getCMSFields();
-
if (count($styles) > 0) {
$this->beforeUpdateCMSFields(function ($fields) use ($styles) {
$fields->addFieldsToTab('Root.Main', new HtmlEditorField('HTML', 'Content'));
@@ -31,9 +29,13 @@ class ElementContent extends BaseElement
$styles->setEmptyString('Select a custom style..');
});
} else {
- $fields->removeByName('Style');
+ $this->beforeUpdateCMSFields(function ($fields) {
+ $fields->removeByName('Style');
+ });
}
+ $fields = parent::getCMSFields();
+
if ($this->isEndofLine('ElementContent') && $this->hasExtension('VersionViewerDataObject')) {
$fields = $this->addVersionViewer($fields, $this);
} | Fixes calling getCMSFields before callbacks setup | dnadesign_silverstripe-elemental | train | php |
9e7dc57e682f74f70fa4df4b8918a35099747cb6 | diff --git a/lib/ndr_support/concerns/working_days.rb b/lib/ndr_support/concerns/working_days.rb
index <HASH>..<HASH> 100644
--- a/lib/ndr_support/concerns/working_days.rb
+++ b/lib/ndr_support/concerns/working_days.rb
@@ -83,11 +83,11 @@ module WorkingDays
'2020-01-01', # Wednesday - New Year's Day
'2020-04-10', # Friday - Good Friday
'2020-04-13', # Monday - Easter Monday
- '2020-05-04', # Monday - Early May bank holiday
+ '2020-05-08', # Friday - Early May bank holiday (moved from Monday)
'2020-05-25', # Monday - Spring bank holiday
'2020-08-31', # Monday - Summer bank holiday
'2020-12-25', # Friday - Christmas Day
- '2020-12-26', # Monday - Boxing Day
+ '2020-12-28', # Monday - Boxing Day (substitute day)
].map { |str| Date.parse(str) }
def self.check_lookup | # corrected <I> bank holidays | PublicHealthEngland_ndr_support | train | rb |
6249607fd5abb7ccd427508bb0bb05422f742e55 | diff --git a/lib/cli/repl.js b/lib/cli/repl.js
index <HASH>..<HASH> 100644
--- a/lib/cli/repl.js
+++ b/lib/cli/repl.js
@@ -155,7 +155,7 @@ Repl.prototype.start = function(options) {
this._defineAdditionalCommands(replServer);
- replServer = injectBefore(replServer, "complete", function() {
+ replServer = injectBefore(replServer, "completer", function() {
self.complete.apply(self, arguments);
});
replServer = injectAfter(replServer, "eval", promisify); | fix repl injection point to match node v6 | jsforce_jsforce | train | js |
846af8e413e10efa87aa05eed55008dfce692cca | diff --git a/cmd/dockerd/config_unix.go b/cmd/dockerd/config_unix.go
index <HASH>..<HASH> 100644
--- a/cmd/dockerd/config_unix.go
+++ b/cmd/dockerd/config_unix.go
@@ -38,7 +38,7 @@ func installConfigFlags(conf *config.Config, flags *pflag.FlagSet) error {
flags.BoolVar(&conf.EnableSelinuxSupport, "selinux-enabled", false, "Enable selinux support")
flags.Var(opts.NewNamedUlimitOpt("default-ulimits", &conf.Ulimits), "default-ulimit", "Default ulimits for containers")
flags.BoolVar(&conf.BridgeConfig.EnableIPTables, "iptables", true, "Enable addition of iptables rules")
- flags.BoolVar(&conf.BridgeConfig.EnableIP6Tables, "ip6tables", false, "Enable addition of ip6tables rules")
+ flags.BoolVar(&conf.BridgeConfig.EnableIP6Tables, "ip6tables", false, "Enable addition of ip6tables rules (experimental)")
flags.BoolVar(&conf.BridgeConfig.EnableIPForward, "ip-forward", true, "Enable net.ipv4.ip_forward")
flags.BoolVar(&conf.BridgeConfig.EnableIPMasq, "ip-masq", true, "Enable IP masquerading")
flags.BoolVar(&conf.BridgeConfig.EnableIPv6, "ipv6", false, "Enable IPv6 networking") | cmd/dockerd: update --ip6tables description to include "experimental"
This feature requires experimental mode to be enabled, so mentioning that
in the flag description. | moby_moby | train | go |
5b1e9f6f5f3b025c631b5b52f5900148f48d36a0 | diff --git a/cake/libs/controller/components/security.php b/cake/libs/controller/components/security.php
index <HASH>..<HASH> 100644
--- a/cake/libs/controller/components/security.php
+++ b/cake/libs/controller/components/security.php
@@ -17,7 +17,7 @@
* @since CakePHP(tm) v 0.10.8.2156
* @license MIT License (http://www.opensource.org/licenses/mit-license.php)
*/
-App::import('Core', 'String');
+App::import('Core', array('String', 'Security'));
/**
* Short description for file.
* | Fixing fatal error caused by Security class not being loaded When Session.start = false. Fixes #<I> | cakephp_cakephp | train | php |
6ecea9123c89fd18754fcb2c0d1330583be6ece3 | diff --git a/panoramix/views.py b/panoramix/views.py
index <HASH>..<HASH> 100644
--- a/panoramix/views.py
+++ b/panoramix/views.py
@@ -181,10 +181,12 @@ class SliceModelView(PanoramixModelView, DeleteMixin):
can_add = False
list_columns = [
'slice_link', 'viz_type', 'datasource_type',
- 'datasource', 'created_by']
+ 'datasource', 'created_by', 'changed_on']
edit_columns = [
'slice_name', 'viz_type', 'druid_datasource',
'table', 'dashboards', 'params']
+ base_order = ('changed_on','desc')
+
appbuilder.add_view(
SliceModelView, | adding sort order of the slices on changed_on field | apache_incubator-superset | train | py |
d3aa13f2eba80239a33364f5c69e29d4b93e819c | diff --git a/src/main/java/org/jboss/jreadline/console/Console.java b/src/main/java/org/jboss/jreadline/console/Console.java
index <HASH>..<HASH> 100644
--- a/src/main/java/org/jboss/jreadline/console/Console.java
+++ b/src/main/java/org/jboss/jreadline/console/Console.java
@@ -808,7 +808,9 @@ public class Console {
String startsWith = Parser.findStartsWith(completions);
- if(startsWith.length() > 0 && possibleCompletions.get(0).getFormattedCompletion(startsWith).length() > 0) {
+ if(startsWith.length() > 0 &&
+ startsWith.length() > Parser.findWordClosestToCursor(buffer.getLine(), buffer.getCursor()).length() &&
+ possibleCompletions.get(0).getFormattedCompletion(startsWith).length() > 0) {
displayCompletion(possibleCompletions.get(0).getFormattedCompletion(startsWith), false);
}
// display all | fix completion bug when startsWith kicks in | aeshell_aesh | train | java |
cd231ade177b93c3484ba37760c154074596ba76 | diff --git a/src/M6Web/Bundle/WSClientBundle/DataCollector/WSClientDataCollector.php b/src/M6Web/Bundle/WSClientBundle/DataCollector/WSClientDataCollector.php
index <HASH>..<HASH> 100644
--- a/src/M6Web/Bundle/WSClientBundle/DataCollector/WSClientDataCollector.php
+++ b/src/M6Web/Bundle/WSClientBundle/DataCollector/WSClientDataCollector.php
@@ -5,12 +5,13 @@ use Symfony\Component\HttpKernel\DataCollector\DataCollector;
use Symfony\Component\HttpFoundation\Response;
use Symfony\Component\HttpFoundation\Request;
use M6Web\Bundle\WSClientBundle\EventDispatcher as WSEventDispatcher;
+
/**
* Handle datacollector for Wsclient
*/
class WSClientDataCollector extends DataCollector
{
- private $data;
+ protected $data;
/**
* Construct the data collector | Fix property visibility in WSClientDataCollector | M6Web_WsClientBundle | train | php |
83709a432dd8272e0588d42433c60956f29fd5b1 | diff --git a/lib/match.js b/lib/match.js
index <HASH>..<HASH> 100644
--- a/lib/match.js
+++ b/lib/match.js
@@ -4,13 +4,11 @@ var through = require('through2');
// object mode transform stream takes tokenized css and yields complete,
// parseable rules or at-rules as strings.
module.exports = function match() {
- var current = null, depth = 0;
+ var current = null; // buffer for the current incoming rule.
+ var depth = 0; // track depth to handle rules nested in at-rules.
function write(token, enc, next) {
var type = token[0], buf = token[1];
- if(depth === 0 && current) {
- this.push({content: Buffer.concat(current).toString()});
- current = null;
- }
+
if(('rule_start' === type || 'atrule_start' === type))
depth++;
if(depth > 0 && !current)
@@ -19,6 +17,11 @@ module.exports = function match() {
depth--;
if(current) current.push(buf);
+ if(depth === 0 && current) {
+ this.push({content: Buffer.concat(current).toString()});
+ current = null;
+ }
+
next();
} | refactor: rearrange for making sense | anandthakker_css-rule-stream | train | js |
62f1e23a1fce0802ebc56f58c2d23e44b1110fcc | diff --git a/lib/govuk_schemas/random_example.rb b/lib/govuk_schemas/random_example.rb
index <HASH>..<HASH> 100644
--- a/lib/govuk_schemas/random_example.rb
+++ b/lib/govuk_schemas/random_example.rb
@@ -98,11 +98,6 @@ Generated payload:
--------------------------
#{JSON.pretty_generate([item])}
-
-Schema:
---------------------------
-
-#{JSON.pretty_generate(@schema)}
err
end | Don't print the schema in error messages
This makes the exception messages very long and hard to read. The
relevant bits of the schema are in the error messages anyway. | alphagov_govuk_schemas | train | rb |
69ed5f8d8f3ac548bf0dd1eea15ec1edde705ac3 | diff --git a/lib/slaw/za/act_nodes.rb b/lib/slaw/za/act_nodes.rb
index <HASH>..<HASH> 100644
--- a/lib/slaw/za/act_nodes.rb
+++ b/lib/slaw/za/act_nodes.rb
@@ -61,11 +61,7 @@ module Slaw
end
def write_preamble(b)
- if preamble.text_value != ""
- b.preamble { |b|
- preamble.to_xml(b)
- }
- end
+ preamble.to_xml(b)
end
def write_body(b)
@@ -81,11 +77,15 @@ module Slaw
class Preamble < Treetop::Runtime::SyntaxNode
def to_xml(b)
- statements.elements.each { |e|
- if not (e.content.text_value =~ /^preamble/i)
- b.p(e.content.text_value)
- end
- }
+ if text_value != ""
+ b.preamble { |b|
+ statements.elements.each { |e|
+ if not (e.content.text_value =~ /^preamble/i)
+ b.p(e.content.text_value)
+ end
+ }
+ }
+ end
end
end | Move premable serialization into node. | longhotsummer_slaw | train | rb |
b1bd5c06106614f3e368ee3a5dd92a2e1df8e265 | diff --git a/pysubs2/tmp.py b/pysubs2/tmp.py
index <HASH>..<HASH> 100644
--- a/pysubs2/tmp.py
+++ b/pysubs2/tmp.py
@@ -47,8 +47,8 @@ class TmpFormat(FormatBase):
start, text = match.groups()
start = tmptimestamp_to_ms(TMPTIMESTAMP.match(start).groups())
- #calculate endtime from starttime + 2 seconds + 0.4 second per each space in string (which should roughly equal number of words)
- end = start + 2000 + (400 * line.count(" "))
+ #calculate endtime from starttime + 500 miliseconds + 67 miliseconds per each character (15 chars per second)
+ end = start + 500 + (len(line) * 67)
timestamps.append((start, end))
lines.append(text) | change .tmp calc formula to chars/sec | tkarabela_pysubs2 | train | py |
df3cf6679be00a837b904f846c313918758889d3 | diff --git a/commands/ping.py b/commands/ping.py
index <HASH>..<HASH> 100755
--- a/commands/ping.py
+++ b/commands/ping.py
@@ -20,7 +20,7 @@ from helpers.misc import recordping
from helpers.command import Command
-@Command('ping', ['handler', 'target', 'config'])
+@Command('ping', ['handler', 'target', 'config', 'nick'])
def cmd(send, msg, args):
"""Ping something.
Syntax: !ping <target>
@@ -28,9 +28,9 @@ def cmd(send, msg, args):
if not msg:
send("Ping what?")
return
- channel = args['target'] if args['target'] != 'private' else args['config']['core']['channel']
+ channel = args['target'] if args['target'] != 'private' else args['nick']
# CTCP PING
- if msg.lower() in args['handler'].channels[channel].users():
+ if "." not in msg:
args['handler'].connection.ctcp("PING", msg, " ".join(str(time()).split('.')))
recordping(msg, channel)
return | make ping do more ctcp | tjcsl_cslbot | train | py |
dbda340e7f91966fb1417a0186dc5dc235bc16ca | diff --git a/deploy/helper.js b/deploy/helper.js
index <HASH>..<HASH> 100644
--- a/deploy/helper.js
+++ b/deploy/helper.js
@@ -33,7 +33,7 @@ var mapFilesToStreams = function(filesPaths) {
};
var uploadFile = R.curry(function(remotePath, payload) {
- var S3 = new AWS.S3({params: {Bucket: 'as24-assets-eu-west-1', Key: remotePath + '/' + payload.fileName}});
+ var S3 = new AWS.S3({params: {Bucket: 'as24-assets-eu-west-1', ACL: 'public-read', Key: remotePath + '/' + payload.fileName}});
S3.upload({Body: payload.fileStream})
.on('httpUploadProgress', function(evt) {
console.log(chalk.green('File ' + evt.key + ' is ' + Math.floor(evt.loaded * 100 / evt.total) + '% loaded')); | Fixed ACL when deploy to s3 | Scout24_showcar-ui | train | js |
558c605097f4bdd3f713303032a8f774a0e82c0f | diff --git a/lib/plaid/user.rb b/lib/plaid/user.rb
index <HASH>..<HASH> 100644
--- a/lib/plaid/user.rb
+++ b/lib/plaid/user.rb
@@ -336,7 +336,7 @@ module Plaid
response = Connector.new(:upgrade, auth: true, client: client)
.post(payload)
- User.new product, response: response
+ User.new product, response: response, client: client
end
# Public: Get the current user tied to another product. | Pass the client onto the new User instance in User#upgrade | plaid_plaid-ruby | train | rb |
36b2817e1339db4b944b56fd38bb08bda1311384 | diff --git a/lib/expression.js b/lib/expression.js
index <HASH>..<HASH> 100644
--- a/lib/expression.js
+++ b/lib/expression.js
@@ -524,7 +524,7 @@ CronExpression.prototype._findSchedule = function _findSchedule (reverse) {
}
// The first character represents the weekday
- var weekday = Number.parseInt(expression[0]);
+ var weekday = Number.parseInt(expression[0]) % 7;
if (Number.isNaN(weekday)) {
throw new Error('Invalid last weekday of the month expression: ' + expression);
diff --git a/test/parser_day_of_month.js b/test/parser_day_of_month.js
index <HASH>..<HASH> 100644
--- a/test/parser_day_of_month.js
+++ b/test/parser_day_of_month.js
@@ -85,7 +85,8 @@ test('parse cron with last weekday of the month', function(t) {
{ expression: '0 0 0 * * 4L', expectedDate: 30 },
{ expression: '0 0 0 * * 5L', expectedDate: 24 },
{ expression: '0 0 0 * * 6L', expectedDate: 25 },
- { expression: '0 0 0 * * 0L', expectedDate: 26 }
+ { expression: '0 0 0 * * 0L', expectedDate: 26 },
+ { expression: '0 0 0 * * 7L', expectedDate: 26 }
];
testCases.forEach(function({ expression, expectedDate }) { | fix(expression): handle 7L, correctly (#<I>) | harrisiirak_cron-parser | train | js,js |
cae37e8b1e42bd355556a200f9beffa7cc841d39 | diff --git a/fahrschein/src/main/java/org/zalando/fahrschein/NakadiClient.java b/fahrschein/src/main/java/org/zalando/fahrschein/NakadiClient.java
index <HASH>..<HASH> 100644
--- a/fahrschein/src/main/java/org/zalando/fahrschein/NakadiClient.java
+++ b/fahrschein/src/main/java/org/zalando/fahrschein/NakadiClient.java
@@ -81,8 +81,8 @@ public class NakadiClient {
* @param eventName where the event should be written to
* @param events that should be written
* @param <T> Type of the Event
- * @throws IOException in case we fail reaching Nakadi or we are unable to write the event.
- * @throws EventPublishingException in case we fail reaching Nakadi or we are unable to write the event.
+ * @throws IOException in case we fail to reach Nakadi
+ * @throws EventPublishingException In case Nakadi returns an Erroneous response
*/
public <T> void publish(String eventName, List<T> events) throws EventPublishingException, IOException {
final URI uri = baseUri.resolve(String.format("/event-types/%s/events", eventName)); | #<I> Make it explicit in the Javadocs when EventPublishingException is thrown. | zalando-nakadi_fahrschein | train | java |
6808b1ac9fb7a23301f88a50653527da4d5ec8c6 | diff --git a/lib/file-watcher.js b/lib/file-watcher.js
index <HASH>..<HASH> 100644
--- a/lib/file-watcher.js
+++ b/lib/file-watcher.js
@@ -8,7 +8,6 @@ var watcher;
var throttleTimeout;
var throttlingTime = 3000;
-
function watch(_throttlingTime) {
isWatching = true;
@@ -28,6 +27,13 @@ function stop() {
if (watcher) watcher.close();
}
+function verifyModuleIsInUse(nameOrPath) {
+ try {
+ return !!require.cache[require.resolve(nameOrPath)];
+ } catch(e) {}
+ return false;
+}
+
function throttleEmitEvent(fileName) {
clearTimeout(throttleTimeout);
@@ -36,8 +42,9 @@ function throttleEmitEvent(fileName) {
var isJsFile = path.extname(filePath) === '.js';
var isModule = filePath.indexOf('node_modules') > -1;
+ var isModuleInUse = verifyModuleIsInUse(path.resolve(fileName));
- if (isModule===false && isJsFile===true){
+ if (isModule===false && isJsFile===true && isModuleInUse===true){
emitter.emit('fileChanged', filePath);
}
}, throttlingTime); | Improved file watcher - considering only loaded modules. | fernandofranca_launchpod | train | js |
4182ae4a35ce78a354877e576d1f8397c651b18c | diff --git a/src/Internal/AutoScheduler.php b/src/Internal/AutoScheduler.php
index <HASH>..<HASH> 100644
--- a/src/Internal/AutoScheduler.php
+++ b/src/Internal/AutoScheduler.php
@@ -4,10 +4,6 @@ namespace mpyw\Co\Internal;
use mpyw\Co\CURLException;
use mpyw\RuntimePromise\Deferred;
-/**
- * Currently this class is not used
- * @codeCoverageIgnore
- */
class AutoScheduler extends AbstractScheduler
{
/** | Now AutoScheduler is already used xD | mpyw_co | train | php |
6553f48d92ccc29372610869b9ac3f839eed3c85 | diff --git a/lib/irrc/connecting.rb b/lib/irrc/connecting.rb
index <HASH>..<HASH> 100644
--- a/lib/irrc/connecting.rb
+++ b/lib/irrc/connecting.rb
@@ -28,12 +28,5 @@ module Irrc
def established?
@connection && !@connection.sock.closed?
end
-
- def execute(command)
- return if command.nil? || command == ''
-
- logger.debug "Executing: #{command}"
- @connection.cmd(command).tap {|result| logger.debug "Returned: #{result}" }
- end
end
end | Remove unused method, even it was confusing | codeout_irrc | train | rb |
8ca65eb4cab6bb61c22c056a80893e792d0fb184 | diff --git a/drivers/mongodb.js b/drivers/mongodb.js
index <HASH>..<HASH> 100644
--- a/drivers/mongodb.js
+++ b/drivers/mongodb.js
@@ -24,7 +24,7 @@ var _ = require('underscore'),
*/
function MongoDB(app, config) {
-
+
var self = this;
config = protos.extend({
@@ -34,6 +34,8 @@ function MongoDB(app, config) {
storage: null
}, config || {});
+ if (typeof config.port != 'number') config.port = parseInt(config.port, 10);
+
this.className = this.constructor.name;
this.app = app;
diff --git a/storages/mongodb.js b/storages/mongodb.js
index <HASH>..<HASH> 100644
--- a/storages/mongodb.js
+++ b/storages/mongodb.js
@@ -32,6 +32,8 @@ function MongoStorage(app, config) {
collection: 'keyvalue'
}, config);
+ if (typeof config.port != 'number') config.port = parseInt(config.port, 10);
+
/**
Application instance | Ensure port in mongodb configs to be always an integer | derdesign_protos | train | js,js |
c8f681a03cc8092c6a32c742c8f5bf53f86f7ce0 | diff --git a/src/psd_tools/composite/effects.py b/src/psd_tools/composite/effects.py
index <HASH>..<HASH> 100644
--- a/src/psd_tools/composite/effects.py
+++ b/src/psd_tools/composite/effects.py
@@ -15,6 +15,8 @@ logger = logging.getLogger(__name__)
def draw_stroke_effect(viewport, shape, desc, psd):
logger.debug('Stroke effect has limited support')
height, width = viewport[3] - viewport[1], viewport[2] - viewport[0]
+ if not isinstance(shape, np.ndarray):
+ shape = np.full((height, width, 1), shape, dtype=np.float32)
paint = desc.get(Key.PaintType).enum
if paint == Enum.SolidColor:
diff --git a/src/psd_tools/version.py b/src/psd_tools/version.py
index <HASH>..<HASH> 100644
--- a/src/psd_tools/version.py
+++ b/src/psd_tools/version.py
@@ -1 +1 @@
-__version__ = '1.9.8'
+__version__ = '1.9.9' | Force numpy array in stroke effect (fix #<I>) | psd-tools_psd-tools | train | py,py |
0a92c43f5359a370f0f0dcc94a9f45eefb75ba7b | diff --git a/babel.config.js b/babel.config.js
index <HASH>..<HASH> 100644
--- a/babel.config.js
+++ b/babel.config.js
@@ -2,8 +2,8 @@ module.exports = {
presets: [
['@babel/preset-env', {
targets: {
- node: 'current',
+ node: '4',
},
- }, ],
+ }],
],
}; | Target an old Node version for dist/ build | kpalmvik_se-free | train | js |
Subsets and Splits
Java Commits in Train Set
Queries for all entries where the diff_languages column is 'java', providing a filtered dataset but without deeper analysis.
Java Commits Test Data
Returns a subset of 5000 entries from the dataset where the programming language difference is Java, providing basic filtering for exploration.
Java Commits Sample
Retrieves the first 1,000 records where the 'diff_languages' column is 'java', providing limited insight into the specific data entries.
Java Commits Validation Sample
Retrieves a sample of entries from the validation dataset where the diff languages are Java, providing limited insight into specific Java-related data points.
Java Commits in Validation
This query retrieves a limited sample of entries from the validation dataset where the programming language difference is Java, providing basic filtering with minimal insight.
Java Commits Sample
This query retrieves a sample of 100 records where the 'diff_languages' is 'java', providing basic filtering but limited analytical value.
Java Commits Sample
Retrieves 100 samples where the language difference is Java, providing basic filtering but minimal analytical value.
Java Commits Sample
Retrieves 10 samples where the diff_languages column is 'java', providing basic examples of data entries with this specific language.
Java Commits Validation Sample
Retrieves 1,000 records where the differences in languages are marked as Java, providing a snapshot of that specific subset but limited to raw data.
Java Commits Sample
This query retrieves 1000 random samples from the dataset where the programming language is Java, offering limited insight beyond raw data.