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 |
|---|---|---|---|---|---|
22d5309d2a10276448894552550b3cfa9158db27
|
diff --git a/engine.go b/engine.go
index <HASH>..<HASH> 100644
--- a/engine.go
+++ b/engine.go
@@ -101,13 +101,18 @@ func (eng *Engine) Observe(name string, value interface{}, tags ...Tag) {
// Clock returns a new clock identified by name and tags.
func (eng *Engine) Clock(name string, tags ...Tag) *Clock {
+ return eng.ClockAt(name, time.Now(), tags...)
+}
+
+// ClockAt returns a new clock identified by name and tags with a specified
+// start time.
+func (eng *Engine) ClockAt(name string, start time.Time, tags ...Tag) *Clock {
cpy := make([]Tag, len(tags), len(tags)+1) // clock always appends a stamp.
copy(cpy, tags)
- now := time.Now()
return &Clock{
name: name,
- first: now,
- last: now,
+ first: start,
+ last: start,
tags: cpy,
eng: eng,
}
|
feat(engine): add ClockAt for creating a clock with a specific start time (#<I>)
|
segmentio_stats
|
train
|
go
|
efef02f0a00122117a9f31a1f466b92efe9007e5
|
diff --git a/anyconfig/backend/xml.py b/anyconfig/backend/xml.py
index <HASH>..<HASH> 100644
--- a/anyconfig/backend/xml.py
+++ b/anyconfig/backend/xml.py
@@ -386,7 +386,7 @@ def container_to_etree(obj, parent=None, **options):
_str = str if options.get("ac_parse_value") else anyconfig.utils.noop
if not anyconfig.mdicts.is_dict_like(obj):
- obj = _str(obj)
+ obj = False if obj is None else _str(obj)
if parent is not None and obj:
parent.text = obj # Parent is a leaf text node.
return # All attributes and text should be set already.
|
fix: correct processing of cases if is None (no text) in XML backend
|
ssato_python-anyconfig
|
train
|
py
|
01bb69ab4fa710bbb13ac3758ccc83b7fe750a7e
|
diff --git a/lib/index.js b/lib/index.js
index <HASH>..<HASH> 100644
--- a/lib/index.js
+++ b/lib/index.js
@@ -7,6 +7,8 @@ module.exports = {
'avoid-leaking-state-in-components': require('./rules/avoid-leaking-state-in-components'),
'avoid-leaking-state-in-ember-objects': require('./rules/avoid-leaking-state-in-ember-objects'),
'avoid-using-needs-in-controllers': require('./rules/avoid-using-needs-in-controllers'),
+ 'classic-decorator-hooks': require('./rules/classic-decorator-hooks'),
+ 'classic-decorator-no-classic-methods': require('./rules/classic-decorator-no-classic-methods'),
'closure-actions': require('./rules/closure-actions'),
'jquery-ember-run': require('./rules/jquery-ember-run'),
'local-modules': require('./rules/local-modules'),
|
fix: add missing rules `classic-decorator-hooks` and `classic-decorator-no-classic-methods` to index.js
|
ember-cli_eslint-plugin-ember
|
train
|
js
|
2fe23c0fa6c89cd5fed6ef00ed85891647fe2633
|
diff --git a/examples/vueds/styleguide/vueds-theme.js b/examples/vueds/styleguide/vueds-theme.js
index <HASH>..<HASH> 100644
--- a/examples/vueds/styleguide/vueds-theme.js
+++ b/examples/vueds/styleguide/vueds-theme.js
@@ -40,7 +40,8 @@ module.exports = {
'& & a': {
fontSize: '13px';
fontWeight: 'normal',
- color: '#258aef'
+ color: '#258aef',
+ cursor: 'pointer'
}
}
},
|
docs: cusor: pointer
|
vue-styleguidist_vue-styleguidist
|
train
|
js
|
9be195cdf06cf38da5b00456e03ad41cce091016
|
diff --git a/index.js b/index.js
index <HASH>..<HASH> 100644
--- a/index.js
+++ b/index.js
@@ -3,10 +3,8 @@ var path = require('path');
function routesResolver(filePath) {
var ngModule = require(filePath).default || require(filePath);
- if (ngModule.routes && ngModule.routes.length) {
- return ngModule.routes;
- }
- return [];
+ var routes = ngModule.routes || require(filePath).routes || [];
+ return routes;
}
function resolveNgRoute(srcPath, config, defaultFile, resolver) {
|
refactor: check for routes in both default and export
|
AngularClass_resolve-angular-routes
|
train
|
js
|
626bf6a861fffeb2e30d7295f0241b98a0777907
|
diff --git a/packages/ui/vue/app-client.js b/packages/ui/vue/app-client.js
index <HASH>..<HASH> 100644
--- a/packages/ui/vue/app-client.js
+++ b/packages/ui/vue/app-client.js
@@ -44,11 +44,8 @@ router.onReady(() => {
// async components are resolved.
router.beforeResolve(async (to, from, next) => {
if (to.matched.some(record => !store.state.$user.scp.includes(record.meta.scope) && !store.state.$user.scp.includes('write_root'))) {
- console.log("scope didnt match")
next(false)
} else {
- console.log("scope did match")
-
const matched = router.getMatchedComponents(to)
// Register dyanmic store modules on route change (not direct load!)
|
fix(ui): removed debug logs
|
cubic-js_cubic
|
train
|
js
|
84cf263497e57118a7aca6c4cadf304fc7ac0c4f
|
diff --git a/account/dashboards.widgets.js b/account/dashboards.widgets.js
index <HASH>..<HASH> 100644
--- a/account/dashboards.widgets.js
+++ b/account/dashboards.widgets.js
@@ -98,11 +98,17 @@ class Widgets {
* @param {JSON} data
* @return {Promise}
*/
- sendData(dashboard_id, widget_id, data) {
+ sendData(dashboard_id, widget_id, data, bypassBucket) {
const url = `${config.api_url}/data/${dashboard_id}/${widget_id}`;
const method = 'POST';
- const options = Object.assign({}, this.default_options, {url, method, data});
+ const options = Object.assign({}, this.default_options, {
+ url,
+ method,
+ data,
+ paramsSerializer,
+ params: { bypass_bucket: bypassBucket || false }
+ });
return request(options);
}
|
feat: added bypassbucket method
|
tago-io_tago-sdk-js
|
train
|
js
|
612465b4be86bb9f28c34bf7f8efe3d62b307309
|
diff --git a/inputs/text-area/text-area.js b/inputs/text-area/text-area.js
index <HASH>..<HASH> 100644
--- a/inputs/text-area/text-area.js
+++ b/inputs/text-area/text-area.js
@@ -87,6 +87,10 @@ export class TextArea extends React.Component {
};
render() {
+ const isElementBiggerThanMinRowCount =
+ this.state.textareaRowCount > TextArea.MIN_ROW_COUNT;
+ const isContentBiggerThanMinRowCount =
+ this.state.contentRowCount > TextArea.MIN_ROW_COUNT;
return (
<Constraints.Horizontal constraint={this.props.horizontalConstraint}>
<Collapsible isDefaultClosed={this.props.isDefaultClosed}>
@@ -123,9 +127,8 @@ export class TextArea extends React.Component {
{...filterDataAttributes(this.props)}
/>
{((!this.props.isDefaultClosed &&
- (this.state.textareaRowCount > TextArea.MIN_ROW_COUNT ||
- !isOpen)) ||
- this.state.contentRowCount > TextArea.MIN_ROW_COUNT) && (
+ (isElementBiggerThanMinRowCount || !isOpen)) ||
+ isContentBiggerThanMinRowCount) && (
<FlatButton
onClick={toggle}
type="primary"
|
fix(text-area): extract assertions to variables
|
commercetools_ui-kit
|
train
|
js
|
84a66c28f4e25b7ec8e519dce79f3d1e57dd9331
|
diff --git a/lib/console-reporter.js b/lib/console-reporter.js
index <HASH>..<HASH> 100644
--- a/lib/console-reporter.js
+++ b/lib/console-reporter.js
@@ -222,13 +222,13 @@ ConsoleReporter.prototype.printReport = function printReport(report, opts) {
let result = [];
for(const metricName of sortedAlphabetically) {
- if (report.counters?.[metricName]) {
+ if (typeof report.counters?.[metricName] !== 'undefined') {
result = result.concat(printCounters([metricName], report));
}
- if (report.summaries?.[metricName]) {
+ if (typeof report.summaries?.[metricName] !== 'undefined') {
result = result.concat(printSummaries([metricName], report));
}
- if (report.rates?.[metricName]) {
+ if (typeof report.rates?.[metricName] !== 'undefined') {
result = result.concat(printRates([metricName], report));
}
}
|
fix(console-reporter): handle metrics with value of zero
|
artilleryio_artillery
|
train
|
js
|
539c97e7ab15afae9678b6c3877b7baebab8fbd6
|
diff --git a/src/index.js b/src/index.js
index <HASH>..<HASH> 100644
--- a/src/index.js
+++ b/src/index.js
@@ -35,7 +35,6 @@ var postprocess = R.memoize(function(symbols) {
var toDecimalRaw = R.curryN(4, function(b, symbols, base, n) {
return R.pipe(
toString,
- splitWithoutSep,
R.reverse,
R.map(indexOfSymbol(symbols)),
R.addIndex(R.map)(posNotation.mapper(b, base)),
|
refactor: remove superfluous step
|
javiercejudo_base-conversion-to-dec
|
train
|
js
|
2aa45429730671e40f6e1eca02ab4761ba361b20
|
diff --git a/setup.py b/setup.py
index <HASH>..<HASH> 100644
--- a/setup.py
+++ b/setup.py
@@ -33,8 +33,8 @@ setup(
long_description=read('README.rst'),
packages=find_packages(exclude='tests'),
install_requires=[
- 'mock==1.0.1',
- 'six==1.9.0',
+ 'mock~=1.0.1',
+ 'six>=1.9.0',
'requests',
],
license='MIT',
|
fix: Use ranges for dependencies
|
relekang_rmoq
|
train
|
py
|
635b3d0fec8d275d2e31237cc5f81461c86edfd7
|
diff --git a/packages/conventional-github-releaser/index.js b/packages/conventional-github-releaser/index.js
index <HASH>..<HASH> 100644
--- a/packages/conventional-github-releaser/index.js
+++ b/packages/conventional-github-releaser/index.js
@@ -40,7 +40,7 @@ function conventionalGithubReleaser(auth, changelogOpts, context, gitRawCommitsO
writerOpts = changelogArgs[4];
changelogOpts = merge({
- transform: through.obj(function(chunk, enc, cb) {
+ transform: function(chunk, cb) {
if (typeof chunk.gitTags === 'string') {
var match = /tag:\s*(.+?)[,\)]/gi.exec(chunk.gitTags);
if (match) {
@@ -53,7 +53,7 @@ function conventionalGithubReleaser(auth, changelogOpts, context, gitRawCommitsO
}
cb(null, chunk);
- }),
+ },
releaseCount: 1
}, changelogOpts);
|
fix(transform): use new syntax of conventional-changelog@<I>
|
conventional-changelog_releaser-tools
|
train
|
js
|
583ead6aaff4abf5d6822646911704ba5078e679
|
diff --git a/src/tabs/tabs.js b/src/tabs/tabs.js
index <HASH>..<HASH> 100644
--- a/src/tabs/tabs.js
+++ b/src/tabs/tabs.js
@@ -1,4 +1,5 @@
import { customAttribute, bindable, bindingMode, inject } from 'aurelia-framework';
+import { fireMaterializeEvent } from '../common/events'
@customAttribute('md-tabs')
@inject(Element)
@@ -8,8 +9,19 @@ export class MdTabs {
}
attached() {
$(this.element).tabs();
+ // $('li a', this.element).on('click', this.fireTabSelectedEvent);
+ this.element.querySelectorAll('li a').forEach(a => {
+ a.addEventListener('click', this.fireTabSelectedEvent);
+ });
}
detached() {
// no destroy handler in tabs
+ this.element.querySelectorAll('li a').forEach(a => {
+ a.removeEventListener('click', this.fireTabSelectedEvent);
+ });
+ }
+ fireTabSelectedEvent() {
+ let href = $('li a').attr('href');
+ fireMaterializeEvent(this.element, 'tabSelected', href);
}
}
|
feat(tabs): tried to implement tabSelected event
|
aurelia-ui-toolkits_aurelia-materialize-bridge
|
train
|
js
|
ee2674834bc9d0008e6c2b686f45c9b62e41e3c2
|
diff --git a/lib/file_list.js b/lib/file_list.js
index <HASH>..<HASH> 100644
--- a/lib/file_list.js
+++ b/lib/file_list.js
@@ -53,6 +53,7 @@ Url.prototype.toString = File.prototype.toString = function () {
var GLOB_OPTS = {
// globDebug: true,
+ follow: true,
cwd: '/'
}
|
fix(file_list): follow symlinks
Changing to the latest version of the glob module means that
karma no longer follows symlinks to find files to serve.
Setting foillow:true in the glob options enables this
behaviour again.
|
karma-runner_karma
|
train
|
js
|
f4c33bdd29eb18c707758ec479c5aa67b734b997
|
diff --git a/ui/build/build.api.js b/ui/build/build.api.js
index <HASH>..<HASH> 100644
--- a/ui/build/build.api.js
+++ b/ui/build/build.api.js
@@ -146,6 +146,18 @@ const objectTypes = {
isBoolean: [ 'internal' ]
},
+ Event: {
+ props: [ 'desc', 'required', 'category', 'examples', 'addedIn', 'internal' ],
+ required: [ 'desc' ],
+ isBoolean: [ 'internal' ]
+ },
+
+ SubmitEvent: {
+ props: [ 'desc', 'required', 'category', 'examples', 'addedIn', 'internal' ],
+ required: [ 'desc' ],
+ isBoolean: [ 'internal' ]
+ },
+
// component only
slots: {
props: [ 'desc', 'link', 'scope', 'addedIn', 'internal' ],
|
chore(ui): fix build broken by previous PR #<I>
|
quasarframework_quasar
|
train
|
js
|
d4336d82b7f4d2906fcdb833acb727c70f11c279
|
diff --git a/lib/core/util.js b/lib/core/util.js
index <HASH>..<HASH> 100644
--- a/lib/core/util.js
+++ b/lib/core/util.js
@@ -47,12 +47,13 @@ function destroy (stream, err) {
}
}
+const KEEPALIVE_TIMEOUT_EXPR = /timeout=(\d+)s/
function parseKeepAliveTimeout (headers) {
for (let n = 0; n < headers.length; n += 2) {
const key = headers[n + 0]
if (key.length === 10 && key.toLowerCase() === 'keep-alive') {
- const timeout = parseInt(headers[n + 1].split('timeout=', 2)[1])
- return timeout ? timeout * 1000 : undefined
+ const m = headers[n + 1].match(KEEPALIVE_TIMEOUT_EXPR)
+ return m ? parseInt(m[1]) * 1000 : null
}
}
}
|
perf: parseKeepAliveTimeout
The regex version is fastest.
|
mcollina_undici
|
train
|
js
|
d2c12cc274df9d2b2fc99398051134d825158841
|
diff --git a/src/index.js b/src/index.js
index <HASH>..<HASH> 100644
--- a/src/index.js
+++ b/src/index.js
@@ -300,6 +300,13 @@ module.exports = {
popSearchPlace: popSearchPlace,
popSearchTitle: popSearchTitle,
+ popSearch: {
+ person : popSearchPerson,
+ organization : popSearchOrganization,
+ place : popSearchPlace,
+ title : popSearchTitle
+ }
+
}
/*
|
feat(api): add popSearch method required by CWRC-WriterBase
popSearch is simply a property on the module referring to an object that in turn references the four
entity search functions of the API. The CWRC-WriterBase uses this object to lookup the methods by
entity type.
|
cwrc_CWRC-PublicEntityDialogs
|
train
|
js
|
cddbc2cc1af5099294e71831bf256bc85bf5dfb9
|
diff --git a/src/actions.js b/src/actions.js
index <HASH>..<HASH> 100644
--- a/src/actions.js
+++ b/src/actions.js
@@ -290,7 +290,7 @@ const initialize: Initialize = (
form: string,
values: Object,
keepDirty?: boolean | Object,
- otherMeta?: Object = {}
+ otherMeta: Object = {}
): InitializeAction => {
if (keepDirty instanceof Object) {
otherMeta = keepDirty
diff --git a/src/createField.js b/src/createField.js
index <HASH>..<HASH> 100644
--- a/src/createField.js
+++ b/src/createField.js
@@ -71,8 +71,6 @@ const createField = (structure: Structure<*, *>) => {
this.props._reduxForm.unregister(this.name)
}
- ref = React.createRef()
-
getRenderedComponent(): ?Component<*, *> {
invariant(
this.props.forwardRef,
|
refactor(createField): remove duplicated ref
|
erikras_redux-form
|
train
|
js,js
|
b32cd67c73e37ce965cc03a839a9d33d365672b6
|
diff --git a/app/models/content_item.rb b/app/models/content_item.rb
index <HASH>..<HASH> 100644
--- a/app/models/content_item.rb
+++ b/app/models/content_item.rb
@@ -33,7 +33,7 @@ class ContentItem < ApplicationRecord
def publish_state
sorted_field_items = field_items.select { |fi| fi.field.field_type_instance.is_a?(DateTimeFieldType) && !fi.field.metadata["state"].nil? }.sort_by{ |a| a.data["timestamp"] }.reverse
- PublishStateService.new.perform(sorted_field_items, self)
+ PublishStateService.new.content_item_state(sorted_field_items, self)
end
def rss_url(base_url, slug_field_id)
diff --git a/app/services/publish_state_service.rb b/app/services/publish_state_service.rb
index <HASH>..<HASH> 100644
--- a/app/services/publish_state_service.rb
+++ b/app/services/publish_state_service.rb
@@ -1,5 +1,5 @@
-class PublishStateService < ApplicationController
- def perform(sorted_field_items, content_item)
+class PublishStateService < ApplicationService
+ def content_item_state(sorted_field_items, content_item)
@sorted_field_items = sorted_field_items
@content_item = content_item
|
refactor: necessary pub system renamings and refactors
|
cortex-cms_cortex
|
train
|
rb,rb
|
60dbdabc657c84ef9f93b9086aa5b08395f7821e
|
diff --git a/packages/node_modules/@webex/internal-plugin-wdm/src/config.js b/packages/node_modules/@webex/internal-plugin-wdm/src/config.js
index <HASH>..<HASH> 100644
--- a/packages/node_modules/@webex/internal-plugin-wdm/src/config.js
+++ b/packages/node_modules/@webex/internal-plugin-wdm/src/config.js
@@ -8,8 +8,10 @@ export default {
device: {
preDiscoveryServices: {
wdmServiceUrl: process.env.WDM_SERVICE_URL || 'https://wdm-a.wbx2.com/wdm/api/v1',
+ u2cServiceUrl: process.env.U2C_SERVICE_URL || 'https://u2c.wbx2.com/u2c/api/v1',
hydraServiceUrl: process.env.HYDRA_SERVICE_URL || 'https://api.ciscospark.com/v1',
wdm: process.env.WDM_SERVICE_URL || 'https://wdm-a.wbx2.com/wdm/api/v1',
+ u2c: process.env.U2C_SERVICE_URL || 'https://u2c.wbx2.com/u2c/api/v1',
hydra: process.env.HYDRA_SERVICE_URL || 'https://api.ciscospark.com/v1'
},
defaults: {
|
refactor(internal-plugin-wdm): add u2c service url to config
Add the u2c service url to the prediscovery services list
in internal-plugin-wdm's config.js.
|
webex_spark-js-sdk
|
train
|
js
|
965dcabfd30e8d9f8709eccb074125e6cb05ea60
|
diff --git a/packages/icon/src/react/index.js b/packages/icon/src/react/index.js
index <HASH>..<HASH> 100644
--- a/packages/icon/src/react/index.js
+++ b/packages/icon/src/react/index.js
@@ -17,8 +17,8 @@ export const sizes = {
const styleSize = ({ size }) =>
({
tiny: {
- height: '12px',
- width: '12px'
+ height: '16px',
+ width: '16px'
},
small: {
height: '24px',
|
fix(icon): adjust tiny/small sizes
|
pluralsight_design-system
|
train
|
js
|
1b9b1e94146ae1733cba3ed06844c09b7a780811
|
diff --git a/packages/cozy-client/src/Schema.js b/packages/cozy-client/src/Schema.js
index <HASH>..<HASH> 100644
--- a/packages/cozy-client/src/Schema.js
+++ b/packages/cozy-client/src/Schema.js
@@ -63,7 +63,6 @@ class Schema {
...normalizeDoctypeSchema(obj)
}))
- this.byName = merge(this.byName || {}, keyBy(values, x => x.name))
this.byDoctype = merge(this.byDoctype || {}, keyBy(values, x => x.doctype))
}
|
style(client): Remove Schema.byName property, actually never used 🔥
|
cozy_cozy-client
|
train
|
js
|
25546fd45bf97622b1dfbaf0b562ee8ed941c18f
|
diff --git a/google-apis-generator/lib/google/apis/generator/updater.rb b/google-apis-generator/lib/google/apis/generator/updater.rb
index <HASH>..<HASH> 100644
--- a/google-apis-generator/lib/google/apis/generator/updater.rb
+++ b/google-apis-generator/lib/google/apis/generator/updater.rb
@@ -30,7 +30,7 @@ module Google
version_content = changelog_content = nil
generator_result.files.each do |path, content|
full_path = File.join(base_dir, path)
- old_content = File.binread(full_path) if File.readable?(full_path)
+ old_content = File.read(full_path) if File.readable?(full_path)
if path == generator_result.version_path
version_content = old_content || content
elsif path == generator_result.changelog_path
|
fix(generator): Fix charset used in file comparison
|
googleapis_google-api-ruby-client
|
train
|
rb
|
7c119650cb585eafa657c200112f6edb79daba99
|
diff --git a/lib/hccrawler.js b/lib/hccrawler.js
index <HASH>..<HASH> 100644
--- a/lib/hccrawler.js
+++ b/lib/hccrawler.js
@@ -301,16 +301,12 @@ class HCCrawler extends EventEmitter {
async _skipRequest(options) {
const allowedDomain = this._checkAllowedDomains(options);
if (!allowedDomain) return true;
- const [
- requested,
- allowedRobot,
- shouldRequest,
- ] = await Promise.all([
- this._checkRequested(options),
- this._checkAllowedRobots(options),
- this._shouldRequest(options),
- ]);
- if (requested || !allowedRobot || !shouldRequest) return true;
+ const requested = await this._checkRequested(options);
+ if (requested) return true;
+ const shouldRequest = await this._shouldRequest(options);
+ if (!shouldRequest) return true;
+ const allowedRobot = await this._checkAllowedRobots(options);
+ if (!allowedRobot) return true;
return false;
}
|
chore(hccrawler): serialize check request process
|
yujiosaka_headless-chrome-crawler
|
train
|
js
|
26b9376c6454a13f3399d32db5a93efbfe8dfc66
|
diff --git a/createNativeStackNavigator.js b/createNativeStackNavigator.js
index <HASH>..<HASH> 100644
--- a/createNativeStackNavigator.js
+++ b/createNativeStackNavigator.js
@@ -90,7 +90,7 @@ class StackView extends React.Component {
translucent: translucent === undefined ? false : translucent,
title,
titleFontFamily: headerTitleStyle && headerTitleStyle.fontFamily,
- titleColor: headerTintColor,
+ titleColor: (headerTitleStyle && headerTitleStyle.color) || headerTintColor,
titleFontSize: headerTitleStyle && headerTitleStyle.fontSize,
backTitle: headerBackTitleVisible === false ? '' : headerBackTitle,
backTitleFontFamily:
|
feat: support header title color (#<I>)
Currently it was not possible to set a title color different than the tint color. This PR keeps the tintColor as the default header title color but also uses the headerStyle.color if defined.
|
kmagiera_react-native-screens
|
train
|
js
|
0d39dbf63bfba46921ac20c0c7aaaaa35d39d386
|
diff --git a/packages/icon/src/Icon.js b/packages/icon/src/Icon.js
index <HASH>..<HASH> 100644
--- a/packages/icon/src/Icon.js
+++ b/packages/icon/src/Icon.js
@@ -16,7 +16,11 @@
/* @flow */
import React, { PureComponent } from 'react';
-import { createStyledComponent, generateId } from '@mineral-ui/component-utils';
+import {
+ createStyledComponent,
+ pxToEm,
+ generateId
+} from '@mineral-ui/component-utils';
type Props = {
/** Available sizes, including custom - e.g. '5em' or '20px' */
@@ -34,9 +38,9 @@ type Props = {
const iconStyles = (props, baseTheme) => {
const theme = {
Icon_fill: baseTheme.color_gray_60,
- Icon_size_small: '2em',
- Icon_size_medium: '3em',
- Icon_size_large: '4em',
+ Icon_size_small: pxToEm(12),
+ Icon_size_medium: pxToEm(16),
+ Icon_size_large: pxToEm(20),
...baseTheme
};
|
refactor(icon): Update sizes
Updates sizes to match those used in Button
BREAKING CHANGE: Sizes changed
|
mineral-ui_mineral-ui
|
train
|
js
|
80533ce1ee574081d2ae6ac0202ce9f8d926aa22
|
diff --git a/models/classes/search/index/DocumentBuilder/IndexDocumentBuilder.php b/models/classes/search/index/DocumentBuilder/IndexDocumentBuilder.php
index <HASH>..<HASH> 100644
--- a/models/classes/search/index/DocumentBuilder/IndexDocumentBuilder.php
+++ b/models/classes/search/index/DocumentBuilder/IndexDocumentBuilder.php
@@ -246,7 +246,9 @@ class IndexDocumentBuilder extends InjectionAwareService implements IndexDocumen
$customPropertiesValues = $resource->getPropertyValuesCollection($property);
$customProperties[$fieldName][] = array_map(
function (core_kernel_classes_Container $property): string {
- return $property instanceof Resource ? $property->getUri() : (string)$property;
+ return tao_helpers_Uri::encode(
+ $property instanceof Resource ? $property->getUri() : (string)$property
+ );
},
$customPropertiesValues->toArray()
);
|
fix: keep value econded in tao format
|
oat-sa_tao-core
|
train
|
php
|
76d98f4405635b979c700b1a07afd7d4512132b3
|
diff --git a/src/geshi/powershell.php b/src/geshi/powershell.php
index <HASH>..<HASH> 100644
--- a/src/geshi/powershell.php
+++ b/src/geshi/powershell.php
@@ -264,7 +264,7 @@ $language_data = array (
'PARSER_CONTROL' => array(
'KEYWORDS' => array(
4 => array(
- 'DISALLOWED_AFTER' => '(?![a-zA-Z])'
+ 'DISALLOWED_AFTER' => '(?![a-zA-Z])',
'DISALLOWED_BEFORE' => ''
),
6 => array(
|
fix: Missing comma in Parser Control
|
GeSHi_geshi-1.0
|
train
|
php
|
2703a07c215c6c92387fdd220e3bf5cb2a91f32e
|
diff --git a/packages/okidoc-md/src/utils/nodeAST.js b/packages/okidoc-md/src/utils/nodeAST.js
index <HASH>..<HASH> 100644
--- a/packages/okidoc-md/src/utils/nodeAST.js
+++ b/packages/okidoc-md/src/utils/nodeAST.js
@@ -56,6 +56,7 @@ function cleanUpClassProperty(
// https://github.com/babel/babel/blob/v7.0.0-beta.44/packages/babel-plugin-transform-typescript/src/index.js#L155-L168
node.accessibility = null;
node.decorators = [];
+ item.optional = false;
cleanUpNodeJSDoc(node, JSDocCommentValue);
}
|
fix(okidoc-md): fix issue ts vs flow issue for optional class property
|
wix_okidoc
|
train
|
js
|
a2430f4266a698abdb75d5e61b44b4bbd33b46af
|
diff --git a/packages/cli/cli.js b/packages/cli/cli.js
index <HASH>..<HASH> 100644
--- a/packages/cli/cli.js
+++ b/packages/cli/cli.js
@@ -4,14 +4,14 @@ const yargs = require("yargs");
const { log, getProject } = require("./utils");
const { boolean } = require("boolean");
+// Disable help processing until after plugins are imported.
+yargs.help(false);
+
// Immediately load .env.{PASSED_ENVIRONMENT} and .env files.
// This way we ensure all of the environment variables are not loaded too late.
const project = getProject();
let paths = [path.join(project.root, ".env")];
-// Disable help processing until after plugins are imported
-yargs.help(false);
-
if (yargs.argv.env) {
paths.push(path.join(project.root, `.env.${yargs.argv.env}`));
}
@@ -102,6 +102,6 @@ yargs
(async () => {
await createCommands(yargs, context);
- // Run
+ // Enable help and run the CLI.
yargs.help().argv;
})();
|
refactor: bring `yargs.help(false);` to the top
|
Webiny_webiny-js
|
train
|
js
|
f595bc0b675bab6c6affb22d48a572f2f342f2b6
|
diff --git a/test/headful.spec.js b/test/headful.spec.js
index <HASH>..<HASH> 100644
--- a/test/headful.spec.js
+++ b/test/headful.spec.js
@@ -118,11 +118,11 @@ module.exports.addTests = function({testRunner, expect, puppeteer, defaultBrowse
await browser.close();
});
it('should open devtools when "devtools: true" option is given', async({server}) => {
- const browser = await puppeteer.launch({...headfulOptions, devtools: true});
+ const browser = await puppeteer.launch(Object.assign({devtools: true}, headfulOptions));
const context = await browser.createIncognitoBrowserContext();
await Promise.all([
context.newPage(),
- context.waitForTarget(target => target.url().startsWith('devtools://')),
+ context.waitForTarget(target => target.url().includes('devtools://')),
]);
await browser.close();
});
|
test: fix tests to work on node6 (#<I>)
Our magical node6 transpiler can't handle object spreads :(
Drive-by: use "includes" instead of "startsWith" for devtools URL
since I remember that it used to be "chrome-devtools://", and somehow
I saw it as "devtools://" somewhere.
|
GoogleChrome_puppeteer
|
train
|
js
|
0efaf5890336b28b8e5e0564d5d8459921246597
|
diff --git a/packages/video/video.showcase.js b/packages/video/video.showcase.js
index <HASH>..<HASH> 100644
--- a/packages/video/video.showcase.js
+++ b/packages/video/video.showcase.js
@@ -108,6 +108,23 @@ export default {
/>
</View>
)
+ },
+ {
+ type: "story",
+ name: "no poster image",
+ component: () => (
+ <View>
+ <Text style={{ marginTop: 10, marginBottom: 10 }}>Mobile size:</Text>
+ <Video {...defaultVideoProps} poster={null} />
+ <Text style={{ marginTop: 20, marginBottom: 10 }}>Desktop size:</Text>
+ <Video
+ {...defaultVideoProps}
+ height={374}
+ poster={null}
+ width={664}
+ />
+ </View>
+ )
}
]
};
|
chore: add storybook story for videos without poster images (#<I>)
|
newsuk_times-components
|
train
|
js
|
7622d838b84cd4a38e8af234ed8a4538498dd4f2
|
diff --git a/packages/ui-scripts/lib/publish-latest.js b/packages/ui-scripts/lib/publish-latest.js
index <HASH>..<HASH> 100644
--- a/packages/ui-scripts/lib/publish-latest.js
+++ b/packages/ui-scripts/lib/publish-latest.js
@@ -41,7 +41,7 @@ const { createNPMRCFile } = require('./utils/npm')
try {
const pkgJSON = getPackageJSON()
// Arguments
- // 1: version to publish. If current version, use 'current' otherwise e.g.: 8.1.3
+ // 1: version to publish. If current version, use 'current' or don't bass anything. Otherwise e.g.: 8.1.3
// 2: publish type. defaults to current. If set to 'maintenance', it will publish with vx_maintenance tag
// e.g.: ui-scripts --publish-latest 5.12.2 maintenance
const releaseVersion =
|
chore(ui-scripts): fix comments
|
instructure_instructure-ui
|
train
|
js
|
c222b221327a1d52338d4f34656f3b8dacfd10ad
|
diff --git a/plugin/common/init.go b/plugin/common/init.go
index <HASH>..<HASH> 100644
--- a/plugin/common/init.go
+++ b/plugin/common/init.go
@@ -137,6 +137,7 @@ func (p *HashicorpPlugin) Call(funcName string, args ...interface{}) (interface{
func (p *HashicorpPlugin) Quit() error {
// kill hashicorp plugin process
+ log.Warn().Msg("quit hashicorp plugin process")
pluginHost.Quit()
return nil
}
diff --git a/runner.go b/runner.go
index <HASH>..<HASH> 100644
--- a/runner.go
+++ b/runner.go
@@ -9,8 +9,11 @@ import (
"net/http"
"net/http/httputil"
"net/url"
+ "os"
+ "os/signal"
"strconv"
"strings"
+ "syscall"
"testing"
"time"
@@ -213,6 +216,18 @@ func initPlugin(path string) (plugin common.Plugin, err error) {
go ga.SendEvent(event)
}()
plugin, err = common.Init(path)
+
+ // catch Interrupt and SIGTERM signals to ensure plugin quitted
+ c := make(chan os.Signal)
+ signal.Notify(c, os.Interrupt, syscall.SIGTERM)
+ go func() {
+ <-c
+ if plugin != nil {
+ plugin.Quit()
+ }
+ os.Exit(1)
+ }()
+
return
}
|
feat: catch Interrupt and SIGTERM signals to ensure plugin quitted
|
HttpRunner_HttpRunner
|
train
|
go,go
|
cba8955bd9b84eafdb179929c4834291c0224dab
|
diff --git a/src/CornerstoneViewport/CornerstoneViewport.js b/src/CornerstoneViewport/CornerstoneViewport.js
index <HASH>..<HASH> 100644
--- a/src/CornerstoneViewport/CornerstoneViewport.js
+++ b/src/CornerstoneViewport/CornerstoneViewport.js
@@ -107,7 +107,6 @@ class CornerstoneViewport extends Component {
imageIdIndex, // Maybe
imageProgress: 0,
isLoading: true,
- numImagesLoaded: 0,
error: null,
// Overlay
scale: undefined,
@@ -127,6 +126,8 @@ class CornerstoneViewport extends Component {
this.startLoadHandler = this.props.startLoadHandler;
this.endLoadHandler = this.props.endLoadHandler;
this.loadHandlerTimeout = undefined; // "Loading..." timer
+
+ this.numImagesLoaded = 0;
}
// ~~ LIFECYCLE
@@ -686,9 +687,7 @@ class CornerstoneViewport extends Component {
onImageLoaded = () => {
// TODO: This is not necessarily true :thinking:
// We need better cache reporting a layer up
- this.setState({
- numImagesLoaded: this.state.numImagesLoaded + 1,
- });
+ this.numImagesLoaded++;
};
onImageProgress = e => {
|
fix: shift numImages out of state to avoid re-renders (unused)
|
cornerstonejs_react-cornerstone-viewport
|
train
|
js
|
81402d32c520649fe2299801b81e812e2f1e0453
|
diff --git a/src/Definition/Plugin/NamespaceDefinitionPlugin.php b/src/Definition/Plugin/NamespaceDefinitionPlugin.php
index <HASH>..<HASH> 100644
--- a/src/Definition/Plugin/NamespaceDefinitionPlugin.php
+++ b/src/Definition/Plugin/NamespaceDefinitionPlugin.php
@@ -216,7 +216,11 @@ class NamespaceDefinitionPlugin extends AbstractDefinitionPlugin
$name = lcfirst($namespace);
$typeName = ucfirst($namespace).(($definition instanceof MutationDefinition) ? $mutationSuffix : $querySuffix);
if (!$root) {
- $root = $this->createRootNamespace(\get_class($definition), $name, $typeName, $endpoint);
+ if (isset($namespacedDefinitions[$name])) {
+ $root = $namespacedDefinitions[$name];
+ } else {
+ $root = $this->createRootNamespace(\get_class($definition), $name, $typeName, $endpoint);
+ }
$parent = $endpoint->getType($root->getType());
$namespacedDefinitions[$root->getName()] = $root;
} else {
|
fix: does not override operations using the same namespace
|
ynloultratech_graphql-bundle
|
train
|
php
|
4cefa2782c565712f458a4d7c4a4026f941f6e4b
|
diff --git a/src/runner.js b/src/runner.js
index <HASH>..<HASH> 100644
--- a/src/runner.js
+++ b/src/runner.js
@@ -389,7 +389,11 @@ async function runTest(test, logs) {
} else {
file.passCount += 1
if (runner.verbose) {
- logs.prepend(indent + huey.green('✦ ') + getTestName(test) + '\n')
+ if (logs.length) {
+ logs.ln()
+ logs.prepend('')
+ }
+ logs.prepend(indent + huey.green('✦ ') + getTestName(test))
} else {
logs.quiet = true
}
@@ -455,10 +459,10 @@ async function runGroup(group) {
logs = mockConsole(true)
logs.quiet = runner.quiet
}
- log('')
try {
await runAll(group.afterEach)
} finally {
+ logs.ln()
logs.exec()
}
} else if (test.fn) {
|
fix: ensure an empty line exists between sections
Where "sections" refers to:
- test names
- test logs
- test errors
- beforeEach logs
- afterEach logs
NOTE: If a test has no logs, no empty line will exist between its name and the next test's name.
|
aleclarson_testpass
|
train
|
js
|
d8864e199e43a8bf2fbd6759442f36dfc382d9e2
|
diff --git a/webroot/js/cart.js b/webroot/js/cart.js
index <HASH>..<HASH> 100644
--- a/webroot/js/cart.js
+++ b/webroot/js/cart.js
@@ -445,6 +445,9 @@ foodcoopshop.Cart = {
},
getCartProductHtml: function (productId, amount, price, productName, unity, manufacturerLink, image, deposit, tax, timebasedCurrencyHours, orderedQuantityInUnits, unitName, unitAmount, priceInclPerUnit, pickupDay) {
+
+ priceInclPerUnit = parseFloat(priceInclPerUnit);
+
var imgHtml = '<span class="image">' + image + '</span>';
if (!$(image).attr('src').match(/de-default-home/)) {
imgHtml = '<a href="javascript:void(0);" data-modal-title="' + productName + '" data-modal-image="' + $(image).attr('src').replace(/-home_/, '-thickbox_') + '" class="image">' + image + '</a>';
|
fix: entering weight multiple times causes wrong price
|
foodcoopshop_foodcoopshop
|
train
|
js
|
c8833f0d60ba5a885a5122898ba6ed60f4aac88e
|
diff --git a/packages/cozy-konnector-libs/src/libs/cozyclient.js b/packages/cozy-konnector-libs/src/libs/cozyclient.js
index <HASH>..<HASH> 100644
--- a/packages/cozy-konnector-libs/src/libs/cozyclient.js
+++ b/packages/cozy-konnector-libs/src/libs/cozyclient.js
@@ -67,8 +67,8 @@ const getCozyClient = function(environment = 'production') {
const cozyFields = JSON.parse(process.env.COZY_FIELDS || '{}')
cozyClient.new = new NewCozyClient({
- uri: cozyClient._uri,
- token: cozyClient._token,
+ uri: cozyURL,
+ token: credentials.token.accessToken,
appMetadata: {
slug: manifest.data.slug,
sourceAccount: cozyFields.account,
|
fix: initalization of new cozy-client instance
|
konnectors_libs
|
train
|
js
|
0af6b56e3b7d2d3bb6037d5ad21c197bb68c4653
|
diff --git a/packages/cozy-scripts/template/app/jest.config.js b/packages/cozy-scripts/template/app/jest.config.js
index <HASH>..<HASH> 100644
--- a/packages/cozy-scripts/template/app/jest.config.js
+++ b/packages/cozy-scripts/template/app/jest.config.js
@@ -9,6 +9,10 @@ module.exports = {
'\\.(css|styl)$': 'identity-obj-proxy'
},
transformIgnorePatterns: ['node_modules/(?!cozy-ui)'],
+ transform: {
+ // babel-jest module is installed by cozy-scripts
+ '^.+\\.jsx?$': 'babel-jest'
+ },
globals: {
__ALLOW_HTTP__: false,
__TARGET__: 'browser',
|
fix: :nail_care: Force using babel-jest for react app
|
CPatchane_create-cozy-app
|
train
|
js
|
bfd4fac0edd82590bbd3e550c5f7dd8b2a042c89
|
diff --git a/vaex/test/dataset.py b/vaex/test/dataset.py
index <HASH>..<HASH> 100644
--- a/vaex/test/dataset.py
+++ b/vaex/test/dataset.py
@@ -1399,8 +1399,8 @@ class TestDataset(unittest.TestCase):
path_fits_astropy = tempfile.mktemp(".fits")
#print path
- with self.assertRaises(AssertionError):
- self.dataset.export_hdf5(path, selection=True)
+ #with self.assertRaises(AssertionError):
+ # self.dataset.export_hdf5(path, selection=True)
for dataset in [self.dataset_concat_dup, self.dataset]:
#print dataset.virtual_columns
|
fix: we don't check for selections anymore in export, test reflects that now
|
vaexio_vaex
|
train
|
py
|
cfd2fed494dc707e03ade086009ebfdd27578477
|
diff --git a/packages/netlify-cms-core/src/components/App/App.js b/packages/netlify-cms-core/src/components/App/App.js
index <HASH>..<HASH> 100644
--- a/packages/netlify-cms-core/src/components/App/App.js
+++ b/packages/netlify-cms-core/src/components/App/App.js
@@ -217,11 +217,11 @@ class App extends React.Component {
render={props => <Collection {...props} isSearchResults />}
/>
<RouteInCollection
- path="/edit/:collectionName/:entryName"
+ path="/edit/:name/:entryName"
collections={collections}
render={({ match }) => {
- const { collectionName, entryName } = match.params;
- return <Redirect to={`/collections/${collectionName}/entries/${entryName}`} />;
+ const { name, entryName } = match.params;
+ return <Redirect to={`/collections/${name}/entries/${entryName}`} />;
}}
/>
<Route component={NotFoundPage} />
|
fix(core): use correct name for edit route param (#<I>)
|
netlify_netlify-cms
|
train
|
js
|
d12dc09e2ad4badd831bb9c3f89f1feeb4802a2d
|
diff --git a/engine/src/main/java/org/camunda/bpm/engine/impl/util/xml/Parse.java b/engine/src/main/java/org/camunda/bpm/engine/impl/util/xml/Parse.java
index <HASH>..<HASH> 100644
--- a/engine/src/main/java/org/camunda/bpm/engine/impl/util/xml/Parse.java
+++ b/engine/src/main/java/org/camunda/bpm/engine/impl/util/xml/Parse.java
@@ -143,7 +143,7 @@ public class Parse extends DefaultHandler {
SAXParser saxParser = parser.getSaxParser();
try {
- saxParser.setProperty(XMLConstants.ACCESS_EXTERNAL_SCHEMA, "file,http,https");
+ saxParser.setProperty("http://javax.xml.XMLConstants/property/accessExternalSchema", "file,http,https,jar,wsjar");
} catch (Exception e) {
// ignore unavailable option
}
|
fix(engine): correct external schema access in parser
* use compatible reference (some JDKs do not contain the XMLConstants constant)
* allow "jar" and "wsjar" references in schema as well
related to CAM-<I>
|
camunda_camunda-bpm-platform
|
train
|
java
|
829b28c300a3b84c47d01b7d678bcbc8324be6a7
|
diff --git a/src/components/MegadraftEditor.js b/src/components/MegadraftEditor.js
index <HASH>..<HASH> 100644
--- a/src/components/MegadraftEditor.js
+++ b/src/components/MegadraftEditor.js
@@ -67,7 +67,6 @@ export default class MegadraftEditor extends Component {
};
this.onChange = this.onChange.bind(this);
- this.onTab = this.onTab.bind(this);
this.mediaBlockRenderer = this.mediaBlockRenderer.bind(this);
@@ -158,12 +157,6 @@ export default class MegadraftEditor extends Component {
return getDefaultKeyBinding(e);
}
- onTab(event) {
- if (this.props.onTab) {
- this.props.onTab(event);
- }
- }
-
handleKeyCommand(command) {
// external key bindings
if (this.keyBindings.length) {
@@ -558,7 +551,6 @@ export default class MegadraftEditor extends Component {
readOnly={this.state.readOnly}
blockRendererFn={this.mediaBlockRenderer}
blockStyleFn={this.props.blockStyleFn || this.blockStyleFn}
- onTab={this.onTab}
handleKeyCommand={this.handleKeyCommand}
handleReturn={this.props.handleReturn || this.handleReturn}
keyBindingFn={this.externalKeyBindings}
|
refactor: remove deprecated method (#<I>)
|
globocom_megadraft
|
train
|
js
|
e50c34d5925a5db3a72db7c4d2c25c1a6cf4c9e0
|
diff --git a/lib/api/express.js b/lib/api/express.js
index <HASH>..<HASH> 100644
--- a/lib/api/express.js
+++ b/lib/api/express.js
@@ -7,7 +7,7 @@
'use strict';
module.exports = function exported(_) {
- return function express(context, pattern, done) {
+ return function express(context, pattern, done) { // eslint-disable-line consistent-return
var api = this;
var handler = api.views.lookup(pattern);
var callback = done ? done : _.noop;
@@ -15,7 +15,5 @@ module.exports = function exported(_) {
if (handler && _.isFunction(handler)) {
return handler.call(api, context, pattern, callback);
}
-
- return null;
};
};
|
test: disable `consistent-return` for api#express
|
eq8_eq8js-api
|
train
|
js
|
a494118dc730afcb6aba8e59f1f3d09a7d4f9302
|
diff --git a/packages/cli/src/download-npm-package.js b/packages/cli/src/download-npm-package.js
index <HASH>..<HASH> 100644
--- a/packages/cli/src/download-npm-package.js
+++ b/packages/cli/src/download-npm-package.js
@@ -15,7 +15,7 @@ export default async (pkg, dest) => {
const tmpObj = tmp.dirSync({ unsafeCleanup: true });
// step 2: download package from npm
- const result = await spawn.sync("npm", ["pack", pkg], {
+ const result = spawn.sync("npm", ["pack", pkg], {
stdio: "ignore",
cwd: tmpObj.name,
});
|
fix: cli await on spawn bug
|
36node_sketch
|
train
|
js
|
1f04f0a282774b7f4764cfe6e680d2fd0eb6b70d
|
diff --git a/ci/publishElmRelease.js b/ci/publishElmRelease.js
index <HASH>..<HASH> 100644
--- a/ci/publishElmRelease.js
+++ b/ci/publishElmRelease.js
@@ -19,7 +19,12 @@ async function tagElmRelease(config, context) {
exec(`elm-package publish`);
- return true;
+ return {
+ name: 'Elm release',
+ url:
+ 'http://package.elm-lang.org/packages/cultureamp/elm-css-modules-loader/' +
+ elmPackageJson.version,
+ };
}
module.exports = tagElmRelease;
|
fix(ci): Fix semantic-release plugin
Previously this returned true, but it should return an object with
information about the release.
Fixes #<I>
|
cultureamp_elm-css-modules-loader
|
train
|
js
|
e9acc7973f39761a237b015a9bfc103c4a10b085
|
diff --git a/timeside/core.py b/timeside/core.py
index <HASH>..<HASH> 100644
--- a/timeside/core.py
+++ b/timeside/core.py
@@ -28,7 +28,8 @@ import re
import numpy
import uuid
import networkx as nx
-
+import inspect
+import os
import gobject
gobject.threads_init()
@@ -52,10 +53,14 @@ class MetaProcessor(MetaComponent):
if id in _processors:
# Doctest test can duplicate a processor
# This can be identify by the conditon "module == '__main__'"
+ new_path = os.path.realpath(inspect.getfile(new_class))
+ id_path = os.path.realpath(inspect.getfile(_processors[id]))
if new_class.__module__ == '__main__':
new_class = _processors[id]
elif _processors[id].__module__ == '__main__':
pass
+ elif new_path == id_path:
+ new_class = _processors[id]
else:
raise ApiError("%s and %s have the same id: '%s'"
% (new_class.__name__,
|
fix(core): fix symlink issue when identifying duplicated processors
|
Parisson_TimeSide
|
train
|
py
|
ffcb546137a4ab609f8bef0d39feb2a9526bbade
|
diff --git a/src/Passport.php b/src/Passport.php
index <HASH>..<HASH> 100644
--- a/src/Passport.php
+++ b/src/Passport.php
@@ -409,11 +409,11 @@ class Passport
}
/**
- * Set the current client for the application with the given scopes.
+ * Set the current client for the application with the given scopes.
*
- * @param \Laravel\Passport\Client $client
- * @param array $scopes
- * @return \Laravel\Passport\Client
+ * @param \Laravel\Passport\Client $client
+ * @param array $scopes
+ * @return \Laravel\Passport\Client
*/
public static function actingAsClient($client, $scopes = [])
{
|
style: correct NBSP for regular spaces (#<I>)
|
laravel_passport
|
train
|
php
|
8541c0526faf51ea3a714be0a606eb28779e853a
|
diff --git a/lib/components/app/responsive-webapp.js b/lib/components/app/responsive-webapp.js
index <HASH>..<HASH> 100644
--- a/lib/components/app/responsive-webapp.js
+++ b/lib/components/app/responsive-webapp.js
@@ -238,7 +238,7 @@ class RouterWrapperWithAuth0 extends Component {
path={'/savetrip'}
component={(routerProps) => {
const props = this._combineProps(routerProps)
- return <SavedTripScreen wizard {...props} />
+ return <SavedTripScreen isCreating {...props} />
}}
/>
<Route
|
refactor(Responsive): Finish rename prop.
|
opentripplanner_otp-react-redux
|
train
|
js
|
42df9e46d9cfb2bf1ff07e7b71f8988b6ff0b9a4
|
diff --git a/ui/src/components/infinite-scroll/QInfiniteScroll.js b/ui/src/components/infinite-scroll/QInfiniteScroll.js
index <HASH>..<HASH> 100644
--- a/ui/src/components/infinite-scroll/QInfiniteScroll.js
+++ b/ui/src/components/infinite-scroll/QInfiniteScroll.js
@@ -184,12 +184,13 @@ export default Vue.extend({
},
render (h) {
- const content = this.$scopedSlots.default !== void 0
- ? this.$scopedSlots.default()
- : []
- const body = this.fetching === true
- ? [ h('div', { staticClass: 'q-infinite-scroll__loading' }, slot(this, 'loading')) ]
- : []
+ const content = slot(this, 'default')
+ const body = [
+ h('div', {
+ staticClass: 'q-infinite-scroll__loading',
+ class: this.fetching === true ? '' : 'invisible'
+ }, slot(this, 'loading'))
+ ]
return h(
'div',
|
feat(QInfiniteScroll): Persist loading indicator to make scroll stable #<I>
|
quasarframework_quasar
|
train
|
js
|
8c6d07448fd31c9476f6cbe6f2c50f3d7269fe55
|
diff --git a/assets/live-tools/tools.js b/assets/live-tools/tools.js
index <HASH>..<HASH> 100644
--- a/assets/live-tools/tools.js
+++ b/assets/live-tools/tools.js
@@ -52,7 +52,6 @@ if(!window.crabfarm) {
var removeOverlay = function() {
overlay.remove();
- window.crabfarm.showSelectorGadget();
};
overlay.bind("click", removeOverlay);
diff --git a/lib/crabfarm/live/interactable.rb b/lib/crabfarm/live/interactable.rb
index <HASH>..<HASH> 100644
--- a/lib/crabfarm/live/interactable.rb
+++ b/lib/crabfarm/live/interactable.rb
@@ -27,6 +27,15 @@ module Crabfarm
end
+ def examine(_tools=true)
+ if Crabfarm.live?
+ Crabfarm.live.show_primary_contents if self.is_a? BaseNavigator
+ Crabfarm.live.show_content raw_document if self.is_a? BaseReducer
+ Crabfarm.live.show_selector_gadget if _tools
+ raise LiveInterrupted.new
+ end
+ end
+
end
end
end
|
feat(live): adds examine method
Also disables selector gadget by default
|
platanus_crabfarm-gem
|
train
|
js,rb
|
56b0aafdfb32e46a6b227410b28891aef361b29d
|
diff --git a/packages/legacy-sensor/test/tracing/test.js b/packages/legacy-sensor/test/tracing/test.js
index <HASH>..<HASH> 100644
--- a/packages/legacy-sensor/test/tracing/test.js
+++ b/packages/legacy-sensor/test/tracing/test.js
@@ -48,11 +48,6 @@ describe('legacy sensor/tracing', function () {
}).registerTestHooks();
it('must trace request(<string>, options, cb)', () => {
- if (semver.lt(process.versions.node, '10.9.0')) {
- // The (url, options[, callback]) API only exists since Node 10.9.0:
- return;
- }
-
return clientControls
.sendRequest({
method: 'GET',
@@ -196,10 +191,6 @@ describe('legacy sensor/tracing', function () {
));
it('must trace get(<string>, options, cb)', () => {
- if (semver.lt(process.versions.node, '10.9.0')) {
- // The (url, options[, callback]) API only exists since Node 10.9.0.
- return;
- }
return clientControls
.sendRequest({
method: 'GET',
|
chore: removed node version check in packages/legacy-sensor/test/tracing/test.js
refs <I>
- no one is using Node < <I>
- CI uses <I>
- IMO its fine to remove these checks although we define >= <I> as engine
|
instana_nodejs-sensor
|
train
|
js
|
1604327513b9a3cc203f0c5f75506d27ccf4b4b3
|
diff --git a/packages/bonde-styleguide/src/content/Button/Button.js b/packages/bonde-styleguide/src/content/Button/Button.js
index <HASH>..<HASH> 100644
--- a/packages/bonde-styleguide/src/content/Button/Button.js
+++ b/packages/bonde-styleguide/src/content/Button/Button.js
@@ -115,7 +115,13 @@ Button.propTypes = {
/** Flat button style. */
flat: bool,
/** Button text color. */
- color: string
+ color: string,
+ /** Button type. */
+ type: string,
+}
+
+Button.defaultProps = {
+ type: 'button',
}
Button.displayName = 'Button'
|
chore(styleguide): button component type as button by default
|
nossas_bonde-client
|
train
|
js
|
18ca81e6b698dfd811df9c239b1292823d4840b8
|
diff --git a/build/tasks/ci.js b/build/tasks/ci.js
index <HASH>..<HASH> 100644
--- a/build/tasks/ci.js
+++ b/build/tasks/ci.js
@@ -1,4 +1,4 @@
var gulp = require('gulp');
-// gulp.task('ci', ['default', 'coveralls']);
-gulp.task('ci', ['default']);
+gulp.task('ci', ['default', 'coveralls']);
+// gulp.task('ci', ['default']);
|
chore(ci-build-task): changed ci task to try travis
|
aurelia-ui-toolkits_aurelia-materialize-bridge
|
train
|
js
|
6f4115d17483cf97a68004cf1a3ae1cdd54db3f2
|
diff --git a/anyconfig/api.py b/anyconfig/api.py
index <HASH>..<HASH> 100644
--- a/anyconfig/api.py
+++ b/anyconfig/api.py
@@ -269,7 +269,8 @@ def multi_load(paths, ac_parser=None, ac_template=False, ac_context=None,
cups = single_load(path, ac_parser=ac_parser,
ac_template=ac_template, ac_context=cnf, **opts)
- cnf.update(cups)
+ if cups:
+ cnf.update(cups)
return _maybe_validated(cnf, schema, **options)
|
fix: only update cnf if needed (diff is not empty)
|
ssato_python-anyconfig
|
train
|
py
|
8286ef8c3ba98b27285bf8ac5cfc49ff4b58af38
|
diff --git a/anyconfig/schema.py b/anyconfig/schema.py
index <HASH>..<HASH> 100644
--- a/anyconfig/schema.py
+++ b/anyconfig/schema.py
@@ -132,8 +132,7 @@ def gen_schema(node, **options):
:return: A dict represents JSON schema of this node
"""
- typemap = options["ac_schema_typemap"] \
- if "ac_schema_typemap" in options else _SIMPLETYPE_MAP
+ typemap = options.get("ac_schema_typemap", _SIMPLETYPE_MAP)
strict = options.get("ac_schema_type", False) == _STRICT_SCHEMA_TYPE
ret = dict(type="null")
|
refactor: simplify a conditional branch statement in .schema.gen_schema
|
ssato_python-anyconfig
|
train
|
py
|
67dc2759995fa498a09dce9e80d430c6ce80d3d8
|
diff --git a/tag/tag.js b/tag/tag.js
index <HASH>..<HASH> 100644
--- a/tag/tag.js
+++ b/tag/tag.js
@@ -72,8 +72,7 @@ export const TagNormalBody = props => (
[getClickableContentWrapperTypeClassName({
type: props.type,
isRemovable: Boolean(props.onRemove),
- })]:
- Boolean(props.onClick) && !props.isDisabled,
+ })]: Boolean(props.onClick) && !props.isDisabled,
[styles.clickableContentWrapper]:
!props.isDisabled && Boolean(props.onClick),
[styles.disabledContent]: props.isDisabled,
|
chore: apply prettier to js
|
commercetools_ui-kit
|
train
|
js
|
ca6894feed667c00a4fcb452f0e800ec1d7e50f2
|
diff --git a/gatsby-node.js b/gatsby-node.js
index <HASH>..<HASH> 100644
--- a/gatsby-node.js
+++ b/gatsby-node.js
@@ -93,7 +93,7 @@ exports.onPostBuild = async function (
}
const currentIndexState = indexState[indexName];
- setStatus(activity, `query ${i}: executing query`);
+ setStatus(activity, `query #${i + 1}: executing query`);
const result = await graphql(query);
if (result.errors) {
report.panic(`failed to index to Algolia`, result.errors);
|
chore: update message to clearly indicate the index of query (#<I>)
* chore: update message to clearly indicate the index of query
* Update gatsby-node.js
|
algolia_gatsby-plugin-algolia
|
train
|
js
|
dc49ac42dacf2c07fe68268eebbb39913448fc77
|
diff --git a/lib/logger/config-serializer.js b/lib/logger/config-serializer.js
index <HASH>..<HASH> 100644
--- a/lib/logger/config-serializer.js
+++ b/lib/logger/config-serializer.js
@@ -4,6 +4,7 @@ module.exports = configSerializer;
function configSerializer(config) {
const redactedFields = [
+ 'authorization',
'token',
'githubAppKey',
'npmToken',
|
fix: add authorization to redacted logger fields
|
renovatebot_renovate
|
train
|
js
|
87681b8e6a9d8799529e275f5b5a40dc0bff59f5
|
diff --git a/Runnable/EventsGenerator/CallableEventsGenerator.php b/Runnable/EventsGenerator/CallableEventsGenerator.php
index <HASH>..<HASH> 100644
--- a/Runnable/EventsGenerator/CallableEventsGenerator.php
+++ b/Runnable/EventsGenerator/CallableEventsGenerator.php
@@ -6,7 +6,7 @@ class CallableEventsGenerator implements EventsGenerator
{
public function produce()
{
- call_user_func_array($this->callable, []);
+ return call_user_func_array($this->callable, []);
}
/**
|
fix(CallableEventsGenerator): return the result of the produce call
|
wizbii_pipeline
|
train
|
php
|
8168056890f8f95b7a509c574e97e0a51f0a2322
|
diff --git a/test/transform.js b/test/transform.js
index <HASH>..<HASH> 100644
--- a/test/transform.js
+++ b/test/transform.js
@@ -53,8 +53,8 @@ describe('Transform stream', function () {
t.on('end', function () {
assert(gotBytes);
- assert(gotBytes);
- assert(gotBytes);
+ assert(gotPassthrough);
+ assert(gotData);
done();
});
|
test: check all the variables in Transform test
Before `gotBytes` was being checked 3 times in a row.
Closes #1.
|
TooTallNate_node-stream-parser
|
train
|
js
|
1c00f741c2e92002c45cf42b69dee0bc8dd549da
|
diff --git a/optlang/cplex_interface.py b/optlang/cplex_interface.py
index <HASH>..<HASH> 100644
--- a/optlang/cplex_interface.py
+++ b/optlang/cplex_interface.py
@@ -93,7 +93,7 @@ _CPLEX_STATUS_TO_STATUS = {
cplex.Cplex.solution.status.num_best: interface.NUMERIC,
cplex.Cplex.solution.status.optimal: interface.OPTIMAL,
cplex.Cplex.solution.status.optimal_face_unbounded: interface.SPECIAL,
- cplex.Cplex.solution.status.optimal_infeasible: interface.SPECIAL,
+ cplex.Cplex.solution.status.optimal_infeasible: interface.INFEASIBLE,
cplex.Cplex.solution.status.optimal_populated: interface.SPECIAL,
cplex.Cplex.solution.status.optimal_populated_tolerance: interface.SPECIAL,
cplex.Cplex.solution.status.optimal_relaxed_inf: interface.SPECIAL,
|
fix: treat "optimal_infeasible" as infeasible
“optimal with unscaled infeasibilities” occurs when the scaled problem
is solved within tolerance, but the optimal solution is outside the
unscaled tolerance. This situation is now interpreted as infeasible.
|
biosustain_optlang
|
train
|
py
|
0b550f96957f0a7b573e5880123010671b470a12
|
diff --git a/modules/core/src/life_cycle/life_cycle.js b/modules/core/src/life_cycle/life_cycle.js
index <HASH>..<HASH> 100644
--- a/modules/core/src/life_cycle/life_cycle.js
+++ b/modules/core/src/life_cycle/life_cycle.js
@@ -1,13 +1,22 @@
import {FIELD} from 'facade/lang';
import {ChangeDetector} from 'change_detection/change_detector';
+import {VmTurnZone} from 'core/zone/vm_turn_zone';
export class LifeCycle {
_changeDetector:ChangeDetector;
- constructor() {
- this._changeDetector = null;
+
+ constructor(changeDetector:ChangeDetector) {
+ this._changeDetector = changeDetector;
+ }
+
+ registerWith(zone:VmTurnZone) {
+ zone.initCallbacks({
+ onTurnDone: () => this.tick()
+ });
+ this.tick();
}
- digest() {
- _changeDetector.detectChanges();
+ tick() {
+ this._changeDetector.detectChanges();
}
}
\ No newline at end of file
|
feat(LifeCycle): change LifeCycle to be able register it with a zone
|
angular_angular
|
train
|
js
|
0d247cdbe1366f511dd61e15d2b0d79a597b3817
|
diff --git a/src/Service/DataExport.php b/src/Service/DataExport.php
index <HASH>..<HASH> 100644
--- a/src/Service/DataExport.php
+++ b/src/Service/DataExport.php
@@ -23,8 +23,8 @@ use Nails\Admin\DataExport\SourceResponse;
*/
class DataExport
{
- protected $aSources = [];
- protected $aFormats = [];
+ protected $aSources = [];
+ protected $aFormats = [];
protected $aCacheFiles = [];
// --------------------------------------------------------------------------
@@ -36,18 +36,8 @@ class DataExport
{
$this->aSources = [];
$this->aFormats = [];
- $aComponents = array_merge(
- [
- (object) [
- 'slug' => 'app',
- 'namespace' => 'App\\',
- 'path' => NAILS_APP_PATH,
- ],
- ],
- Components::available()
- );
-
- foreach ($aComponents as $oComponent) {
+
+ foreach (Components::available() as $oComponent) {
$sPath = $oComponent->path;
$sNamespace = $oComponent->namespace;
|
fix: Components::available() includes the application
|
nails_module-admin
|
train
|
php
|
7b8118e85e140b605d5bb15970c831b9d45817d6
|
diff --git a/models/classes/search/index/DocumentBuilder/IndexDocumentBuilder.php b/models/classes/search/index/DocumentBuilder/IndexDocumentBuilder.php
index <HASH>..<HASH> 100644
--- a/models/classes/search/index/DocumentBuilder/IndexDocumentBuilder.php
+++ b/models/classes/search/index/DocumentBuilder/IndexDocumentBuilder.php
@@ -250,17 +250,6 @@ class IndexDocumentBuilder extends InjectionAwareService implements IndexDocumen
}
$fieldName = $propertyTypeId . '_' . \tao_helpers_Slug::create($customPropertyLabel);
- $propertyValue = $resource->getOnePropertyValue($property);
-
- if (null === $propertyValue) {
- continue;
- }
-
- if ($propertyValue instanceof Literal) {
- $customProperties[$fieldName][] = (string)$propertyValue;
- $customProperties[$fieldName] = array_unique($customProperties[$fieldName]);
- continue;
- }
$customPropertiesValues = $resource->getPropertyValues($property);
$customProperties[$fieldName] = array_map(
|
fix: collections of Literals should be searchable
|
oat-sa_tao-core
|
train
|
php
|
97ac11a9beeec558899ba21f80d2610cd7aabc92
|
diff --git a/lib/Rule.js b/lib/Rule.js
index <HASH>..<HASH> 100644
--- a/lib/Rule.js
+++ b/lib/Rule.js
@@ -64,9 +64,10 @@ Rule.prototype.wrapPath = function (rule) {
if (rule.charAt(rule.length - 1) === symbol.file) {
rule = rule.slice(0, rule.length - 1);
} else {
- rule = rule.replace(/\/$/, '') + '/**/*'
+ rule = rule.replace(/\/$/, '') + '/';
}
- return this.wrapMatch('-' + rule);
+ const length = rule.length;
+ return path => path.length > length && path.indexOf(rule) === 0;
};
Rule.prototype.setNegation = function (negation) {
|
refactor(rule): update rule.wrapPath to str match.
|
xgfe_freepack
|
train
|
js
|
ed8c4906d63cc67bb79b7d889906d866f48a4591
|
diff --git a/build/prepareNightly.js b/build/prepareNightly.js
index <HASH>..<HASH> 100644
--- a/build/prepareNightly.js
+++ b/build/prepareNightly.js
@@ -9,9 +9,14 @@ if (!parts) {
throw new Error(`Invalid version number ${version}`);
}
// Add date to version.
-const major = parts[1];
-const minor = parts[2];
-const patch = parts[3];
+const major = +parts[1];
+const minor = +parts[2];
+let patch = +parts[3];
+const isStable = !parts[4];
+if (isStable) {
+ // It's previous stable version. Dev version should be higher.
+ patch++;
+}
const date = new Date().toISOString().replace(/:|T|\.|-/g, '').slice(0, 8);
const nightlyVersion = `${major}.${minor}.${patch}-dev.${date}`;
|
chore: increase dev version from stable version.
|
ecomfe_zrender
|
train
|
js
|
ddea68a80deedced4bf0fad24e66f075e368c38c
|
diff --git a/lib/genDocute.js b/lib/genDocute.js
index <HASH>..<HASH> 100644
--- a/lib/genDocute.js
+++ b/lib/genDocute.js
@@ -23,6 +23,6 @@ module.exports = async config => {
logger.success('Generated successfully')
} catch (err) {
console.error(err.name === 'SAOError' ? err.message : err.stack)
+ process.exit(1)
}
- process.exit(1)
}
|
fix: Avoid abnormal exits
fix #<I>
|
vuese_vuese
|
train
|
js
|
e75d10d6b7a547f5be7f8e0ce904baafba88c41b
|
diff --git a/cmd/influxd/launcher/query_test.go b/cmd/influxd/launcher/query_test.go
index <HASH>..<HASH> 100644
--- a/cmd/influxd/launcher/query_test.go
+++ b/cmd/influxd/launcher/query_test.go
@@ -44,8 +44,8 @@ mem,server=b value=45.2`))
}
rawQ := fmt.Sprintf(`from(bucket:"%s")
- |> filter(fn: (r) => r._measurement == "cpu" and (r._field == "v1" or r._field == "v0"))
|> range(start:-1m)
+ |> filter(fn: (r) => r._measurement == "cpu" and (r._field == "v1" or r._field == "v0"))
`, be.Bucket.Name)
// Expected keys:
|
test(launcher): fix ill-formatted query; range must come before filter
Until <URL>
|
influxdata_influxdb
|
train
|
go
|
135f529bfc131a9137672be3399e51eecea03f1f
|
diff --git a/worker/bridge.js b/worker/bridge.js
index <HASH>..<HASH> 100644
--- a/worker/bridge.js
+++ b/worker/bridge.js
@@ -1,10 +1,6 @@
import PromiseWorker from 'promise-worker';
-const uri = process.env.NODE_ENV === 'development' ?
- '/panels-worker.js' :
- 'https://cdn.uxtemple.com/panels-worker.js';
-
-const worker = new Worker(uri);
+const worker = new Worker('/panels-worker.js');
const promiseWorker = new PromiseWorker(worker);
export default promiseWorker;
|
fix: always load worker from /panels-worker.js
|
UXtemple_panels
|
train
|
js
|
26f377c4337b2ff7d801a9155fd66992e6d9c57a
|
diff --git a/pkg/tsdb/cloudwatch/metric_find_query.go b/pkg/tsdb/cloudwatch/metric_find_query.go
index <HASH>..<HASH> 100644
--- a/pkg/tsdb/cloudwatch/metric_find_query.go
+++ b/pkg/tsdb/cloudwatch/metric_find_query.go
@@ -162,7 +162,7 @@ func init() {
"AWS/IoT": {"ActionType", "BehaviorName", "CheckName", "JobId", "Protocol", "RuleName", "ScheduledAuditName", "SecurityProfileName"},
"AWS/IoTAnalytics": {"ActionType", "ChannelName", "DatasetName", "DatastoreName", "PipelineActivityName", "PipelineActivityType", "PipelineName"},
"AWS/KMS": {"KeyId"},
- "AWS/Kafka": {"Broker", "Cluster", "Topic"},
+ "AWS/Kafka": {"Broker ID", "Cluster Name", "Topic"},
"AWS/Kinesis": {"ShardId", "StreamName"},
"AWS/KinesisAnalytics": {"Application", "Flow", "Id"},
"AWS/KinesisVideo": {},
|
fix: modifying AWS Kafka dimension names to correct ones (#<I>)
|
grafana_grafana
|
train
|
go
|
d6526753eee2d7cc16c8c5bb6477e5eac642fc38
|
diff --git a/index.js b/index.js
index <HASH>..<HASH> 100644
--- a/index.js
+++ b/index.js
@@ -77,10 +77,6 @@ DynamoDBDOWN.prototype._open = function (options, cb) {
}
}
-DynamoDBDOWN.prototype._close = function (cb) {
- cb()
-}
-
DynamoDBDOWN.prototype._put = function (key, value, options, cb) {
const params = {
TableName: this.encodedTableName,
|
refactor: use abstract implementation of `_close`
|
KlausTrainer_dynamodbdown
|
train
|
js
|
f4cce8c509439cc2a587d92b5039a6b880146108
|
diff --git a/biz/webui/cgi-bin/util.js b/biz/webui/cgi-bin/util.js
index <HASH>..<HASH> 100644
--- a/biz/webui/cgi-bin/util.js
+++ b/biz/webui/cgi-bin/util.js
@@ -16,6 +16,10 @@ exports.getClientId = function() {
};
exports.getServerInfo = function(req) {
+ var baseDir;
+ if (!config.networkMode && !config.pluginsMode) {
+ baseDir = config.baseDirHash;
+ }
var info = {
pid: PID,
pInfo: proc,
@@ -30,7 +34,7 @@ exports.getServerInfo = function(req) {
rulesMode: config.rulesMode,
strictMode: config.strict,
multiEnv: config.multiEnv,
- baseDir: config.baseDirHash,
+ baseDir: baseDir,
username: config.username,
nodeVersion: process.version,
latestVersion: properties.getLatestVersion('latestVersion'),
|
refactor: hide baseDir in network or plugins mode
|
avwo_whistle
|
train
|
js
|
f214bd9637fd7bbd114994c4c2418a9ca37390d7
|
diff --git a/packages/ssr/src/lib/run-client.js b/packages/ssr/src/lib/run-client.js
index <HASH>..<HASH> 100644
--- a/packages/ssr/src/lib/run-client.js
+++ b/packages/ssr/src/lib/run-client.js
@@ -32,9 +32,7 @@ const makeClient = options => {
if (typeof window !== "undefined" && window.nuk) {
const acsTnlCookie = window.nuk.getCookieValue("acs_tnl");
const sacsTnlCookie = window.nuk.getCookieValue("sacs_tnl");
- if (acsTnlCookie && sacsTnlCookie) {
- networkInterfaceOptions.headers.Authorization = `Cookie acs_tnl=${acsTnlCookie};sacs_tnl=${sacsTnlCookie}`;
- }
+ networkInterfaceOptions.headers.Authorization = `Cookie acs_tnl=${acsTnlCookie};sacs_tnl=${sacsTnlCookie}`;
}
return new ApolloClient({
|
fix: revert cookie pagination fix (#<I>)
|
newsuk_times-components
|
train
|
js
|
13d4d984d0393ddc01471b2202b1e6fc3b66a267
|
diff --git a/src/notebook/epics/github-publish.js b/src/notebook/epics/github-publish.js
index <HASH>..<HASH> 100644
--- a/src/notebook/epics/github-publish.js
+++ b/src/notebook/epics/github-publish.js
@@ -40,7 +40,6 @@ export function notifyUser(filename, gistID, notificationSystem) {
},
});
}
-// give these module scope to allow overwriting of metadata
/**
* Callback function to be used in publishNotebookObservable such that the
|
chore(publish): Remove extraneous comment
|
nteract_nteract
|
train
|
js
|
37ab299ba3cd1f10fccda41bda580e24f7e1f07f
|
diff --git a/source/application/tasks/build-bundles/index.js b/source/application/tasks/build-bundles/index.js
index <HASH>..<HASH> 100644
--- a/source/application/tasks/build-bundles/index.js
+++ b/source/application/tasks/build-bundles/index.js
@@ -57,11 +57,17 @@ export default async (application, settings) => {
}
// Get environments
- const environments = await getEnvironments(base, {
+ const loadedEnvironments = await getEnvironments(base, {
cache,
log
});
+ // Environments have to apply on all patterns
+ const environments = loadedEnvironments.map(environment => {
+ environment.applyTo = '**/*';
+ return environment;
+ });
+
// Get available patterns
const availablePatterns = await getPatternMtimes(base, {
resolveDependencies: true
@@ -83,10 +89,17 @@ export default async (application, settings) => {
});
// Merge environment config into transform config
- const config = merge({}, {
- patterns: application.configuration.patterns,
- transforms: application.configuration.transforms
- }, {transforms: envConfig});
+ const config = merge(
+ {},
+ {
+ patterns: application.configuration.patterns,
+ transforms: application.configuration.transforms
+ },
+ envConfig,
+ {
+ environments: [environment.name]
+ }
+ );
// build all patterns matching the include config
const builtPatterns = await Promise.all(includedPatterns
|
fix: apply environment config to bundles properly
* environment config was merged into transforms
* environment config now is merged with whole pattern config
<URL>
|
patternplate-archive_patternplate-server
|
train
|
js
|
b4a1f6a63e0ba71cfd013396aeb8d2e29c0a295f
|
diff --git a/src/utils/save-cordova-xml.js b/src/utils/save-cordova-xml.js
index <HASH>..<HASH> 100644
--- a/src/utils/save-cordova-xml.js
+++ b/src/utils/save-cordova-xml.js
@@ -15,6 +15,9 @@ const parseXML = function(xmlPath) {
return new RSVP.Promise((resolve, reject) => {
const contents = fs.readFileSync(xmlPath, 'utf8');
const parser = new xml2js.Parser();
+
+ if (contents === '') reject('File is empty');
+
parser.parseString(contents, function (err, result) {
if (err) reject(err);
if (result) resolve(result);
|
fix(save-cordova-xml): Update test to guard against config.xml being empty
|
isleofcode_splicon
|
train
|
js
|
d09d125b972ce6addd6aa433576488ef6a8c00c2
|
diff --git a/lib/service/extract-saz.js b/lib/service/extract-saz.js
index <HASH>..<HASH> 100644
--- a/lib/service/extract-saz.js
+++ b/lib/service/extract-saz.js
@@ -34,7 +34,8 @@ function parseMetaInfo(result) {
if (!req.headers.host) {
req.headers.host = options.host;
}
- port = options.port || (/^https:/i.test(req.url) ? 443 : 80);
+ req.isHttps = /^https:/i.test(req.url);
+ port = options.port || (req.isHttps ? 443 : 80);
req.url = options.path;
} else if (typeof req.headers.host !== 'string') {
req.headers.host = '';
@@ -77,7 +78,7 @@ function parseMetaInfo(result) {
result.url = req.url;
result.isHttps = true;
} else {
- result.url = 'http://' + req.headers.host + req.url;
+ result.url = 'http' + (req.isHttps ? 's' : '') +'://' + req.headers.host + req.url;
if (/\bwebsocket\b/i.test(req.headers.upgrade)) {
result.url = result.url.replace(/^http/, 'ws');
}
|
fix: import saz file
|
avwo_whistle
|
train
|
js
|
5bb8865a768f0052d223a50e4ed27f6763a69338
|
diff --git a/lib/core/environment.js b/lib/core/environment.js
index <HASH>..<HASH> 100644
--- a/lib/core/environment.js
+++ b/lib/core/environment.js
@@ -57,8 +57,8 @@ exports.getConfig = function (platform, env, project_dir, argv) {
}
// option to configure custom ports
- if (argv.hasOwnProperty('custom_ports')) {
- var c_ports = argv['custom_ports'].split(',').reduce(function (memo, port) {
+ if (argv.hasOwnProperty('custom-ports')) {
+ var c_ports = argv['custom-ports'].split(',').reduce(function (memo, port) {
port = parseInt(port, 10);
if (port > 0) {
memo.push(port);
@@ -138,7 +138,7 @@ exports.getConfig = function (platform, env, project_dir, argv) {
});
}
- if (!process.env.COUCH_URL && !argv.hasOwnProperty('custom_ports')) {
+ if (!process.env.COUCH_URL && !argv.hasOwnProperty('custom-ports')) {
cfg.couch.port = ports.getPort(cfg.id + '-couch');
}
|
fix(custom-ports): unify on `custom-ports`
* * *
This commit was sponsored by The Hoodie Firm.
You can hire The Hoodie Firm:
<URL>
|
hoodiehq_hoodie-server
|
train
|
js
|
cad54d6c31b0e79581787130c27bb90d50e95263
|
diff --git a/src/amo-client.js b/src/amo-client.js
index <HASH>..<HASH> 100644
--- a/src/amo-client.js
+++ b/src/amo-client.js
@@ -571,6 +571,9 @@ export class PseudoProgress {
finish() {
this.clearInterval(this.interval);
this.fillBucket();
+ // The bucket has already filled to the terminal width at this point
+ // but for copy/paste purposes, add a new line:
+ this.stdout.write("\n");
}
randomlyFillBucket() {
|
fix: Added missing new line after download progress bar
|
mozilla_sign-addon
|
train
|
js
|
e769781ac489dfd408c2f872b2d60603451fc677
|
diff --git a/advanced_filters/__init__.py b/advanced_filters/__init__.py
index <HASH>..<HASH> 100644
--- a/advanced_filters/__init__.py
+++ b/advanced_filters/__init__.py
@@ -1 +1 @@
-__version__ = '1.0.7.1'
+__version__ = '1.1.0'
|
chore: bump to next minor release <I>
Since we're breaking backward compatiblity, by dropping Python <I>
|
modlinltd_django-advanced-filters
|
train
|
py
|
41a604025ad1ea23c556baa3943b6b6db4108d9e
|
diff --git a/tornado/test/process_test.py b/tornado/test/process_test.py
index <HASH>..<HASH> 100644
--- a/tornado/test/process_test.py
+++ b/tornado/test/process_test.py
@@ -235,7 +235,7 @@ class SubprocessTest(AsyncTestCase):
os.kill(subproc.pid, signal.SIGTERM)
try:
- ret = self.wait(timeout=1.0)
+ ret = self.wait()
except AssertionError:
# We failed to get the termination signal. This test is
# occasionally flaky on pypy, so try to get a little more
@@ -246,7 +246,7 @@ class SubprocessTest(AsyncTestCase):
fut = subproc.stdout.read_until_close()
fut.add_done_callback(lambda f: self.stop()) # type: ignore
try:
- self.wait(timeout=1.0)
+ self.wait()
except AssertionError:
raise AssertionError("subprocess failed to terminate")
else:
|
test: Use default timeouts in sigchild test
The 1s timeout used here has become flaky with the introduction of a
sleep (before the timeout even starts).
|
tornadoweb_tornado
|
train
|
py
|
9a10f16f70238844e582d2978c4ad4bb16b7508b
|
diff --git a/packages/upload-core/upload.js b/packages/upload-core/upload.js
index <HASH>..<HASH> 100644
--- a/packages/upload-core/upload.js
+++ b/packages/upload-core/upload.js
@@ -49,6 +49,8 @@ class Upload {
'X-XSRF-TOKEN': this.getToken(),
'X-Availity-Customer-ID': this.options.customerId,
'X-Client-ID': this.options.clientId,
+ 'Availity-Filename': file.name,
+ 'Availity-Content-Type': file.type,
},
onError: err => {
this.error = err;
|
fix(upload-core): add additional headers
|
Availity_sdk-js
|
train
|
js
|
a52bdb5c8e3e3a9e7e37807f454c97d389b063f8
|
diff --git a/site/src/_layout.js b/site/src/_layout.js
index <HASH>..<HASH> 100644
--- a/site/src/_layout.js
+++ b/site/src/_layout.js
@@ -260,7 +260,7 @@ const Hits = ({ searchResults }) => {
},
},
}
- const slug = highlightedHit.url.replace(/https:\/\/cli.netlify.com/, '')
+ const slug = highlightedHit.url.replace('https://cli.netlify.com', '')
return (
<HitsOverlay key={index}>
<a href={slug}>
|
chore(site): fix wrong regex (#<I>)
|
netlify_cli
|
train
|
js
|
0beb9f70407bed715e67dc28eaf6e6eb3c3263e1
|
diff --git a/pkg/chartutil/create.go b/pkg/chartutil/create.go
index <HASH>..<HASH> 100644
--- a/pkg/chartutil/create.go
+++ b/pkg/chartutil/create.go
@@ -304,7 +304,7 @@ kind: ServiceAccount
metadata:
name: {{ include "<CHARTNAME>.serviceAccountName" . }}
labels:
-{{ include "<CHARTNAME>.labels" . | nindent 4 }}
+ {{- include "<CHARTNAME>.labels" . | nindent 4 }}
{{- with .Values.serviceAccount.annotations }}
annotations:
{{- toYaml . | nindent 4 }}
@@ -405,7 +405,7 @@ kind: Pod
metadata:
name: "{{ include "<CHARTNAME>.fullname" . }}-test-connection"
labels:
-{{ include "<CHARTNAME>.labels" . | nindent 4 }}
+ {{- include "<CHARTNAME>.labels" . | nindent 4 }}
annotations:
"helm.sh/hook": test-success
spec:
@@ -413,7 +413,7 @@ spec:
- name: wget
image: busybox
command: ['wget']
- args: ['{{ include "<CHARTNAME>.fullname" . }}:{{ .Values.service.port }}']
+ args: ['{{ include "<CHARTNAME>.fullname" . }}:{{ .Values.service.port }}']
restartPolicy: Never
`
|
fix(chartutil): remove empty lines and a space from rendered chart templates (#<I>)
|
helm_helm
|
train
|
go
|
1587b3a35164ecec06cb1b784e11277eb68d0e62
|
diff --git a/alot/db/utils.py b/alot/db/utils.py
index <HASH>..<HASH> 100644
--- a/alot/db/utils.py
+++ b/alot/db/utils.py
@@ -132,8 +132,12 @@ def decode_header(header, normalize=False):
except UnicodeEncodeError:
return value
+ # some mailers send out incorrectly escaped headers
+ # and double quote the escaped realname part again. remove those
+ value = re.sub(r'\"(.*?=\?.*?.*?)\"', r'\1', value)
+
# otherwise we interpret RFC2822 encoding escape sequences
- valuelist = email.header.decode_header(header)
+ valuelist = email.header.decode_header(value)
decoded_list = []
for v, enc in valuelist:
v = string_decode(v, enc)
|
fix: be more relaxed wrt non-rfc-compliant headers
this makes db.utils.decode_header remove superflous double quotes around header values before
decoding them
|
pazz_alot
|
train
|
py
|
3d21ee60f42f4423fbdad1f2667d9f4b812449da
|
diff --git a/src/Karma/Hydrator.php b/src/Karma/Hydrator.php
index <HASH>..<HASH> 100644
--- a/src/Karma/Hydrator.php
+++ b/src/Karma/Hydrator.php
@@ -102,20 +102,20 @@ class Hydrator implements ConfigurableProcessor
public function hydrate($environment)
{
- $distFiles = $this->collectDistFiles();
+ $files = $this->collectFiles();
- foreach($distFiles as $file)
+ foreach($files as $file)
{
$this->hydrateFile($file, $environment);
}
$this->info(sprintf(
'%d files generated',
- count($distFiles)
+ count($files)
));
}
- private function collectDistFiles()
+ private function collectFiles()
{
$pattern = sprintf('.*\%s$', $this->suffix);
if($this->nonDistFilesOverwriteAllowed === true)
@@ -390,9 +390,9 @@ class Hydrator implements ConfigurableProcessor
public function rollback()
{
- $distFiles = $this->collectDistFiles();
+ $files = $this->collectFiles();
- foreach($distFiles as $file)
+ foreach($files as $file)
{
$this->rollbackFile($file);
}
|
refactor: change name of collection file method (not only dist are loaded)
|
Niktux_karma
|
train
|
php
|
ea596f2e0abaa72c195440a9757b8213eaa8f70d
|
diff --git a/CHANGES.rst b/CHANGES.rst
index <HASH>..<HASH> 100644
--- a/CHANGES.rst
+++ b/CHANGES.rst
@@ -25,6 +25,8 @@ Removed
Fixed
-----
+- :kbd:`^c` not able to terminate initialization process due to the handler
+ registered.
Known issue
-----------
diff --git a/ehforwarderbot/__main__.py b/ehforwarderbot/__main__.py
index <HASH>..<HASH> 100644
--- a/ehforwarderbot/__main__.py
+++ b/ehforwarderbot/__main__.py
@@ -332,11 +332,14 @@ def main():
setup_logging(args, conf)
setup_telemetry(conf['telemetry'])
+ init(conf)
+
+ # Only register graceful stop signals when we are ready to start
+ # polling threads.
atexit.register(stop_gracefully)
signal.signal(signal.SIGTERM, stop_gracefully)
signal.signal(signal.SIGINT, stop_gracefully)
- init(conf)
poll()
diff --git a/ehforwarderbot/__version__.py b/ehforwarderbot/__version__.py
index <HASH>..<HASH> 100644
--- a/ehforwarderbot/__version__.py
+++ b/ehforwarderbot/__version__.py
@@ -1,3 +1,3 @@
# coding=utf-8
-__version__ = "2.1.0"
+__version__ = "2.1.1.dev1"
|
fix: ^c not able to stop the init process (#<I>)
|
blueset_ehForwarderBot
|
train
|
rst,py,py
|
41b733ce4f4567e826cdcdb0ebeae0630e200e2f
|
diff --git a/lib/config/definitions.js b/lib/config/definitions.js
index <HASH>..<HASH> 100644
--- a/lib/config/definitions.js
+++ b/lib/config/definitions.js
@@ -555,15 +555,13 @@ const options = [
stage: 'package',
type: 'json',
default: {
- force: {
- unpublishSafe: false,
- recreateClosed: true,
- rebaseStalePrs: true,
- groupName: 'Pin Dependencies',
- commitMessageAction: 'Pin',
- group: {
- commitMessageTopic: 'dependencies',
- },
+ unpublishSafe: false,
+ recreateClosed: true,
+ rebaseStalePrs: true,
+ groupName: 'Pin Dependencies',
+ commitMessageAction: 'Pin',
+ group: {
+ commitMessageTopic: 'dependencies',
},
},
cli: false,
|
fix: Revert "fix: force pin dependencies config"
This reverts commit <I>bdf6bb3dcdb<I>dd<I>a0a<I>f2d<I>a<I>a2.
|
renovatebot_renovate
|
train
|
js
|
afcc765f597b09b085a2c6f73e2b05d65ba09b4e
|
diff --git a/src/index.js b/src/index.js
index <HASH>..<HASH> 100644
--- a/src/index.js
+++ b/src/index.js
@@ -53,9 +53,7 @@ module.exports = class WebappWebpackPlugin {
if (this.options.inject) {
// Hook into the html-webpack-plugin processing and add the html
tap(compilation, 'html-webpack-plugin-before-html-processing', 'WebappWebpackPlugin', (htmlPluginData, callback) => {
- if (htmlPluginData.plugin.options.favicons !== false) {
- htmlPluginData.html = htmlPluginData.html.replace(/(<\/head>)/i, result + '$&');
- }
+ htmlPluginData.html = htmlPluginData.html.replace(/(<\/head>)/i, result + '$&');
return callback(null, htmlPluginData);
});
}
|
fix: do not rely on html-webpack-plugin's internals
|
brunocodutra_webapp-webpack-plugin
|
train
|
js
|
b4c62e6e3af1f7bc79d9b4509603a2c6d96b72e1
|
diff --git a/packages/tabs/src/Tab.js b/packages/tabs/src/Tab.js
index <HASH>..<HASH> 100644
--- a/packages/tabs/src/Tab.js
+++ b/packages/tabs/src/Tab.js
@@ -98,7 +98,7 @@ Tab.propTypes = {
/**
* Sets the label of a tab
*/
- label: PropTypes.string,
+ label: PropTypes.node,
/**
* Function to modify the component's styles
*/
diff --git a/packages/tabs/src/presenters/TabPresenter.js b/packages/tabs/src/presenters/TabPresenter.js
index <HASH>..<HASH> 100644
--- a/packages/tabs/src/presenters/TabPresenter.js
+++ b/packages/tabs/src/presenters/TabPresenter.js
@@ -142,7 +142,7 @@ export default function TabPresenter({
TabPresenter.propTypes = {
active: PropTypes.bool,
- label: PropTypes.string,
+ label: PropTypes.node,
icon: PropTypes.node,
disabled: PropTypes.bool,
closable: PropTypes.bool,
|
feat: Tab label to accept a node
|
Autodesk_hig
|
train
|
js,js
|
4808ea90dfe9722a58986f8ec583e77384bff0fb
|
diff --git a/client/deis.py b/client/deis.py
index <HASH>..<HASH> 100755
--- a/client/deis.py
+++ b/client/deis.py
@@ -600,7 +600,9 @@ class DeisClient(object):
Usage: deis apps:run <command>...
"""
- app = self._session.app
+ app = args.get('--app')
+ if not app:
+ app = self._session.app
body = {'command': ' '.join(sys.argv[2:])}
response = self._dispatch('post',
"/api/apps/{}/run".format(app),
|
feat(client): add --app option to apps:run
All of the other apps commands have a --app option. This commit
introduces that option to the apps:run command as well.
fixes #<I>
|
deis_deis
|
train
|
py
|
93e083da4fd8a936d534abb6d16e42f37837da4d
|
diff --git a/src/client/actions/GuildMemberRemove.js b/src/client/actions/GuildMemberRemove.js
index <HASH>..<HASH> 100644
--- a/src/client/actions/GuildMemberRemove.js
+++ b/src/client/actions/GuildMemberRemove.js
@@ -8,8 +8,8 @@ class GuildMemberRemoveAction extends Action {
let member = null;
if (guild) {
member = guild.members.get(data.user.id);
+ guild.memberCount--;
if (member) {
- guild.memberCount--;
guild.members.remove(member.id);
if (client.status === Status.READY) client.emit(Events.GUILD_MEMBER_REMOVE, member);
}
diff --git a/src/structures/GuildMember.js b/src/structures/GuildMember.js
index <HASH>..<HASH> 100644
--- a/src/structures/GuildMember.js
+++ b/src/structures/GuildMember.js
@@ -526,12 +526,7 @@ class GuildMember extends Base {
*/
kick(reason) {
return this.client.api.guilds(this.guild.id).members(this.user.id).delete({ reason })
- .then(() =>
- this.client.actions.GuildMemberRemove.handle({
- guild_id: this.guild.id,
- user: this.user,
- }).member
- );
+ .then(() => this);
}
/**
|
fix(Guild): memberCount not decrementing when an uncached member leaves
This leads to GuildMemberStore#_fetchMany to always reject
because it expects more member than possible.
Also no longer call the GuildMemberRemove handler locally
to not decrement twice.
|
discordjs_discord.js
|
train
|
js,js
|
ddf5980574c56859f7159e04fe2e8587e8740c80
|
diff --git a/tests/Stubs/AuditableModelStub.php b/tests/Stubs/AuditableModelStub.php
index <HASH>..<HASH> 100644
--- a/tests/Stubs/AuditableModelStub.php
+++ b/tests/Stubs/AuditableModelStub.php
@@ -13,6 +13,13 @@ class AuditableModelStub extends Model implements AuditableContract
/**
* {@inheritdoc}
*/
+ protected $casts = [
+ 'published' => 'bool',
+ ];
+
+ /**
+ * {@inheritdoc}
+ */
public function resolveIpAddress()
{
return '127.0.0.1';
@@ -41,4 +48,16 @@ class AuditableModelStub extends Model implements AuditableContract
{
$this->auditThreshold = $threshold;
}
+
+ /**
+ * Uppercase Title accessor.
+ *
+ * @param string $value
+ *
+ * @return string
+ */
+ public function getTitleAttribute($value)
+ {
+ return strtoupper($value);
+ }
}
|
feat(AuditableModelStub): implement cast and accessor
|
owen-it_laravel-auditing
|
train
|
php
|
6dd21530dcd0837d651b999685546c93af4aecb8
|
diff --git a/site/bisheng.config.js b/site/bisheng.config.js
index <HASH>..<HASH> 100644
--- a/site/bisheng.config.js
+++ b/site/bisheng.config.js
@@ -40,21 +40,13 @@ module.exports = {
'create-react-class': 'preact-compat/lib/create-react-class',
'react-router': 'react-router',
});
- } else if (isDev) {
+ } else {
config.externals = Object.assign({}, config.externals, {
react: 'React',
'react-dom': 'ReactDOM',
});
}
- // config.babel.plugins.push([
- // require.resolve('babel-plugin-transform-runtime'),
- // {
- // polyfill: false,
- // regenerator: true,
- // },
- // ]);
-
config.plugins.push(new CSSSplitWebpackPlugin({ size: 4000 }));
return config;
|
docs: always use externals
|
avetjs_avet
|
train
|
js
|
12881131ed2e63e84ed819a00c1d8b248f552024
|
diff --git a/packages/vaex-server/vaex/server/tornado_server.py b/packages/vaex-server/vaex/server/tornado_server.py
index <HASH>..<HASH> 100644
--- a/packages/vaex-server/vaex/server/tornado_server.py
+++ b/packages/vaex-server/vaex/server/tornado_server.py
@@ -167,7 +167,7 @@ GB = MB * 1024
class WebServer(threading.Thread):
- def __init__(self, address="localhost", port=9000, webserver_thread_count=2, cache_byte_size=500 * MB,
+ def __init__(self, address="127.0.0.1", port=9000, webserver_thread_count=2, cache_byte_size=500 * MB,
token=None, token_trusted=None, base_url=None,
cache_selection_byte_size=500 * MB, datasets=[], compress=True, development=False, threads_per_job=4):
threading.Thread.__init__(self)
|
fix(server): docker does not like localhost, <I> seems to work
|
vaexio_vaex
|
train
|
py
|
68e74c9b82ab3763a5496cde0b645a21b61ec1c0
|
diff --git a/src/TypesGenerator.php b/src/TypesGenerator.php
index <HASH>..<HASH> 100644
--- a/src/TypesGenerator.php
+++ b/src/TypesGenerator.php
@@ -296,7 +296,7 @@ class TypesGenerator
// Second pass
foreach ($classes as &$class) {
- if ($class['parent'] && $class['parent'] !== 'Enum') {
+ if ($class['parent'] && 'Enum' !== $class['parent']) {
if (isset($classes[$class['parent']])) {
$classes[$class['parent']]['hasChild'] = true;
$class['parentHasConstructor'] = $classes[$class['parent']]['hasConstructor'];
|
chore: fix CS (#<I>)
|
api-platform_schema-generator
|
train
|
php
|
3fb1d356184d0ba0058627dfa5209934ae39330b
|
diff --git a/src/Keboola/Syrup/Service/StorageApi/StorageApiService.php b/src/Keboola/Syrup/Service/StorageApi/StorageApiService.php
index <HASH>..<HASH> 100644
--- a/src/Keboola/Syrup/Service/StorageApi/StorageApiService.php
+++ b/src/Keboola/Syrup/Service/StorageApi/StorageApiService.php
@@ -87,7 +87,7 @@ class StorageApiService
'token' => $request->headers->get('X-StorageApi-Token'),
'url' => $this->storageApiUrl,
'userAgent' => explode('/', $request->getPathInfo())[1],
- 'jobPollRetryDelay' => createSimpleJobPollDelay($this->getBackoffTries(gethostname()))
+ 'backoffMaxTries' => $this->getBackoffTries(gethostname())
]
)
);
|
fix(StorageApiService): missing backoffMaxTries
|
keboola_syrup
|
train
|
php
|
4536302a69a889e192df1c8de9369737689ab7fb
|
diff --git a/vyper/parser/function_definitions/parse_function.py b/vyper/parser/function_definitions/parse_function.py
index <HASH>..<HASH> 100644
--- a/vyper/parser/function_definitions/parse_function.py
+++ b/vyper/parser/function_definitions/parse_function.py
@@ -1,4 +1,6 @@
-from vyper.parser.context import Constancy, Context
+# can't use from [module] import [object] because it breaks mocks in testing
+from vyper.parser import context as ctx
+from vyper.parser.context import Constancy
from vyper.parser.function_definitions.parse_external_function import ( # NOTE black/isort conflict
parse_external_function,
)
@@ -37,7 +39,7 @@ def parse_function(code, sigs, origcode, global_ctx, is_contract_payable, _vars=
# Create a local (per function) context.
memory_allocator = MemoryAllocator()
- context = Context(
+ context = ctx.Context(
vars=_vars,
global_ctx=global_ctx,
sigs=sigs,
|
test: adjust import style to allow mocking
|
ethereum_vyper
|
train
|
py
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.