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 |
|---|---|---|---|---|---|
1f3efe90de976e569152699bb156f948e54e21b6
|
diff --git a/ibis/backends/clickhouse/registry.py b/ibis/backends/clickhouse/registry.py
index <HASH>..<HASH> 100644
--- a/ibis/backends/clickhouse/registry.py
+++ b/ibis/backends/clickhouse/registry.py
@@ -402,6 +402,11 @@ def _literal(translator, expr):
return str(list(_tuple_to_list(value)))
elif isinstance(expr, ir.SetScalar):
return '({})'.format(', '.join(map(repr, value)))
+ elif isinstance(expr, ir.StructScalar):
+ fields = ", ".join(
+ f"{value} as `{key}`" for key, value in expr.op().value.items()
+ )
+ return f"tuple({fields})"
else:
raise NotImplementedError(type(expr))
|
feat(clickhouse): implement struct scalars
|
ibis-project_ibis
|
train
|
py
|
0ca95cb6ed887fa7e6c0e8d018982b1f7d33cd7d
|
diff --git a/mountains/file/__init__.py b/mountains/file/__init__.py
index <HASH>..<HASH> 100644
--- a/mountains/file/__init__.py
+++ b/mountains/file/__init__.py
@@ -6,14 +6,15 @@ from ..encoding import force_text, force_bytes
from .. import json
-def read_dict(file_name, clear_none=False):
+def read_dict(file_name, clear_none=False, encoding='utf-8'):
"""
读取字典文件
+ :param encoding:
:param clear_none:
:param file_name:
:return:
"""
- with open(file_name, 'r') as f:
+ with open(file_name, 'r', encoding=encoding) as f:
data = []
i = 0
for line in f:
@@ -50,13 +51,14 @@ def write_file(file_name, data):
f.write(data)
-def read_file(file_name):
+def read_file(file_name, encoding='utf-8'):
"""
读文本文件
+ :param encoding:
:param file_name:
:return:
"""
- with open(file_name, 'r') as f:
+ with open(file_name, 'r', encoding=encoding) as f:
return f.read()
|
fix: read_dict encoding
|
restran_mountains
|
train
|
py
|
fee0dfc5461e489e7869f82b1507fd8942b2550c
|
diff --git a/app/templates/entry/bex/content/content-script.js b/app/templates/entry/bex/content/content-script.js
index <HASH>..<HASH> 100644
--- a/app/templates/entry/bex/content/content-script.js
+++ b/app/templates/entry/bex/content/content-script.js
@@ -47,7 +47,7 @@ function injectScript (url) {
}
if (document instanceof HTMLDocument) {
- injectScript(chrome.extension.getURL('www/bex-dom.js'))
+ injectScript(chrome.extension.getURL(process.env.DEV ? 'www/bex-dom.js' : 'www/js/bex-dom.js'))
}
// Listen for event from the web page
|
fix(bex): Dom-scripts has wrong path on build (#<I>)
|
quasarframework_quasar
|
train
|
js
|
421344257cea435ace8d6a0bd0cc02e4e3196b6a
|
diff --git a/src/iter.js b/src/iter.js
index <HASH>..<HASH> 100644
--- a/src/iter.js
+++ b/src/iter.js
@@ -134,9 +134,6 @@ export default class Iter<T> extends ProducerBase<T> {
return this.sizeHint() === 0 ? 0 : this.reduce(ops.mul, 1)
}
- /* eslint-disable no-unused-vars, no-dupe-class-members */
-
- reduce(fn: (T, T) => T): T {}
reduce<U>(fn: (U, T) => U, init: U): U {
const size = this.sizeHint()
let acc = init
@@ -154,8 +151,6 @@ export default class Iter<T> extends ProducerBase<T> {
return acc
}
- /* eslint-enable no-unused-vars, no-dupe-class-members */
-
sizeHint(): number {
return this.producer.sizeHint()
}
|
refactor: remove unnecessary reduce method signature (#<I>)
|
zacharygolba_orio
|
train
|
js
|
5cc875730bcc70c82be6caaa8f3b81441c273700
|
diff --git a/test/cli/swarm.js b/test/cli/swarm.js
index <HASH>..<HASH> 100644
--- a/test/cli/swarm.js
+++ b/test/cli/swarm.js
@@ -78,5 +78,11 @@ describe('swarm', () => {
)
})
})
+
+ it('`peers` should not throw after `disconnect`', () => {
+ return ipfsA('swarm peers').then((out) => {
+ expect(out).to.be.empty()
+ })
+ })
})
})
|
test: `peers` should not throw after `disconnect` (#<I>)
|
ipfs_js-ipfs
|
train
|
js
|
fcdcabb55787775fbe77bbd4cd1537c67b082ba2
|
diff --git a/lib/pincers/http/client.rb b/lib/pincers/http/client.rb
index <HASH>..<HASH> 100644
--- a/lib/pincers/http/client.rb
+++ b/lib/pincers/http/client.rb
@@ -1,4 +1,6 @@
require 'forwardable'
+require 'net/http'
+
require 'pincers/http/utils'
require 'pincers/http/session'
require 'pincers/http/request'
|
fix(http): adds missing net/http require
|
platanus_pincers
|
train
|
rb
|
e0c5e8eb3d897cfea2831c804eeb4fcaaf8ce85c
|
diff --git a/.eslintrc.js b/.eslintrc.js
index <HASH>..<HASH> 100644
--- a/.eslintrc.js
+++ b/.eslintrc.js
@@ -79,5 +79,6 @@ module.exports = {
'no-return-await': 'error',
'no-template-curly-in-string': 'error',
'generator-star-spacing': 'off',
+ indent: ['error', 2],
},
};
diff --git a/lib/BaseRequest.js b/lib/BaseRequest.js
index <HASH>..<HASH> 100644
--- a/lib/BaseRequest.js
+++ b/lib/BaseRequest.js
@@ -467,9 +467,10 @@ export class BaseRequest extends EventEmitter {
if (this.auth) {
return this.auth;
}
- let auth = this._response._headers.has('www-authenticate')
- ? this._response._headers.get('www-authenticate')
- : undefined;
+ let auth;
+ if (this._response._headers.has('www-authenticate')) {
+ auth = this._response._headers.get('www-authenticate');
+ }
const result = {
method: 'unknown',
};
|
chore: fixing some lint errors
|
advanced-rest-client_electron-request
|
train
|
js,js
|
2115c7befadd6d7ecc1fd0e02d54a2a462f2774e
|
diff --git a/lib/components/narrative/line-itin/time-column-with-delays.js b/lib/components/narrative/line-itin/time-column-with-delays.js
index <HASH>..<HASH> 100644
--- a/lib/components/narrative/line-itin/time-column-with-delays.js
+++ b/lib/components/narrative/line-itin/time-column-with-delays.js
@@ -105,8 +105,9 @@ export default function TimeColumnWithDelays ({
<TimeColumn>
{renderedTime}
<StatusText>
- {!isOnTime && <>{delayInMinutes} min</>}
- {'\n'}
+ {/* Keep the '5 min' string on the same line. */}
+ {/* Append space before printing statusText. (statusText can be displayed on same line or new line.) */}
+ {!isOnTime && `${delayInMinutes}\xa0min `}
{statusText}
</StatusText>
</TimeColumn>
|
refactor(TimeColumnWithDelays): Format delay using template string.
|
opentripplanner_otp-react-redux
|
train
|
js
|
944f8c1f40a66870a12517ab5421696c85650b2a
|
diff --git a/webapps/Gruntfile.js b/webapps/Gruntfile.js
index <HASH>..<HASH> 100644
--- a/webapps/Gruntfile.js
+++ b/webapps/Gruntfile.js
@@ -190,8 +190,8 @@ module.exports = function(grunt) {
require('./grunt/tasks/compileLibs')(grunt, true);
require('camunda-commons-ui/grunt/tasks/localescompile')(grunt);
- require('camunda-commons-ui/grunt/tasks/persistify')(grunt);
- require('camunda-commons-ui/grunt/tasks/ensureLibs')(grunt);
+ require('camunda-commons-ui/grunt/tasks/persistify')(grunt, __dirname);
+ require('camunda-commons-ui/grunt/tasks/ensureLibs')(grunt, __dirname);
grunt.loadNpmTasks('grunt-karma');
|
chore(deps): fix test release job
|
camunda_camunda-bpm-platform
|
train
|
js
|
8eb1722cc08a57ea79d826127e36d38c1d54d805
|
diff --git a/setup.py b/setup.py
index <HASH>..<HASH> 100644
--- a/setup.py
+++ b/setup.py
@@ -15,7 +15,7 @@ DESCRIPTION = "Global hotkey bindings for Windows and Linux for PyQt apps"
URL = "https://github.com/codito/pyqtkeybind"
EMAIL = "arun@codito.in"
AUTHOR = "Arun Mahapatra"
-VERSION = (0, 0, 8)
+VERSION = (0, 0, 9)
# Dependencies required for execution
REQUIRED = [
|
chore: release <I>.
|
codito_pyqtkeybind
|
train
|
py
|
6823dd8e818fee2005cf4f5797f8eb16a962309b
|
diff --git a/src/ai/backend/client/cli/proxy.py b/src/ai/backend/client/cli/proxy.py
index <HASH>..<HASH> 100644
--- a/src/ai/backend/client/cli/proxy.py
+++ b/src/ai/backend/client/cli/proxy.py
@@ -130,7 +130,7 @@ async def web_handler(request):
down_resp.headers['Access-Control-Allow-Origin'] = '*'
await down_resp.prepare(request)
while True:
- chunk = await up_resp.aread(8192)
+ chunk = await up_resp.read(8192)
if not chunk:
break
await down_resp.write(chunk)
|
fix: Apply renamed request.Response methods
* This is a follow-up to #<I>
|
lablup_backend.ai-client-py
|
train
|
py
|
7f54204aed468a507848dd7d1c8cf8f858d7db4d
|
diff --git a/lib/rules/rules.js b/lib/rules/rules.js
index <HASH>..<HASH> 100644
--- a/lib/rules/rules.js
+++ b/lib/rules/rules.js
@@ -507,7 +507,7 @@ proto.resolveRule = function(url, index) {
return;
}
rule = {
- rule: rule
+ rule: rule
};
util.ignoreRules(rule, filter);
return rule.rule;
diff --git a/lib/util/index.js b/lib/util/index.js
index <HASH>..<HASH> 100644
--- a/lib/util/index.js
+++ b/lib/util/index.js
@@ -1257,6 +1257,7 @@ function ignoreRules(rules, ignore, isResRules) {
delete ignore[name];
});
delete ignore.http;
+ delete ignore.filter;
Object.keys(ignore).forEach(function(name) {
if (!isResRules || protoMgr.resProtocols.indexOf(name) != -1) {
if (ignorePlugins(rules, name)) {
|
refactor: Exclude ignore: filter, https, http, hide, intercept
|
avwo_whistle
|
train
|
js,js
|
a36b2112aafcee309a02de0cff5440cf69cd53a7
|
diff --git a/src/identify/index.js b/src/identify/index.js
index <HASH>..<HASH> 100644
--- a/src/identify/index.js
+++ b/src/identify/index.js
@@ -202,9 +202,9 @@ class IdentifyService {
this.peerStore.protoBook.set(id, protocols)
this.peerStore.metadataBook.set(id, 'AgentVersion', uint8ArrayFromString(message.agentVersion))
- // TODO: Score our observed addr
+ // TODO: Add and score our observed addr
log('received observed address of %s', observedAddr)
- this.addressManager.addObservedAddr(observedAddr)
+ // this.addressManager.addObservedAddr(observedAddr)
}
/**
|
fix: do not add observed address received from peers (#<I>)
|
libp2p_js-libp2p
|
train
|
js
|
8eae41b24446f260693178fa3abc757fe88a5447
|
diff --git a/packages/react/src/components/NumberInput/NumberInput.js b/packages/react/src/components/NumberInput/NumberInput.js
index <HASH>..<HASH> 100644
--- a/packages/react/src/components/NumberInput/NumberInput.js
+++ b/packages/react/src/components/NumberInput/NumberInput.js
@@ -301,6 +301,8 @@ class NumberInput extends Component {
'aria-label': ariaLabel,
};
+ const errorId = `${id}-error-id`;
+
const buttonProps = {
disabled,
type: 'button',
@@ -311,7 +313,9 @@ class NumberInput extends Component {
if (invalid || (!allowEmpty && this.state.value === '')) {
inputWrapperProps['data-invalid'] = true;
error = (
- <div className={`${prefix}--form-requirement`}>{invalidText}</div>
+ <div className={`${prefix}--form-requirement`} id={errorId}>
+ {invalidText}
+ </div>
);
}
@@ -381,6 +385,9 @@ class NumberInput extends Component {
{helper}
<div className={`${prefix}--number__input-wrapper`}>
<input
+ data-invalid={invalid || null}
+ aria-invalid={invalid || null}
+ aria-describedby={errorId}
type="number"
pattern="[0-9]*"
{...other}
|
fix(number-input): mimic text input validation a<I>y (#<I>)
|
carbon-design-system_carbon-components
|
train
|
js
|
2e1c7e96f01e07c78475fd51619c52c230661f30
|
diff --git a/index.js b/index.js
index <HASH>..<HASH> 100644
--- a/index.js
+++ b/index.js
@@ -9,7 +9,7 @@ var analyze = require('./lib/analyze');
* Unpacks, parses, validates, and analyzes Scratch projects. If successful,
* will return a valid Scratch project object with appended metadata.
*
- * @param {Buffer} Input buffer
+ * @param {Buffer | string} Input buffer or string representing scratch project
*
* @return {Object}
*/
|
docs(index): Update jsdocs for function exported by index.js.
|
LLK_scratch-parser
|
train
|
js
|
cea0452bce4fd255cff1fc8fa3d1c083b401568c
|
diff --git a/app/models/concerns/fog_extensions/proxmox/server.rb b/app/models/concerns/fog_extensions/proxmox/server.rb
index <HASH>..<HASH> 100644
--- a/app/models/concerns/fog_extensions/proxmox/server.rb
+++ b/app/models/concerns/fog_extensions/proxmox/server.rb
@@ -55,7 +55,7 @@ module FogExtensions
delegate :description, to: :config
def vm_description
- "Name=#{name}, vmid=#{vmid}"
+ _("Type %{type}, node %{node}, %{cpus} CPUs and %{memory} MB memory") % { :type => type, :node => node_id, :cpus => config.cores || '0', :memory => config.memory / (1024 * 1024) || '0' }
end
def select_nic(fog_nics, nic)
|
feat: :lipstick: vm description used into profiles
|
theforeman_foreman_fog_proxmox
|
train
|
rb
|
4d1d60c34a9d3b1a800667a6300a6a5f96c69437
|
diff --git a/views/cypress/support/resourceProperties.js b/views/cypress/support/resourceProperties.js
index <HASH>..<HASH> 100644
--- a/views/cypress/support/resourceProperties.js
+++ b/views/cypress/support/resourceProperties.js
@@ -141,6 +141,17 @@ Cypress.Commands.add('assignValueToTextProperty', (property, value) => {
});
/**
+ * Assigns value to the calendar property
+ * @param {Object} property - property to assign value to
+ * @param {String} property.name - name of the property
+ * @param {String} value - value to assign
+*/
+Cypress.Commands.add('assignValueToCalendarProperty', (property, value) => {
+ cy.log('COMMAND: assignValueToCalendarProperty', property.name);
+ cy.get(`[id^="${property.name}_calendar_"]`).clear().type(value);
+});
+
+/**
* Assigns value to the checkbox/radio property
* @param {Object} property - property to assign value to
* @param {String} property.name - name of the property
|
feat: add assign value to calendar cypress command
|
oat-sa_tao-core
|
train
|
js
|
e981cc156b447ce7a936114dafac591126fd65dd
|
diff --git a/lib/v8-to-istanbul.js b/lib/v8-to-istanbul.js
index <HASH>..<HASH> 100644
--- a/lib/v8-to-istanbul.js
+++ b/lib/v8-to-istanbul.js
@@ -82,8 +82,14 @@ module.exports = class V8ToIstanbul {
startCol,
endCol
} = this._maybeRemapStartColEndCol(range)
-
const lines = this.source.lines.filter(line => {
+ // Upstream tooling can provide a block with the functionName
+ // (empty-report), this will result in a report that has all
+ // lines zeroed out.
+ if (block.functionName === '(empty-report)') {
+ line.count = 0
+ return true
+ }
return startCol <= line.endCol && endCol >= line.startCol
})
const startLineInstance = lines[0]
|
feat: adds special (empty-report) block (#<I>)
|
istanbuljs_v8-to-istanbul
|
train
|
js
|
68698b3759035464ed9b069c6a263e047f4de3f2
|
diff --git a/src/Models/Sde/MapDenormalize.php b/src/Models/Sde/MapDenormalize.php
index <HASH>..<HASH> 100644
--- a/src/Models/Sde/MapDenormalize.php
+++ b/src/Models/Sde/MapDenormalize.php
@@ -186,14 +186,6 @@ class MapDenormalize extends Model
}
/**
- * @return int
- */
- public function getTypeIdAttribute()
- {
- return $this->typeID;
- }
-
- /**
* @return string
*/
public function getNameAttribute()
|
fix(sde): Remove typeID special attribute as it is already defined (#<I>)
Closes eveseat/seat#<I>
|
eveseat_eveapi
|
train
|
php
|
a9e0323eec01ac33798bb34ba0e5803081c3d980
|
diff --git a/src/utils.js b/src/utils.js
index <HASH>..<HASH> 100644
--- a/src/utils.js
+++ b/src/utils.js
@@ -5,7 +5,7 @@ let style = {}
let lastNotification = ''
const deferred = {}
-const impacts = ['critical', 'serious', 'moderate', 'minor']
+const impacts = [...axeCore.constants.impact].reverse()
export function checkAndReport (options, node) {
const deferred = createDeferred()
|
chore: Get impacts by axeCore constants
|
vue-a11y_vue-axe
|
train
|
js
|
226e252556476af3f9a28b388fb60c790b23f33e
|
diff --git a/test/extended/util/prometheus/helpers.go b/test/extended/util/prometheus/helpers.go
index <HASH>..<HASH> 100644
--- a/test/extended/util/prometheus/helpers.go
+++ b/test/extended/util/prometheus/helpers.go
@@ -97,6 +97,7 @@ func LocatePrometheus(oc *exutil.CLI) (queryURL, prometheusURL, bearerToken stri
type MetricCondition struct {
Selector map[string]string
Text string
+ Matches func(sample *model.Sample) bool
}
type MetricConditions []MetricCondition
@@ -109,9 +110,9 @@ func (c MetricConditions) Matches(sample *model.Sample) *MetricCondition {
matches = false
break
}
- if matches {
- return &c[i]
- }
+ }
+ if matches && (condition.Matches == nil || condition.Matches(sample)) {
+ return &c[i]
}
}
return nil
|
test: Alert check should check all conditions
The alert was exiting early after only one matching condition, which
means it was overly aggressively matching the first label. We may
have more bugs after this.
Also add a new custom function to allow conditions to apply only in
specific cases.
|
openshift_origin
|
train
|
go
|
bab00bd7cb84fc69c3639bdbe19636a9e4cfa1df
|
diff --git a/packages/editor/src/index.js b/packages/editor/src/index.js
index <HASH>..<HASH> 100644
--- a/packages/editor/src/index.js
+++ b/packages/editor/src/index.js
@@ -277,6 +277,7 @@ function init() {
console.error(msg);
// eslint-disable-next-line no-alert
window.alert(msg);
+ trigger.innerText = 'Save & Close';
}
break;
}
|
fix: Reset button state on failed save
It's confusing to leave the button state as "Saving..." when it's no
longer trying to save. Depending on what went wrong, it's also possible
that trying again will work.
|
bolt-design-system_bolt
|
train
|
js
|
7d7580f602d28c069ca9c48273d2398a06967af8
|
diff --git a/packages/orbit-components/src/BaggageStepper/index.js b/packages/orbit-components/src/BaggageStepper/index.js
index <HASH>..<HASH> 100644
--- a/packages/orbit-components/src/BaggageStepper/index.js
+++ b/packages/orbit-components/src/BaggageStepper/index.js
@@ -39,6 +39,7 @@ const BaggageStepper = ({ onChange, defaultValue = 0, ...props }: Props): React.
onFocus,
disabled,
name,
+ selected,
dataTest,
minValue,
maxValue,
@@ -51,6 +52,7 @@ const BaggageStepper = ({ onChange, defaultValue = 0, ...props }: Props): React.
dataTest={dataTest}
value={value}
name={name}
+ selected={selected}
minValue={minValue}
maxValue={maxValue}
onKeyDown={handleKeyDown}
|
fix(BaggageStepper): forgotten prop (#<I>)
|
kiwicom_orbit-components
|
train
|
js
|
dab0cfc5bf6662eeb9bb3f0b26b5a5a785eab94e
|
diff --git a/packages/search-field/src/SearchField.js b/packages/search-field/src/SearchField.js
index <HASH>..<HASH> 100644
--- a/packages/search-field/src/SearchField.js
+++ b/packages/search-field/src/SearchField.js
@@ -166,7 +166,7 @@ class SearchField extends React.Component {
onChange={this.onChange}
type={focused ? "search" : "text"}
clearable={!!inputValue}
- clearIcon={focused ? "wg-edit" : undefined}
+ clearIcon={focused ? undefined : "wg-edit"}
displayBlock
onKeyDown={this.onKeyDown}
onFocus={this.onFocus}
|
fix(search-field): clearIcon inverted
affects: @crave/farmblocks-search-field
|
CraveFood_farmblocks
|
train
|
js
|
e6d7dd2e01c495c6da327269c06f4ab08fde6117
|
diff --git a/allauth/utils.py b/allauth/utils.py
index <HASH>..<HASH> 100644
--- a/allauth/utils.py
+++ b/allauth/utils.py
@@ -80,11 +80,16 @@ def generate_username_candidate(basename, suffix_length):
def generate_username_candidates(basename):
- ret = [basename]
+ from .account.app_settings import USERNAME_MIN_LENGTH
+ if len(basename) >= USERNAME_MIN_LENGTH:
+ ret = [basename]
+ else:
+ ret = []
+ min_suffix_length = max(1, USERNAME_MIN_LENGTH - len(basename))
max_suffix_length = min(
get_username_max_length(),
MAX_USERNAME_SUFFIX_LENGTH)
- for suffix_length in range(2, max_suffix_length):
+ for suffix_length in range(min_suffix_length, max_suffix_length):
ret.append(generate_username_candidate(basename, suffix_length))
return ret
|
fix(account): Honor ACCOUNT_USERNAME_MIN_LENGTH by setting min_suffix_length in generate_username_candidates in utils.py
|
pennersr_django-allauth
|
train
|
py
|
b5bb6e6db3e2b68da2a4005165f7c338c8279361
|
diff --git a/docs/conf.py b/docs/conf.py
index <HASH>..<HASH> 100644
--- a/docs/conf.py
+++ b/docs/conf.py
@@ -147,7 +147,7 @@ html_theme = 'alabaster'
# Add any paths that contain custom static files (such as style sheets) here,
# relative to this directory. They are copied after the builtin static files,
# so a file named "default.css" will overwrite the builtin "default.css".
-html_static_path = ['_static']
+html_static_path = []
# Add any extra paths that contain custom files (such as robots.txt or
# .htaccess) here, relative to this directory. These files are copied
|
docs: _static directory does not exist
|
geertj_pyskiplist
|
train
|
py
|
d73380fea33635fdec7450b7c3c02b665aa25e88
|
diff --git a/lib/launcher.js b/lib/launcher.js
index <HASH>..<HASH> 100644
--- a/lib/launcher.js
+++ b/lib/launcher.js
@@ -18,6 +18,7 @@ process.on('unhandledRejection', error => {
async function launch() {
let app;
+ const carloArgs = process.env.NDB_CARLO_ARGS ? JSON.parse(process.env.NDB_CARLO_ARGS) : {};
try {
app = await carlo.launch({
bgcolor: '#242424',
@@ -28,7 +29,8 @@ async function launch() {
argv: process.argv,
nodeExecPath: process.execPath
})).toString('base64')
- }
+ },
+ ...carloArgs
});
} catch (e) {
if (e.message !== 'Could not start the browser or the browser was already running with the given profile.')
|
feat: Support for passing args to carlo
Ability to specify additional arguments to
carlo through an environment variable (NDB_CARLO_ARGS)
Ref #<I>
|
GoogleChromeLabs_ndb
|
train
|
js
|
47eb7b9855c1995acb7d1bcae8d0f150bd7a056e
|
diff --git a/src/Models/Mail/MailHeader.php b/src/Models/Mail/MailHeader.php
index <HASH>..<HASH> 100644
--- a/src/Models/Mail/MailHeader.php
+++ b/src/Models/Mail/MailHeader.php
@@ -99,6 +99,13 @@ class MailHeader extends Model
protected $primaryKey = null;
/**
+ * @var array
+ */
+ protected $casts = [
+ 'labels' => 'array',
+ ];
+
+ /**
* @return \Illuminate\Database\Eloquent\Relations\HasOne
*/
public function body()
|
fix(mail): Add missing cast definition on MailHeader (#<I>)
Labels field had no cast whereas we're storing them as a json array. Initial fix introduced with
eveseat/eveapi#ace<I> result in exception due to that missing cast in the model.
Closes eveseat/seat#<I>
|
eveseat_eveapi
|
train
|
php
|
b23e606d8fe47a474b45b4bbe5a518efb3b4b47e
|
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
@@ -36,7 +36,9 @@ describe('Transactions', function() {
'increment txnNumber',
// There is something wrong with the distinct command in the runner:
// it is not failing properly
- 'add transient label to connection errors'
+ 'add transient label to connection errors',
+ // Skipping this until SPEC-1320 is resolved
+ 'remain pinned after non-transient error on commit'
];
return SKIP_TESTS.indexOf(spec.description) === -1;
|
test(transactions): disable invalid pinning test
Disables test 'remain pinned after non-transient error on commit'
until SPEC-<I> is resolved
|
mongodb_node-mongodb-native
|
train
|
js
|
88adb49acfec5f8649be9f05e9b621eff83a821c
|
diff --git a/intranet/apps/printing/views.py b/intranet/apps/printing/views.py
index <HASH>..<HASH> 100644
--- a/intranet/apps/printing/views.py
+++ b/intranet/apps/printing/views.py
@@ -54,13 +54,9 @@ def get_printers() -> List[str]:
names = []
for line in lines:
if "requests since" in line:
- names.append(line.split(" ", 1)[0])
-
- if "Please_Select_a_Printer" in names:
- names.remove("Please_Select_a_Printer")
-
- if "" in names:
- names.remove("")
+ name = line.split(" ", 1)[0]
+ if name and name != "Please_Select_a_Printer":
+ names.append(name)
cache.set(key, names, timeout=settings.CACHE_AGE["printers_list"])
return names
@@ -309,7 +305,7 @@ def print_job(obj: PrintJob, do_print: bool = True):
)
if do_print:
- args = ["lpr", "-P", "{}".format(printer), "{}".format(final_filename)]
+ args = ["lpr", "-P", printer, final_filename]
if obj.page_range:
args.extend(["-o", "page-ranges={}".format(obj.page_range)])
|
refactor(printing): minor cleanup
|
tjcsl_ion
|
train
|
py
|
c9837caa5826e9ace9b60022dee41de462fa955a
|
diff --git a/src/lib.js b/src/lib.js
index <HASH>..<HASH> 100644
--- a/src/lib.js
+++ b/src/lib.js
@@ -54,6 +54,7 @@ import drawLink from './drawing/drawLink.js';
import drawLinkedTextBox from './drawing/drawLinkedTextBox.js';
import drawHandles from './drawing/drawHandles.js';
+import getActiveTool from './util/getActiveTool';
import getLuminance from './util/getLuminance.js';
import getROITextBoxCoords from './util/getROITextBoxCoords';
import copyPoints from './util/copyPoints.js';
@@ -131,6 +132,7 @@ export const lib = {
'drawing/drawHandles': drawHandles,
'drawing/textBoxWidth': textBoxWidth,
+ 'util/getActiveTool': getActiveTool,
'util/getLuminance': getLuminance,
'util/getROITextBoxCoords': getROITextBoxCoords,
'util/copyPoints': copyPoints,
|
fix: Expose getActiveTool from Utils (#<I>)
|
cornerstonejs_cornerstoneTools
|
train
|
js
|
e9374b87cb90f4062201715f8cafc8990c93887b
|
diff --git a/test/specs/mounting-options/slots.spec.js b/test/specs/mounting-options/slots.spec.js
index <HASH>..<HASH> 100644
--- a/test/specs/mounting-options/slots.spec.js
+++ b/test/specs/mounting-options/slots.spec.js
@@ -237,24 +237,6 @@ describeWithMountingMethods('options.slots', mountingMethod => {
}
})
- it('mounts functional component with only named text slot', () => {
- const TestComponent = {
- name: 'component-with-slots',
- functional: true,
- render: (h, ctx) => h('div', ctx.data, [ctx.slots().default, ctx.slots().footer])
- }
- const wrapper = mountingMethod(TestComponent, {
- slots: {
- footer: 'foo'
- }
- })
- if (mountingMethod.name === 'renderToString') {
- expect(wrapper).contains('foo')
- } else {
- expect(wrapper.text()).to.equal('foo')
- }
- })
-
it('mounts functional component with text slot', () => {
const TestComponent = {
name: 'component-with-slots',
|
fix: remove incorrect test (#<I>)
|
vuejs_vue-test-utils
|
train
|
js
|
1c40b8cf546969541d465a4b94d42a837d31205f
|
diff --git a/index.js b/index.js
index <HASH>..<HASH> 100644
--- a/index.js
+++ b/index.js
@@ -71,8 +71,8 @@ function prohibitedStrings (ast, file, strings) {
results.forEach(({ result, index }) => {
const message = val.yes ? `Use "${val.yes}" instead of "${result}"` : `Do not use "${result}"`
file.message(message, {
- start: location.toPosition(initial + index),
- end: location.toPosition(initial + index + [...result].length)
+ start: location.toPoint(initial + index),
+ end: location.toPoint(initial + index + [...result].length)
})
})
}
|
chore: update toPosition() to toPoint()
toPosition() is an alias of toPoint() and is deprecated.
Refs: <URL>
|
Trott_remark-lint-prohibited-strings
|
train
|
js
|
d3ad40bfa502f210315af15bb580efedcd9a91a4
|
diff --git a/src/miscellaneous/resolve.js b/src/miscellaneous/resolve.js
index <HASH>..<HASH> 100644
--- a/src/miscellaneous/resolve.js
+++ b/src/miscellaneous/resolve.js
@@ -71,7 +71,7 @@ module.exports = (createCommon, options) => {
// Test resolve turns /ipfs/QmRootHash/path/to/file into /ipfs/QmFileHash
it('should resolve an IPFS path link', (done) => {
- const path = '/path/to/testfile.txt'
+ const path = 'path/to/testfile.txt'
const content = loadFixture('test/fixtures/testfile.txt', 'interface-ipfs-core')
ipfs.add([{ path, content }], { wrapWithDirectory: true }, (err, res) => {
@@ -80,7 +80,7 @@ module.exports = (createCommon, options) => {
const rootHash = res.find(r => r.path === '').hash
const fileHash = res.find(r => r.path === path).hash
- ipfs.resolve(`/ipfs/${rootHash}${path}`, (err, path) => {
+ ipfs.resolve(`/ipfs/${rootHash}/${path}`, (err, path) => {
expect(err).to.not.exist()
expect(path).to.equal(`/ipfs/${fileHash}`)
done()
|
fix: don't expect ipfs to preserve a leading slash (#<I>)
Go-ipfs now normalizes paths before adding files. This will:
* remove any leading slashes.
* remove any `/./` components.
* normalize any `/../` components.
That breaks this test which assumes that paths are returned _exactly_ as
specified.
|
ipfs_interface-js-ipfs-core
|
train
|
js
|
f817ea2af6717702506eb0bf281b2a1b4c4cb414
|
diff --git a/lib/supervisor.js b/lib/supervisor.js
index <HASH>..<HASH> 100644
--- a/lib/supervisor.js
+++ b/lib/supervisor.js
@@ -121,7 +121,7 @@ module.exports = function (opts) {
}
if (workers.length === 0) {
- sb.hardKill();
+ sp.hardKill();
}
worker.requests.filter(function (d) {
|
fix(supervisor): spelling mistake
|
swanest_load-process-manager
|
train
|
js
|
5182ee4c595d393a57bad2c757ed75bbd7a2793d
|
diff --git a/packages/vuetify/build/babel-transform-sass-paths.js b/packages/vuetify/build/babel-transform-sass-paths.js
index <HASH>..<HASH> 100644
--- a/packages/vuetify/build/babel-transform-sass-paths.js
+++ b/packages/vuetify/build/babel-transform-sass-paths.js
@@ -10,7 +10,8 @@ function listener(path, file, opts) {
const matches = regex.exec(path.node.value)
if (!matches) return
const m = matches[0].startsWith('./') ? matches[0].substr(2) : matches[0]
- const folder = path.node.value.slice(2).replace('.sass', '')
+ const folder = file.hub.file.opts.filename.split('/').slice(2, 3)[0]
+
path.node.value = path.node.value.replace(matches[0], `${m}../../../src/components/${folder}/`)
}
}
|
fix: use actual folder containing file
script assumed any component importing a style file was in its own folder
|
vuetifyjs_vuetify
|
train
|
js
|
b494d46a81f34a18d2e0fefdf2881edc224c7b52
|
diff --git a/webapps/client/scripts/index.js b/webapps/client/scripts/index.js
index <HASH>..<HASH> 100644
--- a/webapps/client/scripts/index.js
+++ b/webapps/client/scripts/index.js
@@ -84,15 +84,13 @@ define('camunda-tasklist-ui', [
return $rootScope.authentication && $rootScope.authentication.name;
}
- $rootScope.$on('authentication.login.success', function() {
- if (!isAuth()) { return; }
+ function checkFilterCreationAccess() {
var Filter = camAPI.resource('filter');
$rootScope.authentication.userCanCreateFilter = false;
Filter.authorizations(function(err, resp) {
- if (!isAuth()) { return; }
if (err) { throw err; }
angular.forEach(resp.links, function(link) {
@@ -101,6 +99,12 @@ define('camunda-tasklist-ui', [
}
});
});
+ }
+
+ $rootScope.$watch('authentication', function(newValue, oldValue) {
+ if (isAuth() && (!oldValue || newValue.name !== oldValue.name)) {
+ checkFilterCreationAccess();
+ }
});
|
fix(filter): correct the filter creation authorization check
|
camunda_camunda-bpm-platform
|
train
|
js
|
948d4718769843a7d733fcd50f4bdd74f4f176d4
|
diff --git a/src/components/Search/Search.js b/src/components/Search/Search.js
index <HASH>..<HASH> 100644
--- a/src/components/Search/Search.js
+++ b/src/components/Search/Search.js
@@ -10,7 +10,7 @@ export default class Search extends Component {
type: PropTypes.string,
small: PropTypes.bool,
placeHolderText: PropTypes.string,
- labelText: PropTypes.string.isRequired,
+ labelText: PropTypes.node.isRequired,
id: PropTypes.string,
searchButtonLabelText: PropTypes.string,
layoutButtonLabelText: PropTypes.string,
|
fix(Search): allow arbitrary React nodes for label (#<I>)
Fixes #<I>.
|
carbon-design-system_carbon-components-react
|
train
|
js
|
6ae9a9159a6f0d17f9a0e655d6d6d54b237c5b4c
|
diff --git a/lib/versioning/semver-composer/index.js b/lib/versioning/semver-composer/index.js
index <HASH>..<HASH> 100644
--- a/lib/versioning/semver-composer/index.js
+++ b/lib/versioning/semver-composer/index.js
@@ -55,7 +55,6 @@ const minSatisfyingVersion = (versions, range) =>
semver.minSatisfyingVersion(versions.map(composer2npm), composer2npm(range));
function getNewValue(currentValue, rangeStrategy, fromVersion, toVersion) {
- const fromMajor = getMajor(fromVersion);
const toMajor = getMajor(toVersion);
const toMinor = getMinor(toVersion);
let newValue;
@@ -84,7 +83,7 @@ function getNewValue(currentValue, rangeStrategy, fromVersion, toVersion) {
newValue = `~${toMajor}`;
} else if (currentValue.match(/^~([0-9]*(?:\.[0-9]*)?)$/)) {
// handle ~4.1 case
- if (toMajor > fromMajor) {
+ if (fromVersion && toMajor > getMajor(fromVersion)) {
newValue = `~${toMajor}.0`;
} else {
newValue = `~${toMajor}.${toMinor}`;
|
fix(composer): lazy evaluate fromVersion major
|
renovatebot_renovate
|
train
|
js
|
e456c51b54fc281b72eee3ffd7a3003f3061f44a
|
diff --git a/lib/index.js b/lib/index.js
index <HASH>..<HASH> 100644
--- a/lib/index.js
+++ b/lib/index.js
@@ -97,7 +97,8 @@
});
};
- if (req.method === 'OPTIONS') {
+ var method = req.method && req.method.toUpperCase && req.method.toUpperCase();
+ if (method === 'OPTIONS') {
// preflight
headers.push(configureOrigin(options, req));
headers.push(configureCredentials(options, req));
diff --git a/test/cors.js b/test/cors.js
index <HASH>..<HASH> 100644
--- a/test/cors.js
+++ b/test/cors.js
@@ -74,6 +74,26 @@
cors()(req, res, next);
});
+ it('normalizes method names', function (done) {
+ // arrange
+ var req, res, next;
+ req = fakeRequest();
+ req.method = 'options';
+ res = fakeResponse();
+ res.end = function () {
+ // assert
+ res.statusCode.should.equal(204);
+ done();
+ };
+ next = function () {
+ // assert
+ done('should not be called');
+ };
+
+ // act
+ cors()(req, res, next);
+ });
+
it('no options enables default CORS to all origins', function (done) {
// arrange
var req, res, next;
|
fix: Normalize method names to use uppercase before comparison.
fixes #<I>
|
reconbot_json-inflector
|
train
|
js,js
|
2cfa6b125b81651fa1aa5cddc8a37613d6d5c1d9
|
diff --git a/src/Cache/NullCacheItemPool.php b/src/Cache/NullCacheItemPool.php
index <HASH>..<HASH> 100644
--- a/src/Cache/NullCacheItemPool.php
+++ b/src/Cache/NullCacheItemPool.php
@@ -66,7 +66,7 @@ class NullCacheItemPool implements CacheItemPoolInterface
public function deleteItem($key)
{
// do nothing
- return $this;
+ return true;
}
/**
|
fix: correct null psr6 cache pool impl to fit psr6
|
usemarkup_contentful
|
train
|
php
|
2a16064d6a471ae6bd44c025df759498a9ffbd08
|
diff --git a/google-apis-core/lib/google/apis/core/http_command.rb b/google-apis-core/lib/google/apis/core/http_command.rb
index <HASH>..<HASH> 100644
--- a/google-apis-core/lib/google/apis/core/http_command.rb
+++ b/google-apis-core/lib/google/apis/core/http_command.rb
@@ -275,7 +275,7 @@ module Google
# @yield [nil, err] if block given
# @raise [StandardError] if no block
def error(err, rethrow: false, &block)
- logger.debug { sprintf('Error - %s', PP.pp(err, '')) }
+ logger.error { sprintf('Error - %s', PP.pp(err, '')) }
if err.is_a?(HTTPClient::BadResponseError)
begin
res = err.res
|
chore(core): log errors as error instead of debug(#<I>)
|
googleapis_google-api-ruby-client
|
train
|
rb
|
10a136f274b0e6b9e4db550b74ca08ac4928a089
|
diff --git a/ipyvolume/style.py b/ipyvolume/style.py
index <HASH>..<HASH> 100644
--- a/ipyvolume/style.py
+++ b/ipyvolume/style.py
@@ -109,13 +109,11 @@ demo = create("demo", \
})
minimal = {
- 'background-color': 'white',
'box' : {
'visible': False,
},
'axes': {
'visible': False,
- 'color': 'black'
}
}
|
fix: style minimal does not define colors, so it can be mixed with dark
|
maartenbreddels_ipyvolume
|
train
|
py
|
7eb9ef48d7c1f35ad6a3a41ed590027ea7a5d9be
|
diff --git a/src/commands/model_generate.js b/src/commands/model_generate.js
index <HASH>..<HASH> 100644
--- a/src/commands/model_generate.js
+++ b/src/commands/model_generate.js
@@ -17,6 +17,11 @@ exports.builder =
type: 'string',
demandOption: true
})
+ .option('force', {
+ describe: 'Forcefully re-creates model with the same name',
+ type: 'string',
+ demandOption: false
+ })
)
.help()
.argv;
|
fix: add force flag to model:create (#<I>)
|
sequelize_cli
|
train
|
js
|
6b72e3893b2fc4635fae29a5c2c7beb54570744e
|
diff --git a/setup.py b/setup.py
index <HASH>..<HASH> 100644
--- a/setup.py
+++ b/setup.py
@@ -32,7 +32,7 @@ test_requires = [
'pytest~=5.4.1',
'pytest-cov',
'pytest-mock',
- 'pytest-asyncio>=0.11.0',
+ 'pytest-asyncio>=0.12.0',
'aioresponses~=0.6.3',
'asynctest>=0.13; python_version<"3.8"',
'codecov',
|
test: Update pytest-asyncio to <I>
|
lablup_backend.ai-client-py
|
train
|
py
|
21b4c1a369bcf9b1d3b7ba057b48622373e21632
|
diff --git a/actions/issues/src/conditions.js b/actions/issues/src/conditions.js
index <HASH>..<HASH> 100644
--- a/actions/issues/src/conditions.js
+++ b/actions/issues/src/conditions.js
@@ -47,7 +47,7 @@ const states = {
key: `has_issue_label_${label}`,
run(context) {
if (!context.payload.issue) {
- return;
+ return false;
}
return context.payload.issue.labels.find(({ name }) => {
return name === label;
@@ -67,10 +67,9 @@ function or(...conditions) {
return {
key: `or(${key})`,
run(context) {
- const condition = conditions.find((condition) => {
+ return conditions.some((condition) => {
return condition.run(context);
});
- return condition !== null;
},
};
}
|
chore(actions): update or() check with conditions
|
carbon-design-system_carbon-components
|
train
|
js
|
a7836a30e6429c508729ce30bdf32de2ff3b8605
|
diff --git a/src/swipe-cell/index.js b/src/swipe-cell/index.js
index <HASH>..<HASH> 100644
--- a/src/swipe-cell/index.js
+++ b/src/swipe-cell/index.js
@@ -31,6 +31,8 @@ export default createComponent({
},
},
+ emits: ['open', 'close', 'click'],
+
data() {
return {
offset: 0,
|
fix(SwipeCell): missing emits config
|
youzan_vant
|
train
|
js
|
4c8ac9631a067c50c583bde0f3cfbd31305595f8
|
diff --git a/actor/appium/src/main/java/org/getopentest/appium/core/AppiumTestAction.java b/actor/appium/src/main/java/org/getopentest/appium/core/AppiumTestAction.java
index <HASH>..<HASH> 100644
--- a/actor/appium/src/main/java/org/getopentest/appium/core/AppiumTestAction.java
+++ b/actor/appium/src/main/java/org/getopentest/appium/core/AppiumTestAction.java
@@ -294,6 +294,8 @@ public abstract class AppiumTestAction extends TestAction {
return MobileBy.iOSNsPredicateString(argValueAsMap.get("predicate").toString());
} else if (argValueAsMap.containsKey("iosClassChain")) {
return MobileBy.iOSClassChain(argValueAsMap.get("iosClassChain").toString());
+ } else if (argValueAsMap.containsKey("androidUiAutomator")) {
+ return MobileBy.AndroidUIAutomator(argValueAsMap.get("androidUiAutomator").toString());
} else if (argValueAsMap.containsKey("name")) {
return By.name(argValueAsMap.get("name").toString());
} else if (argValueAsMap.containsKey("css")) {
|
feat(appium): add support for Android UIAutomator locators
|
mcdcorp_opentest
|
train
|
java
|
2bfc82a31adbedc5f9e2e89122e13181d93345bd
|
diff --git a/app/middlewares.js b/app/middlewares.js
index <HASH>..<HASH> 100644
--- a/app/middlewares.js
+++ b/app/middlewares.js
@@ -1,6 +1,6 @@
import { compose, applyMiddleware } from 'redux';
-import * as ActionTypes from './ActionTypes';
-import * as Actions from './Actions';
+import * as ActionTypes from './actionTypes';
+import * as Actions from './actions';
function updateViewState({ getState, dispatch }) {
return (next) => (action) => {
|
fix(filename): PascalCase into camelCase (actionTypes and actions)
|
xodio_xod
|
train
|
js
|
e3b3b67a31b8bd1ef30fffcc7bfd3d77f942e80f
|
diff --git a/src/AlgoliaSearch/SynonymBrowser.php b/src/AlgoliaSearch/SynonymBrowser.php
index <HASH>..<HASH> 100644
--- a/src/AlgoliaSearch/SynonymBrowser.php
+++ b/src/AlgoliaSearch/SynonymBrowser.php
@@ -70,7 +70,8 @@ class SynonymBrowser implements \Iterator
// more results in Algolia, we get the next page
if (! isset($this->response['hits'][$this->position])
&& count($this->response['hits']) >= $this->hitsPerPage) {
- $this->doQuery($this->page + 1);
+ $this->page++;
+ $this->fetchCurrentPageResults();
}
}
@@ -108,7 +109,7 @@ class SynonymBrowser implements \Iterator
$this->page = 0;
$this->position = 0;
- $this->doQuery($this->page);
+ $this->fetchCurrentPageResults();
}
/**
@@ -116,12 +117,10 @@ class SynonymBrowser implements \Iterator
*
* @param $page Page number to call
*/
- private function doQuery($page)
+ private function fetchCurrentPageResults()
{
- $this->page = $page;
$this->position = 0;
-
- $this->response = $this->index->searchSynonyms('', array(), $page, $this->hitsPerPage);
+ $this->response = $this->index->searchSynonyms('', array(), $this->page, $this->hitsPerPage);
}
/**
|
refactor(synonymborwser): always rely on the same page state
|
algolia_algoliasearch-client-php
|
train
|
php
|
5d95c4c65968fae949525914f6a01c2a022c2f17
|
diff --git a/docs-site/src/components/bolt-select/bolt-select.standalone.js b/docs-site/src/components/bolt-select/bolt-select.standalone.js
index <HASH>..<HASH> 100644
--- a/docs-site/src/components/bolt-select/bolt-select.standalone.js
+++ b/docs-site/src/components/bolt-select/bolt-select.standalone.js
@@ -249,7 +249,7 @@ class BoltSelect extends withLitHtml() {
shouldSortItems: this.props.shouldSortItems,
searchPlaceholderValue: this.props.searchPlaceholderValue,
itemSelectText: this.props.itemSelectText,
-
+ searchEnabled: this.props.searchEnabled,
// @todo: continue adding additional options below as time + need permits
// silent: this.props.silent,
// items: this.props.items,
|
feat: allow <bolt-select> to optionally disable search
|
bolt-design-system_bolt
|
train
|
js
|
60a07b7e36fbfda1eefac87f9254cb6f1d904e40
|
diff --git a/packages/hw-transport-webhid/src/TransportWebHID.js b/packages/hw-transport-webhid/src/TransportWebHID.js
index <HASH>..<HASH> 100644
--- a/packages/hw-transport-webhid/src/TransportWebHID.js
+++ b/packages/hw-transport-webhid/src/TransportWebHID.js
@@ -114,6 +114,10 @@ export default class TransportWebHID extends Transport<HIDDevice> {
let unsubscribed = false;
getFirstLedgerDevice().then(
(device) => {
+ if (!device) {
+ throw new Error('Access denied to use Ledger device')
+ }
+
if (!unsubscribed) {
const deviceModel = identifyUSBProductId(device.productId);
observer.next({ type: "add", descriptor: device, deviceModel });
|
fix(TransportWebHID): device undefined error handling
|
LedgerHQ_ledgerjs
|
train
|
js
|
fad77ec0b5036af73dcd5747c9ff8f6fa0a70bac
|
diff --git a/src/entity.js b/src/entity.js
index <HASH>..<HASH> 100644
--- a/src/entity.js
+++ b/src/entity.js
@@ -640,10 +640,7 @@ function asObject(entity, shallow) {
}
});
- // We don't send along empty arrays.
- if (asObjects.length > 0) {
- pojo[propertyName] = asObjects;
- }
+ pojo[propertyName] = asObjects;
});
return pojo;
|
fix(entity): do not skip empty arrays
BREAKING CHANGE: toObject and toJSON will now return empty arrays instead of skipping completely
|
SpoonX_aurelia-orm
|
train
|
js
|
4c072adf0e56d22d8ec3c5402de2c05cd4d6d06b
|
diff --git a/lib/client.js b/lib/client.js
index <HASH>..<HASH> 100644
--- a/lib/client.js
+++ b/lib/client.js
@@ -161,7 +161,7 @@ extend(Raven.prototype, {
// also we want to make sure we don't go recursion crazy if more errors happen after this one
firstError = err;
caughtFirstError = true;
- self.captureException(err, function(sendErr, eventId) {
+ self.captureException(err, {level: 'fatal'}, function(sendErr, eventId) {
if (!calledFatalError) {
calledFatalError = true;
self.onFatalError(err, sendErr, eventId);
|
fix: Report fatal errors as indeed "fatal" (#<I>)
|
getsentry_sentry-javascript
|
train
|
js
|
203528ecdb6372f58ad5a6b168e33992c34eec9e
|
diff --git a/src/plugins/media_control/media_control.js b/src/plugins/media_control/media_control.js
index <HASH>..<HASH> 100644
--- a/src/plugins/media_control/media_control.js
+++ b/src/plugins/media_control/media_control.js
@@ -342,6 +342,7 @@ export default class MediaControl extends UICorePlugin {
toggleFullscreen() {
this.trigger(Events.MEDIACONTROL_FULLSCREEN, this.name)
this.container.fullscreen()
+ this.core.toggleFullscreen()
this.resetUserKeepVisible()
}
|
refactor(media_control): call toggleFullscreen core method at toggleFullscreen media control method
|
clappr_clappr
|
train
|
js
|
7df9420edf552c770b3415ebb85c655afd70877b
|
diff --git a/Gruntfile.js b/Gruntfile.js
index <HASH>..<HASH> 100644
--- a/Gruntfile.js
+++ b/Gruntfile.js
@@ -38,7 +38,7 @@ module.exports = function (grunt) {
tagName: 'v%VERSION%',
tagMessage: 'Version %VERSION%',
push: true,
- pushTo: 'origin master',
+ pushTo: 'origin',
gitDescribeOptions: '--tags --always --abbrev=1 --dirty=-d' // options to use with '$ git describe'
}
},
|
fix(grunt): revert failed merge
Accidentally overwrite the fix in f<I>e<I> for the failing `grunt bump`
task with the style changes in #<I>.
|
seriema_angular-apimock
|
train
|
js
|
b73590f4f9aa2a162140efddf84cf4b56c04dce7
|
diff --git a/packages/core/src/util/buffer.js b/packages/core/src/util/buffer.js
index <HASH>..<HASH> 100644
--- a/packages/core/src/util/buffer.js
+++ b/packages/core/src/util/buffer.js
@@ -5,23 +5,13 @@
'use strict';
-const semver = require('semver');
-
// This is no longer used as of release 1.110.3, but apparently there are setups where the version of @instana/collector
// and @instana/core do not match, so we need to keep this around for a while for backwards compatibility.
-// Node.js 0.12 is lacking support for Buffer.from,
-// and < 4.5.0 version Buffer.from doesn't support string as parameter
-const suppotsBufferFrom = Buffer.from && semver.satisfies(process.versions.node, '>=4.5.0');
-
/**
* @param {string} str
* @param {BufferEncoding} [encoding]
*/
exports.fromString = function fromString(str, encoding = 'utf8') {
- if (suppotsBufferFrom) {
- return Buffer.from(str, encoding);
- }
- // eslint-disable-next-line no-buffer-constructor
- return new Buffer(str, encoding);
+ return Buffer.from(str, encoding);
};
|
chore: removed node version check in core/src/util/buffer.js
refs <I>
- Buffer.from is support >= <I> (and even earlier versions)
- <URL>
|
instana_nodejs-sensor
|
train
|
js
|
8df46ab130e3adf962bf7114c32207c810bbc81f
|
diff --git a/lib/utils.js b/lib/utils.js
index <HASH>..<HASH> 100644
--- a/lib/utils.js
+++ b/lib/utils.js
@@ -28,6 +28,7 @@ var notifySendFlags = {
u: 'urgency',
urgency: 'urgency',
t: 'expire-time',
+ time: 'expire-time',
e: 'expire-time',
expire: 'expire-time',
'expire-time': 'expire-time',
diff --git a/test/notify-send.js b/test/notify-send.js
index <HASH>..<HASH> 100644
--- a/test/notify-send.js
+++ b/test/notify-send.js
@@ -73,7 +73,7 @@ describe('notify-send', function() {
it(
'should remove extra options that are not supported by notify-send',
function(done) {
- var expected = [ '"title"', '"body"', '--icon', '"icon-string"' ];
+ var expected = [ '"title"', '"body"', '--icon', '"icon-string"', '--expire-time', '"100"' ];
expectArgsListToBe(expected, done);
var notifier = new Notify({ suppressOsdCheck: true });
@@ -81,6 +81,7 @@ describe('notify-send', function() {
title: 'title',
message: 'body',
icon: 'icon-string',
+ time: 100,
tullball: 'notValid'
});
}
|
fix: link notifier time property to notify-send expire-time flag
The `time` property specified in the documentation had
no effect since it wasn't link to notify-send
expire-time flag
|
mikaelbr_node-notifier
|
train
|
js,js
|
a777e979ebb896816121b51d5dce2d6dac941b0f
|
diff --git a/packages/reactstrap-validation-select/AvResourceSelect.js b/packages/reactstrap-validation-select/AvResourceSelect.js
index <HASH>..<HASH> 100644
--- a/packages/reactstrap-validation-select/AvResourceSelect.js
+++ b/packages/reactstrap-validation-select/AvResourceSelect.js
@@ -125,7 +125,7 @@ class AvResourceSelect extends Component {
let fetch;
if (this.props.graphqlConfig || this.props.method === 'POST') {
fetch = () =>
- this.props.resource.post(data, {
+ this.props.resource.post(data || params, {
headers: {
'Content-Type': 'application/json',
},
|
refactor(reactstrap-validation-select): fixed params not posting for method override
|
Availity_availity-react
|
train
|
js
|
36938e63ac7c949489a09be06a5eb97973cf3293
|
diff --git a/webapps/ui/tasklist/tests/pages/dashboard/tasklist/task-list.js b/webapps/ui/tasklist/tests/pages/dashboard/tasklist/task-list.js
index <HASH>..<HASH> 100644
--- a/webapps/ui/tasklist/tests/pages/dashboard/tasklist/task-list.js
+++ b/webapps/ui/tasklist/tests/pages/dashboard/tasklist/task-list.js
@@ -185,7 +185,7 @@ module.exports = Page.extend({
showMoreVariables: function(idxOrName) {
function callPageObject(idx) {
- this.taskList().get(idx).element(by.css('.shutter .glyphicon-chevron-down')).click();
+ this.taskList().get(idx).element(by.css('.shutter .glyphicon-menu-down')).click();
}
if (typeof idxOrName === 'number') {
|
test(tasklist): change selector of variable shutter
to reflect changes made in CAM-<I>
|
camunda_camunda-bpm-platform
|
train
|
js
|
ac42bba8516151773566d4936bc6575fc7bf6d74
|
diff --git a/type.go b/type.go
index <HASH>..<HASH> 100644
--- a/type.go
+++ b/type.go
@@ -61,6 +61,9 @@ var SupportedImageTypes = map[ImageType]bool{
// isBinary checks if the given buffer is a binary file.
func isBinary(buf []byte) bool {
+ if len(buf) < 24 {
+ return false
+ }
for i := 0; i < 24; i++ {
charCode, _ := utf8.DecodeRuneInString(string(buf[i]))
if charCode == 65533 || charCode <= 8 {
|
fix(type): check buffer length
|
h2non_bimg
|
train
|
go
|
e6e9d8c8df035555e245424d16d7abe227d74936
|
diff --git a/src/schema/schema.js b/src/schema/schema.js
index <HASH>..<HASH> 100644
--- a/src/schema/schema.js
+++ b/src/schema/schema.js
@@ -266,10 +266,10 @@ function getFields(graffitiModels, {
};
}, {
queries: isFunction(customQueries)
- ? customQueries(mapValues(types, (type) => createInputObject(type)))
+ ? customQueries(mapValues(types, (type) => createInputObject(type)), types)
: customQueries,
mutations: isFunction(customMutations)
- ? customMutations(mapValues(types, (type) => createInputObject(type)))
+ ? customMutations(mapValues(types, (type) => createInputObject(type)), types)
: customMutations
});
|
feat(schema): pass in types for customQueries and customMutations (#<I>)
|
RisingStack_graffiti-mongoose
|
train
|
js
|
0765c11639d4e788de5f978a1ee753be167db2d0
|
diff --git a/lib/FileStorage.js b/lib/FileStorage.js
index <HASH>..<HASH> 100644
--- a/lib/FileStorage.js
+++ b/lib/FileStorage.js
@@ -127,7 +127,9 @@ FileStorage.prototype.rotateLog = function (noOpen, callback) {
if (!noOpen) {
- fs.rename(this.logFileName(),this.logFileName()+'.bak');
+ if (fs.existsSync(this.logFileName())) {
+ fs.rename(this.logFileName(),this.logFileName()+'.bak');
+ }
this.logFile = fs.createWriteStream(this.logFileName()); // TODO file swap
this.logFile.on('error', function (err) {
self.close(null,err);
|
fix: rename non-existing file
|
gritzko_swarm
|
train
|
js
|
4d3cf50fee86d9b3ecba99a80ec64aacfd524bce
|
diff --git a/src/utils.js b/src/utils.js
index <HASH>..<HASH> 100644
--- a/src/utils.js
+++ b/src/utils.js
@@ -14,7 +14,7 @@ function getCommentContent( input ) {
return input.replace( /^\/\//, '' );
}
- return input.replace( /^\/\*/, '' ).replace( /\*\/$/, '' );
+ return input.replace( /^\/\*/, '' ).replace( /\*\/\n?$/, '' );
}
export { isComment };
diff --git a/tests/utils.js b/tests/utils.js
index <HASH>..<HASH> 100644
--- a/tests/utils.js
+++ b/tests/utils.js
@@ -68,6 +68,7 @@ describe( 'getCommentContent', () => {
'/**/': '',
'/*\n*/': '\n',
'/*T\ne\ns\nt */': 'T\ne\ns\nt ',
+ '/*Test*/\n': 'Test',
'//test': 'test',
'//Test\n': 'Test\n',
'// test': ' test',
|
feat(utils): support newline after multiline comment
|
Comandeer_babel-plugin-banner
|
train
|
js,js
|
e3e1396d9d8031273a832987040e5c5544c54195
|
diff --git a/lib/index.js b/lib/index.js
index <HASH>..<HASH> 100644
--- a/lib/index.js
+++ b/lib/index.js
@@ -11,9 +11,7 @@ const adjustType = type => {
};
function documentModel(Model) {
- const modelName = Model.modelName;
const obj = {
- id: modelName,
properties: {},
required: []
};
diff --git a/test/index.js b/test/index.js
index <HASH>..<HASH> 100644
--- a/test/index.js
+++ b/test/index.js
@@ -15,7 +15,6 @@ describe('mongoose-to-swagger', function () {
it('should do something', () => {
const Cat = mongoose.model('Cat', {name: String});
const swaggerSchema = m2s(Cat);
- expect(swaggerSchema.id).toBe('Cat');
expect(swaggerSchema.properties).toExist();
});
});
@@ -35,7 +34,6 @@ describe('mongoose-to-swagger', function () {
}
});
const swaggerSchema = m2s(Dog);
- expect(swaggerSchema.id).toBe('Dog');
expect(swaggerSchema.required).toEqual(['name', 'likesWater']);
});
});
|
fix: Additional properties not allowed: id - not allowed to add extra properties in swagger <I>
|
giddyinc_mongoose-to-swagger
|
train
|
js,js
|
3fbe9f235a1cc994c0eee24f55ffae7fa952ce63
|
diff --git a/docs/.vuepress/config.js b/docs/.vuepress/config.js
index <HASH>..<HASH> 100644
--- a/docs/.vuepress/config.js
+++ b/docs/.vuepress/config.js
@@ -8,6 +8,11 @@ module.exports = {
lineNumbers: true
},
themeConfig: {
+ repo: "tendermint/tendermint",
+ editLinks: true,
+ docsDir: "docs",
+ docsBranch: "develop",
+ editLinkText: 'Edit this page on Github',
lastUpdated: true,
algolia: {
apiKey: '59f0e2deb984aa9cdf2b3a5fd24ac501',
|
docs: add edit on Github links (#<I>)
|
tendermint_tendermint
|
train
|
js
|
67cc7de17de1b9f106a33823f9ec2a3ea3e8f155
|
diff --git a/roc.config.js b/roc.config.js
index <HASH>..<HASH> 100644
--- a/roc.config.js
+++ b/roc.config.js
@@ -4,7 +4,7 @@ module.exports = {
targets: ['cjs'],
babelPresetEnv: {
targets: {
- node: '4.8',
+ node: '6',
},
},
mono: [
|
chore(ALL): Update the babel preset to target Node 6
BREAKING CHANGES: Users of Node 4 will need to upgrade to Node 6
|
rocjs_extensions
|
train
|
js
|
224ce38882d0842305b498a554779feb90b9959d
|
diff --git a/packages/babel-preset-stage-3/src/index.js b/packages/babel-preset-stage-3/src/index.js
index <HASH>..<HASH> 100644
--- a/packages/babel-preset-stage-3/src/index.js
+++ b/packages/babel-preset-stage-3/src/index.js
@@ -33,7 +33,7 @@ export default declare((api, opts) => {
syntaxImportMeta,
transformAsyncGeneratorFunctions,
[transformClassProperties, { loose }],
- [transformObjectRestSpread, { useBuiltIns }],
+ [transformObjectRestSpread, { loose, useBuiltIns }],
transformOptionalCatchBinding,
transformUnicodePropertyRegex,
],
|
fix(preset-stage-3): pass along loose flag to proposal-object-rest-spread (#<I>)
|
babel_babel
|
train
|
js
|
cfdaa445198927cea096071e14c66b1f97456f2c
|
diff --git a/src/Alert/index.js b/src/Alert/index.js
index <HASH>..<HASH> 100644
--- a/src/Alert/index.js
+++ b/src/Alert/index.js
@@ -210,8 +210,6 @@ class AlertUnstyled extends React.Component { // eslint-disable-line react/prefe
};
render() {
- console.log(this.props.autoHideDuration, 'autoHideDuration');
-
const {
className,
cssModule,
|
fix(Alert): Removed console.log()
|
bootstrap-styled_v4
|
train
|
js
|
9cdef4d1a44de4392518613227076bfa371497c0
|
diff --git a/webapps/ui/cockpit/plugins/tasks/app/views/dashboard/task-dashboard.js b/webapps/ui/cockpit/plugins/tasks/app/views/dashboard/task-dashboard.js
index <HASH>..<HASH> 100644
--- a/webapps/ui/cockpit/plugins/tasks/app/views/dashboard/task-dashboard.js
+++ b/webapps/ui/cockpit/plugins/tasks/app/views/dashboard/task-dashboard.js
@@ -58,7 +58,7 @@ module.exports = ['ViewsProvider', function(ViewsProvider) {
var resourceCallback = function(err, res) {
if (err) {
Notifications.addError({
- status: $translate.instant('PLUGIN_TASK_ASSIGNED_ERR_COULD_NOT', {err: getErrorStatus}),
+ status: $translate.instant('PLUGIN_TASK_ASSIGNED_ERR_COULD_NOT', {err: getErrorStatus()}),
message: err.toString()
});
deferred.reject(err);
|
chore(cockpit): fix broken error notification title
related to CAM-<I>
|
camunda_camunda-bpm-platform
|
train
|
js
|
8c3cf8f3d801bb5840535de2bc7c1755b8af8cf7
|
diff --git a/modules/browser.js b/modules/browser.js
index <HASH>..<HASH> 100644
--- a/modules/browser.js
+++ b/modules/browser.js
@@ -10,6 +10,7 @@ let noop = () => {}
* Browser detection
*/
let isBrowser = typeof window !== undefined
+
/**
* Browser functions needed by router5
*/
@@ -30,7 +31,9 @@ let getLocation = (opts) => {
return path + window.location.search;
}
-// Export
+/**
+ * Export browser object
+ */
let browser = {}
if (isBrowser) {
browser = {getBase, pushState, replaceState, addPopstateListener, removePopstateListener, getLocation}
diff --git a/modules/router5.js b/modules/router5.js
index <HASH>..<HASH> 100644
--- a/modules/router5.js
+++ b/modules/router5.js
@@ -331,7 +331,7 @@ class Router5 {
*/
buildUrl(route, params) {
return this.options.base +
- (this.options.useHash ?'#' + this.options.hashPrefix : '') +
+ (this.options.useHash ? '#' + this.options.hashPrefix : '') +
this.rootNode.buildPath(route, params)
}
|
refactor: fix linting issues
|
router5_router5
|
train
|
js,js
|
946fee9b8c03b16eaa60598376d3a7866aecc9c3
|
diff --git a/R/candela/inst/htmlwidgets/candela.js b/R/candela/inst/htmlwidgets/candela.js
index <HASH>..<HASH> 100644
--- a/R/candela/inst/htmlwidgets/candela.js
+++ b/R/candela/inst/htmlwidgets/candela.js
@@ -8,7 +8,6 @@ window.HTMLWidgets.widget({
renderValue: function (x) {
var render = function () {
if (window.candela) {
- console.log(JSON.stringify(x));
visualization = new window.candela.components[x.name](el, x.options);
visualization.render();
} else {
@@ -18,7 +17,7 @@ window.HTMLWidgets.widget({
render();
},
resize: function (width, height) {
- // TODO: code to re-render the widget with a new size
+ visualization.render();
}
};
}
|
chore(R): Rerender on resize in R library
|
Kitware_candela
|
train
|
js
|
53d455c92bac93f86fa8a12586f63cee3d750b31
|
diff --git a/mini-sync-sink.js b/mini-sync-sink.js
index <HASH>..<HASH> 100644
--- a/mini-sync-sink.js
+++ b/mini-sync-sink.js
@@ -11,6 +11,7 @@ class MiniSyncSink extends EventEmitter {
write (data, encoding, next) {
try {
this._write(data, encoding)
+ /* istanbul ignore next */
if (next) next()
return true
} catch (err) {
diff --git a/reduce-stream.js b/reduce-stream.js
index <HASH>..<HASH> 100644
--- a/reduce-stream.js
+++ b/reduce-stream.js
@@ -57,6 +57,7 @@ class ReduceStreamSync extends MiniSyncSink {
return false
}
}
+ /* istanbul ignore next */
if (next) next()
return true
}
|
chore(coverage): Skip coverage on optional next() args
|
iarna_funstream
|
train
|
js,js
|
0a7028db3d6e1681a1b33c055f36e635fb253a0e
|
diff --git a/test/utils.js b/test/utils.js
index <HASH>..<HASH> 100644
--- a/test/utils.js
+++ b/test/utils.js
@@ -200,7 +200,7 @@ Utils.prototype.findAttrs = function (db, partition, where) {
};
Utils.prototype.sortAttrs = function (attrs) {
- var sortAttrs = ['doc_id', 'name', 'updated_at', 'seq', 'value'];
+ var sortAttrs = ['doc_id', 'name', 'updated_at', 'seq', 'value', 'quorum'];
return utils.sort(attrs, sortAttrs);
};
@@ -404,4 +404,4 @@ Utils.prototype.shouldDoAndNotOnce = function (promiseFactory, emitter, evnt) {
});
};
-module.exports = new Utils();
\ No newline at end of file
+module.exports = new Utils();
|
fix(utils): also sort by quorum
|
delta-db_deltadb-server
|
train
|
js
|
d09a193ab21161cf462b08c806c3fccd7b09f792
|
diff --git a/packages/xod-project/src/index.js b/packages/xod-project/src/index.js
index <HASH>..<HASH> 100644
--- a/packages/xod-project/src/index.js
+++ b/packages/xod-project/src/index.js
@@ -6,6 +6,7 @@ import * as link from './link';
import * as constants from './constants';
import * as utils from './utils';
import * as funcTools from './func-tools';
+import flatten from './flatten';
import { toV2 } from './adapter';
export * from './project';
@@ -17,9 +18,11 @@ export * from './constants';
export * from './utils';
export * from './func-tools';
export { toV2 } from './adapter';
+export { default as flatten } from './flatten';
export default Object.assign({
toV2,
+ flatten,
},
project,
patch,
|
fix(xod-project): export flatten function from xod-project package
|
xodio_xod
|
train
|
js
|
a0661120d9321d78235352829bb173e989a6f814
|
diff --git a/lib/chai/config.js b/lib/chai/config.js
index <HASH>..<HASH> 100644
--- a/lib/chai/config.js
+++ b/lib/chai/config.js
@@ -1,6 +1,6 @@
module.exports = {
- /*!
+ /**
* ### config.includeStack
*
* User configurable property, influences whether stack trace
@@ -9,11 +9,13 @@ module.exports = {
*
* chai.config.includeStack = true; // enable stack on error
*
+ * @param {Boolean}
* @api public
*/
+
includeStack: false,
- /*!
+ /**
* ### config.showDiff
*
* User configurable property, influences whether or not
@@ -22,11 +24,13 @@ module.exports = {
* will be true when the assertion has requested a diff
* be shown.
*
+ * @param {Boolean}
* @api public
*/
+
showDiff: true,
- /*!
+ /**
* ### config.truncateThreshold
*
* User configurable property, sets length threshold for actual and
@@ -37,8 +41,10 @@ module.exports = {
*
* chai.config.truncateThreshold = 0; // disable truncating
*
+ * @param {Number}
* @api public
*/
+
truncateThreshold: 40
-};
\ No newline at end of file
+};
|
docs: [config] make public, express param type
|
chaijs_chai
|
train
|
js
|
b3238c8e6cdbc644341d40f242dd5952279ca403
|
diff --git a/webapps/ui/tasklist/client/scripts/config/config.js b/webapps/ui/tasklist/client/scripts/config/config.js
index <HASH>..<HASH> 100644
--- a/webapps/ui/tasklist/client/scripts/config/config.js
+++ b/webapps/ui/tasklist/client/scripts/config/config.js
@@ -35,7 +35,7 @@ var camTasklistConf = {
"description": "set the focus to the first filter in the list"
},
"focusList": {
- "key": "ctrl+shift+l",
+ "key": "ctrl+alt+l",
"description": "sets the focus to the first task in the list"
},
"focusForm": {
|
chore(tasklist): do not use ctrl+shift+l as shortcut
because of IE
related to CAM-<I>
|
camunda_camunda-bpm-platform
|
train
|
js
|
3c574d2dc6e9ffedd3565cf138c3029f63c17de6
|
diff --git a/python/setup.py b/python/setup.py
index <HASH>..<HASH> 100755
--- a/python/setup.py
+++ b/python/setup.py
@@ -108,7 +108,7 @@ if platform.system() == 'Darwin':
setup(
name='neuroglancer',
- version='2.5',
+ version='2.6',
description='Python data backend for neuroglancer, a WebGL-based viewer for volumetric data',
author='Jeremy Maitin-Shepard, Jan Funke',
author_email='jbms@google.com, jfunke@iri.upc.edu',
|
chore: bump Python package version to <I>
|
google_neuroglancer
|
train
|
py
|
7e94e91e786a6cfe017df61da2bcdf347974ef26
|
diff --git a/src/parser.js b/src/parser.js
index <HASH>..<HASH> 100644
--- a/src/parser.js
+++ b/src/parser.js
@@ -8,14 +8,18 @@ const parser = yargs
.alias('h', 'help')
.version()
.options({
- write: {default: false, describe: 'Edit the file in-place (beware!)'},
- stdin: {default: false, describe: 'Read input via stdin'},
+ write: {
+ default: false,
+ describe: 'Edit the file in-place (beware!)',
+ type: 'boolean',
+ },
+ stdin: {default: false, describe: 'Read input via stdin', type: 'boolean'},
eslintPath: {
default: getPathInHostNodeModules('eslint'),
describe: 'The path to the eslint module to use',
},
prettierPath: {describe: 'The path to the prettier module to use'},
- log: {default: false, describe: 'Show logs'},
+ log: {default: false, describe: 'Show logs', type: 'boolean'},
// TODO: if we allow people to to specify a config path,
// we need to read that somehow. These can come invarious
// formats and we'd have to work out `extends` somehow as well.
@@ -33,6 +37,7 @@ const parser = yargs
sillyLogs: {
default: false,
describe: 'Show silly amount of logs (good for debugging)',
+ type: 'boolean',
},
})
|
fix(options): make boolean options boolean
as it was, the options were taking anything after them as the value which lead to people saying
`prettier-eslint --write "directory/**/*.js"` and nothing happening
|
prettier_prettier-eslint-cli
|
train
|
js
|
62b3be02feb33f2990b97040398f9923ae68f69a
|
diff --git a/platform/php/MailChecker.php b/platform/php/MailChecker.php
index <HASH>..<HASH> 100644
--- a/platform/php/MailChecker.php
+++ b/platform/php/MailChecker.php
@@ -12,7 +12,7 @@
*/
class MailChecker
{
- private static array $blacklist;
+ private static $blacklist;
public static function init(): void
{
|
fix: array does not seems to be compatible with our php version
|
FGRibreau_mailchecker
|
train
|
php
|
b385e4a8aeafb504e1525708f657f984ec479196
|
diff --git a/example.js b/example.js
index <HASH>..<HASH> 100644
--- a/example.js
+++ b/example.js
@@ -45,25 +45,8 @@ if (useCustomIcons) {
MyModeIcon = CustomIcons.CustomModeIcon
}
-// create an initial query for demo/testing purposes
-// FIXME: Remove. This is just for testing.
-const initialQuery = otpConfig.datastoreUrl
- ? {}
- : {
- from: {
- lat: 28.45119,
- lon: -81.36818,
- name: 'P&R'
- },
- to: {
- lat: 28.54834,
- lon: -81.37745,
- name: 'Downtownish'
- },
- numItineraries: 1,
- maxWalkDistance: 1609.34 * 6, // 2 miles
- type: 'ITINERARY'
- }
+// Get the initial query from config (for demo/testing purposes).
+const {initialQuery} = otpConfig
const history = createHashHistory()
const middleware = [
thunk,
|
refactor(example): get initial query from config
|
opentripplanner_otp-react-redux
|
train
|
js
|
ac2034fe05c2aa6a0921de18f76a76860c059439
|
diff --git a/packages/mc-scripts/config/create-webpack-config-for-production.js b/packages/mc-scripts/config/create-webpack-config-for-production.js
index <HASH>..<HASH> 100644
--- a/packages/mc-scripts/config/create-webpack-config-for-production.js
+++ b/packages/mc-scripts/config/create-webpack-config-for-production.js
@@ -43,6 +43,13 @@ const defaultToggleFlags = {
enableExtractCss: true,
// Allow to disable index.html generation in case it's not necessary (e.g. for Storybook)
generateIndexHtml: true,
+ // Some plugins spawn workers to speed up the build. However this can cause trouble on
+ // certain machines local and CI. This flag set to limit or disable any parallelism.
+ // Options:
+ // `true` to default to the machines number of CPUs
+ // `false` to disable any paralelism
+ // `int` for a specific number of CPUs
+ parallelism: true,
};
/**
@@ -110,7 +117,7 @@ module.exports = ({ distPath, entryPoint, sourceFolders, toggleFlags }) => {
},
// Use multi-process parallel running to improve the build speed
// Default number of concurrent runs: os.cpus().length - 1
- parallel: true,
+ parallel: mergedToggleFlags.parallelism,
// Enable file caching
cache: true,
sourceMap: true,
|
fix(mc-scripts): allowing to opt-out of parallel builds (#<I>)
|
commercetools_merchant-center-application-kit
|
train
|
js
|
6e60554c5c8b6ac341e1f58c0c078cb53d50a624
|
diff --git a/test/spec/directives/snap-content.js b/test/spec/directives/snap-content.js
index <HASH>..<HASH> 100644
--- a/test/spec/directives/snap-content.js
+++ b/test/spec/directives/snap-content.js
@@ -10,8 +10,15 @@
* @see https://groups.google.com/forum/#!topic/angular/D00S1DqE3jM
* @see http://jsfiddle.net/eitanp461/qTvMz/
*/
-var myApp = angular.module('snap').config(function(snapRemoteProvider){
- snapRemoteProvider.globalOptions.disable = 'right';
+var myApp = angular.module('snap');
+
+myApp.config(function(snapRemoteProvider) {
+ snapRemoteProvider.globalOptions = {
+ disable: 'right'
+ };
+});
+
+myApp.config(function(snapRemoteProvider){
snapRemoteProvider.globalOptions.overwritten = false;
});
|
test: Should be able to assign global options directly
|
jtrussell_angular-snap.js
|
train
|
js
|
c1848b2dac8dab9c64bfbe22082befbf9034e650
|
diff --git a/fastly/acl_entry.go b/fastly/acl_entry.go
index <HASH>..<HASH> 100644
--- a/fastly/acl_entry.go
+++ b/fastly/acl_entry.go
@@ -3,21 +3,21 @@ package fastly
import (
"fmt"
"sort"
+ "time"
)
type ACLEntry struct {
ServiceID string `mapstructure:"service_id"`
ACLID string `mapstructure:"acl_id"`
- ID string `mapstructure:"id"`
- IP string `mapstructure:"ip"`
- Subnet string `mapstructure:"subnet"`
- Negated bool `mapstructure:"negated"`
- Comment string `mapstructure:"comment"`
-
- DeletedAt string `mapstructure:"deleted_at"`
- CreatedAt string `mapstructure:"created_at"`
- UpdatedAt string `mapstructure:"updated_at"`
+ ID string `mapstructure:"id"`
+ IP string `mapstructure:"ip"`
+ Subnet string `mapstructure:"subnet"`
+ Negated bool `mapstructure:"negated"`
+ Comment string `mapstructure:"comment"`
+ CreatedAt *time.Time `mapstructure:"created_at"`
+ UpdatedAt *time.Time `mapstructure:"updated_at"`
+ DeletedAt *time.Time `mapstructure:"deleted_at"`
}
// entriesById is a sortable list of ACL entries.
|
refactor(acl_entry): response object timestamp fields
Change data type from string to time of all timestamp fields.
fix #<I>
|
sethvargo_go-fastly
|
train
|
go
|
abbf76fe9d378ca422cad68c60ab7f9fa43afb4f
|
diff --git a/packages/cozy-konnector-libs/src/libs/saveFiles.js b/packages/cozy-konnector-libs/src/libs/saveFiles.js
index <HASH>..<HASH> 100644
--- a/packages/cozy-konnector-libs/src/libs/saveFiles.js
+++ b/packages/cozy-konnector-libs/src/libs/saveFiles.js
@@ -484,10 +484,10 @@ const shouldReplaceFile = async function(file, entry, options) {
const fileHasNoMetadata = !getAttribute(file, 'metadata')
const fileHasNoId = !getAttribute(file, 'metadata.fileIdAttributes')
const entryHasMetadata = !!get(entry, 'fileAttributes.metadata')
- return (
+ const result =
(fileHasNoMetadata && entryHasMetadata) ||
- (fileHasNoId && options.fileIdAttributes)
- )
+ (fileHasNoId && !!options.fileIdAttributes)
+ return result
}
const shouldReplaceFileFn =
entry.shouldReplaceFile ||
@@ -671,5 +671,5 @@ function getFilePath({ file, entry, options }) {
}
function getAttribute(obj, attribute) {
- return get(obj, `attributes.${attribute}`, obj[attribute])
+ return get(obj, `attributes.${attribute}`, get(obj, attribute))
}
|
fix: bug if file with already an id detection
This caused files to be replaced everytime
|
konnectors_libs
|
train
|
js
|
a748aa562ccd11dfe9aa53f99d3035db74e2e41d
|
diff --git a/boot/database.js b/boot/database.js
index <HASH>..<HASH> 100644
--- a/boot/database.js
+++ b/boot/database.js
@@ -120,7 +120,7 @@ function migrateData (version, done) {
Client.list({
// list all clients, avoid paging
page: 1,
- size: '0'
+ size: 0
}, function (err, clients) {
if (err) { return next(err) }
|
fix: Use integer for size option in Client.list
|
anvilresearch_connect
|
train
|
js
|
363435117d37aab9122af4adf36be42a3f8272c5
|
diff --git a/test/spec/agile/utils.js b/test/spec/agile/utils.js
index <HASH>..<HASH> 100644
--- a/test/spec/agile/utils.js
+++ b/test/spec/agile/utils.js
@@ -301,6 +301,7 @@ describe('utils', function() {
});
describe('#identity', function() {
+ var identity = value;
it('should get a value and return is as-is', function() {
var a = {};
expect(identity(a) === a).toBeTruthy();
|
fix(utils): fix tests fails
|
a8m_agile
|
train
|
js
|
e4b688617979e96b7a8fe347ba119f08480a735a
|
diff --git a/niworkflows/interfaces/tests/test_bids.py b/niworkflows/interfaces/tests/test_bids.py
index <HASH>..<HASH> 100644
--- a/niworkflows/interfaces/tests/test_bids.py
+++ b/niworkflows/interfaces/tests/test_bids.py
@@ -142,5 +142,3 @@ def test_ReadSidecarJSON_connection(testdata_dir, field):
wf.connect([
(n, o, [(field, 'out_port')]),
])
-
- assert 'Some connections were not found' in str(excinfo)
|
fix(tests): remove assert that is not necessary after applying @effigies' comment
|
poldracklab_niworkflows
|
train
|
py
|
257d4e7509c07d687b079830f83b9b11641858fb
|
diff --git a/lib/contentful.js b/lib/contentful.js
index <HASH>..<HASH> 100644
--- a/lib/contentful.js
+++ b/lib/contentful.js
@@ -103,10 +103,6 @@ function obscureAuthTokenInResponse (http) {
error.response.config.headers.Authorization = error.response.config.headers.Authorization.replace(token, `Bearer...${token.substr(-5)}`)
- if (error.response.request._headers && error.response.request._headers.authorization) {
- error.response.request._headers.authorization = error.response.request._headers.authorization.replace(token, `Bearer...${token.substr(-5)}`)
- }
-
if (error.response.request._header) {
error.response.request._header = error.response.request._header.replace(token, `Bearer...${token.substr(-5)}`)
}
|
fix: remove use of the deprecated OutgoingMessage.prototype._headers
Removes deprecated code. Cannot replace with setHeaders since headers already sent.
In case you still want to obscure the headers from the request-object i suggest you strip down the request object to only include desired attributes, rather than changing the original object.
|
contentful_contentful.js
|
train
|
js
|
15b42ca56db30b59d2b6fd2fb796e224550b337f
|
diff --git a/lib/config/bump.js b/lib/config/bump.js
index <HASH>..<HASH> 100644
--- a/lib/config/bump.js
+++ b/lib/config/bump.js
@@ -6,8 +6,9 @@ module.exports = function() {
files: '<%= angularToolbox._.files.pkg %>',
updateConfigs: ['pkg'],
commitFiles: [
- '<%= angularToolbox._.files.pkg %>',
- '<%= angularToolbox.folder.dist %>/**/*'
+ '<%= jqueryToolbox.files.bower %>',
+ '<%= jqueryToolbox.files.pkg %>',
+ '<%= jqueryToolbox.folder.dist %>'
],
pushTo: 'origin'
}
|
fix(bump): use explicit package files and no glob
|
Jimdo_grunt-angular-toolbox
|
train
|
js
|
1abb455161502e3cf47c590302fac527b6138dba
|
diff --git a/packages/micro-journeys/src/two-character-layout.js b/packages/micro-journeys/src/two-character-layout.js
index <HASH>..<HASH> 100644
--- a/packages/micro-journeys/src/two-character-layout.js
+++ b/packages/micro-journeys/src/two-character-layout.js
@@ -77,8 +77,10 @@ class BoltTwoCharacterLayout extends withLitHtml() {
charsAreReady &&
this.isInitialRender
) {
- this.charactersAreReadyInitialization();
- this.isInitialRender = false;
+ setTimeout(() => {
+ this.charactersAreReadyInitialization();
+ this.isInitialRender = false;
+ });
}
}
|
fix(micro-journeys): push charactersAreReadyInitialization to bottom of call stack in bolt-two-character-layout
|
bolt-design-system_bolt
|
train
|
js
|
a1158de98a5ecb21c77a015d0b30d282136498e8
|
diff --git a/packages/svg-transform-loader/test/loader.test.js b/packages/svg-transform-loader/test/loader.test.js
index <HASH>..<HASH> 100644
--- a/packages/svg-transform-loader/test/loader.test.js
+++ b/packages/svg-transform-loader/test/loader.test.js
@@ -43,8 +43,7 @@ it('should allow to pass transformer params as query string', async () => {
it('should allow to convert colors with alpha channel', async () => {
const { image } = await compile(
- `require('${imageReq}?fill=${encodeURIComponent('rgba(255, 0, 0, 0.5)')}')`,
- { convertAlphaColors: true }
+ `require('${imageReq}?fill=rgba%28255%2C%200%2C%200%2C%200.5%29')`
);
expect(image).toMatchSnapshot();
});
|
chore: convert alpha colors by default
|
JetBrains_svg-mixer
|
train
|
js
|
9ef70940cdce7304e88aad6d60c6772866dde59b
|
diff --git a/packer.py b/packer.py
index <HASH>..<HASH> 100644
--- a/packer.py
+++ b/packer.py
@@ -41,9 +41,8 @@ class Packer(object):
self.packer = sh.Command(exec_path)
self.packer = self.packer.bake(**kwargs)
- def build(
- self, parallel=True, debug=False, force=False,
- machine_readable=False):
+ def build(self, parallel=True, debug=False, force=False,
+ machine_readable=False):
"""Executes a `packer build`
:param bool parallel: Run builders in parallel
@@ -115,7 +114,8 @@ class Packer(object):
result = self.packer_cmd()
if mrf:
- result.parsed_output = self._parse_inspection_output(result.stdout.decode())
+ result.parsed_output = self._parse_inspection_output(
+ result.stdout.decode())
else:
result.parsed_output = None
return result
|
chore: linting
Related: PSOBAT-<I>
|
nir0s_python-packer
|
train
|
py
|
6c793d6f7f160f401c0c70b98fa6544f378b4975
|
diff --git a/packages/api-page-builder/src/plugins/graphql/pageResolvers/listPages.js b/packages/api-page-builder/src/plugins/graphql/pageResolvers/listPages.js
index <HASH>..<HASH> 100644
--- a/packages/api-page-builder/src/plugins/graphql/pageResolvers/listPages.js
+++ b/packages/api-page-builder/src/plugins/graphql/pageResolvers/listPages.js
@@ -23,6 +23,9 @@ export default async (root: any, args: Object, context: Object) => {
createdOn: {
$first: "$createdOn"
},
+ savedOn: {
+ $first: "$savedOn"
+ },
id: {
$first: "$id"
},
|
fix: enable sorting pages by "savedOn" field
|
Webiny_webiny-js
|
train
|
js
|
34aa86d4bc7ce2d8f56fc9673411d9eddbbf27f8
|
diff --git a/app/templates/entry/client-prefetch.js b/app/templates/entry/client-prefetch.js
index <HASH>..<HASH> 100644
--- a/app/templates/entry/client-prefetch.js
+++ b/app/templates/entry/client-prefetch.js
@@ -9,8 +9,6 @@
*
* Boot files are your "main.js"
**/
-import App from 'app/<%= sourceFiles.rootComponent %>'
-
<% if (__loadingBar) { %>
import { LoadingBar } from 'quasar'
<% } %>
@@ -20,6 +18,7 @@ import { isRunningOnPWA } from './ssr-pwa'
<% } %>
<% if (!ctx.mode.ssr || ctx.mode.pwa) { %>
+import App from 'app/<%= sourceFiles.rootComponent %>'
let appOptions = App.options /* Vue.extend() */ || App
let appPrefetch = typeof appOptions.preFetch === 'function'
<% } %>
|
chore(app): more tweaks to webpack entry files
|
quasarframework_quasar
|
train
|
js
|
fce9b269534d490e29d3a06d4751b2ce27b0833f
|
diff --git a/packages/analytics-core/src/analytics.js b/packages/analytics-core/src/analytics.js
index <HASH>..<HASH> 100644
--- a/packages/analytics-core/src/analytics.js
+++ b/packages/analytics-core/src/analytics.js
@@ -64,7 +64,7 @@ export default class AvAnalytics {
handleEvent = event => {
if (
isModifiedEvent(event) ||
- !isLeftClickEvent(event) ||
+ (event.type === 'click' && !isLeftClickEvent(event)) ||
!isValidEventTypeOnTarget(event)
) {
return;
diff --git a/packages/api-core/src/api.js b/packages/api-core/src/api.js
index <HASH>..<HASH> 100644
--- a/packages/api-core/src/api.js
+++ b/packages/api-core/src/api.js
@@ -289,7 +289,7 @@ export default class AvApi {
getPage(page = 1, config = {}, limit) {
limit = limit || (config.params && config.params.limit) || 50;
const offset = (page - 1) * limit;
- return this.query(this.addParams({ offset }, config, false));
+ return this.query(this.addParams({ offset, limit }, config, false));
}
// put request
|
fix(analytics-core): fix non-click events
|
Availity_sdk-js
|
train
|
js,js
|
9504f1951a3cca55bb7b4e25e4934e4024034ee8
|
diff --git a/src/upgrader.js b/src/upgrader.js
index <HASH>..<HASH> 100644
--- a/src/upgrader.js
+++ b/src/upgrader.js
@@ -201,7 +201,7 @@ class Upgrader {
* @private
* @param {object} options
* @param {string} options.cryptoProtocol - The crypto protocol that was negotiated
- * @param {string} options.direction - One of ['inbound', 'outbound']
+ * @param {'inbound' | 'outbound'} options.direction - One of ['inbound', 'outbound']
* @param {MultiaddrConnection} options.maConn - The transport layer connection
* @param {MuxedStream | MultiaddrConnection} options.upgradedConn - A duplex connection returned from multiplexer and/or crypto selection
* @param {MuxerFactory} [options.Muxer] - The muxer to be used for muxing
|
fix: connection direction should be only inbound or outbound
|
libp2p_js-libp2p
|
train
|
js
|
c7f2d76c30fe84caa5df9e1f5b3c48f6282aa94e
|
diff --git a/test/TippySingleton.test.js b/test/TippySingleton.test.js
index <HASH>..<HASH> 100644
--- a/test/TippySingleton.test.js
+++ b/test/TippySingleton.test.js
@@ -298,7 +298,7 @@ describe('<TippySingleton />', () => {
</TippySingleton>,
);
- expect(instance.plugins).toEqual(plugins);
+ expect(instance.plugins.slice(1)).toEqual(plugins);
});
});
diff --git a/test/useSingleton.test.js b/test/useSingleton.test.js
index <HASH>..<HASH> 100644
--- a/test/useSingleton.test.js
+++ b/test/useSingleton.test.js
@@ -263,7 +263,7 @@ describe('The useSingleton hook', () => {
const singleton = useSingleton({
plugins,
onCreate(instance) {
- expect(instance.plugins).toEqual(plugins);
+ expect(instance.plugins.slice(1)).toEqual(plugins);
},
});
|
fix: singleton plugins tests
|
atomiks_tippy.js-react
|
train
|
js,js
|
27e37394f62305be072ad5e4f8b3755505ed22f6
|
diff --git a/packages/button/src/Button.test.js b/packages/button/src/Button.test.js
index <HASH>..<HASH> 100644
--- a/packages/button/src/Button.test.js
+++ b/packages/button/src/Button.test.js
@@ -107,12 +107,20 @@ describe("Button", () => {
});
describe("when a disabled link", () => {
+ const link = "https://www.autodesk.com";
+
beforeEach(() => {
- wrapper = subject({ link: "https://www.autodesk.com", disabled: true });
+ wrapper = subject({ link, disabled: true });
});
it("is not tabbable", () => {
- expect(wrapper.matchesElement(<a tabIndex="-1">Button</a>));
+ expect(
+ wrapper.matchesElement(
+ <a href={link} tabIndex="-1">
+ Button
+ </a>
+ )
+ );
});
});
});
|
test: update test per lint rule
|
Autodesk_hig
|
train
|
js
|
4ee86f1c48f51ee1cf0773aefcff3a37ed5c1b5d
|
diff --git a/src/bundler.js b/src/bundler.js
index <HASH>..<HASH> 100644
--- a/src/bundler.js
+++ b/src/bundler.js
@@ -1,8 +1,8 @@
import { rollup } from 'rollup';
-import convertCJS from 'rollup-plugin-commonjs';
+import convertCJS from '@rollup/plugin-commonjs';
import { terser } from 'rollup-plugin-terser';
import json from '@rollup/plugin-json';
-import babel from 'rollup-plugin-babel';
+import babel from '@rollup/plugin-babel';
import preset from '@babel/preset-env';
import generateBanner from './generateBanner.js';
import { node as nodeTarget } from './targets.js';
|
fix(bundler): fix outdated references to Rollup plugins
|
Comandeer_rollup-lib-bundler
|
train
|
js
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.