hash
stringlengths 40
40
| diff
stringlengths 172
2.63k
| message
stringlengths 12
593
| project
stringlengths 7
65
| split
stringclasses 1
value | diff_languages
stringclasses 54
values |
|---|---|---|---|---|---|
30fef390f55fd8c23ade69c54a0357a46945ac18
|
diff --git a/isso/views/comments.py b/isso/views/comments.py
index <HASH>..<HASH> 100644
--- a/isso/views/comments.py
+++ b/isso/views/comments.py
@@ -843,14 +843,19 @@ class API(object):
return JSON({'text': self.isso.render(data["text"])}, 200)
def demo(self, env, req):
- return redirect(get_current_url(env) + '/index.html')
+ return redirect(
+ get_current_url(env, strip_querystring=True) + '/index.html'
+ )
def login(self, env, req):
data = req.form
password = self.isso.conf.get("general", "admin_password")
if data['password'] and data['password'] == password:
- response = redirect(get_current_url(
- env, host_only=True) + '/admin')
+ response = redirect(re.sub(
+ r'/login$',
+ '/admin',
+ get_current_url(env, strip_querystring=True)
+ ))
cookie = functools.partial(dump_cookie,
value=self.isso.sign({"logged": True}),
expires=datetime.now() + timedelta(1))
|
fix: admin and demo view redirect issue
|
posativ_isso
|
train
|
py
|
6874f497cc16b3fce0b07420e0638c1411948f85
|
diff --git a/api/src/opentrons/protocol_api/instrument_context.py b/api/src/opentrons/protocol_api/instrument_context.py
index <HASH>..<HASH> 100644
--- a/api/src/opentrons/protocol_api/instrument_context.py
+++ b/api/src/opentrons/protocol_api/instrument_context.py
@@ -174,7 +174,7 @@ class InstrumentContext(CommandPublisher):
:type volume: int or float
:param location: Where to aspirate from. If `location` is a
:py:class:`.Well`, the robot will aspirate from
- :py:obj:`well_bottom_clearance```.aspirate`` mm
+ :py:obj:`well_bottom_clearance.aspirate` mm
above the bottom of the well. If `location` is a
:py:class:`.Location` (i.e. the result of
:py:meth:`.Well.top` or :py:meth:`.Well.bottom`), the
@@ -275,7 +275,7 @@ class InstrumentContext(CommandPublisher):
:param location: Where to dispense into. If `location` is a
:py:class:`.Well`, the robot will dispense into
- :py:obj:`well_bottom_clearance```.dispense`` mm
+ :py:obj:`well_bottom_clearance.dispense` mm
above the bottom of the well. If `location` is a
:py:class:`.Location` (i.e. the result of
:py:meth:`.Well.top` or :py:meth:`.Well.bottom`), the
|
docs(api): fix aspirate and dispense typo (#<I>)
|
Opentrons_opentrons
|
train
|
py
|
1b98576f51a072dbc368c762158ffa11a9cd295f
|
diff --git a/src/index.js b/src/index.js
index <HASH>..<HASH> 100644
--- a/src/index.js
+++ b/src/index.js
@@ -58,7 +58,7 @@ function createLoader() {
}
// AMD Module Loader Support
- if (typeof host.require === 'function' && typeof host.require.version === 'string') {
+ if (typeof host.require === 'function' && typeof host.define === 'function' && typeof host.define.amd === 'object') {
return new Promise((resolve, reject) => host.require(['aurelia-loader-default'], m => resolve(new m.DefaultLoader()), reject));
}
|
fix(loader): Use better detection of amd loaders
|
aurelia_bootstrapper
|
train
|
js
|
1208cdc74b7898c0cd7ad214fdfd1257c52f8ed8
|
diff --git a/hdl_toolkit/simulator/agents/signal.py b/hdl_toolkit/simulator/agents/signal.py
index <HASH>..<HASH> 100644
--- a/hdl_toolkit/simulator/agents/signal.py
+++ b/hdl_toolkit/simulator/agents/signal.py
@@ -2,8 +2,8 @@ from hdl_toolkit.simulator.agents.agentBase import AgentBase
from hdl_toolkit.hdlObjects.specialValues import Time
class SignalAgent(AgentBase):
- READER_DELAY = 0.001 # random small value
- def __init__(self, intf, delay=10*Time.ns):
+ READER_DELAY = 0.001 # random small value
+ def __init__(self, intf, delay=10 * Time.ns):
self.delay = delay
self.intf = intf
self.data = []
@@ -23,9 +23,8 @@ class SignalAgent(AgentBase):
def monitor(self, s):
yield s.wait(self.READER_DELAY)
while True:
- while s.applyValuesPlaned:
- yield s.wait(0)
+ yield s.updateComplete
d = self.doRead(s)
self.data.append(d)
yield s.wait(self.delay)
-
\ No newline at end of file
+
|
fix: wait on right event before reading
|
Nic30_hwt
|
train
|
py
|
7df47257cc2943d36f61f0a0e85a88a3205051c0
|
diff --git a/build/gulp.modules.js b/build/gulp.modules.js
index <HASH>..<HASH> 100644
--- a/build/gulp.modules.js
+++ b/build/gulp.modules.js
@@ -137,4 +137,8 @@ const build = () => {
return gulp.series([buildModuleBuilder, copySdkDefinitions, buildModules()])
}
-module.exports = { build, copySdkDefinitions, buildModules, packageModules, buildModuleBuilder }
+const buildSdk = () => {
+ return gulp.series([copySdkDefinitions])
+}
+
+module.exports = { build, buildSdk, buildModules, packageModules, buildModuleBuilder }
diff --git a/gulpfile.js b/gulpfile.js
index <HASH>..<HASH> 100644
--- a/gulpfile.js
+++ b/gulpfile.js
@@ -16,6 +16,7 @@ gulp.task('build', gulp.series([core.build(), modules.build(), ui.build()]))
gulp.task('build:ui', ui.build())
gulp.task('build:core', core.build())
gulp.task('build:modules', gulp.series([modules.build()]))
+gulp.task('build:sdk', gulp.series([modules.buildSdk()]))
gulp.task('start:guide', docs.startDevServer)
gulp.task('build:guide', docs.buildGuide)
|
chore(build): added "build:sdk" gulp command
|
botpress_botpress
|
train
|
js,js
|
efce87b6488ec0d5072853ad7202e0e0d8a92181
|
diff --git a/lib/converter-dtrace.js b/lib/converter-dtrace.js
index <HASH>..<HASH> 100644
--- a/lib/converter-dtrace.js
+++ b/lib/converter-dtrace.js
@@ -44,6 +44,9 @@ proto._parseFrame = function _parseFrame(frame) {
}
}
+function inspect(obj, depth) {
+ console.error(require('util').inspect(obj, false, depth || 5, true));
+}
proto._parseTraceInfo = function _parseTraceInfo(line, isStart) {
var parts = line.split(' ');
@@ -53,7 +56,7 @@ proto._parseTraceInfo = function _parseTraceInfo(line, isStart) {
}
if (this._startTime && this._process && this._pid && this._type) return;
- this._startTime = (parts[2] && parts[2].slice(0, -1)) || '0';
+ this._startTime = (parts[2] && parts[2].slice(0, -1)) || '0.0';
this._process = parts[0];
this._pid = parts[1];
@@ -70,6 +73,8 @@ proto._normalizeFrame = function _normalizeFrame(frame) {
proto._adjustTime = function _adjustTime(t) {
var s = t.toString();
+ // 0 is a special case
+ if (s.length < 5) return s;
return s.slice(0, -3) + '.' + s.slice(4);
}
|
fix: properly adjusting milliseconds smaller than length 5
|
thlorenz_cpuprofilify
|
train
|
js
|
61caa3a2315e96e40d39d833e9f1bc510780c16e
|
diff --git a/test/browser/sauce-tests.js b/test/browser/sauce-tests.js
index <HASH>..<HASH> 100755
--- a/test/browser/sauce-tests.js
+++ b/test/browser/sauce-tests.js
@@ -2,7 +2,7 @@
'use strict';
-var promise = require('bluebird'),
+var Promise = require('bluebird'),
spawn = require('child_process').spawn;
var clients = [
|
test(sauce): correct case
|
delta-db_deltadb-common-utils
|
train
|
js
|
b9ac334efc410d11fe57ef5ab6e511f194115e3a
|
diff --git a/lib/browser/api/dialog.js b/lib/browser/api/dialog.js
index <HASH>..<HASH> 100644
--- a/lib/browser/api/dialog.js
+++ b/lib/browser/api/dialog.js
@@ -249,7 +249,11 @@ module.exports = {
},
showCertificateTrustDialog: function (window, options) {
- if (window && window.constructor !== BrowserWindow) options = window;
+ if (window && window.constructor !== BrowserWindow) {
+ options = window;
+ window = null;
+ }
+
if (options == null || typeof options !== 'object') {
throw new TypeError('options must be an object');
}
|
fix: showing certificate dialog with no window (#<I>)
|
electron_electron
|
train
|
js
|
f20e6ca0bde0453924fe4882b1f999ea91a1df1d
|
diff --git a/aiogram/utils/exceptions.py b/aiogram/utils/exceptions.py
index <HASH>..<HASH> 100644
--- a/aiogram/utils/exceptions.py
+++ b/aiogram/utils/exceptions.py
@@ -368,7 +368,7 @@ class WrongFileIdentifier(BadRequest):
class GroupDeactivated(BadRequest):
- match = 'group is deactivated'
+ match = 'Group chat was deactivated'
class PhotoAsInputFileRequired(BadRequest):
|
fix: GroupDeactivated exception text update (#<I>)
|
aiogram_aiogram
|
train
|
py
|
8e429144e90501ba4c9afbca78fa4a00d2e21fb8
|
diff --git a/packages/select/src/Select.js b/packages/select/src/Select.js
index <HASH>..<HASH> 100644
--- a/packages/select/src/Select.js
+++ b/packages/select/src/Select.js
@@ -251,6 +251,10 @@ const Select = ({
color: showError ? '#931b1d' : 'hsl(0,0%,80%)',
};
},
+ option: provided => ({
+ ...provided,
+ color: '#000',
+ }),
}}
{...attributes}
value={getViewValue()}
|
fix(select): changed menu item color to black
|
Availity_availity-react
|
train
|
js
|
e85d4aa06f50775062f7b48954a1559edf261df1
|
diff --git a/src/commands/sign.js b/src/commands/sign.js
index <HASH>..<HASH> 100644
--- a/src/commands/sign.js
+++ b/src/commands/sign.js
@@ -13,7 +13,7 @@ import { cores } from '../utils/plugins.js'
* Create a signed commit
*
* <aside>
- * OpenPGP.js is unfortunately licensed under the LGPL-3.0 and thus cannot be included in a minified bundle with
+ * OpenPGP.js is unfortunately licensed under an incompatible license and thus cannot be included in a minified bundle with
* isomorphic-git which is an MIT/BSD style library, because that would violate the "dynamically linked" stipulation.
* To use this feature you include openpgp with a separate script tag and pass it in as an argument.
* </aside>
|
fix: remove false positive from FOSSA license check (#<I>)
|
isomorphic-git_isomorphic-git
|
train
|
js
|
f6b27e26d8c2d15e620f7612645d45109e591d3b
|
diff --git a/src/Views.php b/src/Views.php
index <HASH>..<HASH> 100644
--- a/src/Views.php
+++ b/src/Views.php
@@ -9,6 +9,7 @@ use Carbon\CarbonInterface;
use CyrildeWit\EloquentViewable\Contracts\View as ViewContract;
use CyrildeWit\EloquentViewable\Contracts\Viewable as ViewableContract;
use CyrildeWit\EloquentViewable\Contracts\Views as ViewsContract;
+use CyrildeWit\EloquentViewable\Contracts\Viewer as ViewerContract;
use CyrildeWit\EloquentViewable\Support\Period;
use DateTime;
use DateTimeInterface;
@@ -279,6 +280,18 @@ class Views implements ViewsContract
}
/**
+ * Set the viewer.
+ *
+ * @param \CyrildeWit\EloquentViewable\Contracts\Viewer
+ */
+ public function useViewer(ViewerContract $viewer)
+ {
+ $this->viewer = $viewer;
+
+ return $this;
+ }
+
+ /**
* Determine if we should record the view.
*
* @return bool
|
feat: add setter for viewer class
|
cyrildewit_eloquent-viewable
|
train
|
php
|
589d3ad63840329b5a61186603a415c534f8d4fc
|
diff --git a/lib/socket.js b/lib/socket.js
index <HASH>..<HASH> 100644
--- a/lib/socket.js
+++ b/lib/socket.js
@@ -386,6 +386,7 @@ class Socket extends Emitter {
case "ping":
this.resetPingTimeout();
this.sendPacket("pong");
+ this.emit("ping");
this.emit("pong");
break;
|
fix: emit ping when receiving a ping from the server
The "ping" event was forgotten when reversing the ping-pong mechanism
in [1]. It will now be properly emitted when receiving a ping from the
server.
[1]: <URL>
|
socketio_engine.io-client
|
train
|
js
|
f64ed31c4595019636ff8afc249fb9c01b858522
|
diff --git a/packages/testing-helpers/src/scopedElementsWrapper.js b/packages/testing-helpers/src/scopedElementsWrapper.js
index <HASH>..<HASH> 100644
--- a/packages/testing-helpers/src/scopedElementsWrapper.js
+++ b/packages/testing-helpers/src/scopedElementsWrapper.js
@@ -29,7 +29,7 @@ const transform = template => {
* However, a new type error is created --> Base constructors must all have the same return type.ts(2510)
* But this can be ignored, and then at least you do get the super static props typed properly.
*/
-// @ts-expect-error
+// @ts-ignore https://github.com/microsoft/TypeScript/issues/40110 , not using expect-error, because in some TS versions it does not throw
class ScopedElementsTestWrapper extends ScopedElementsMixin(LitElement) {
static get properties() {
return {
|
fix(testing-helpers): replace ts-expect-error with ignore
This is needed because different typescript versions seem to either throw or not throw, inconsistently. This makes expect-error problematic for users with typescript versions that don't throw on this. Review when the TS issue is closed by typescript.
|
open-wc_open-wc
|
train
|
js
|
b53fbdbf72bc88a44623785b2f93f67c8ae04157
|
diff --git a/src/index.js b/src/index.js
index <HASH>..<HASH> 100644
--- a/src/index.js
+++ b/src/index.js
@@ -151,7 +151,7 @@ function patch(modules) {
}
const applyFixes = SourceCodeFixer.applyFixes
- SourceCodeFixer.applyFixes = function(sourceCode, messages) {
+ SourceCodeFixer.applyFixes = function(sourceCode, messages, shouldFix) {
const originalSourceCode = sourceCodeForMessages.get(messages)
if (originalSourceCode) {
const hasBOM = originalSourceCode.startsWith(BOM)
@@ -162,7 +162,7 @@ function patch(modules) {
hasBOM,
}
}
- return applyFixes.call(this, sourceCode, messages)
+ return applyFixes.call(this, sourceCode, messages, shouldFix)
}
}
|
fix: ESLint <I>+ support
This is a quickfix for now. A better way to support ESLint <I>+ would
be to tell ESLint this plugin supports autofixing (new feature in <I>).
|
BenoitZugmeyer_eslint-plugin-html
|
train
|
js
|
a88bf21cdf99db807655a7e49a61d7d2ca768795
|
diff --git a/lib/client/address_group.js b/lib/client/address_group.js
index <HASH>..<HASH> 100644
--- a/lib/client/address_group.js
+++ b/lib/client/address_group.js
@@ -360,6 +360,9 @@ class AddressGroup extends Base {
if (this._healthCounter) {
this._healthCounter.close();
}
+ if (this._loadbalancer && this._loadbalancer.close) {
+ this._loadbalancer.close();
+ }
}
}
diff --git a/lib/client/loadbalancer/base.js b/lib/client/loadbalancer/base.js
index <HASH>..<HASH> 100644
--- a/lib/client/loadbalancer/base.js
+++ b/lib/client/loadbalancer/base.js
@@ -149,6 +149,10 @@ class LoadBalancer extends Base {
getWeight(address) {
return this.addressGroup.getWeight(address);
}
+
+ close() {
+ // do nothing here, for override
+ }
}
module.exports = LoadBalancer;
|
feat: do loadBalancer close when address_group close
|
alipay_sofa-rpc-node
|
train
|
js,js
|
e8bdbd2b38c654b5c7f6e222438868a0df3c36d2
|
diff --git a/src/bots/actions.js b/src/bots/actions.js
index <HASH>..<HASH> 100644
--- a/src/bots/actions.js
+++ b/src/bots/actions.js
@@ -2,7 +2,7 @@ var timeoutDuration = 20000;
var config = function (cwd) {
var template = this.plugins.template;
- var xpath = casper.plugins.xpath;
+ var xpath = this.plugins.xpath;
var actions = {
assert: require('./actions/assert.js').bind(this),
capture: require('./actions/capture.js').bind(this),
|
fix: use this instead of casper
|
damonjs_damon
|
train
|
js
|
be6f51e9e4d5f1cef1ae1d856252d1b90a0727f9
|
diff --git a/src/core/serialize.js b/src/core/serialize.js
index <HASH>..<HASH> 100644
--- a/src/core/serialize.js
+++ b/src/core/serialize.js
@@ -36,7 +36,7 @@ export default function serialize(arg1, arg2) {
}
export function checkStarSchemaInvariant(propDef) {
- invariant(propDef === true || propDef.pattern, `prop schema '*' can only be used with 'true' or a prop def with a 'pattern': ${JSON.stringify(propDef)}`)
+ invariant(propDef === true || propDef.pattern, "prop schema '*' can only be used with 'true' or a prop def with a 'pattern': " + JSON.stringify(propDef))
}
export function serializeWithSchema(schema, obj) {
|
fix: Fix interpolation problem with IE<I>
Closes #<I>
|
mobxjs_serializr
|
train
|
js
|
40af9aba81b543c07e1001ec524a744569d89a1d
|
diff --git a/packages/xgplayer/src/control/progress.js b/packages/xgplayer/src/control/progress.js
index <HASH>..<HASH> 100755
--- a/packages/xgplayer/src/control/progress.js
+++ b/packages/xgplayer/src/control/progress.js
@@ -91,6 +91,7 @@ progress = function () {
let containerWidth = container.getBoundingClientRect().width
let compute = function (e) {
let now = (e.clientX - containerLeft) / containerWidth * player.duration
+ now = now < 0 ? 0 : now
point.textContent = util.format(now)
let pointWidth = point.getBoundingClientRect().width
if (player.config.thumbnail) {
|
fix: fix time when computed now < 0
|
bytedance_xgplayer
|
train
|
js
|
0789398b345f4330fc7ae22a95551ee5d487ab0a
|
diff --git a/src/Resource/MoipResource.php b/src/Resource/MoipResource.php
index <HASH>..<HASH> 100644
--- a/src/Resource/MoipResource.php
+++ b/src/Resource/MoipResource.php
@@ -234,10 +234,8 @@ abstract class MoipResource implements JsonSerializable
$body = null;
if ($payload !== null) {
$body = json_encode($payload, JSON_UNESCAPED_SLASHES);
- if ($body) { // if it's json serializable
- if (!isset($headers['Content-Type'])) {
- $headers['Content-Type'] = 'application/json';
- }
+ if ($body) { // if it's json serializable
+ $headers['Content-Type'] = 'application/json';
} else {
$body = null;
}
|
refactor(MoipResource): reduces method's complexity
|
wirecardBrasil_moip-sdk-php
|
train
|
php
|
800454a3c7a059f15275b5078eace167ca142758
|
diff --git a/Model/File/Writer/YamlWriter.php b/Model/File/Writer/YamlWriter.php
index <HASH>..<HASH> 100644
--- a/Model/File/Writer/YamlWriter.php
+++ b/Model/File/Writer/YamlWriter.php
@@ -94,6 +94,10 @@ class YamlWriter extends AbstractWriter
*/
private function prepareValue($value)
{
+ if ($value === null) {
+ return '';
+ }
+
if (is_numeric($value)) {
return $value;
}
|
fix: php<I> compatibility for yaml export with null values
|
semaio_Magento2-ConfigImportExport
|
train
|
php
|
4a89b7140a81ff3a2e51a846cf4311cd164fe12a
|
diff --git a/web/src/main/webapp/my-app/marketplace/controllers.js b/web/src/main/webapp/my-app/marketplace/controllers.js
index <HASH>..<HASH> 100644
--- a/web/src/main/webapp/my-app/marketplace/controllers.js
+++ b/web/src/main/webapp/my-app/marketplace/controllers.js
@@ -128,11 +128,11 @@ define(['angular', 'jquery', 'require'], function(angular, $, require) {
}
if (filter === 'az') {
$scope.selectedFilter = 'az';
- $scope.sortParameter = 'name';
+ $scope.sortParameter = 'title';
}
if (filter === 'category') {
$scope.selectedFilter = 'category';
- $scope.sortParameter = 'name';
+ $scope.sortParameter = 'title';
$scope.showCategories = true;
}
@@ -251,8 +251,8 @@ define(['angular', 'jquery', 'require'], function(angular, $, require) {
// Default filter is to sort by category for
// marketplaceDetails back to marketplace
$scope.selectedFilter = 'category';
- // To sort by category, angular will use name to filter
- $scope.sortParameter = 'name';
+ // To sort by category, angular will use title to filter
+ $scope.sortParameter = 'title';
// Show category selection div by default
$scope.showCategories = true;
|
fix: a-z sort app dir browse by portlet.title not portlet.name
title is the user-facing label. name is an internal, admin-facing label. Usually they're the same and it doesnt matter. When they differ, bug yielded a-z sorting by a label not visible to or understandable by end user.
|
uPortal-Project_uportal-home
|
train
|
js
|
3c2abed5f59b299b229fcb1666a038cf389d5a09
|
diff --git a/setup.py b/setup.py
index <HASH>..<HASH> 100755
--- a/setup.py
+++ b/setup.py
@@ -18,7 +18,7 @@ if __name__ == '__main__':
download_url='http://github.com/dagwieers/vmguestlib/archive/0.1.2.tar.gz',
description='Python API for interacting with VMware\'s VMGuestLib SDK',
license = 'GPLv2',
- install_requires=['ctypes', ],
+ install_requires=[],
py_modules = ['vmguestlib', ],
scripts=[ 'vmguest-stats', ],
keywords = ['Virtual', 'vmware', 'ESX', 'ESXi', 'VMGuestLib', 'SDK', 'API'],
|
fix: remove ctypes requirement since ctypes is already a builtin lib in python (#8)
|
dagwieers_vmguestlib
|
train
|
py
|
ab84662ecf011520f39fff8cced644f701a23c3b
|
diff --git a/src/area/index.js b/src/area/index.js
index <HASH>..<HASH> 100644
--- a/src/area/index.js
+++ b/src/area/index.js
@@ -185,10 +185,8 @@ export default createComponent({
this.code = values[index].code;
this.setValues();
- let getValues = picker.getValues();
- getValues = this.parseOutputValues(getValues);
-
- this.$emit('change', picker, getValues, index);
+ const parsedValues = this.parseOutputValues(picker.getValues());
+ this.$emit('change', picker, parsedValues, index);
},
onConfirm(values, index) {
|
chore(Area): rename variable (#<I>)
|
youzan_vant
|
train
|
js
|
d70ffdfe32388d2d6a1d29f9d478df9d50c00b6a
|
diff --git a/src/geshi/cfm.php b/src/geshi/cfm.php
index <HASH>..<HASH> 100644
--- a/src/geshi/cfm.php
+++ b/src/geshi/cfm.php
@@ -239,7 +239,7 @@ $language_data = array (
)
),
'SYMBOLS' => array(
- '/', '=', '&', '{', '}', '(', ')', '[', ']', '<', '>'
+ '/', '=', '{', '}', '(', ')', '[', ']', '<', '>', '&'
),
'CASE_SENSITIVE' => array(
GESHI_COMMENTS => false,
@@ -340,6 +340,10 @@ $language_data = array (
2 => array(
'DISALLOWED_BEFORE' => 'a-zA-Z0-9\$_\|\#>|^', // allow ; before keywords
'DISALLOWED_AFTER' => 'a-zA-Z0-9_\|%\\-', // allow & after keywords
+ ),
+ 7 => array(
+ 'DISALLOWED_BEFORE' => 'a-zA-Z0-9\$_\|\#>&|^', // allow ; before keywords
+ 'DISALLOWED_AFTER' => 'a-zA-Z0-9_\|%\\-', // allow & after keywords
)
)
)
|
fix: Broken rendering of < and > due to too loose bound checks
|
GeSHi_geshi-1.0
|
train
|
php
|
6a11f61a48b3ed72036f6cdafff9a2766b1fd09e
|
diff --git a/packages/node_modules/@ciscospark/spark-core/src/lib/credentials/credentials.js b/packages/node_modules/@ciscospark/spark-core/src/lib/credentials/credentials.js
index <HASH>..<HASH> 100644
--- a/packages/node_modules/@ciscospark/spark-core/src/lib/credentials/credentials.js
+++ b/packages/node_modules/@ciscospark/spark-core/src/lib/credentials/credentials.js
@@ -247,8 +247,6 @@ const Credentials = SparkPlugin.extend({
});
}))
.then(() => {
- this.logger.info(`this.supertoken${this.supertoken} this.canRefresh${this.canRefresh}`);
-
if (!this.canAuthorize) {
this.logger.info('credentials: cannot produce an access token from current state');
return Promise.reject(new Error('Current state cannot produce an access token'));
|
feat(federation): make federation config changes
|
webex_spark-js-sdk
|
train
|
js
|
a9f69f9ddc738db804ea3fd3e8b8b8a38aa6619f
|
diff --git a/packages/netlify-cms-backend-gitlab/src/API.js b/packages/netlify-cms-backend-gitlab/src/API.js
index <HASH>..<HASH> 100644
--- a/packages/netlify-cms-backend-gitlab/src/API.js
+++ b/packages/netlify-cms-backend-gitlab/src/API.js
@@ -119,7 +119,12 @@ export default class API {
.map(str => str.trim().split(';'))
.map(([linkStr, keyStr]) => [
keyStr.match(/rel="(.*?)"/)[1],
- unsentRequest.fromURL(linkStr.trim().match(/<(.*?)>/)[1]),
+ unsentRequest.fromURL(
+ linkStr
+ .trim()
+ .match(/<(.*?)>/)[1]
+ .replace(/\+/g, '%20'),
+ ),
])
.update(list => Map(list));
const actions = links
|
fix(backend-gitlab): support folder names with whitespace (#<I>)
|
netlify_netlify-cms
|
train
|
js
|
0005f8e7b318af7801d149320b7de19a22515afa
|
diff --git a/public/app/plugins/datasource/elasticsearch/query_builder.js b/public/app/plugins/datasource/elasticsearch/query_builder.js
index <HASH>..<HASH> 100644
--- a/public/app/plugins/datasource/elasticsearch/query_builder.js
+++ b/public/app/plugins/datasource/elasticsearch/query_builder.js
@@ -1,8 +1,7 @@
define([
'./query_def',
- 'lodash',
],
-function (queryDef, _) {
+function (queryDef) {
'use strict';
function ElasticQueryBuilder(options) {
|
fix: fixed jshint issue
|
grafana_grafana
|
train
|
js
|
1f170417c3af18bc227034d76da8213f3ece00eb
|
diff --git a/packages/hover-react/src/index.js b/packages/hover-react/src/index.js
index <HASH>..<HASH> 100644
--- a/packages/hover-react/src/index.js
+++ b/packages/hover-react/src/index.js
@@ -35,11 +35,11 @@ const Wrapper = styled.span`
text-decoration: inherit;
position: relative;
display: inline-block;
+ padding-top: var(--microlink-gap, 15px);
&:hover ${PopOver} {
visibility: visible;
opacity: 1;
- margin-bottom: 15px;
}
`
|
fix: bug with transition (#<I>)
|
microlinkhq_sdk
|
train
|
js
|
50c4558c5ad48975f64f581199a425e099c686a7
|
diff --git a/engine-rest/engine-rest/src/main/java/org/camunda/bpm/engine/rest/dto/task/TaskQueryDto.java b/engine-rest/engine-rest/src/main/java/org/camunda/bpm/engine/rest/dto/task/TaskQueryDto.java
index <HASH>..<HASH> 100644
--- a/engine-rest/engine-rest/src/main/java/org/camunda/bpm/engine/rest/dto/task/TaskQueryDto.java
+++ b/engine-rest/engine-rest/src/main/java/org/camunda/bpm/engine/rest/dto/task/TaskQueryDto.java
@@ -768,7 +768,7 @@ public class TaskQueryDto extends AbstractQueryDto<TaskQuery> {
}
public String getNameNotEqual() {
- return name;
+ return nameNotEqual;
}
public String getNameLike() {
|
fix(rest): property "name" is returned instead of "nameNotEqual"
related to CAM-<I>
|
camunda_camunda-bpm-platform
|
train
|
java
|
264976d81a37d06ad64242afa28bc8167cfd1efa
|
diff --git a/Console/PruneCommand.php b/Console/PruneCommand.php
index <HASH>..<HASH> 100644
--- a/Console/PruneCommand.php
+++ b/Console/PruneCommand.php
@@ -87,7 +87,9 @@ class PruneCommand extends Command
protected function models()
{
if (! empty($models = $this->option('model'))) {
- return collect($models);
+ return collect($models)->filter(function ($model) {
+ return class_exists($model);
+ })->values();
}
$except = $this->option('except');
@@ -111,6 +113,8 @@ class PruneCommand extends Command
});
})->filter(function ($model) {
return $this->isPrunable($model);
+ })->filter(function ($model) {
+ return class_exists($model);
})->values();
}
|
fix: PruneCommand finding its usage within other traits (#<I>)
This addresses an edge case where using the Prunable trait within another trait (due to several reasons like modifying behaviour, removing duplication, etc..) it was breaking the PruneCommand from behaving properly ince the trait was being detected as a class.
|
illuminate_database
|
train
|
php
|
9f61c71e6cd9334d31e4d449387f8653702f1b44
|
diff --git a/docs/app/utils.js b/docs/app/utils.js
index <HASH>..<HASH> 100644
--- a/docs/app/utils.js
+++ b/docs/app/utils.js
@@ -18,7 +18,7 @@ export const parentComponents = _.flow(
/**
* Get the Webpack Context for all doc site examples.
*/
-export const exampleContext = require.context('docs/app/Examples/', true, /(\w+Example\w+|index)\.js$/)
+export const exampleContext = require.context('docs/app/Examples/', true, /(\w+Example\w*|index)\.js$/)
export const repoURL = 'https://github.com/Semantic-Org/Semantic-UI-React'
export const semanticUIDocsURL = 'http://semantic-ui.com/'
|
fix(docs): more permissive exampleContext regex (#<I>)
|
Semantic-Org_Semantic-UI-React
|
train
|
js
|
1ade38410ec849a4dd582afaf442235e2cb08ccf
|
diff --git a/setup.py b/setup.py
index <HASH>..<HASH> 100644
--- a/setup.py
+++ b/setup.py
@@ -48,6 +48,7 @@ setup(
"backoff-stubs",
"twine",
"parameterized",
+ "pylint",
],
"docs": ["sphinx"],
},
|
chore: pylint
|
censys_censys-python
|
train
|
py
|
e0cc42236e3d080a515fd6266a3668ab417484bc
|
diff --git a/app/state.js b/app/state.js
index <HASH>..<HASH> 100644
--- a/app/state.js
+++ b/app/state.js
@@ -26,9 +26,6 @@ const initialState = {
x: 320,
y: 120,
},
- props: {
- brightness: 0.67,
- },
},
2: {
id: 2,
|
refactor(state): remove excess property
|
xodio_xod
|
train
|
js
|
46b39a578ed2a650343ca5d2baaec9407df1fd24
|
diff --git a/components/TextInput.js b/components/TextInput.js
index <HASH>..<HASH> 100644
--- a/components/TextInput.js
+++ b/components/TextInput.js
@@ -25,7 +25,7 @@ const defaultProps = {
onChange: () => {},
onClick: () => {},
invalid: false,
- labelText: 'Provide labelText',
+ labelText: '',
invalidText: 'Provide invalidText'
};
|
fix(Slider): provide LabelText for TextInput from Slider or hide it (#<I>)
* fix(Slider): provide LabelText for TextInput from Slider or hide it
* fix(Slider): storybook
* fix(Slider): storybook desc
* fix(Slider): undo
|
carbon-design-system_carbon-components-react
|
train
|
js
|
21c25210d743aa2b59da4c3df752f1db8021d04c
|
diff --git a/lib/manager/pip_setup/extract.js b/lib/manager/pip_setup/extract.js
index <HASH>..<HASH> 100644
--- a/lib/manager/pip_setup/extract.js
+++ b/lib/manager/pip_setup/extract.js
@@ -58,12 +58,10 @@ async function extractSetupFile(content, packageFile, config) {
err.message.includes('No such file or directory') &&
!config.gitFs
) {
- logger.debug({ err }, 'setup.py extraction error');
- throw new Error(
+ logger.warn(
'File not found error when extracting setup.py. Ask your Renovate administrator to enable gitFs and try again'
);
}
- logger.warn({ err }, 'Error extracting setup.py');
throw err;
}
// istanbul ignore if
@@ -82,7 +80,7 @@ async function extractPackageFile(content, packageFile, config) {
try {
setup = await extractSetupFile(content, packageFile, config);
} catch (err) {
- logger.warn({ err }, 'Failed to read setup file');
+ logger.warn({ err }, 'Failed to read setup.py file');
return null;
}
const requires = [];
|
refactor: reduce setup.py warnings
|
renovatebot_renovate
|
train
|
js
|
d4d8b964c1d907a0220f59b7b3d054da9c9d845b
|
diff --git a/registry/txt.go b/registry/txt.go
index <HASH>..<HASH> 100644
--- a/registry/txt.go
+++ b/registry/txt.go
@@ -94,7 +94,6 @@ func (im *TXTRegistry) Records() ([]*endpoint.Endpoint, error) {
return nil, err
}
endpointDNSName := im.mapper.toEndpointName(record.DNSName)
- log.Debugf("Parsed endpoint dns name is %s", endpointDNSName)
labelMap[endpointDNSName] = labels
}
|
chore: remove additional debug output from txt registry
|
kubernetes-incubator_external-dns
|
train
|
go
|
0bde3dca152f48c18c3323c5515e352a05041cb1
|
diff --git a/example/consumer.js b/example/consumer.js
index <HASH>..<HASH> 100644
--- a/example/consumer.js
+++ b/example/consumer.js
@@ -1,7 +1,7 @@
/**
* XadillaX created at 2015-12-18 17:24:31 With ♥
*
- * Copyright (c) 2015 Souche.com, all rights
+ * Copyright (c) 2017 Souche.com, all rights
* reserved.
*/
"use strict";
diff --git a/example/producer.js b/example/producer.js
index <HASH>..<HASH> 100644
--- a/example/producer.js
+++ b/example/producer.js
@@ -1,7 +1,7 @@
/**
* XadillaX created at 2015-12-19 23:37:40 With ♥
*
- * Copyright (c) 2015 Souche.com, all rights
+ * Copyright (c) 2017 Souche.com, all rights
* reserved.
*/
"use strict";
|
refactor: update example's copyright
|
XadillaX_aliyun-ons
|
train
|
js,js
|
dea4911688d739e1a8e4f596cf0876b93617cc34
|
diff --git a/src/index.js b/src/index.js
index <HASH>..<HASH> 100644
--- a/src/index.js
+++ b/src/index.js
@@ -236,8 +236,14 @@ export default class Trilogy {
if (isPlainObject(column)) {
if (!column.name) return
if (!column.type || !(column.type in table)) column.type = 'text'
- let partial = table[column.type](column.name)
-
+ if ('unique' in column && column.unique === 'inline') {
+ // bypass knex's usual unique method
+ column['__TYPE__'] = `${column.type} unique`
+ column.type = 'specificType'
+ delete column.unique
+ }
+
+ let partial = table[column.type](column.name, column['__TYPE__'])
map(column, (attr, prop: string) => {
// name & type are handled above
if (prop === 'name' || prop === 'type') return
@@ -245,6 +251,7 @@ export default class Trilogy {
// handle methods that take no arguments
switch (prop) {
+ case 'unique':
case 'primary':
case 'notNull':
case 'notNullable':
|
fix(createTable): unique column indices
Fix the creation of unique indices on columns. Add 'inline' option for unique columns which specifiies the unique flag along with the column type in the statement.
|
citycide_trilogy
|
train
|
js
|
0f5958976d944d868508e2b84b734010de03bfa6
|
diff --git a/Spanner/owlbot.py b/Spanner/owlbot.py
index <HASH>..<HASH> 100644
--- a/Spanner/owlbot.py
+++ b/Spanner/owlbot.py
@@ -31,7 +31,13 @@ dest = Path().resolve()
# Added so that we can pass copy_excludes in the owlbot_main() call
_tracked_paths.add(src)
-php.owlbot_main(src=src, dest=dest)
+php.owlbot_main(
+ src=src,
+ dest=dest,
+ copy_excludes=[
+ src / "*/src/V1/SpannerClient.php"
+ ]
+)
|
fix: [Spanner] exclude partial veneer SpannerClient from owlbot (#<I>)
|
googleapis_google-cloud-php
|
train
|
py
|
250530777054f713fb22b88fd25c22c9c67ac359
|
diff --git a/src/aria/jsunit/SynEvents.js b/src/aria/jsunit/SynEvents.js
index <HASH>..<HASH> 100644
--- a/src/aria/jsunit/SynEvents.js
+++ b/src/aria/jsunit/SynEvents.js
@@ -262,27 +262,6 @@ module.exports = Aria.classDefinition({
return res;
},
- _resolveGeometry : function (geometry) {
- var domUtils = aria.utils.Dom;
- var res;
- if (ariaUtilsType.isString(geometry)) {
- // it is a string, resolve it to an HTML element
- geometry = this._resolveHTMLElement(geometry);
- }
- if (ariaUtilsType.isHTMLElement(geometry)) {
- res = domUtils.getGeometry(geometry);
- // TODO: check if the item is really visible
- } else if (geometry.hasOwnProperty("x") && geometry.hasOwnProperty("y") &&
- geometry.hasOwnProperty("width") && geometry.hasOwnProperty("height")) {
- res = geometry;
- } else {
- // FIXME: log error correctly
- this.$logError("Invalid position.");
- return null;
- }
- return res;
- },
-
_resolveHTMLElement : function (element) {
var res;
if (ariaUtilsType.isString(element)) {
|
fix: removing useless code in aria.jsunit.SynEvents
|
ariatemplates_ariatemplates
|
train
|
js
|
1e7d8ee7e95b44c405e1b20923e8ab24ac9d9a54
|
diff --git a/packages/xod-client/src/utils/ramda.js b/packages/xod-client/src/utils/ramda.js
index <HASH>..<HASH> 100644
--- a/packages/xod-client/src/utils/ramda.js
+++ b/packages/xod-client/src/utils/ramda.js
@@ -5,7 +5,7 @@ export const notNil = R.complement(R.isNil);
export const noop = R.always(undefined);
// :: [propName] -> Object -> Bool
-export const propsAreFalsy = R.curry(R.pipe(
- R.props,
- R.all(R.not)
+export const propsAreFalsy = R.curry(R.compose(
+ R.all(R.not),
+ R.props
));
|
refactor(client): use compose instead of pipe in propsAreFalsy
|
xodio_xod
|
train
|
js
|
91790d1e55647721bccd31ed4230c3a669b7c4ce
|
diff --git a/helpers/form/class.FormContainer.php b/helpers/form/class.FormContainer.php
index <HASH>..<HASH> 100644
--- a/helpers/form/class.FormContainer.php
+++ b/helpers/form/class.FormContainer.php
@@ -252,12 +252,10 @@ abstract class tao_helpers_form_FormContainer
): void {
$property = $this->getProperty(tao_helpers_Uri::decode($element->getName()));
- foreach ($validators as $index => $validator) {
+ foreach ($validators as &$validator) {
if ($validator instanceof CrossPropertyEvaluationAwareInterface) {
- $uniqueValidator = clone $validator;
- $uniqueValidator->setProperty($property);
-
- $validators[$index] = $uniqueValidator;
+ $validator = clone $validator;
+ $validator->setProperty($property);
}
}
}
|
refactor: improve cloning
|
oat-sa_tao-core
|
train
|
php
|
98b9bf135a3600901556daffbad0790827dd7143
|
diff --git a/karma.conf.js b/karma.conf.js
index <HASH>..<HASH> 100644
--- a/karma.conf.js
+++ b/karma.conf.js
@@ -15,11 +15,11 @@ module.exports = function(config) {
loaders: [{
test: /\.js$/,
exclude: /node_modules/,
- loader: 'babel'
+ loader: 'babel-loader'
}, {
test: /\.js$/,
include: path.resolve('src/'),
- loader: 'isparta'
+ loader: 'isparta-loader'
}]
}
},
diff --git a/webpack.config.js b/webpack.config.js
index <HASH>..<HASH> 100644
--- a/webpack.config.js
+++ b/webpack.config.js
@@ -11,7 +11,7 @@ module.exports = {
loaders: [{
test: /\.js$/,
exclude: /node_modules/,
- loader: 'babel'
+ loader: 'babel-loader'
}, {
test: /\.css$/,
loader: 'style-loader!css-loader'
|
fix(webpack): fix loader names for latest webpack
|
willsoto_angular-chartist.js
|
train
|
js,js
|
d08591021ee5b2626a9c0929fbf2a5dc210040b7
|
diff --git a/test/specs/modules/Dropdown/Dropdown-test.js b/test/specs/modules/Dropdown/Dropdown-test.js
index <HASH>..<HASH> 100644
--- a/test/specs/modules/Dropdown/Dropdown-test.js
+++ b/test/specs/modules/Dropdown/Dropdown-test.js
@@ -973,7 +973,7 @@ describe('Dropdown', () => {
{ value: 0, text: 'foo' },
{ value: 1, text: 'foe' },
]
- wrapperMount(<Dropdown options={searchOptions} selection />)
+ wrapperMount(<Dropdown options={searchOptions} search selection />)
// open and simulate search
wrapper
@@ -984,13 +984,10 @@ describe('Dropdown', () => {
domEvent.keyDown(document, { key: 'ArrowDown' })
domEvent.keyDown(document, { key: 'Enter' })
- const item = wrapper
- .find('.selected')
-
// text updated
wrapper
.find('div.text')
- .should.contain.text(item.text())
+ .should.contain.text('foe')
})
it('displays if value is 0', () => {
const text = faker.hacker.noun()
|
test(Dropdown): fix multiple search text assertion
|
Semantic-Org_Semantic-UI-React
|
train
|
js
|
e0c260cf728c5802d26bf8b2ae6ba4488bdc9349
|
diff --git a/src/directives/mwlCalendarHourList.js b/src/directives/mwlCalendarHourList.js
index <HASH>..<HASH> 100644
--- a/src/directives/mwlCalendarHourList.js
+++ b/src/directives/mwlCalendarHourList.js
@@ -61,7 +61,7 @@ angular
};
vm.getClickedDate = function(baseDate, minutes, days) {
- return moment(baseDate).clone().add(minutes, 'minutes').add(days || 0, 'days').toDate();
+ return moment(baseDate).clone().startOf('hour').add(minutes, 'minutes').add(days || 0, 'days').toDate();
};
vm.onDragSelectStart = function(date, dayIndex) {
|
fix(onDateRangeSelect): fix behaviour after bug was introduced in previous commit
|
mattlewis92_angular-bootstrap-calendar
|
train
|
js
|
fa1679b8443e2074fcbd71028417c9ce8d1934e7
|
diff --git a/admin/starter/tests/unit/HealthTest.php b/admin/starter/tests/unit/HealthTest.php
index <HASH>..<HASH> 100644
--- a/admin/starter/tests/unit/HealthTest.php
+++ b/admin/starter/tests/unit/HealthTest.php
@@ -21,7 +21,7 @@ class HealthTest extends \CodeIgniter\Test\CIUnitTestCase
// First check in .env
if (is_file(HOMEPATH . '.env'))
{
- $env = (bool) preg_grep("/^app\.baseURL = './", file(HOMEPATH . '.env'));
+ $env = (bool) preg_grep('/^app\.baseURL = ./', file(HOMEPATH . '.env'));
}
// Then check the actual config file
|
test: fix regexp, remove unneeded "'"
|
codeigniter4_CodeIgniter4
|
train
|
php
|
a9907565358fccf1a79b1401d1b3e347e87b16fb
|
diff --git a/src/Common/GeneratorFieldRelation.php b/src/Common/GeneratorFieldRelation.php
index <HASH>..<HASH> 100644
--- a/src/Common/GeneratorFieldRelation.php
+++ b/src/Common/GeneratorFieldRelation.php
@@ -24,9 +24,6 @@ class GeneratorFieldRelation
$modelName = $this->inputs[0];
switch ($this->type) {
case '1t1':
- if (isset($this->inputs[1])) {
- $modelName = str_replace('_id', '', strtolower($this->inputs[1]));
- }
$functionName = camel_case($modelName);
$relation = 'hasOne';
$relationClass = 'HasOne';
diff --git a/src/Generators/ModelGenerator.php b/src/Generators/ModelGenerator.php
index <HASH>..<HASH> 100755
--- a/src/Generators/ModelGenerator.php
+++ b/src/Generators/ModelGenerator.php
@@ -155,6 +155,7 @@ class ModelGenerator extends BaseGenerator
case 'datetime':
return 'string|\Carbon\Carbon';
case '1t1':
+ return '\\'.$this->commandData->config->nsModel.'\\'.$relation->inputs[0].' '.camel_case($relation->inputs[0]);
case 'mt1':
if (isset($relation->inputs[1])) {
$relationName = str_replace('_id', '', strtolower($relation->inputs[1]));
|
fix(relationship): fix hasOne relationship method name (#<I>)
|
InfyOmLabs_laravel-generator
|
train
|
php,php
|
1732d2b5acb77dae2b2f2cce8d5425653889c37e
|
diff --git a/views/js/qtiCreator/widgets/static/figure/Widget.js b/views/js/qtiCreator/widgets/static/figure/Widget.js
index <HASH>..<HASH> 100755
--- a/views/js/qtiCreator/widgets/static/figure/Widget.js
+++ b/views/js/qtiCreator/widgets/static/figure/Widget.js
@@ -64,10 +64,18 @@ define([
helper.buildBlockContainer(this);
const img = _.find(this.element.getBody().elements, elem => elem.is('img'));
const $img = this.$original.find('img');
- this.$container.css({
- width: img.attr('width'),
- height: img.attr('height')
- });
+ if (img.attr('width') && !/[0-9]+%/.test(img.attr('width'))) {
+ // absolute size
+ this.$container.css({
+ width: img.attr('width')
+ });
+ } else {
+ // responsive
+ this.$container.css({
+ width: img.attr('width'),
+ height: img.attr('height')
+ });
+ }
if ($img[0]) {
$img[0].setAttribute('width', '100%');
$img[0].removeAttribute('style');
|
fix: render figure image with absolute size
|
oat-sa_extension-tao-mediamanager
|
train
|
js
|
096b04b2a9c44ace439ef92959d877c3c923f5ef
|
diff --git a/lib/parser.js b/lib/parser.js
index <HASH>..<HASH> 100644
--- a/lib/parser.js
+++ b/lib/parser.js
@@ -72,7 +72,7 @@ CronParser.parseString = function parseString (data) {
for (var i = 0, c = blocks.length; i < c; i++) {
var block = blocks[i];
var matches = null;
- var entry = block.replace(/^\s+|\s+$/g, ''); // Remove surrounding spaces
+ var entry = block.trim(); // Remove surrounding spaces
if (entry.length > 0) {
if (entry.match(/^#/)) { // Comment
|
fix: raw block check from regex to trim method (#<I>)
|
harrisiirak_cron-parser
|
train
|
js
|
bc120cce79c8b0facea3c23c6602e1492ad4ff6b
|
diff --git a/test/k8sT/Services.go b/test/k8sT/Services.go
index <HASH>..<HASH> 100644
--- a/test/k8sT/Services.go
+++ b/test/k8sT/Services.go
@@ -528,8 +528,7 @@ var _ = Describe("K8sServicesTest", func() {
res = kubectl.CiliumExec(pod, "cilium bpf ct flush global")
res.ExpectSuccess("Unable to flush CT maps")
res = kubectl.CiliumExec(pod, "cilium bpf nat list | grep 64000")
- res.ExpectSuccess("Unable to list NAT entries")
- Expect(res.GetStdOut()).Should(BeEmpty(), "NAT entry was not evicted")
+ res.ExpectFail("NAT entry was not evicted")
})
})
})
|
test: Fix DSR NAT GC test
Previously, the test case which checked whether DSR NAT entry was
successfully evicted expected the cmd ".... | grep $NAT_ENTRY_PORT"
to succeed, which is wrong, as grep returns != 0 when no line can
be matched by grep.
|
cilium_cilium
|
train
|
go
|
4b05a5fa4f00c9f385f6100e938e3d37a37e5ecf
|
diff --git a/lib/cli.js b/lib/cli.js
index <HASH>..<HASH> 100644
--- a/lib/cli.js
+++ b/lib/cli.js
@@ -1,7 +1,7 @@
'use strict';
-const gitbook = require('gitbook');
const yargs = require('yargs');
+const gitbook = require('./gitbook');
function buildCommands() {
for (const command of gitbook.commands) {
|
fix(cli): fixup "bail out if gitbook not found"
Require the wrapper added in <I>bd3ae instead of requiring GitBook
directly.
|
aqrln_gitbook-commander
|
train
|
js
|
b7b70855c94935b845bbf2ba183a7456e754ba06
|
diff --git a/ts/blueprints/ember-cli-typescript/index.js b/ts/blueprints/ember-cli-typescript/index.js
index <HASH>..<HASH> 100644
--- a/ts/blueprints/ember-cli-typescript/index.js
+++ b/ts/blueprints/ember-cli-typescript/index.js
@@ -190,9 +190,9 @@ module.exports = {
let pkg = JSON.parse(fs.readFileSync(pkgPath, 'utf-8'));
- // Really `prepack` and `postpack` would be ideal, but yarn doesn't execute those when publishing
- this._addScript(pkg.scripts, 'prepublishOnly', 'ember ts:precompile');
- this._addScript(pkg.scripts, 'postpublish', 'ember ts:clean');
+ // As of https://github.com/yarnpkg/yarn/pull/5712 yarn runs `prepack` and `postpack` when publishing
+ this._addScript(pkg.scripts, 'prepack', 'ember ts:precompile');
+ this._addScript(pkg.scripts, 'postpack', 'ember ts:clean');
// avoid being placed in devDependencies
if (pkg.devDependencies[ADDON_NAME]) {
|
feat: use prepack and postpack instead of prepublishOnly and postpublish
|
typed-ember_ember-cli-typescript
|
train
|
js
|
9309a263f4c2457cd6e43b1b55b238317d8a7546
|
diff --git a/lib/tools/system-calls.js b/lib/tools/system-calls.js
index <HASH>..<HASH> 100644
--- a/lib/tools/system-calls.js
+++ b/lib/tools/system-calls.js
@@ -72,8 +72,13 @@ systemCallMethods.getBinaryFromSdkRoot = async function getBinaryFromSdkRoot (bi
}
const fullBinaryName = this.getBinaryNameForOS(binaryName);
- const binaryLocs = ['platform-tools', 'emulator', 'tools', `tools${path.sep}bin`]
- .map((x) => path.resolve(this.sdkRoot, x, fullBinaryName));
+ const binaryLocs = [
+ 'platform-tools',
+ 'emulator',
+ ['cmdline-tools', 'latest', 'bin'],
+ 'tools',
+ ['tools', 'bin']
+ ].map((x) => path.resolve(this.sdkRoot, ...(_.isArray(x) ? x : [x]), fullBinaryName));
// get subpaths for currently installed build tool directories
let buildToolsDirs = await getBuildToolsDirs(this.sdkRoot);
if (this.buildToolsVersion) {
|
feat: add cmdline-tools path in binary search (#<I>)
* feat: support cmdline-tools
* prior newer version
* improve to use array for path
* fix lint
|
appium_appium-adb
|
train
|
js
|
55ef7974a72180f57853bf401ed8a0bb14d202a7
|
diff --git a/models/classes/media/LocalItemSource.php b/models/classes/media/LocalItemSource.php
index <HASH>..<HASH> 100644
--- a/models/classes/media/LocalItemSource.php
+++ b/models/classes/media/LocalItemSource.php
@@ -297,6 +297,7 @@ class LocalItemSource implements MediaManagement
'path' => $parentLink,
'label' => $label,
'childrenLimit' => $childrenLimit,
+ 'total' => 0,
];
if ($depth <= 0) {
|
fix: preliminary crash prevented on empty local directories
|
oat-sa_extension-tao-item
|
train
|
php
|
fab5ab688289c1dab0f87d73255840e601667d87
|
diff --git a/src/components/Separator.js b/src/components/Separator.js
index <HASH>..<HASH> 100644
--- a/src/components/Separator.js
+++ b/src/components/Separator.js
@@ -19,7 +19,7 @@ export default class Separator extends Component {
constructor(properties) {
super(properties);
this.state = {
- childProps: sanitizeChildProps(properties)
+ childProps: sanitizeChildProps(properties),
};
}
@@ -28,9 +28,9 @@ export default class Separator extends Component {
static propTypes = {
children: React.PropTypes.oneOfType([
React.PropTypes.arrayOf(React.PropTypes.node),
- React.PropTypes.node
+ React.PropTypes.node,
]),
- style: React.PropTypes.object
+ style: React.PropTypes.object,
};
/**
@@ -44,7 +44,7 @@ export default class Separator extends Component {
render() {
const computedStyle = {
...style.style,
- ...this.props.style
+ ...this.props.style,
};
return (
|
chore(Separator): comply to jscs standard
|
nikgraf_belle
|
train
|
js
|
b9044ef332a2d04df110b40b27e9c172c505a856
|
diff --git a/benchbuild/environments/adapters/common.py b/benchbuild/environments/adapters/common.py
index <HASH>..<HASH> 100644
--- a/benchbuild/environments/adapters/common.py
+++ b/benchbuild/environments/adapters/common.py
@@ -37,10 +37,10 @@ def container_cmd(base: BaseCommand) -> BaseCommand:
runroot = CFG['container']['runroot']
if path_longer_than_50_chars(str(root)):
- LOG.error(root.to_env_dict(), __MSG_SHORTER_PATH_REQUIRED)
+ LOG.error(root.__to_env_var__(), __MSG_SHORTER_PATH_REQUIRED)
if path_longer_than_50_chars(str(runroot)):
- LOG.error(runroot.to_env_dict(), __MSG_SHORTER_PATH_REQUIRED)
+ LOG.error(runroot.__to_env_var__(), __MSG_SHORTER_PATH_REQUIRED)
opts = ['--root', root, '--runroot', runroot]
|
feat(environments): just print env var name as error message
|
PolyJIT_benchbuild
|
train
|
py
|
285d8ce65b2eb26eb18ec1541a5710dcd31bf186
|
diff --git a/model/ResultsService.php b/model/ResultsService.php
index <HASH>..<HASH> 100644
--- a/model/ResultsService.php
+++ b/model/ResultsService.php
@@ -601,6 +601,7 @@ class ResultsService extends OntologyClassService
$attempts = $this->splitByItemAndAttempt($itemVariables, $filter);
$variablesByItem = [];
foreach ($attempts as $time => $variables) {
+ $variablesByItem[$time] = [];
foreach ($variables as $itemVariable) {
$variable = $itemVariable->variable;
$itemCallId = $itemVariable->callIdItem;
|
fix: showing right selected answrs in result view
|
oat-sa_extension-tao-outcomeui
|
train
|
php
|
2e52efec8ed8231dc5adbe25ef3aa34e8b97ed08
|
diff --git a/src/lib/isIP.js b/src/lib/isIP.js
index <HASH>..<HASH> 100644
--- a/src/lib/isIP.js
+++ b/src/lib/isIP.js
@@ -51,14 +51,10 @@ export default function isIP(str, version = '') {
return isIP(str, 4) || isIP(str, 6);
}
if (version === '4') {
- if (!IPv4AddressRegExp.test(str)) {
- return false;
- }
- const parts = str.split('.').sort((a, b) => a - b);
- return parts[3] <= 255;
+ return IPv4AddressRegExp.test(str);
}
if (version === '6') {
- return !!IPv6AddressRegExp.test(str);
+ return IPv6AddressRegExp.test(str);
}
return false;
}
|
refactor(isIP): removed redundant check for IPv4 addresses
refactor(isIP): removed redundant !!
Closes #<I>
|
chriso_validator.js
|
train
|
js
|
46da8d708ca8af6a6753fe4ec852e10adf073f54
|
diff --git a/servlet/src/test/java/org/woelker/jimix/servlet/JimixServletIntegrationTest.java b/servlet/src/test/java/org/woelker/jimix/servlet/JimixServletIntegrationTest.java
index <HASH>..<HASH> 100644
--- a/servlet/src/test/java/org/woelker/jimix/servlet/JimixServletIntegrationTest.java
+++ b/servlet/src/test/java/org/woelker/jimix/servlet/JimixServletIntegrationTest.java
@@ -9,6 +9,7 @@ import org.eclipse.jetty.servlet.ServletContextHandler;
import org.eclipse.jetty.servlet.ServletHolder;
import org.junit.After;
import org.junit.Before;
+import org.junit.Ignore;
import org.junit.Test;
import org.openqa.selenium.By;
import org.openqa.selenium.WebDriver;
@@ -54,6 +55,7 @@ public class JimixServletIntegrationTest {
}
@Test
+ @Ignore("Disabled while react UI is being developed")
public void basicTest() throws Exception {
driver.get("http://localhost:8081/jimix/");
final WebElement element = driver.findElement(By.linkText("buzz - foo"));
|
test(servlet): Ignore integration test while react UI is being developed
|
manuel-woelker_jimix
|
train
|
java
|
28a39b9ef516cabf3d89dfd3c735540b03946c2a
|
diff --git a/packages/react/src/components/CodeSnippet/CodeSnippet.js b/packages/react/src/components/CodeSnippet/CodeSnippet.js
index <HASH>..<HASH> 100644
--- a/packages/react/src/components/CodeSnippet/CodeSnippet.js
+++ b/packages/react/src/components/CodeSnippet/CodeSnippet.js
@@ -78,6 +78,7 @@ function CodeSnippet({
</code>
</div>
<CopyButton
+ className={`${prefix}--snippet-button`}
onClick={onClick}
feedback={feedback}
iconDescription={copyButtonDescription}
|
fix(code-snippet): re-introduce snippet copy button class (#<I>)
|
carbon-design-system_carbon-components
|
train
|
js
|
1c4e3d5e7310fc6919ec765eee98be7eeedce1e3
|
diff --git a/lib/cli/src/generators/WEB-COMPONENTS/index.js b/lib/cli/src/generators/WEB-COMPONENTS/index.js
index <HASH>..<HASH> 100755
--- a/lib/cli/src/generators/WEB-COMPONENTS/index.js
+++ b/lib/cli/src/generators/WEB-COMPONENTS/index.js
@@ -14,7 +14,6 @@ export default async (npmOptions, { storyFormat }) => {
'@storybook/web-components',
'@storybook/addon-actions',
'@storybook/addon-links',
- '@storybook/addons',
'lit-html',
];
|
feat(cli): remove `@storybook/addons` from deps installed when running `sb init` in a web-component project
`@storybook/addons` is already a dependency of all `@storybook/addon-XXX` packages so there is no need to add it to the root project directly.
|
storybooks_storybook
|
train
|
js
|
a29a5d35874b04f9c3241a3d821da1a264dce475
|
diff --git a/src/Common/Console/Command/Make/Model.php b/src/Common/Console/Command/Make/Model.php
index <HASH>..<HASH> 100644
--- a/src/Common/Console/Command/Make/Model.php
+++ b/src/Common/Console/Command/Make/Model.php
@@ -123,7 +123,8 @@ class Model extends BaseMaker
*/
->validateServiceFile(static::SERVICE_RESOURCE_TOKEN)
->validateServiceFile()
- ->createPath(self::MODEL_PATH);
+ ->createPath(self::MODEL_PATH)
+ ->createPath(self::MODEL_RESOURCE_PATH);
if (!$bSkipAdmin) {
$this->createPath(self::ADMIN_PATH);
}
|
fix: Ensuring Resource path is created
|
nails_common
|
train
|
php
|
ad78cab9bd3edfe7e1d513edae7226f850c93ba8
|
diff --git a/src/Views.php b/src/Views.php
index <HASH>..<HASH> 100644
--- a/src/Views.php
+++ b/src/Views.php
@@ -155,9 +155,9 @@ class Views implements ViewsContract
}
}
- if ($this->period) {
- $query->withinPeriod($this->period);
- }
+ $query->when($this->period, function ($query, $period) {
+ $query->withinPeriod($period);
+ });
$query->collection($this->collection);
|
refactor: use when method for conditional period query scope
|
cyrildewit_eloquent-viewable
|
train
|
php
|
43b2585161c6e44763a81d6328d83d6ff9a3559e
|
diff --git a/test/test_ulog2csv.py b/test/test_ulog2csv.py
index <HASH>..<HASH> 100644
--- a/test/test_ulog2csv.py
+++ b/test/test_ulog2csv.py
@@ -21,6 +21,7 @@ class Test(unittest.TestCase):
saved_stdout = sys.stdout
with open(expected_output_file, 'r') as file_handle:
expected_output = file_handle.read().strip()
+ output = None
try:
out = StringIO()
sys.stdout = out
@@ -28,11 +29,12 @@ class Test(unittest.TestCase):
output = out.getvalue().strip()
assert output == expected_output
finally:
- sys.stdout = saved_stdout
- print("Got output:")
- print(output)
- print("\nExpected output:")
- print(expected_output)
+ if output is not None:
+ sys.stdout = saved_stdout
+ print("Got output:")
+ print(output)
+ print("\nExpected output:")
+ print(expected_output)
def test_ulog2csv(self):
tmpdir = tempfile.gettempdir()
|
test: check if output is set
if exception is thrown before setting the output, this will catch it.
|
PX4_pyulog
|
train
|
py
|
86ec98655be853313ee20d752b2e671a8786f375
|
diff --git a/src/components/btn/QBtnToggle.js b/src/components/btn/QBtnToggle.js
index <HASH>..<HASH> 100644
--- a/src/components/btn/QBtnToggle.js
+++ b/src/components/btn/QBtnToggle.js
@@ -20,6 +20,7 @@ export default {
required: true,
validator: v => v.every(opt => ('label' in opt || 'icon' in opt) && 'value' in opt)
},
+ readonly: Boolean,
disable: Boolean,
noCaps: Boolean,
noWrap: Boolean,
@@ -40,6 +41,9 @@ export default {
},
methods: {
set (value, opt) {
+ if (this.readonly) {
+ return
+ }
this.$emit('input', value, opt)
this.$nextTick(() => {
if (JSON.stringify(value) !== JSON.stringify(this.value)) {
|
feat(QBtnToggle): readonly prop
|
quasarframework_quasar
|
train
|
js
|
3e06b1c3f5d14bbcb0beaa1cecb8aa512ec9e68a
|
diff --git a/api.js b/api.js
index <HASH>..<HASH> 100644
--- a/api.js
+++ b/api.js
@@ -165,6 +165,11 @@ dbmigrate.prototype = {
return true;
},
+ /**
+ * Registers and initializes hooks.
+ *
+ * @returns Promise
+ */
registerAPIHook: function(callback) {
var plugins = this.internals.plugins;
@@ -550,7 +555,7 @@ function setDefaultArgv(internals, isModule) {
'ignore-completed-migrations': false
})
.usage(
- 'Usage: db-migrate [up|down|reset|sync|create|db|seed|transition] ' +
+ 'Usage: db-migrate [up|down|reset|sync|create|db|transition] ' +
'[[dbname/]migrationName|all] [options]'
)
|
refactor(api): cleanup information and added commentary
|
db-migrate_node-db-migrate
|
train
|
js
|
40b3a9a67c1bda76c9f9d49e299a8358e29a198e
|
diff --git a/packages/xod-client-electron/src/upload/actions.js b/packages/xod-client-electron/src/upload/actions.js
index <HASH>..<HASH> 100644
--- a/packages/xod-client-electron/src/upload/actions.js
+++ b/packages/xod-client-electron/src/upload/actions.js
@@ -26,15 +26,16 @@ const getTranspiledCode = (transpiler, state) => {
};
export const upload = () => (dispatch, getState) => {
- const code = getTranspiledCode(transpileForEspruino, getState());
+ const eitherCode = getTranspiledCode(transpileForEspruino, getState());
const processId = dispatch(client.addProcess(UPLOAD));
+ const fail = failUpload(dispatch, processId);
foldEither(
fail,
(code) => {
uploadToEspruino(code, progressUpload(dispatch, processId))
.then(succeedUpload(dispatch, processId))
- .catch(failUpload(dispatch, processId));
+ .catch(fail);
},
eitherCode
);
|
fix(xod-client-electron): fix merging mistake
|
xodio_xod
|
train
|
js
|
dc8a53d0615e5e5c13a8a1a70569dd4c6c97591f
|
diff --git a/phwoolcon-package/phwoolcon-package-phwoolcon.php b/phwoolcon-package/phwoolcon-package-phwoolcon.php
index <HASH>..<HASH> 100755
--- a/phwoolcon-package/phwoolcon-package-phwoolcon.php
+++ b/phwoolcon-package/phwoolcon-package-phwoolcon.php
@@ -44,7 +44,7 @@ return [
'ie-hack-css' => [],
'ie-hack-js' => [
'phwoolcon/ie/html-elements.js',
- 'phwoolcon/ie/add-event-listener.js',
+ 'phwoolcon/ie/add-event-listener.min.js',
'phwoolcon/ie/es5-shim-4.5.9.min.js',
'phwoolcon/ie/es5-sham-4.5.9.min.js',
'phwoolcon/ie/json2.min.js',
|
feat(assets): update ie hack js [ci skip]
|
phwoolcon_phwoolcon
|
train
|
php
|
98f1151b06ea7b5264f4ac340e2243c4dbc98cc8
|
diff --git a/index.js b/index.js
index <HASH>..<HASH> 100644
--- a/index.js
+++ b/index.js
@@ -137,11 +137,11 @@ function mockServiceMethod(service, client, method, replace) {
return promise;
} : undefined,
createReadStream: function() {
- return new Readable({
- read: function(size) {
- this.push(null);
- }
- });
+ var stream = new Readable();
+ stream._read = function(size) {
+ this.push(null);
+ };
+ return stream;
}
};
// If the value of 'replace' is a function we call it with the arguments.
|
fix: backport stream code to node <I>
|
dwyl_aws-sdk-mock
|
train
|
js
|
eeea2a8a51ba6bf5b34ddd64551ae9665e67a32d
|
diff --git a/src/cli.js b/src/cli.js
index <HASH>..<HASH> 100644
--- a/src/cli.js
+++ b/src/cli.js
@@ -439,31 +439,13 @@ function cli (inputArgs) {
});
}
- if (args.nosave) {
- args.save = false;
- } else {
- args.save = true;
- }
-
- if (args.noprod) {
- args.production = false;
- } else {
- args.production = true;
- }
+ args.save = !args.nosave;
+ args.production = !args.noprod;
- if (args.save === undefined) {
- // User explicitly did not pass in save
- args.save = conf.get('autosave');
- }
if (args.searchpath === undefined) {
// User explicitly did not pass in searchpath
args.searchpath = conf.get('searchpath');
}
- if (args.production === undefined) {
- // User explicitly did not pass in noprod
- args.production = conf.get('production');
- }
-
if (args['save-exact'] === undefined) {
// User explicitly did not pass in save-exact
args['save-exact'] = conf.get('save-exact');
|
refactor: remove dead code & simplify (#<I>)
This refactoring exposes that the `autosave` and `production` settings
in Cordova's config are actually always ignored.
|
apache_cordova-cli
|
train
|
js
|
c695ee61736b749819fc13f72e997e72822e7830
|
diff --git a/lib/config/eslint.js b/lib/config/eslint.js
index <HASH>..<HASH> 100644
--- a/lib/config/eslint.js
+++ b/lib/config/eslint.js
@@ -13,7 +13,7 @@ module.exports = function (webpackConfig) {
return {
configFile: fileExists(eslintrcPath) ? eslintrcPath : path.join(__dirname, '../.eslintrc'),
// 报warning了就终止webpack编译
- failOnWarning: true,
+ failOnWarning: false,
// 报error了就终止webpack编译
failOnError: true,
// 开启eslint的cache,cache存在node_modules/.cache目录里
|
refactor: improve aslant config
|
zuzucheFE_guido
|
train
|
js
|
93e42577613b933398c9e3c9e97ca43e92ae79fe
|
diff --git a/src/Database/Eloquent/ModelReturnTypeExtension.php b/src/Database/Eloquent/ModelReturnTypeExtension.php
index <HASH>..<HASH> 100644
--- a/src/Database/Eloquent/ModelReturnTypeExtension.php
+++ b/src/Database/Eloquent/ModelReturnTypeExtension.php
@@ -68,7 +68,10 @@ final class ModelReturnTypeExtension implements DynamicStaticMethodReturnTypeExt
* "static" points to the concrete class model.
*/
if ($variants[0] instanceof FunctionVariantWithPhpDocs) {
- if ((new \ReflectionClass($methodCall->class->toString()))->isSubclassOf(Model::class)) {
+
+ $className = class_exists($methodCall->class->toString());
+
+ if (class_exists($className) && (new \ReflectionClass($className))->isSubclassOf(Model::class)) {
$types = method_exists($returnType, 'getTypes') ? $returnType->getTypes() : [$returnType];
$types = $this->replaceStaticType($types, $methodCall->class->toString());
$returnType = count($types) > 1 ? new UnionType($types) : current($types);
|
fix: model return type when class don't exist
|
nunomaduro_larastan
|
train
|
php
|
ba78824f8be0e38b954286fc543c68caffbe574e
|
diff --git a/test/get-page-data.js b/test/get-page-data.js
index <HASH>..<HASH> 100644
--- a/test/get-page-data.js
+++ b/test/get-page-data.js
@@ -32,3 +32,19 @@ test('should get the body', t => {
t.equal(output.body, '<p>Some more text</p>');
t.end();
});
+
+test('should display the footer if there is a horizontal rule', t => {
+ const html = '<h1>Hello World</h1><p>Text</p><p>Some more text</p><hr><p>some footer content</p>';
+ const output = getPageData(html);
+
+ t.equal(output.footer, '<p>some footer content</p>');
+ t.end();
+});
+
+test('should not display the footer if there is no horizontal rule', t => {
+ const html = '<h1>Hello World</h1><p>Text</p><p>Some more text</p>';
+ const output = getPageData(html);
+
+ t.equal(output.footer, '');
+ t.end();
+});
|
test(get-page-data): add test to cover with and without footer
|
voorhoede_voorhoede-ocelot-formatter
|
train
|
js
|
67436826c788da74b522809e164fe66d8e70ba29
|
diff --git a/packages/d3fc-sample/test/bucketSpec.js b/packages/d3fc-sample/test/bucketSpec.js
index <HASH>..<HASH> 100644
--- a/packages/d3fc-sample/test/bucketSpec.js
+++ b/packages/d3fc-sample/test/bucketSpec.js
@@ -51,6 +51,11 @@ describe('bucket', () => {
expect(bucketedData).toEqual([[0], [1], [6], [4], [8], [4], [8], [9], [3], [5], [2], [10], [2], [4], [3], [8], [5]]);
});
+ it('should return the same number of buckets as the data length if the bucket size is less than 1', () => {
+ const bucketedData = dataBucketer.bucketSize(0.5)(data);
+ expect(bucketedData).toEqual([[0], [1], [6], [4], [8], [4], [8], [9], [3], [5], [2], [10], [2], [4], [3], [8], [5]]);
+ });
+
it('should create a last bucket with (data.length % bucketSize) data points', () => {
const bucketSize = 3;
const bucketedData = dataBucketer.bucketSize(bucketSize)(data);
|
test: add test for bucket utility when bucket size is less than 1
|
d3fc_d3fc
|
train
|
js
|
710d08b04db08cfff2ab8719e19dde399804db20
|
diff --git a/packages/@vue/cli/lib/upgrade.js b/packages/@vue/cli/lib/upgrade.js
index <HASH>..<HASH> 100644
--- a/packages/@vue/cli/lib/upgrade.js
+++ b/packages/@vue/cli/lib/upgrade.js
@@ -196,7 +196,13 @@ class Upgrader {
const latest = await this.pm.getRemoteVersion(name)
if (installed !== latest) {
- upgradable.push({ name, installed, wanted, latest })
+ // always list @vue/cli-service as the first one
+ // as it's depended by all other plugins
+ if (name === '@vue/cli-service') {
+ upgradable.unshift({ name, installed, wanted, latest })
+ } else {
+ upgradable.push({ name, installed, wanted, latest })
+ }
}
}
}
@@ -244,7 +250,7 @@ async function upgrade (packageName, options, context = process.cwd()) {
if (!(await confirmIfGitDirty(context))) {
return
}
-
+
const upgrader = new Upgrader(context)
if (!packageName) {
|
chore: always upgrade @vue/cli-service first
|
vuejs_vue-cli
|
train
|
js
|
a7b4f67d545100de30e0b379018cf9d790930689
|
diff --git a/Model/Write/EavIterator.php b/Model/Write/EavIterator.php
index <HASH>..<HASH> 100644
--- a/Model/Write/EavIterator.php
+++ b/Model/Write/EavIterator.php
@@ -262,7 +262,7 @@ class EavIterator implements IteratorAggregate
Profiler::start('loop');
try {
- $this->eventManager->dispatch('tweakwise_iterator_processbatch', ['batch_size' => $this->batchSize, 'entity_code' => $this->entityCode]);
+ $this->eventManager->dispatch('tweakwise_iterator_processbatch', ['batch_size' => count($entityIds), 'entity_code' => $this->entityCode]);
// Loop over all rows and combine them to one array for entity
foreach ($this->loopUnionRows($stmt) as $result) {
yield $result;
|
fix: count entity ids so the size is correctly sent
|
EmicoEcommerce_Magento2TweakwiseExport
|
train
|
php
|
ec968a33b1f5ca3e8cef4d1290750e23a8e53115
|
diff --git a/test/oAuth2.spec.js b/test/oAuth2.spec.js
index <HASH>..<HASH> 100644
--- a/test/oAuth2.spec.js
+++ b/test/oAuth2.spec.js
@@ -108,7 +108,6 @@ describe('OAuth2', () => {
describe('.buildQuery()', () => {
it('return query', () => {
const query = oAuth2.buildQuery(baseConfig.providers['facebook']);
- expect(query.nonce).toMatch(/.\d/);
expect(query.display).toBe('popup');
expect(query.scope).toBe('email');
});
|
chore(test): obsolete nonce test removed
|
SpoonX_aurelia-authentication
|
train
|
js
|
891567fb2ded451e1571973c57db8a3ee67607d9
|
diff --git a/lib/index.js b/lib/index.js
index <HASH>..<HASH> 100644
--- a/lib/index.js
+++ b/lib/index.js
@@ -152,7 +152,7 @@ app.use(require('mongodb-favicon/express'));
/**
* Setup socket.io
*/
-require('./io');
+require('./io').attach(app.server);
module.exports.start = function(opts, fn) {
if (typeof opts === 'function') {
diff --git a/lib/io.js b/lib/io.js
index <HASH>..<HASH> 100644
--- a/lib/io.js
+++ b/lib/io.js
@@ -6,8 +6,7 @@
* This is the socket.io equivalent of `routes/*.js`
* in express terms.
*/
-var app = require('./');
-var io = module.exports = require('socket.io')(app.server);
+var io = module.exports = require('socket.io')();
var ss = require('socket.io-stream');
var series = require('async').series;
var _ = require('lodash');
|
fix(io): simplify by connecting socket.io to express in index.js
|
mongodb-js_scope-server
|
train
|
js,js
|
42bb4d4ae0d8b9ba7f5be5ed192705f389529440
|
diff --git a/lib/write_xlsx/worksheet.rb b/lib/write_xlsx/worksheet.rb
index <HASH>..<HASH> 100644
--- a/lib/write_xlsx/worksheet.rb
+++ b/lib/write_xlsx/worksheet.rb
@@ -2554,7 +2554,7 @@ module Writexlsx
store_row_col_max_min_values(row, col)
# keep original value of cell
- if @cell_data_table.dig(row, col).nil?
+ if @cell_data_table[row].nil? || @cell_data_table[row][col].nil?
format = @workbook.add_format(params)
write_blank(row, col, format)
elsif @cell_data_table[row][col].xf.nil?
|
fix: Remove dig method for lower version Ruby
|
cxn03651_write_xlsx
|
train
|
rb
|
e7dcf3cc86560745fad97f545448142c1e91630d
|
diff --git a/src/lib/storage/up-storage.js b/src/lib/storage/up-storage.js
index <HASH>..<HASH> 100644
--- a/src/lib/storage/up-storage.js
+++ b/src/lib/storage/up-storage.js
@@ -231,7 +231,6 @@ class ProxyStorage {
const headers = {};
if (_.isNil(options.etag) === false) {
headers['If-None-Match'] = options.etag;
- headers['Accept'] = 'application/octet-stream';
}
this.request({
|
fix: #<I> remove the accept header that avoids request with some regiestries
|
verdaccio_verdaccio
|
train
|
js
|
5d9beb547a46cfc48e7685a0c4da92c98d670a28
|
diff --git a/test/xccdf/session_test.rb b/test/xccdf/session_test.rb
index <HASH>..<HASH> 100644
--- a/test/xccdf/session_test.rb
+++ b/test/xccdf/session_test.rb
@@ -45,7 +45,7 @@ class TestSession < Test::Unit::TestCase
private
def to_work_dir()
workdir = "test/output"
- FileUtils.rmdir workdir
+ FileUtils.rm_rf workdir
Dir.mkdir workdir
Dir.chdir workdir
end
|
test: Remove working directory even if there is content
Addressing:
Errno::EEXIST: File exists - test/output
test/xccdf/session_test.rb:<I>:in `mkdir'
test/xccdf/session_test.rb:<I>:in `to_work_dir'
test/xccdf/session_test.rb:<I>:in `test_session_export'
|
OpenSCAP_ruby-openscap
|
train
|
rb
|
e31f38fe782b407350a5350078bf9b37da48576d
|
diff --git a/packages/input-select/src/components/withImage.js b/packages/input-select/src/components/withImage.js
index <HASH>..<HASH> 100644
--- a/packages/input-select/src/components/withImage.js
+++ b/packages/input-select/src/components/withImage.js
@@ -20,7 +20,7 @@ export default Input =>
<LabelContainer className="labelContainer">
{image && (
<ItemImage
- className="itemImage"
+ className="selectedItemImage"
src={image}
size={badgeSizes.SMALL}
badge
|
feat(withImage): Use different classes for selected or option images
|
CraveFood_farmblocks
|
train
|
js
|
cbab82c543e5b2c72ebb29b69b240beb216cef76
|
diff --git a/pyguetzli/guetzli.py b/pyguetzli/guetzli.py
index <HASH>..<HASH> 100644
--- a/pyguetzli/guetzli.py
+++ b/pyguetzli/guetzli.py
@@ -26,7 +26,7 @@ def process_jpeg_bytes(bytes_in, quality=DEFAULT_JPEG_QUALITY):
import pyguetzli
- input_jpeg_bytes = open("./test/image.jpg", "rb")
+ input_jpeg_bytes = open("./test/image.jpg", "rb").read()
optimized_jpeg = pyguetzli.process_jpeg_bytes(input_jpeg_bytes)
"""
bytes_out_p = ffi.new("char**")
|
docs: fixed an error in example
|
wanadev_pyguetzli
|
train
|
py
|
7aa450f68acd421aea996a53b857c0c48a1e893b
|
diff --git a/lib/link.js b/lib/link.js
index <HASH>..<HASH> 100644
--- a/lib/link.js
+++ b/lib/link.js
@@ -15,6 +15,7 @@ function Link(session, handle, linkPolicy) {
this.session = session;
this.handle = handle;
this.remote = { handle: undefined };
+ this.deliveryCount = 0;
this._onAttach = [];
if (this.policy && this.policy.reattach) {
diff --git a/lib/receiver_link.js b/lib/receiver_link.js
index <HASH>..<HASH> 100644
--- a/lib/receiver_link.js
+++ b/lib/receiver_link.js
@@ -98,14 +98,6 @@ ReceiverLink.prototype.settle = function(message, state) {
// private API
-ReceiverLink.prototype._attachReceived = function(attachFrame) {
- this.deliveryCount = attachFrame.deliveryCount;
-
- // call super method
- ReceiverLink.super_.prototype._attachReceived.call(this, attachFrame);
-};
-
-
ReceiverLink.prototype._flowReceived = function(flowFrame) {
this.drain = flowFrame.drain;
|
refactor(receiver-link): remove dead code, initialize deliveryCount
|
noodlefrenzy_node-amqp10
|
train
|
js,js
|
dc380ec1a100fd35dd3b373f2f6b82b1a4316a7f
|
diff --git a/test/functional/transactions_tests.js b/test/functional/transactions_tests.js
index <HASH>..<HASH> 100644
--- a/test/functional/transactions_tests.js
+++ b/test/functional/transactions_tests.js
@@ -236,6 +236,21 @@ function parseTopologies(topologies) {
return topologies;
}
+function shouldSkipTest(spec) {
+ const SKIP_TESTS = [
+ // commitTransaction retry seems to be swallowed by mongos in these three cases
+ 'commitTransaction retry succeeds on new mongos',
+ 'commitTransaction retry fails on new mongos',
+ 'unpin after transient error within a transaction and commit'
+ ];
+
+ if (spec.skipReason || SKIP_TESTS.indexOf(spec.description) !== -1) {
+ return it.skip;
+ }
+
+ return it;
+}
+
function generateTopologyTests(testSuites, testContext) {
testSuites.forEach(testSuite => {
const suiteName = testSuite.name;
@@ -252,7 +267,7 @@ function generateTopologyTests(testSuites, testContext) {
afterEach(() => cleanupAfterSuite(testContext));
tests.forEach(spec => {
- const maybeSkipIt = spec.skipReason ? it.skip : it;
+ const maybeSkipIt = shouldSkipTest(spec);
maybeSkipIt(spec.description, function() {
let testPromise = Promise.resolve();
|
test(txns): add skip list for outstanding mongos problem tests
|
mongodb_node-mongodb-native
|
train
|
js
|
8c9e35bd600a2d156c6131aedd855bfcea460d78
|
diff --git a/src/components/ComposedModal/ComposedModal.js b/src/components/ComposedModal/ComposedModal.js
index <HASH>..<HASH> 100644
--- a/src/components/ComposedModal/ComposedModal.js
+++ b/src/components/ComposedModal/ComposedModal.js
@@ -257,12 +257,12 @@ export class ModalHeader extends Component {
/**
* Specify an optional label to be displayed
*/
- label: PropTypes.string,
+ label: PropTypes.node,
/**
* Specify an optional title to be displayed
*/
- title: PropTypes.string,
+ title: PropTypes.node,
/**
* Specify the content to be placed in the ModalHeader
diff --git a/src/components/Modal/Modal.js b/src/components/Modal/Modal.js
index <HASH>..<HASH> 100644
--- a/src/components/Modal/Modal.js
+++ b/src/components/Modal/Modal.js
@@ -46,7 +46,8 @@ export default class Modal extends Component {
/**
* Specify the content of the modal header title.
*/
- modalHeading: PropTypes.string,
+ modalHeading: PropTypes.node,
+
/**
* Specify the content of the modal header label.
*/
|
fix(Modal): accept nodes to heading (#<I>)
Fixes carbon-design-system/carbon-components#<I>.
|
carbon-design-system_carbon-components-react
|
train
|
js,js
|
094bd5731910ee7244a85b4becd5d5a60194b408
|
diff --git a/samples/moveFile.js b/samples/moveFile.js
index <HASH>..<HASH> 100644
--- a/samples/moveFile.js
+++ b/samples/moveFile.js
@@ -30,7 +30,7 @@ function main(
* TODO(developer): Uncomment the following lines before running the sample.
*/
// The ID of your GCS bucket
- // const srcBucketName = 'your-source-bucket';
+ // const bucketName = 'your-source-bucket';
// The ID of your GCS file
// const srcFileName = 'your-file-name';
|
docs: fix typo in sample moveFile (#<I>)
* fix typo
* docs: fix typo in sample moveFile
|
googleapis_nodejs-storage
|
train
|
js
|
d1ad01dd8ace7013b896bf335c49905892521fa1
|
diff --git a/packages/site/pages/components/card.js b/packages/site/pages/components/card.js
index <HASH>..<HASH> 100644
--- a/packages/site/pages/components/card.js
+++ b/packages/site/pages/components/card.js
@@ -48,7 +48,7 @@ const decorateCardsM = decorateCards.bind(null, null)
const capitalize = str => str.charAt(0).toUpperCase() + str.substring(1)
const InAppExample = props => (
- <div>
+ <Theme>
<div className="gallery">
<Layout.EqualColumnLayout>
<ul>
@@ -121,7 +121,9 @@ const InAppExample = props => (
</ul>
</Layout.EqualColumnLayout>
</div>
- <Code lang="javascript" collapsible>{`<Layout.EqualColumnLayout>
+
+ <Code lang="javascript" collapsible>
+ {`<Layout.EqualColumnLayout>
<ul>
<li>
<Card
@@ -191,14 +193,16 @@ const InAppExample = props => (
</li>
</ul>
</Layout.EqualColumnLayout>
-`}</Code>
+`}
+ </Code>
+
<style jsx>{`
.gallery {
padding: ${core.layout.spacingMedium};
background: ${core.colors.gray06};
}
`}</style>
- </div>
+ </Theme>
)
export default withServerProps(_ => (
|
fix(site): fix Card example theme
|
pluralsight_design-system
|
train
|
js
|
f9ab1d35f8ec633a25c223ed979cef34a68072fe
|
diff --git a/redis/utils.py b/redis/utils.py
index <HASH>..<HASH> 100644
--- a/redis/utils.py
+++ b/redis/utils.py
@@ -8,7 +8,7 @@ except ImportError:
HIREDIS_AVAILABLE = False
-def from_url(url, db=None, **kwargs):
+def from_url(url, **kwargs):
"""
Returns an active Redis client generated from the given database URL.
@@ -16,7 +16,7 @@ def from_url(url, db=None, **kwargs):
none is provided.
"""
from redis.client import Redis
- return Redis.from_url(url, db, **kwargs)
+ return Redis.from_url(url, **kwargs)
@contextmanager
|
fix: Align from_url in utils.py to remove DB as a 2nd param
|
andymccurdy_redis-py
|
train
|
py
|
5fbbc98864e887a69439de81fb48b8d11ff4540e
|
diff --git a/src/components/Tile/Tile.js b/src/components/Tile/Tile.js
index <HASH>..<HASH> 100644
--- a/src/components/Tile/Tile.js
+++ b/src/components/Tile/Tile.js
@@ -271,6 +271,8 @@ export class SelectableTile extends Component {
}
export class ExpandableTile extends Component {
+ state = {};
+
static propTypes = {
children: PropTypes.node,
className: PropTypes.string,
@@ -300,15 +302,11 @@ export class ExpandableTile extends Component {
expanded: currentExpanded,
tileMaxHeight: currentTileMaxHeight,
tilePadding: currentTilePadding,
- } =
- state || {};
+ } = state;
const expandedChanged = prevExpanded !== expanded;
const tileMaxHeightChanged = prevTileMaxHeight !== tileMaxHeight;
const tilePaddingChanged = prevTilePadding !== tilePadding;
- return state &&
- !expandedChanged &&
- !tileMaxHeightChanged &&
- !tilePaddingChanged
+ return !expandedChanged && !tileMaxHeightChanged && !tilePaddingChanged
? null
: {
expanded: !expandedChanged ? currentExpanded : expanded,
|
fix(ExpendableTile): add initial state to prevent warnings (#<I>)
|
carbon-design-system_carbon-components-react
|
train
|
js
|
f8678e803c9289762b3f82e1a9923b5141132c6e
|
diff --git a/samcli/local/docker/lambda_container.py b/samcli/local/docker/lambda_container.py
index <HASH>..<HASH> 100644
--- a/samcli/local/docker/lambda_container.py
+++ b/samcli/local/docker/lambda_container.py
@@ -181,9 +181,9 @@ class LambdaContainer(Container):
+ debug_args_list \
+ [
"-agentlib:jdwp=transport=dt_socket,server=y,suspend=y,quiet=y,address=" + str(debug_port),
- "-XX:MaxHeapSize=1336935k",
- "-XX:MaxMetaspaceSize=157286k",
- "-XX:ReservedCodeCacheSize=78643k",
+ "-XX:MaxHeapSize=2834432k",
+ "-XX:MaxMetaspaceSize=163840k",
+ "-XX:ReservedCodeCacheSize=81920k",
"-XX:+UseSerialGC",
# "-Xshare:on", doesn't work in conjunction with the debug options
"-XX:-TieredCompilation",
|
chore: Update JVM size params to match docker-lambda (#<I>)
|
awslabs_aws-sam-cli
|
train
|
py
|
12f536317626fdc95c3b361207ad316d631169da
|
diff --git a/webapps/client/scripts/pages/decisionInstance.js b/webapps/client/scripts/pages/decisionInstance.js
index <HASH>..<HASH> 100644
--- a/webapps/client/scripts/pages/decisionInstance.js
+++ b/webapps/client/scripts/pages/decisionInstance.js
@@ -162,10 +162,12 @@ define([
disableBinaryFetching: true,
disableCustomObjectDeserialization: true
}, function(err, data) {
- if(!err) {
+ if(!err && data.length) {
deferred.resolve(data[0]);
} else {
- deferred.reject(err);
+ deferred.reject(err || {
+ status: 404
+ });
}
});
|
fix(dmn): redirect to dashboard if id not found
related to CAM-<I>
|
camunda_camunda-bpm-platform
|
train
|
js
|
e14754da2215a1fa78433d20b5ff6df44cf9dcc3
|
diff --git a/Controller/Payment/Verify.php b/Controller/Payment/Verify.php
index <HASH>..<HASH> 100644
--- a/Controller/Payment/Verify.php
+++ b/Controller/Payment/Verify.php
@@ -128,10 +128,6 @@ class Verify extends \Magento\Framework\App\Action\Action
// Process the order
if ($this->orderHandler->isOrder($order)) {
- // Add the payment info to the order
-
- $this->utilities->setPaymentData($order, $response);
-
// Logging
$this->logger->display($response);
|
chore: removed set payment data from /verify
|
checkout_checkout-magento2-plugin
|
train
|
php
|
601d61370a9487437d6515eb4765f77059b0e421
|
diff --git a/scripts/deploy-docs.js b/scripts/deploy-docs.js
index <HASH>..<HASH> 100644
--- a/scripts/deploy-docs.js
+++ b/scripts/deploy-docs.js
@@ -69,6 +69,7 @@ const deployToS3_deprecated = () => {
domain: `cdn.telus-thorium-doc-${env}`,
prefix: env === 'production' ? undefined : 'latest'
});
+
console.log('Deploying to s3 (deprecated)...');
console.log(deployConfig);
@@ -98,7 +99,5 @@ if (env === 'production') {
deployToS3_deprecated();
}
else {
-
- deployToS3_deprecated()
- .then(deployToS3('staging'));
+ deployToS3('staging');
}
|
ci(deploy-docs): remove call to second promise when on staging
|
telus_tds-core
|
train
|
js
|
fba47b172a34a3e703d30dc411f186ce9da07511
|
diff --git a/test/helpers/kubectl.go b/test/helpers/kubectl.go
index <HASH>..<HASH> 100644
--- a/test/helpers/kubectl.go
+++ b/test/helpers/kubectl.go
@@ -648,7 +648,7 @@ func (kub *Kubectl) labelNodes() error {
if noCiliumNodeNames != "" {
// Prevent scheduling any pods on the node, as it will be used as an external client
// to send requests to k8s{1,2}
- cmd := fmt.Sprintf("%s taint --overwrite nodes %s key=value:NoSchedule", KubectlCmd, noCiliumNodeNames)
+ cmd := fmt.Sprintf("%s taint --overwrite nodes %s prevent-scheduling:NoSchedule", KubectlCmd, noCiliumNodeNames)
res := kub.ExecMiddle(cmd)
if !res.WasSuccessful() {
return fmt.Errorf("unable to taint node with '%s': %s", cmd, res.OutputPrettyPrint())
|
test: Use more explicit key for k8s3's taint
Node k8s3 has a taint to prevent scheduling of pods. The key and value
for the taint are key=value, which is neither very explicit about the
purpose nor easy to grep. This commit changes it to prevent-scheduling
(no value).
|
cilium_cilium
|
train
|
go
|
223722ad4ca0f44509e66db46843958da4504414
|
diff --git a/lib/workers/pr/index.js b/lib/workers/pr/index.js
index <HASH>..<HASH> 100644
--- a/lib/workers/pr/index.js
+++ b/lib/workers/pr/index.js
@@ -328,6 +328,11 @@ async function ensurePr(prConfig) {
logger.info(`Created ${pr.displayNumber}`);
return pr;
} catch (err) {
+ // istanbul ignore if
+ if (err.message === 'rate-limit-exceeded') {
+ logger.debug('Passing rate-limit-exceeded error up');
+ throw err;
+ }
logger.error({ err }, 'Failed to ensure PR:', err);
}
return null;
|
fix: pass rate limit exceeded errors up from ensurePr
|
renovatebot_renovate
|
train
|
js
|
ca6ad3c7be3a3c0b72099a4b06fbac8a0a3a0ec5
|
diff --git a/scripts/release.js b/scripts/release.js
index <HASH>..<HASH> 100644
--- a/scripts/release.js
+++ b/scripts/release.js
@@ -113,7 +113,10 @@ const release = async () => {
console.log(`lerna ${releaseArguments.join(' ')}`)
await execa(require.resolve('lerna/bin/lerna'), releaseArguments, { stdio: 'inherit' })
+
await execa('yarn', ['changelog'])
+ await execa('git', ['add', '-A'], { stdio: 'inherit' })
+ await execa('git', ['commit', '-m', `chore: ${version} changelog`], { stdio: 'inherit' })
}
release().catch(err => {
|
ci: auto commit changelog after publish
|
vuejs_vuepress
|
train
|
js
|
6ba15df253b447e668c4f90c537d3b6c77ed530e
|
diff --git a/src/ServerCapabilities.php b/src/ServerCapabilities.php
index <HASH>..<HASH> 100644
--- a/src/ServerCapabilities.php
+++ b/src/ServerCapabilities.php
@@ -40,6 +40,24 @@ class ServerCapabilities
public $definitionProvider;
/**
+ * The server provides goto type definition support.
+ *
+ * @since 3.6.0
+ *
+ * @var bool|null
+ */
+ public $typeDefinitionProvider;
+
+ /**
+ * The server provides goto implementation support.
+ *
+ * @since 3.6.0
+ *
+ * @var bool|null
+ */
+ public $implementationProvider;
+
+ /**
* The server provides find references support.
*
* @var bool|null
|
feat: goto type and implemenatation capabilities (#<I>)
|
felixfbecker_php-language-server-protocol
|
train
|
php
|
07891acd1db39c40577b67fd277e483d4eb120de
|
diff --git a/samcli/__init__.py b/samcli/__init__.py
index <HASH>..<HASH> 100644
--- a/samcli/__init__.py
+++ b/samcli/__init__.py
@@ -2,4 +2,4 @@
SAM CLI version
"""
-__version__ = '0.3.0'
+__version__ = '0.4.0'
diff --git a/setup.py b/setup.py
index <HASH>..<HASH> 100644
--- a/setup.py
+++ b/setup.py
@@ -44,8 +44,8 @@ setup(
license=read('LICENSE'),
packages=find_packages(exclude=('tests', 'docs')),
keywords="AWS SAM CLI",
- # Support Python2.7 and higher, but not 3.x
- python_requires='~=2.7',
+ # Support Python 2.7 and 3.6 or greater
+ python_requires='>=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*, !=3.5.*',
entry_points={
'console_scripts': [
'{}=samcli.cli.main:cli'.format(cmd_name)
@@ -66,6 +66,7 @@ setup(
'Operating System :: OS Independent',
'Programming Language :: Python',
'Programming Language :: Python :: 2.7',
+ 'Programming Language :: Python :: 3.6',
'Topic :: Internet',
'Topic :: Software Development :: Build Tools',
'Topic :: Utilities',
|
chore: Version bump and update setup.py to include Python<I> (#<I>)
|
awslabs_aws-sam-cli
|
train
|
py,py
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.