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
82b940ae064dd14e000a1cd3434b2245fffb5355
diff --git a/http/write_handler.go b/http/write_handler.go index <HASH>..<HASH> 100644 --- a/http/write_handler.go +++ b/http/write_handler.go @@ -175,7 +175,10 @@ func (h *WriteHandler) handleWrite(w http.ResponseWriter, r *http.Request) { sw := kithttp.NewStatusResponseWriter(w) recorder := NewWriteUsageRecorder(sw, h.EventRecorder) var requestBytes int - defer recorder.Record(ctx, requestBytes, org.ID, r.URL.Path) + defer func() { + // Close around the requestBytes variable to placate the linter. + recorder.Record(ctx, requestBytes, org.ID, r.URL.Path) + }() bucket, err := h.findBucket(ctx, org.ID, req.Bucket) if err != nil { @@ -303,7 +306,7 @@ func (pw *PointsParser) parsePoints(ctx context.Context, orgID, bucketID influxd } } - span, ctx := tracing.StartSpanFromContextWithOperationName(ctx, "encoding and parsing") + span, _ := tracing.StartSpanFromContextWithOperationName(ctx, "encoding and parsing") encoded := tsdb.EncodeName(orgID, bucketID) mm := models.EscapeMeasurement(encoded[:])
fix(http): Placate the linter.
influxdata_influxdb
train
go
06a2d085bd8a51d55a6657ff52210e2570ac4981
diff --git a/intranet/settings/__init__.py b/intranet/settings/__init__.py index <HASH>..<HASH> 100644 --- a/intranet/settings/__init__.py +++ b/intranet/settings/__init__.py @@ -634,12 +634,6 @@ if SHOW_DEBUG_TOOLBAR: INSTALLED_APPS += ["debug_toolbar"] -# Maintenance mode -# This should be adjusted in secrets.py or by running: -# ./manage.py maintenance [on|off] -if MAINTENANCE_MODE is None: - MAINTENANCE_MODE = False - MAINTENANCE_MODE_TEMPLATE = "error/503.html" MAINTENANCE_MODE_IGNORE_SUPERUSER = True
chore: allow dynamic configuration of maintenance mode
tjcsl_ion
train
py
8b4f98cefa34565bb07ad81d72aacda2a1871315
diff --git a/sum_test.go b/sum_test.go index <HASH>..<HASH> 100644 --- a/sum_test.go +++ b/sum_test.go @@ -144,8 +144,8 @@ func TestSmallerLengthHashID(t *testing.T) { for l := (dataLength - 1); l >= 0; l-- { _, err = multihash.Sum(data, multihash.ID, l) if err == nil { - t.Fatal(fmt.Sprintf("identity hash of length %d smaller than data length %d didn't fail", - l, dataLength)) + t.Fatalf("identity hash of length %d smaller than data length %d didn't fail", + l, dataLength) } } }
fix: Unnecessarily complex way of printing formatted string
multiformats_go-multihash
train
go
34c484408f80562fd592a4954a29ee6fce6e2a47
diff --git a/src/handshake/finish.js b/src/handshake/finish.js index <HASH>..<HASH> 100644 --- a/src/handshake/finish.js +++ b/src/handshake/finish.js @@ -10,6 +10,10 @@ const lp = require('it-length-prefixed') const Wrap = require('it-pb-rpc') const { int32BEEncode, int32BEDecode } = lp +// Maximum length of the data section of the message +// 8MB, https://github.com/libp2p/specs/blob/94ad1bd/secio/README.md#message-framing +const MAX_DATA_LENGTH = 0x800000 + const etm = require('../etm') const crypto = require('./crypto') @@ -28,10 +32,12 @@ module.exports = async function finish (state, wrapped) { etm.createBoxStream(proto.local.cipher, proto.local.mac), lp.encode({ lengthEncoder: int32BEEncode }), network, // and gets piped INTO and FROM the network - lp.decode({ lengthDecoder: int32BEDecode }), + lp.decode({ lengthDecoder: int32BEDecode, maxDataLength: MAX_DATA_LENGTH }), etm.createUnboxStream(proto.remote.cipher, proto.remote.mac), secure // and gets piped TO the user - ) + ).catch(err => { + log.error('an error occurred in the crypto stream', err) + }) // Exchange nonces over the encrypted stream for final verification const shake = Wrap(user)
fix: comply with message framing spec (#<I>) fix: catch async pipe errors
libp2p_js-libp2p-secio
train
js
eef9679e3d8cde1febb03ff021da25ea552a58f2
diff --git a/index.js b/index.js index <HASH>..<HASH> 100644 --- a/index.js +++ b/index.js @@ -217,3 +217,12 @@ function bind(method) { return quest[method](this.request('GET', ...arguments)) } } + +Object.assign(http.ClientRequest.prototype, { + then(next, onError) { + return this.end().then(done, onError) + }, + catch(onError) { + return this.end().catch(onError) + } +})
feat: add `then` and `catch` methods to http.ClientRequest
aleclarson_quest
train
js
48f706b0f3c90c776506f6e2e1240f79a051b9da
diff --git a/mfs/dir.go b/mfs/dir.go index <HASH>..<HASH> 100644 --- a/mfs/dir.go +++ b/mfs/dir.go @@ -404,8 +404,15 @@ func (d *Directory) Path() string { cur := d var out string for cur != nil { - out = path.Join(cur.name, out) - cur = cur.parent.(*Directory) + switch parent := cur.parent.(type) { + case *Directory: + out = path.Join(cur.name, out) + cur = parent + case *Root: + return "/" + out + default: + panic("directory parent neither a directory nor a root") + } } return out } diff --git a/mfs/mfs_test.go b/mfs/mfs_test.go index <HASH>..<HASH> 100644 --- a/mfs/mfs_test.go +++ b/mfs/mfs_test.go @@ -324,6 +324,11 @@ func TestDirectoryLoadFromDag(t *testing.T) { topd := topi.(*Directory) + path := topd.Path() + if path != "/foo" { + t.Fatalf("Expected path '/foo', got '%s'", path) + } + // mkdir over existing but unloaded child file should fail _, err = topd.Mkdir("a") if err == nil {
fix(mfs): Directory.Path not working, add test Credit goes to @ridewindx License: MIT
ipfs_go-ipfs
train
go,go
2e0fecd06e9c901d370d54542e1aa6dc7b183403
diff --git a/lib/cmd/test.js b/lib/cmd/test.js index <HASH>..<HASH> 100644 --- a/lib/cmd/test.js +++ b/lib/cmd/test.js @@ -116,7 +116,9 @@ class TestCommand extends Command { // for power-assert if (testArgv.typescript && testArgv.espower) { - requireArr.splice(requireArr.indexOf(testArgv.tscompiler), 1); + if (requireArr.includes(testArgv.tscompiler)) { + requireArr.splice(requireArr.indexOf(testArgv.tscompiler), 1); + } requireArr.push(testArgv.tscompiler, require.resolve('../espower-typescript')); }
fix: fix espwoer-typescript inject logic (#<I>)
eggjs_egg-bin
train
js
b19cb041b6e3bb6f375dab34294ead9f4f82184b
diff --git a/src/Tabs.js b/src/Tabs.js index <HASH>..<HASH> 100644 --- a/src/Tabs.js +++ b/src/Tabs.js @@ -2,6 +2,7 @@ import React from 'react'; import PropTypes from 'prop-types'; import requiredForA11y from 'prop-types-extra/lib/isRequiredForA11y'; import uncontrollable from 'uncontrollable'; +import elementType from 'prop-types-extra/lib/elementType'; import Nav from './Nav'; import NavItem from './NavItem'; @@ -25,7 +26,12 @@ const propTypes = { */ bsStyle: PropTypes.oneOf(['tabs', 'pills']), - animation: PropTypes.bool, + /** + * Sets a default animation strategy. Use `false` to disable, `true` + * to enable the default `<Fade>` animation, or a react-transition-group + * v2 `<Transition/>` component. + */ + animation: PropTypes.oneOfType([PropTypes.bool, elementType]), id: requiredForA11y( PropTypes.oneOfType([PropTypes.string, PropTypes.number])
fix: tab animation propType to allow custom tab animation (#<I>)
react-bootstrap_react-bootstrap
train
js
f0f2bbf8940356f7a939c10441d9f3bb629e090a
diff --git a/cmd/helm/fetch.go b/cmd/helm/fetch.go index <HASH>..<HASH> 100644 --- a/cmd/helm/fetch.go +++ b/cmd/helm/fetch.go @@ -6,6 +6,7 @@ import ( "net/http" "net/url" "os" + "path/filepath" "strings" "github.com/spf13/cobra" @@ -34,13 +35,18 @@ func fetch(cmd *cobra.Command, args []string) error { return fmt.Errorf("This command needs at least one argument, url or repo/name of the chart.") } + pname := args[0] + if filepath.Ext(pname) != ".tgz" { + pname += ".tgz" + } + f, err := repo.LoadRepositoriesFile(repositoriesFile()) if err != nil { return err } // get download url - u, err := mapRepoArg(args[0], f.Repositories) + u, err := mapRepoArg(pname, f.Repositories) if err != nil { return err }
fix(helm): add .tgz to package names on fetch Closes #<I>
helm_helm
train
go
a61c8712e57e85e4845702516e06ca1b55310617
diff --git a/model/DeliveryAssemblyService.php b/model/DeliveryAssemblyService.php index <HASH>..<HASH> 100755 --- a/model/DeliveryAssemblyService.php +++ b/model/DeliveryAssemblyService.php @@ -15,7 +15,7 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. * - * Copyright (c) 2021 (original work) Open Assessment Technologies SA (under the project TAO-PRODUCT); + * Copyright (c) 2016 (original work) Open Assessment Technologies SA (under the project TAO-PRODUCT); * */
chore: Revert copyright year to <I> in DeliveryAssemblyService.php
oat-sa_extension-tao-delivery-rdf
train
php
42cda579bc04ed845fa8828844107de14d19304c
diff --git a/code/extensions/CDNFile.php b/code/extensions/CDNFile.php index <HASH>..<HASH> 100644 --- a/code/extensions/CDNFile.php +++ b/code/extensions/CDNFile.php @@ -225,6 +225,9 @@ class CDNFile extends DataExtension { } public function localFileExists() { + if (!$this->owner->getField('Filename')) { + return false; + } $path = $this->owner->getFullPath(); if (!file_exists($path) || filesize($path) == 0) { return false;
fix(CDNFile): Don't do file_exists check on 'getFullPath' if 'Filename' isn't set. (Avoids 'assets/' directory returning as an existing file)
symbiote_silverstripe-cdncontent
train
php
543e5ba8cddf825904965a0f85af1a24bd0b08c7
diff --git a/src/Form/Field/HasMany.php b/src/Form/Field/HasMany.php index <HASH>..<HASH> 100644 --- a/src/Form/Field/HasMany.php +++ b/src/Form/Field/HasMany.php @@ -111,6 +111,13 @@ class HasMany extends Field $input = Arr::only($input, $this->column); + /** unset item that contains remove flag */ + foreach ($input[$this->column] as $key => $value) { + if ($value[NestedForm::REMOVE_FLAG_NAME]) { + unset($input[$this->column][$key]); + } + } + $form = $this->buildNestedForm($this->column, $this->builder); $rules = $attributes = []; @@ -490,7 +497,7 @@ $('#has-many-{$this->column}').off('click', '.add').on('click', '.add', function }); $('#has-many-{$this->column}').off('click', '.remove').on('click', '.remove', function () { - $(this).closest('.has-many-{$this->column}-form').remove(); + $(this).closest('.has-many-{$this->column}-form').hide(); $(this).closest('.has-many-{$this->column}-form').find('.$removeClass').val(1); return false; });
fix: validate unset item that contains remove flag
z-song_laravel-admin
train
php
b6d6e1830d70a8576d5c34a2571cd067ccdc1835
diff --git a/api/src/opentrons/util/logging_config.py b/api/src/opentrons/util/logging_config.py index <HASH>..<HASH> 100644 --- a/api/src/opentrons/util/logging_config.py +++ b/api/src/opentrons/util/logging_config.py @@ -11,6 +11,7 @@ def _balena_config(level_value: int) -> Dict[str, Any]: api_log_filename = CONFIG['api_log_file'] return { 'version': 1, + 'disable_existing_loggers': False, 'formatters': { 'basic': { 'format': @@ -68,6 +69,7 @@ def _buildroot_config(level_value: int) -> Dict[str, Any]: # either return { 'version': 1, + 'disable_existing_loggers': False, 'formatters': { 'message_only': { 'format': '%(message)s'
fix(api): don't stomp other loggers in log config (#<I>) A recent robot-server PR deferred API loading until after the server is up, which is a great change but means that the API-side logging configuration now stomps on the robot server's logging configuration, so robot server messages are not logged. This commit removes the stomping and the robot server's logs should now be visible again.
Opentrons_opentrons
train
py
942e59953c65a58cca5a8b20d4b089f01f9f57f8
diff --git a/modules/fuse-box-responsive-api/index.js b/modules/fuse-box-responsive-api/index.js index <HASH>..<HASH> 100644 --- a/modules/fuse-box-responsive-api/index.js +++ b/modules/fuse-box-responsive-api/index.js @@ -235,7 +235,17 @@ /* @if codeSplitting */ if (bMapping.i && bMapping.i[id]) { var data = bMapping.i[id]; - req(bMapping.c.b + data[0], function(err, result) { + /* @if universal */ + var path = isBrowser ? bMapping.c.b : bMapping.c.s; + /* @end */ + /* @if server */ + var path = bMapping.c.s; + /* @end */ + + /* @if browser */ + var path = bMapping.c.b; + /* @end */ + req(path + data[0], function(err, result) { /* @if browser */ if (!err) { new Function(result)(); } @@ -328,4 +338,4 @@ /* @if !isContained */ })(); -/* @end */ \ No newline at end of file +/* @end */
fix: Fixes code splitting issue when Quantum doesn't take path resolver (#<I>) * Update index.js - use correct split config options with quantum * Update index.js - changes const to var - making short var name
fuse-box_fuse-box
train
js
d05df81c8d2a072d3f7d45e372c7a8049c24c450
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 @@ -290,7 +290,10 @@ class Upload { if (uploadResult === 'encrypted') { // needs pw, isDecrypting, isScanning - if (!this.waitForPw && decryptResult === null) { + if ( + !this.waitForPw && + (decryptResult === null || decryptResult === 'pending') + ) { return { status: 'pending', message: msg || '' }; } if (decryptResult === 'rejected') {
fix(upload-core): fix for pending decryption status
Availity_sdk-js
train
js
eff1939c8cfea645782f2c87b0cdb0f420de270d
diff --git a/alerta/utils/logging.py b/alerta/utils/logging.py index <HASH>..<HASH> 100644 --- a/alerta/utils/logging.py +++ b/alerta/utils/logging.py @@ -98,10 +98,6 @@ class Logger: } }, 'loggers': { - 'root': { - 'level': log_level, - 'handlers': app.config['LOG_HANDLERS'], - }, 'alerta': { 'level': log_level, }, @@ -120,7 +116,11 @@ class Logger: 'werkzeug': { 'level': 'WARNING', }, - } + }, + 'root': { + 'level': log_level, + 'handlers': app.config['LOG_HANDLERS'], + }, }) # from logging_tree import printout
fix: move root logger config key back to top level (#<I>)
alerta_alerta
train
py
b27abd39a8b07f751eaf405244cfe9edbea3771d
diff --git a/packages/babel-parser/src/plugins/estree.js b/packages/babel-parser/src/plugins/estree.js index <HASH>..<HASH> 100644 --- a/packages/babel-parser/src/plugins/estree.js +++ b/packages/babel-parser/src/plugins/estree.js @@ -394,6 +394,8 @@ export default (superClass: Class<Parser>): Class<Parser> => delete node.arguments; // $FlowIgnore - callee isn't optional in the type definition delete node.callee; + } else if (node.type === "CallExpression") { + (node: N.Node).optional = false; } return node; @@ -434,4 +436,14 @@ export default (superClass: Class<Parser>): Class<Parser> => return node; } + + parseSubscript(...args) { + const node = super.parseSubscript(...args); + + if (node.type === "MemberExpression") { + node.optional = false; + } + + return node; + } };
fix: add optional: false to MemberExpression (#<I>)
babel_babel
train
js
f2a9434b2608e4827bba3b58c13e57979476b862
diff --git a/packages/icon/cli/generate-components.js b/packages/icon/cli/generate-components.js index <HASH>..<HASH> 100644 --- a/packages/icon/cli/generate-components.js +++ b/packages/icon/cli/generate-components.js @@ -48,6 +48,7 @@ const exportTemplate = filePaths => filePath => `export { ${filePath.split('.')[0]} } from './${filePath}'` ) .join('\n') + .concat('\n') exports.generateComponents = async ({ src, dest, ext = 'dist.js', core }) => { try {
fix(icon): adds new line to end of generated file
pluralsight_design-system
train
js
e627f24cca182a9b763fa6f71cc2cf79d356be2a
diff --git a/handlers/apexlogs/apexlogs.go b/handlers/apexlogs/apexlogs.go index <HASH>..<HASH> 100644 --- a/handlers/apexlogs/apexlogs.go +++ b/handlers/apexlogs/apexlogs.go @@ -97,7 +97,7 @@ func (h *Handler) HandleLog(e *log.Entry) error { return nil } -// Flush any pending logs. +// Flush any pending logs. This method is non-blocking. func (h *Handler) Flush() { h.b.Flush() }
docs: mention that Flush() is non-blocking now, use Close()
apex_log
train
go
4c86d7a4f82f50ea4a43d530c890b1299be8ea36
diff --git a/blocks/blockstore/arc_cache_test.go b/blocks/blockstore/arc_cache_test.go index <HASH>..<HASH> 100644 --- a/blocks/blockstore/arc_cache_test.go +++ b/blocks/blockstore/arc_cache_test.go @@ -175,4 +175,10 @@ func TestPutManyCaches(t *testing.T) { trap("has hit datastore", cd, t) arc.Has(exampleBlock.Key()) + untrap(cd) + arc.DeleteBlock(exampleBlock.Key()) + + arc.Put(exampleBlock) + trap("PunMany has hit datastore", cd, t) + arc.PutMany([]blocks.Block{exampleBlock}) }
test: add test case for PutMany using cache to eliminate the call License: MIT
ipfs_go-ipfs
train
go
a07a880befc55c8568adac9db37bdfac89a784d5
diff --git a/models/classes/QtiResultsService.php b/models/classes/QtiResultsService.php index <HASH>..<HASH> 100644 --- a/models/classes/QtiResultsService.php +++ b/models/classes/QtiResultsService.php @@ -27,6 +27,7 @@ use common_Exception; use common_exception_InvalidArgumentType; use common_exception_NotFound; use common_exception_NotImplemented; +use common_exception_ResourceNotFound; use core_kernel_classes_Resource; use DOMDocument; use DOMElement; @@ -145,12 +146,15 @@ class QtiResultsService extends ConfigurableService implements ResultService /** Context */ $contextElt = $dom->createElementNS(self::QTI_NS, 'context'); $userId = $resultServer->getTestTaker($deId); + + if ($userId === false) { + throw new common_exception_ResourceNotFound('Provided parameters don\'t match with any delivery execution.'); + } + if (\common_Utils::isUri($userId)) { $userId = \tao_helpers_Uri::getUniqueId($userId); } - if ($userId === false) { - $userId = ''; - } + $contextElt->setAttribute('sourcedId', $userId); $assessmentResultElt->appendChild($contextElt);
fix: throw resource not found exception when test taker not found when retrieving delivery execution results
oat-sa_extension-tao-outcome
train
php
da4ef1071fefda7750e5083dbfcee264eb39fa87
diff --git a/core/component.js b/core/component.js index <HASH>..<HASH> 100644 --- a/core/component.js +++ b/core/component.js @@ -36,7 +36,7 @@ function useOnContent (contentMiddleware) { } const config = this[secret.config] if (config.isolate === true) { - throw new Error('content middlewares can not be added to isolated components') + console.log('warning: content middlewares have no effect inside isolated components') } config.contentMiddlewares = config.contentMiddlewares || [] config.contentMiddlewares.push(contentMiddleware) @@ -82,7 +82,7 @@ function attachedCallback () { const contentObserver = new MutationObserver(onMutations) contentObserver.observe(this, observerConfig) } - + if (addedNodes.size === 0) { Promise.resolve().then(processAddedNodes) }
fix(core): replace isolated contentMiddleware error with a warning
nx-js_framework
train
js
fc03a04fb98696d3f5b498ebe6659a2758e37bb7
diff --git a/src/game/structures.js b/src/game/structures.js index <HASH>..<HASH> 100644 --- a/src/game/structures.js +++ b/src/game/structures.js @@ -4,7 +4,7 @@ var utils = require('./../utils'), C = driver.constants, _ = require('lodash'); -var runtimeData, intents, register, globals, createdCreepNames; +var runtimeData, intents, register, globals, createdCreepNames, lastActivateSafeMode; function data(id) { if(!runtimeData.roomObjects[id]) { @@ -109,6 +109,7 @@ exports.make = function(_runtimeData, _intents, _register, _globals) { globals = _globals; createdCreepNames = []; + lastActivateSafeMode = null; if(globals.Structure) { return; @@ -302,6 +303,11 @@ exports.make = function(_runtimeData, _intents, _register, _globals) { return C.ERR_BUSY; } + if(lastActivateSafeMode) { + intents.remove(lastActivateSafeMode, 'activateSafeMode'); + } + lastActivateSafeMode = this.id; + intents.set(this.id, 'activateSafeMode', {}); return C.OK; });
fix(StructureController): disallow simultaneous activateSafeMode
screeps_engine
train
js
1496f25119ff879003f3fa3edef456833bed000a
diff --git a/typed-values/src/main/java/org/camunda/bpm/engine/variable/Variables.java b/typed-values/src/main/java/org/camunda/bpm/engine/variable/Variables.java index <HASH>..<HASH> 100644 --- a/typed-values/src/main/java/org/camunda/bpm/engine/variable/Variables.java +++ b/typed-values/src/main/java/org/camunda/bpm/engine/variable/Variables.java @@ -189,14 +189,14 @@ public class Variables { } /** - * Shortcut for {@code Variables.serializedObjectValue().serializedObjectValue(value)} + * Shortcut for {@code Variables.serializedObjectValue().serializedValue(value)} */ public static SerializedObjectValueBuilder serializedObjectValue(String value) { return serializedObjectValue().serializedValue(value); } /** - * Shortcut for {@code Variables.serializedObjectValue().serializedObjectValue(value).setTransient(isTransient)} + * Shortcut for {@code Variables.serializedObjectValue().serializedValue(value).setTransient(isTransient)} */ public static SerializedObjectValueBuilder serializedObjectValue(String value, boolean isTransient) { return (SerializedObjectValueBuilder) serializedObjectValue().serializedValue(value).setTransient(isTransient);
chore(javadoc): cleanup javadoc Related with CAM-<I>
camunda_camunda-commons
train
java
3da7b09264e15bc8a956acdbf0d4123fdd27a9ba
diff --git a/perms/perms.go b/perms/perms.go index <HASH>..<HASH> 100644 --- a/perms/perms.go +++ b/perms/perms.go @@ -1,3 +1,4 @@ +// Package perms provides methods for managing user app and administrative permissions. package perms import ( @@ -30,7 +31,7 @@ func List(c *deis.Client, appID string) ([]string, error) { return users.Users, nil } -// ListAdmins lists administrators. +// ListAdmins lists deis platform administrators. func ListAdmins(c *deis.Client, results int) ([]string, int, error) { body, count, err := c.LimitedRequest("/v2/admin/perms/", results) @@ -52,7 +53,7 @@ func ListAdmins(c *deis.Client, results int) ([]string, int, error) { return usersList, count, nil } -// New adds a user to an app. +// New gives a user access to an app. func New(c *deis.Client, appID string, username string) error { return doNew(c, fmt.Sprintf("/v2/apps/%s/perms/", appID), username) }
docs(perms): add godoc to perms package (#<I>)
deis_controller-sdk-go
train
go
861b6aa446ae5872036902ace7560a85a868de61
diff --git a/packages/type/examples/preview/index.js b/packages/type/examples/preview/index.js index <HASH>..<HASH> 100644 --- a/packages/type/examples/preview/index.js +++ b/packages/type/examples/preview/index.js @@ -147,7 +147,7 @@ function TypeScale() { <tbody> {CarbonType.scale.map((size, step) => ( <tr key={size}> - <td>{step}</td> + <td>{step + 1}</td> <td>{size}</td> <td className={`type-scale-${step + 1}`}> Good design is good business
fix(type): update step in preview documentation (#<I>)
carbon-design-system_carbon-elements
train
js
b5d201001c3721a7ab928703aa9fcc758c46c2bc
diff --git a/packages/webpack/loaders/import-meta-url-loader.js b/packages/webpack/loaders/import-meta-url-loader.js index <HASH>..<HASH> 100644 --- a/packages/webpack/loaders/import-meta-url-loader.js +++ b/packages/webpack/loaders/import-meta-url-loader.js @@ -4,7 +4,7 @@ const regex = /(?!\()import.meta.url(?=\))/g; /** Webpack loader to rewrite `import.meta.url` in modules to the source code file location. */ module.exports = function (source) { const relativePath = this.context.substring( - this.context.indexOf(this.rootContext) + this.rootContext.length, + this.context.indexOf(this.rootContext) + this.rootContext.length + 1, this.resource.lastIndexOf('/') + 1 );
fix(webpack): remove extra "/" in generated url in meta-url-loader
open-wc_open-wc
train
js
4d2969aad052ccbcb0a24e0d7170f53717e43eb9
diff --git a/addon/transitions/scale.js b/addon/transitions/scale.js index <HASH>..<HASH> 100644 --- a/addon/transitions/scale.js +++ b/addon/transitions/scale.js @@ -2,11 +2,11 @@ import { TransitionPromise, animate } from 'liquid-fire-tweenlite'; export default function scale(opts={}) { return new TransitionPromise({ - animateIn: function() { - return animate(this.oldElement, {scale: 0.2}, opts); - }.bind(this), animateOut: function() { - return animate(this.newElement, {scale: 1}, opts); + return animate(this.oldElement, { scale: [1, 0.2] }, opts, 'scale--out'); + }.bind(this), + animateIn: function() { + return animate(this.newElement, { scale: [0.2, 1] }, opts, 'scale--in'); }.bind(this) }); }
fix(scale-transition): corrects order of operations
runspired_liquid-fire-tweenlite
train
js
9d36af36ea58221ec69f6d265d66b1daa4200401
diff --git a/src/lib/customPropTypes.js b/src/lib/customPropTypes.js index <HASH>..<HASH> 100644 --- a/src/lib/customPropTypes.js +++ b/src/lib/customPropTypes.js @@ -8,7 +8,7 @@ const typeOf = (...args) => Object.prototype.toString.call(...args) * Ensure a component can render as a give prop value. */ export const as = (...args) => - PropTypes.oneOfType([PropTypes.func, PropTypes.string, PropTypes.symbol])(...args) + PropTypes.oneOfType([PropTypes.func, PropTypes.object, PropTypes.string, PropTypes.symbol])(...args) /** * Ensure a prop is a valid DOM node.
fix(customPropTypes): allow to pass an object to "as" (#<I>) * Allows having JSX elements as an "as" property See #<I> for the problem described. Solves problem when custom links are used * update order
Semantic-Org_Semantic-UI-React
train
js
a737eff06d0605e34601dee7d3a4e6ba80cbcde4
diff --git a/docs/app/Components/ComponentDoc/ComponentExample/ComponentExample.js b/docs/app/Components/ComponentDoc/ComponentExample/ComponentExample.js index <HASH>..<HASH> 100644 --- a/docs/app/Components/ComponentDoc/ComponentExample/ComponentExample.js +++ b/docs/app/Components/ComponentDoc/ComponentExample/ComponentExample.js @@ -200,7 +200,7 @@ class ComponentExample extends Component { // which can be rendered in this ComponentExample's render() method // rewrite imports to const statements against the UPPERCASE module names - const imports = _.get(/(^import[\s\S]*from[\s\S]*['"]\n)/.exec(sourceCode), '[1]', '') + const imports = _.get(/(^[\s\S])*import[\s\S]*from[\s\S]*['"]\n/.exec(sourceCode), '[0]', '') .replace(/[\s\n]+/g, ' ') // normalize spaces and make one line .replace(/ import/g, '\nimport') // one import per line .split('\n') // split lines
fix(docs): fix import regex (#<I>) (#<I>)
Semantic-Org_Semantic-UI-React
train
js
790ccca695233e80f2720e3d4b2b67d2736b39fd
diff --git a/src/components/autocomplete/js/autocompleteController.js b/src/components/autocomplete/js/autocompleteController.js index <HASH>..<HASH> 100644 --- a/src/components/autocomplete/js/autocompleteController.js +++ b/src/components/autocomplete/js/autocompleteController.js @@ -6,7 +6,7 @@ var ITEM_HEIGHT = 41, MAX_HEIGHT = 5.5 * ITEM_HEIGHT, MENU_PADDING = 8; -function MdAutocompleteCtrl ($scope, $element, $mdUtil, $mdConstant, $timeout, $mdTheming, $window, $rootElement) { +function MdAutocompleteCtrl ($scope, $element, $mdUtil, $mdConstant, $timeout, $mdTheming, $window, $animate, $rootElement) { //-- private variables @@ -104,6 +104,7 @@ function MdAutocompleteCtrl ($scope, $element, $mdUtil, $mdConstant, $timeout, $ $mdTheming(elements.$.ul); elements.$.ul.detach(); elements.$.root.append(elements.$.ul); + if ($animate.pin) $animate.pin(elements.$.ul, $rootElement); } function focusElement () {
fix(autocomplete): adds support for the new `$animate.pin()` in `ng-animate@<I>-rc<I>`
angular_material
train
js
720081843f898a055167684030594252a9fb97dc
diff --git a/nightwatch.js b/nightwatch.js index <HASH>..<HASH> 100644 --- a/nightwatch.js +++ b/nightwatch.js @@ -14,17 +14,17 @@ srcFolders = srcFolders.map(function(folder) { process.env.NOW_URL = process.env.NOW_URL || 'https://boltdesignsystem.com'; module.exports = { - selenium: { - start_process: true, - server_path: require('selenium-server').path, - log_path: './reports', - host: '127.0.0.1', - port: 4444, - cli_args: { - 'webdriver.chrome.driver': './node_modules/chromedriver/bin/chromedriver', - }, - }, - test_workers: { enabled: true, workers: 'auto' }, + // selenium: { + // start_process: true, + // server_path: require('selenium-server').path, + // log_path: './reports', + // host: '127.0.0.1', + // port: 4444, + // cli_args: { + // 'webdriver.chrome.driver': './node_modules/chromedriver/bin/chromedriver', + // }, + // }, + // test_workers: { enabled: true, workers: 'auto' }, test_settings: { local: { screenshots: {
chore: disable selenium server in nightwatch
bolt-design-system_bolt
train
js
ab74f403070c1d9134c6de10c2c5456ebf6514dd
diff --git a/test/mp/runtime/directives/on.spec.js b/test/mp/runtime/directives/on.spec.js index <HASH>..<HASH> 100644 --- a/test/mp/runtime/directives/on.spec.js +++ b/test/mp/runtime/directives/on.spec.js @@ -26,6 +26,20 @@ describe('Directive v-on', () => { expect(event.type).toBe('tap') }) + it('should bind event to duplicate method', () => { + const { page } = createPage({ + template: '<div @click="foo" v-on:click="bar" ></div>', + methods: { foo: spy, bar: spy } + }) + + page._triggerEvent(undefined, 'tap') + expect(spy.calls.count()).toBe(2) + + const args = spy.calls.allArgs() + const event = args[0] && args[0][0] || {} + expect(event.type).toBe('tap') + }) + it('should bind event to a inline statement', () => { const { page } = createPage({ template: '<div v-on:click="foo(1,2,3,$event)"></div>',
test: update tests for duplicate event hanlders
kaola-fed_megalo
train
js
dfd38870c002a648ceb81cbecbfb30269813d6a7
diff --git a/renku/service/views/cache.py b/renku/service/views/cache.py index <HASH>..<HASH> 100644 --- a/renku/service/views/cache.py +++ b/renku/service/views/cache.py @@ -115,7 +115,7 @@ def project_clone_view(user_data, cache): requestBody: content: application/json: - schema: ProjectCloneRequest + schema: RepositoryCloneRequest responses: 200: description: Cloned project.
docs: fix project_clone endpoint documentation (#<I>)
SwissDataScienceCenter_renku-python
train
py
84fe954fe037c4ab8eca6d50d454f5ab14b5bbac
diff --git a/test/spec/client/doc.js b/test/spec/client/doc.js index <HASH>..<HASH> 100644 --- a/test/spec/client/doc.js +++ b/test/spec/client/doc.js @@ -29,7 +29,7 @@ describe('doc', function () { return db.destroy(true); }); - it('should save change', function () { + var shouldSaveChange = function () { return task.set({ priority: 'high' }).then(function () { @@ -49,12 +49,14 @@ describe('doc', function () { // Make sure change was removed utils.empty(task._dat.changes).should.eql(true); }); + }; + + it('should save change', function () { + return shouldSaveChange(); }); it('should save destroy change', function () { - return task.set({ - priority: 'high' - }).then(function () { + return shouldSaveChange().then(function () { return task.destroy(); }).then(function () {
test(client): fix destroy recording
delta-db_deltadb-server
train
js
8106f181fe70379414bce137664afee83e338fe5
diff --git a/src/Utility.php b/src/Utility.php index <HASH>..<HASH> 100644 --- a/src/Utility.php +++ b/src/Utility.php @@ -950,9 +950,9 @@ class Utility $charList = implode('', $trim); - $this->string = ltrim($this->string, $charList); + $string = ltrim($this->string, $charList); - return $this; + return new static($string, $this->encoding); } /** @@ -968,9 +968,9 @@ class Utility $charList = implode('', $trim); - $this->string = rtrim($this->string, $charList); + $string = rtrim($this->string, $charList); - return $this; + return new static($string, $this->encoding); } /**
refactor: leftTrim and rightTrim now return new instances rather than themselves
myerscode_utilities-strings
train
php
67f7d9bd9aad0124f05a9856dd30e4df704d2bb3
diff --git a/neurom/fst/__init__.py b/neurom/fst/__init__.py index <HASH>..<HASH> 100644 --- a/neurom/fst/__init__.py +++ b/neurom/fst/__init__.py @@ -64,14 +64,13 @@ from ..analysis.morphmath import segment_taper_rate as seg_taper from ..analysis.morphmath import section_length as sec_len -def _iseg(nrn, neurite_type=None): +def _iseg(nrn, neurite_type=NeuriteType.all): '''Build a tree type filter from a neurite type and forward to functon TODO: This should be a decorator ''' - tree_filter = None if neurite_type is None else _is_type(neurite_type) - return _mm.iter_segments(nrn, tree_filter=tree_filter) + return _mm.iter_segments(nrn, tree_filter=_is_type(neurite_type)) load_population = deprecated('Use load_neurons instead.',
fix: change default value for isegment neurite filter.
BlueBrain_NeuroM
train
py
02c9c3ae7ad1f627cf4acefcc3e08d7e1f8d5b54
diff --git a/sparse/client.go b/sparse/client.go index <HASH>..<HASH> 100644 --- a/sparse/client.go +++ b/sparse/client.go @@ -96,7 +96,10 @@ func connect(host, port string, timeout int) net.Conn { return conn } log.Warn("Failed connection to", endpoint, "Retrying...") - time.Sleep(1 * time.Second) + if timeNow != timeStart { + // only sleep after the second attempt to speedup tests + time.Sleep(1 * time.Second) + } } return nil }
test: updated tests with new client/server timeout option
rancher_sparse-tools
train
go
cf9c2f578ffccf015602f1941d67d2d3b87a4627
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 @@ -168,13 +168,13 @@ def elem_to_container(elem, to_container, nspaces, tags=False): dic[elem.tag] = elem.text if _num_of_children: - # Note: Configuration item cannot have both attributes and values - # (list) at the same time in current implementation: args = (to_container, nspaces, tags) + items = [elem_to_container(c, *args) for c in elem] if _num_of_children == 1: # .. note:: Another special case. - dic[elem.tag] = [elem_to_container(c, *args) for c in elem][0] + dic[elem.tag] = items[0] else: - subdic[children] = [elem_to_container(c, *args) for c in elem] + subdic[children] = items + elif not elem.text and not elem.attrib: # ex. <tag/>. dic[elem.tag] = None
refactor: follow DRY principle in .backend.xml.elem_to_container
ssato_python-anyconfig
train
py
3c797c1262fd59bdda85df9c1108c0ccf839e0f0
diff --git a/src/OpenApi/Factory/OpenApiFactory.php b/src/OpenApi/Factory/OpenApiFactory.php index <HASH>..<HASH> 100644 --- a/src/OpenApi/Factory/OpenApiFactory.php +++ b/src/OpenApi/Factory/OpenApiFactory.php @@ -90,7 +90,6 @@ final class OpenApiFactory implements OpenApiFactoryInterface foreach ($this->resourceNameCollectionFactory->create() as $resourceClass) { $resourceMetadata = $this->resourceMetadataFactory->create($resourceClass); - $resourceShortName = $resourceMetadata->getShortName(); // Items needs to be parsed first to be able to reference the lines from the collection operation $this->collectPaths($resourceMetadata, $resourceClass, OperationType::ITEM, $context, $paths, $links, $schemas);
chore(open-api-factory): unused variable removal (#<I>)
api-platform_core
train
php
5f1355889b9c04c91f87c4b175c837a1820c7a44
diff --git a/test/functional/find_tests.js b/test/functional/find_tests.js index <HASH>..<HASH> 100644 --- a/test/functional/find_tests.js +++ b/test/functional/find_tests.js @@ -2629,7 +2629,7 @@ describe('Find', function() { metadata: { requires: { mongodb: '>=3.6.0 <= 4.1.0', - topology: ['single', 'replicaset', 'sharded', 'ssl', 'heap', 'wiredtiger'] + topology: ['single', 'replicaset'] } }, test: function(done) {
test(find): should not test parallelCollectionScan with sharded parallelCollectionScan cannot run against a mongos, so we should not test it against sharded clusters
mongodb_node-mongodb-native
train
js
f87617121dd97b3d823f58e29ca4128d634dd521
diff --git a/examples/transfer-files/public/js/app.js b/examples/transfer-files/public/js/app.js index <HASH>..<HASH> 100644 --- a/examples/transfer-files/public/js/app.js +++ b/examples/transfer-files/public/js/app.js @@ -1,3 +1,4 @@ +'use strict' /* global self */ const $startButton = document.querySelector('#start') @@ -126,7 +127,8 @@ function onDrop (event) { event.preventDefault() const dt = event.dataTransfer const files = dt.files - const readFileContents = (file) => { + + function readFileContents (file) { return new Promise((resolve) => { const reader = new window.FileReader() reader.onload = (event) => resolve(event.target.result) @@ -134,8 +136,7 @@ function onDrop (event) { }) } - for (var i = 0; i < files.length; i++) { - const file = files[i] + files.map((file) => { readFileContents(file) .then((buffer) => { return node.files.add([{ @@ -150,7 +151,7 @@ function onDrop (event) { .join('<br>') }) .catch(onError) - } + }) } /*
fix: linting on transfer-files example
ipfs_js-ipfs
train
js
66116e2f521ff7edbb3c34457c5c21aacca3bda6
diff --git a/pygenstub.py b/pygenstub.py index <HASH>..<HASH> 100644 --- a/pygenstub.py +++ b/pygenstub.py @@ -679,9 +679,13 @@ class StubGenerator(ast.NodeVisitor): stub_lines = self.root.get_code() prev_line = None for line in stub_lines: - if line.startswith("class ") and prev_line: + if line.startswith("class ") and prev_line and (not prev_line.startswith("class ")): out.write("\n") - if line.startswith("def ") and prev_line and prev_line.startswith(" "): + if ( + line.startswith("def ") + and prev_line + and (prev_line.startswith(" ") or prev_line.startswith("class ")) + ): out.write("\n") out.write(line + "\n") prev_line = line
fix: Remove blank lines between empty class stubs
uyar_pygenstub
train
py
35ca3bf89314bf7152fd10b114dba989cafeea3b
diff --git a/src/Config/web.config.php b/src/Config/web.config.php index <HASH>..<HASH> 100644 --- a/src/Config/web.config.php +++ b/src/Config/web.config.php @@ -21,6 +21,5 @@ */ return [ - 'version' => '4.3.0', 'queue_status_update_time' => 10 * 1000, // milliseconds = seconds x 1,000 ]; diff --git a/src/resources/views/includes/footer.blade.php b/src/resources/views/includes/footer.blade.php index <HASH>..<HASH> 100644 --- a/src/resources/views/includes/footer.blade.php +++ b/src/resources/views/includes/footer.blade.php @@ -19,7 +19,7 @@ @if(file_exists(storage_path('version'))) <b>{{ trans('web::seat.docker_version') }}</b> {{ file_get_contents(storage_path('version')) }} @else - <b>{{ trans('web::seat.web_version') }}</b> {{ config('web.config.version') }} + <b>{{ trans('web::seat.web_version') }}</b> {{ Composer\InstalledVersions::getPrettyVersion($name) ?? trans('web::seat.unknown') }} @endif </div>
refactor: use composer version instead config one
eveseat_web
train
php,php
59dcd33d398afe064a1e2c86c0f2f232d263be00
diff --git a/engine/src/main/java/org/camunda/bpm/engine/history/HistoricActivityStatisticsQuery.java b/engine/src/main/java/org/camunda/bpm/engine/history/HistoricActivityStatisticsQuery.java index <HASH>..<HASH> 100644 --- a/engine/src/main/java/org/camunda/bpm/engine/history/HistoricActivityStatisticsQuery.java +++ b/engine/src/main/java/org/camunda/bpm/engine/history/HistoricActivityStatisticsQuery.java @@ -44,10 +44,10 @@ public interface HistoricActivityStatisticsQuery extends Query<HistoricActivityS /** Only select historic activities of process instances that were started after the given date. */ HistoricActivityStatisticsQuery startedAfter(Date date); - /** Only select historic activities of process instances that were started before the given date. */ + /** Only select historic activities of process instances that were finished before the given date. */ HistoricActivityStatisticsQuery finishedBefore(Date date); - /** Only select historic activities of process instances that were started after the given date. */ + /** Only select historic activities of process instances that were finished after the given date. */ HistoricActivityStatisticsQuery finishedAfter(Date date); /**
chore(query): fix typo related to CAM-<I>
camunda_camunda-bpm-platform
train
java
2b22dadfece88c5501c966d6f5729a540f448fad
diff --git a/packages/build-tools/tasks/pattern-lab-tasks.js b/packages/build-tools/tasks/pattern-lab-tasks.js index <HASH>..<HASH> 100644 --- a/packages/build-tools/tasks/pattern-lab-tasks.js +++ b/packages/build-tools/tasks/pattern-lab-tasks.js @@ -138,9 +138,9 @@ async function compile() { 'build', ], false, - false, + true, ).then(output => { - // console.log(output); + console.log(output); }); } @@ -155,9 +155,9 @@ async function compile() { 'build', ], false, - false, + true, ).then(output => { - // console.log(output); + console.log(output); }); }
test: test updating PL shell command to output progress
bolt-design-system_bolt
train
js
a6f6eb6c27d4f9630d58f8b1eb55ff96535610f2
diff --git a/src/Zephyrus/Database/Core/Database.php b/src/Zephyrus/Database/Core/Database.php index <HASH>..<HASH> 100644 --- a/src/Zephyrus/Database/Core/Database.php +++ b/src/Zephyrus/Database/Core/Database.php @@ -139,12 +139,14 @@ class Database } /** - * @param string|null $name + * Finds the last inserted id for the specified sequence name. + * + * @param string $sequenceName * @return string */ - public function getLastInsertedId(string $name = null): string + public function getLastInsertedId(string $sequenceName): string { - return $this->handle->lastInsertId($name); + return $this->handle->lastInsertId($sequenceName); } /**
refactor: rename argument
dadajuice_zephyrus
train
php
c1e3dcd2dae84d0ec8dde0a6792552025b4d262b
diff --git a/lib/util/git.js b/lib/util/git.js index <HASH>..<HASH> 100644 --- a/lib/util/git.js +++ b/lib/util/git.js @@ -105,7 +105,7 @@ function revs (repo, opts) { return BB.resolve(cached) } return pinflight(`ls-remote:${repo}`, () => { - return spawnGit(['ls-remote', repo], { + return spawnGit(['ls-remote', '-h', '-t', repo], { env: gitEnv() }, opts).then(child => { let stdout = ''
fix(git): limit ls-remote output to heads/tags (#<I>) GitHub repositories can contain other types of refs, such as pull requests, which can be fetched via `git-fetch` but not cloned via `git clone -b`. Fixes: npm/npm#<I>
zkat_pacote
train
js
73b32782a460477774e6376b4fa94c56754ddb88
diff --git a/test/tests.js b/test/tests.js index <HASH>..<HASH> 100644 --- a/test/tests.js +++ b/test/tests.js @@ -1,5 +1,5 @@ var testsContext = require.context(".", true, /.Spec/); -var ignoredSpecs = [/viewDirectiveSpec/]; +var ignoredSpecs = []; var notIgnored = function (key) { var ignored = ignoredSpecs.reduce(function(memo, regexp) { return memo || regexp.exec(key); }, false); diff --git a/test/viewDirectiveSpec.js b/test/viewDirectiveSpec.js index <HASH>..<HASH> 100644 --- a/test/viewDirectiveSpec.js +++ b/test/viewDirectiveSpec.js @@ -569,7 +569,7 @@ describe('uiView controllers or onEnter handlers', function() { .state('aside', { url: '/aside', template: '<div class="aside"></div>' }) .state('A', { url: '/A', template: '<div class="A" ui-view="fwd"></div>' }) .state('A.fwd', { - url: '/fwd', views: { 'fwd@A': { + url: '/fwd', views: { 'fwd': { template: '<div class="fwd" ui-view>', controller: function($state) { if (count++ < 20 && $state.current.name == 'A.fwd') $state.go(".nest"); } }}
test(viewDirective): switch a named view from old state-based targeting to new view naming
ui-router_angular
train
js,js
d17f8538b2e6e52165c37927cbdaa35a6547a266
diff --git a/pkg/setting/setting.go b/pkg/setting/setting.go index <HASH>..<HASH> 100644 --- a/pkg/setting/setting.go +++ b/pkg/setting/setting.go @@ -363,10 +363,6 @@ func validateStaticRootPath() error { return nil } - if _, err := os.Stat(path.Join(StaticRootPath, "css")); err == nil { - return nil - } - if _, err := os.Stat(StaticRootPath + "_gen/css"); err == nil { StaticRootPath = StaticRootPath + "_gen" return nil
fix(backend): made public_gen detection more bullet proof, #<I>
grafana_grafana
train
go
b10d2d10a8a916c35cf32bccf935f64e99612325
diff --git a/packages/side-nav/src/__stories__/ExampleSideNav.js b/packages/side-nav/src/__stories__/ExampleSideNav.js index <HASH>..<HASH> 100644 --- a/packages/side-nav/src/__stories__/ExampleSideNav.js +++ b/packages/side-nav/src/__stories__/ExampleSideNav.js @@ -10,10 +10,12 @@ const ExampleSideNav = () => ( <SideNav headerLabel={text("Header Label", "Storybook")} headerLink={text("Header Link", "https://www.autodesk.com")} + onClickHeader={action("onClick")} onMinimize={action("onMinimize")} showMinimizeButton={boolean("Show Minimize Button", false)} superHeaderLabel={text("Superheader Label", "HIG")} superHeaderLink={text("Superheader Link", "https://www.autodesk.com")} + onClickSuperHeader={action("onClick")} groups={ <SideNav.Group> <SideNav.Module title="Module 1" icon={<Insight24 />} activeChildren>
test: update the stories with onClick events
Autodesk_hig
train
js
8eccd0f82cc03cf9b487682d787b044227751cc3
diff --git a/packages/eslint-config-accurapp/index.js b/packages/eslint-config-accurapp/index.js index <HASH>..<HASH> 100644 --- a/packages/eslint-config-accurapp/index.js +++ b/packages/eslint-config-accurapp/index.js @@ -73,7 +73,16 @@ module.exports = { ignoredNodes: ['TemplateLiteral *'], }, ], - 'comma-dangle': ['warn', 'always-multiline'], // No risks, beacuse it will be transpiled + 'comma-dangle': [ + 'warn', + { + arrays: 'always-multiline', + objects: 'always-multiline', + imports: 'always-multiline', + exports: 'always-multiline', + functions: 'never', + }, + ], // No risks, beacuse it will be transpiled 'space-before-function-paren': ['warn', { anonymous: 'always', named: 'never' }], 'key-spacing': ['warn', { beforeColon: false, afterColon: true, mode: 'minimum' }], 'object-curly-spacing': ['warn', 'always'],
fix: 🐛 Fix conflict with eslint and prettier config
accurat_accurapp
train
js
7c774fdf01eb2ae4d2699b713874ae1ae6ffba92
diff --git a/packages/heading/react/index.js b/packages/heading/react/index.js index <HASH>..<HASH> 100644 --- a/packages/heading/react/index.js +++ b/packages/heading/react/index.js @@ -17,7 +17,8 @@ const getClassName = props => classNames({ [props.className]: props.className, [props.css['ps-heading']]: true, - [props.css['ps-heading--' + props.size]]: props.size + [props.css['ps-heading--' + props.size]]: props.size, + [props.className]: props.className }) const Heading = props => {
feat(heading): allow overriding className
pluralsight_design-system
train
js
b47eb02dc0b6e16e22c83f20b7b53aad52aab20e
diff --git a/sdk/dist/cc.js b/sdk/dist/cc.js index <HASH>..<HASH> 100644 --- a/sdk/dist/cc.js +++ b/sdk/dist/cc.js @@ -1489,6 +1489,11 @@ cc.models.Product.prototype.getBasePriceInfo = function(){ return ''; }; + +cc.models.Product.prototype.hasOldPrice = function(){ + return cc.Util.isNumeric(this.priceOld) && this.priceOld > 0; +}; + cc.models.Product.prototype.hasVariants = function(){ return this.variants && this.variants.length > 0; }; diff --git a/sdk/src/core/cc.models.product.js b/sdk/src/core/cc.models.product.js index <HASH>..<HASH> 100644 --- a/sdk/src/core/cc.models.product.js +++ b/sdk/src/core/cc.models.product.js @@ -46,6 +46,11 @@ cc.models.Product.prototype.getBasePriceInfo = function(){ return ''; }; + +cc.models.Product.prototype.hasOldPrice = function(){ + return cc.Util.isNumeric(this.priceOld) && this.priceOld > 0; +}; + cc.models.Product.prototype.hasVariants = function(){ return this.variants && this.variants.length > 0; };
feat(sdk): add hasOldPrice to product model
sofa_sofa-couch-service
train
js,js
2920949dd752f85c8f6b764f4092a0d0e66ba942
diff --git a/imgix/__init__.py b/imgix/__init__.py index <HASH>..<HASH> 100644 --- a/imgix/__init__.py +++ b/imgix/__init__.py @@ -25,4 +25,4 @@ from .urlbuilder import UrlBuilder __all__ = [ 'UrlBuilder', - 'SIGNATURE_MODE_QUERY', 'SIGNATURE_MODE_PATH', '__version__', ] + '__version__']
chore: clean up remnant SIGNATURE_MODE artifacts (#<I>)
imgix_imgix-python
train
py
c73d3cfc8afb6e4346bee12aa1a06fbd592fd1d4
diff --git a/lib/client.js b/lib/client.js index <HASH>..<HASH> 100644 --- a/lib/client.js +++ b/lib/client.js @@ -692,7 +692,6 @@ class Parser extends HTTPParser { } assert(statusCode >= 100) - assert(this.resuming || (socket._handle && socket._handle.reading)) if (upgrade) { // TODO: When, how and why does this happen?
fix: don't access socket._handler
mcollina_undici
train
js
db552bc856494430be0bd9e15e03f665d2fbccb0
diff --git a/doc/docusaurus.docs.config.js b/doc/docusaurus.docs.config.js index <HASH>..<HASH> 100644 --- a/doc/docusaurus.docs.config.js +++ b/doc/docusaurus.docs.config.js @@ -13,8 +13,8 @@ module.exports = { tagline: 'Interactive, extendable street imagery visualization platform', url: 'https://mapillary.github.io', baseUrl: '/mapillary-js/', - onBrokenLinks: 'warn', - onBrokenMarkdownLinks: 'warn', + onBrokenLinks: 'error', + onBrokenMarkdownLinks: 'error', favicon: 'img/favicon.png', organizationName: 'mapillary', projectName: 'mapillary-js',
chore: error on broken links in doc build
mapillary_mapillary-js
train
js
185f396b6552f0aa017112d4a1dd928eb3a07f41
diff --git a/src/plugin/release/index.js b/src/plugin/release/index.js index <HASH>..<HASH> 100644 --- a/src/plugin/release/index.js +++ b/src/plugin/release/index.js @@ -76,15 +76,6 @@ function action (config, directory, options) { previousFile = readFileSync(changelog, 'utf8') } - const changelogOptions = { - commits: status[packageName].commits, - file: check ? process.stdout : createFileStream(changelog), - version: newVersion, - url: pkg.repository.url.replace('.git', '').replace('git+', '') || pkg.repository, - bugs: pkg.bugs, - previousFile - } - if (isDirectoryClean()) { if (!method || check || pkg.private) { console.log(separator(packageName)) @@ -93,6 +84,15 @@ function action (config, directory, options) { } } + const changelogOptions = { + commits: status[packageName].commits, + file: check ? process.stdout : createFileStream(changelog), + version: newVersion, + url: pkg.repository.url.replace('.git', '').replace('git+', '') || pkg.repository, + bugs: pkg.bugs, + previousFile + } + if (!method || check || pkg.private) { return generateChangelog(changelogOptions).then(() => { if (!check) {
fix(northbrook): dont create file stream before checking directory checking the that the git directory is clean after creating a write file stream always leads to the directory being dirty.
northbrookjs_northbrook
train
js
b2a5e19eb8912fcaecbb8f2e427efbc19674335d
diff --git a/src/TimePicker/TimePicker.js b/src/TimePicker/TimePicker.js index <HASH>..<HASH> 100644 --- a/src/TimePicker/TimePicker.js +++ b/src/TimePicker/TimePicker.js @@ -115,12 +115,20 @@ function _timePickerBlur(){ }; function _changeHandler(e){ + console.log('change handler'); + console.log(e.target.value); this.setState({ timePickerValue:e.target.value, displayOpen:false, labelStyleTmp:this.state.labelStyle }); this.props.changeHandler.call(this, e.target.value); }; function _listHandler(e){ + const changeHandlerParam = { + target: { + value: e.target.innerText.toUpperCase() + } + }; this.setState({ timePickerValue:e.target.innerText, displayOpen:false, labelStyleTmp:this.state.labelStyle }); + this.changeHandler(changeHandlerParam); }; function _inputEvents(e){
fix: timepicker - insure changeHandler called in listHandler
Pearson-Higher-Ed_compounds
train
js
4396f096208cd319af942996c3a61ea4c9c05ed3
diff --git a/manifest.js b/manifest.js index <HASH>..<HASH> 100644 --- a/manifest.js +++ b/manifest.js @@ -36,6 +36,7 @@ function manifest (spec, opts) { if (opts.annotate) { manifest._requested = spec manifest._spec = spec.raw + manifest._from = spec.raw manifest._where = opts.where }
fix(manifest): meh just shove _from in there
zkat_pacote
train
js
2ff40857dd9d36b383278f4c4743e45de511ddee
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 @@ -339,6 +339,26 @@ export default class AvApi { return this.update(...args); } + // patch request + patch(id, data, config) { + if (typeof id !== 'string' && typeof id !== 'number') { + config = data; + data = id; + id = ''; + } + + config = this.config(config); + config.method = 'PATCH'; + config.url = this.getUrl(config, id); + config.data = data; + + const beforeFunc = this.beforePatch; + if (beforeFunc) { + config.data = beforeFunc(config.data); + } + return this.request(config, this.afterPatch); + } + // delete request remove(id, config) { if (typeof id !== 'string' && typeof id !== 'number') {
feat(api-core): proposed support for patch method, see issue #<I>
Availity_sdk-js
train
js
01b135c69f731ec6841953491d310d06fd5740c0
diff --git a/scripts/serverless.js b/scripts/serverless.js index <HASH>..<HASH> 100755 --- a/scripts/serverless.js +++ b/scripts/serverless.js @@ -331,10 +331,8 @@ const processSpanPromise = (async () => { return; } })(); - } else if (!commandSchema) { - // If command was not recognized and not in service context - // We recognize all AWS service commands - // (to report "Missing service context" instead of "Unrecognized command" error) + } else { + // In non-service context we recognize all AWS service commands resolveInput.clear(); ({ command, commands, options, isHelpRequest, commandSchema } = resolveInput( require('../lib/cli/commands-schema/aws-service')
fix(CLI): Ensure to expose accurate `commandsSchema` in resolved input
serverless_serverless
train
js
e4f94f067847e1dbfcbdd241eb2833a3e8da8e55
diff --git a/modules/angular1_router/build.js b/modules/angular1_router/build.js index <HASH>..<HASH> 100644 --- a/modules/angular1_router/build.js +++ b/modules/angular1_router/build.js @@ -22,8 +22,8 @@ var PRELUDE = '(function(){\n'; var POSTLUDE = '\n}());\n'; var FACADES = fs.readFileSync(__dirname + '/lib/facades.es5', 'utf8'); var DIRECTIVES = fs.readFileSync(__dirname + '/src/ng_outlet.js', 'utf8'); -var ES6_SHIM = fs.readFileSync(__dirname + '/../../node_modules/es6-shim/es6-shim.js', 'utf8'); function main() { + var ES6_SHIM = fs.readFileSync(__dirname + '/../../node_modules/es6-shim/es6-shim.js', 'utf8'); var dir = __dirname + '/../angular2/src/router/'; var out = '';
fix(build): lazy-require es6-shim in the a1 router to prevent npm/gulp issues We should really remove this shim from the angular 1 bundle. I'll create an issue for that.
angular_angular
train
js
bc66fa1711dcd66c98bd961a2d7f8cc1cb62743b
diff --git a/test/e2e/runner.js b/test/e2e/runner.js index <HASH>..<HASH> 100644 --- a/test/e2e/runner.js +++ b/test/e2e/runner.js @@ -43,9 +43,9 @@ if (args.indexOf('-c') < 0) { // check if multiple envs are provided. The way Nightwatch works // requires to explicitely provide the conf const envs = args[args.indexOf('-e') + 1] - if (!envs || envs.indexOf(',') > -1) { + if (envs && envs.indexOf(',') > -1) { console.warn( - `Specify the conf with providing multiple browsers:\n$ yarn run test:e2e ${args.join( + `Specify the conf when providing multiple browsers:\n$ yarn run test:e2e ${args.join( ' ' )} -c ${NW_CONFIG}` )
test: fix runner check of -e
vuejs_vue-router
train
js
4013977c23a04b9f7706c3b4568d10c10fcf6f58
diff --git a/test/browser/render.js b/test/browser/render.js index <HASH>..<HASH> 100644 --- a/test/browser/render.js +++ b/test/browser/render.js @@ -273,13 +273,11 @@ describe('DOM Rendering', function () { DOM: makeDOMDriver(createRenderTarget()) }); - const expected = Rx.Observable.from(['1/1','2/1','2/2']) - sources.DOM.select('.target').observable .map(els => els[0].innerHTML) - .sequenceEqual(expected) - .subscribe((areSame) => { - assert.strictEqual(areSame, true); + .last() + .subscribe((html) => { + assert.strictEqual(html, '2/2'); sources.dispose(); sinks.dispose(); done();
test(render): fix for sometimes fail/pass test
TylorS_cycle-snabbdom
train
js
25e47ae8048b3ee3e6588161e797ac9c0fc07829
diff --git a/packages/spaces/src/useLink.js b/packages/spaces/src/useLink.js index <HASH>..<HASH> 100644 --- a/packages/spaces/src/useLink.js +++ b/packages/spaces/src/useLink.js @@ -1,7 +1,9 @@ import nativeForm from '@availity/native-form'; import { getUrl, getTarget } from '@availity/link'; +import { isAbsoluteUrl } from '@availity/resolve-url'; import { useSpaces, useSpacesContext } from './Spaces'; // import { updateTopApps } from './helpers'; +import { updateUrl } from './helpers'; export default (spaceOrSpaceId, { clientId: propsClientId, linkAttributes = {} } = {}) => { const { clientId = propsClientId } = useSpacesContext() || {}; @@ -61,7 +63,17 @@ export default (spaceOrSpaceId, { clientId: propsClientId, linkAttributes = {} } // await updateTopApps(id, type); const target = getTarget(link.target); - const url = getUrl(link.url); + const url = !isAbsoluteUrl(link.url) + ? getUrl( + updateUrl( + link.url, + 'spaceId', + space.parents && space.parents[0] ? space.parents[0].id : linkAttributes.spaceId + ), + false, + false + ) + : link.url; window.open(url, target); };
fix(spaces): build url with params
Availity_availity-react
train
js
7dd2fd82fda6410c394301ee031071ca661c58dd
diff --git a/index.js b/index.js index <HASH>..<HASH> 100644 --- a/index.js +++ b/index.js @@ -21,7 +21,8 @@ module.exports = function(schema) { schema.path(path).validate({ validator: function() { - var arr = this.getValue(path + '.' + _path); + // handle private API changes for mongoose >= 5.5.14 Automattic/mongoose#7870 + var arr = (this.$__getValue || this.getValue)(path + '.' + _path); var dup = hasDuplicates(arr); if (dup) { return false;
fix: handle private API changes for mongoose >= <I>
vkarpov15_mongoose-unique-array
train
js
697ce51409d6c31da54d68fb57371af58ca0ea8b
diff --git a/lib/plugins/load-plugin.js b/lib/plugins/load-plugin.js index <HASH>..<HASH> 100644 --- a/lib/plugins/load-plugin.js +++ b/lib/plugins/load-plugin.js @@ -336,7 +336,7 @@ var customParser = function() { return retryCustomParser(); } idList.forEach(function(reqId) { - var cb = parserCalretryCustomParserlbacks[reqId]; + var cb = parserCallbacks[reqId]; cb && cb(result[reqId]); }); retryCustomParser(framesList.length> 0 ? 20 : 200);
feat: custom socket data parer by plugin
avwo_whistle
train
js
f394ec474d62b4b79c463af4bdcbbe22651ccbd7
diff --git a/docs/docs/.vitepress/config.js b/docs/docs/.vitepress/config.js index <HASH>..<HASH> 100644 --- a/docs/docs/.vitepress/config.js +++ b/docs/docs/.vitepress/config.js @@ -14,9 +14,9 @@ module.exports = { docsDir: 'docs/docs', docsBranch: 'v1', algolia: { - appId: '', - apiKey: '', - indexName: '' + appId: 'V60OC8MPVK', + apiKey: 'f0f7f91f8388d5b8d8c7f78dbcc4ea97', + indexName: 'nystudio107-twig-profiler' }, editLinks: true, editLinkText: 'Edit this page on GitHub',
refactor: Add DocSearch settings
nystudio107_craft-twigprofiler
train
js
94f6247593b99d408df55ab33c095b20876b0a69
diff --git a/lib/hapi/index.js b/lib/hapi/index.js index <HASH>..<HASH> 100644 --- a/lib/hapi/index.js +++ b/lib/hapi/index.js @@ -8,12 +8,12 @@ module.exports = function (env_config) { rootPathFactory('web', 'www_root'), require('./logger'), require('./handle_404') - ]).map(function (plugin) { + ].map(function (plugin) { return { register: plugin, options: { app: env_config } } - }) + })) }
fix(hapi): not passing options to core plugins * * * This commit was sponsored by The Hoodie Firm. You can hire The Hoodie Firm: <URL>
hoodiehq_hoodie-server
train
js
2a48c6a60762e3281fddb8dd64028f94610d14a0
diff --git a/commitlint.config.js b/commitlint.config.js index <HASH>..<HASH> 100644 --- a/commitlint.config.js +++ b/commitlint.config.js @@ -33,6 +33,7 @@ module.exports = { 'CLI', 'Components', 'Config Schema', + 'Dashboard', 'Plugins', 'Standalone', 'Templates',
chore: Register "Dashboard" message scope
serverless_serverless
train
js
f05ab83ca0a1795514ad56234a2fefea2e31708f
diff --git a/src/Model.php b/src/Model.php index <HASH>..<HASH> 100644 --- a/src/Model.php +++ b/src/Model.php @@ -313,6 +313,16 @@ abstract class Model extends PhalconModel return $this; } + /** + * @codeCoverageIgnore + */ + public function setRelatedRecord($key, $value) + { + $this->_related[$key] = $value; + $this->_dirtyState = static::DIRTY_STATE_TRANSIENT; + return $this; + } + public static function setup(array $options) { PhalconModel::setup($options);
feat(model): add set related record method
phwoolcon_phwoolcon
train
php
a187ee064e19d55172813355bee3cfe50d9704d5
diff --git a/test/edit_history_test.go b/test/edit_history_test.go index <HASH>..<HASH> 100644 --- a/test/edit_history_test.go +++ b/test/edit_history_test.go @@ -242,12 +242,12 @@ func TestEditHistorySelfClusters(t *testing.T) { addTime(1*time.Minute), mkfile("a", "hello"), ), - as(bob, - checkUserEditHistory(expectedEdits2Bob), - ), as(alice, checkUserEditHistory(expectedEdits2Alice), ), + as(bob, + checkUserEditHistory(expectedEdits2Bob), + ), ) } @@ -367,10 +367,10 @@ func TestEditHistoryRenameParent(t *testing.T) { addTime(1*time.Minute), rm("c/b"), ), - as(bob, + as(alice, checkUserEditHistory([]expectedEdit{}), ), - as(alice, + as(bob, checkUserEditHistory([]expectedEdit{}), ), ) @@ -411,10 +411,10 @@ func TestEditHistoryRenameParentAcrossDirs(t *testing.T) { addTime(1*time.Minute), rm("d/c/b"), ), - as(bob, + as(alice, checkUserEditHistory([]expectedEdit{}), ), - as(alice, + as(bob, checkUserEditHistory([]expectedEdit{}), ), )
test: fix order of edit history tests To make sure the writer's background goroutines finish before checking the history.
keybase_client
train
go
aabb486129e0378c11749f5a611ec83191426f22
diff --git a/lib/workers/repository/init/config.js b/lib/workers/repository/init/config.js index <HASH>..<HASH> 100644 --- a/lib/workers/repository/init/config.js +++ b/lib/workers/repository/init/config.js @@ -6,6 +6,7 @@ const { decryptConfig } = require('../../../config/decrypt'); const presets = require('../../../config/presets'); const npmApi = require('../../../datasource/npm'); const { flattenPackageRules } = require('./flatten'); +const hostRules = require('../../../util/host-rules'); // Check for config in `renovate.json` async function mergeRenovateConfig(config) { @@ -145,6 +146,12 @@ async function mergeRenovateConfig(config) { ); resolvedConfig.ignoreNpmrcFile = true; } + // istanbul ignore if + if (resolvedConfig.hostRules) { + logger.info('Setting hostRules from config'); + resolvedConfig.hostRules.forEach(hostRules.update); + delete resolvedConfig.hostRules; + } returnConfig = mergeChildConfig(returnConfig, resolvedConfig); returnConfig.renovateJsonPresent = true; returnConfig.packageRules = flattenPackageRules(returnConfig.packageRules);
fix(hostRules): allow to be set in config
renovatebot_renovate
train
js
a06000f287661e6a3390132f20618c0fd5be99e1
diff --git a/mangopay/resources.py b/mangopay/resources.py index <HASH>..<HASH> 100644 --- a/mangopay/resources.py +++ b/mangopay/resources.py @@ -641,7 +641,7 @@ class PreAuthorization(BaseModel): secure_mode_redirect_url = CharField(api_name='SecureModeRedirectURL') secure_mode_return_url = CharField(api_name='SecureModeReturnURL', required=True) expiration_date = DateField(api_name='ExpirationDate') - payin = ForeignKeyField(PayIn, api_name='PayinId') + payin = ForeignKeyField(PayIn, api_name='PayInId') billing = BillingField(api_name='Billing') security_info = SecurityInfoField(api_name='SecurityInfo')
fix(resources): fix typo to api_name
Mangopay_mangopay2-python-sdk
train
py
0d6f7b1bb811f6e89214a869ffa3cf9e8fa88a6c
diff --git a/packages/node_modules/cerebral/src/index.js b/packages/node_modules/cerebral/src/index.js index <HASH>..<HASH> 100644 --- a/packages/node_modules/cerebral/src/index.js +++ b/packages/node_modules/cerebral/src/index.js @@ -1,8 +1,9 @@ +import * as tags from './tags' + import ControllerClass from './Controller' -import UniversalControllerClass from './UniversalController' -import ModuleClass from './Module' import { DEPRECATE } from './utils' -import * as tags from './tags' +import ModuleClass from './Module' +import UniversalControllerClass from './UniversalController' let tagsVar = tags @@ -41,6 +42,8 @@ export { SequenceWithPropsFactory as ChainSequenceWithPropsFactory, } from 'function-tree/fluent' +export { sequence, parallel } from 'function-tree' + export function Controller(rootModule, options) { DEPRECATE('Controller', 'Use App default import instead') return new ControllerClass(rootModule, options)
fix(cerebral): fix missing sequence and parallel exports
cerebral_cerebral
train
js
021e741009830df963ffa465f0b2ebc0b2b43c30
diff --git a/src/router.js b/src/router.js index <HASH>..<HASH> 100644 --- a/src/router.js +++ b/src/router.js @@ -38,6 +38,8 @@ export class Router { } else { current.href = '#/' + this.baseUrl; } + } else { + current.href = '/' + this.baseUrl; } if (current.href[current.href.length - 1] != '/') {
fix(router): url fragments duplicated on subsequent navigations between routes when using pushState
aurelia_router
train
js
8df1ac9920a20d74c7d5cd15ee0124f6e7236abc
diff --git a/src/structures/interfaces/TextBasedChannel.js b/src/structures/interfaces/TextBasedChannel.js index <HASH>..<HASH> 100644 --- a/src/structures/interfaces/TextBasedChannel.js +++ b/src/structures/interfaces/TextBasedChannel.js @@ -268,6 +268,7 @@ class TextBasedChannel { if (this.client.user._typing.has(this.id)) { const entry = this.client.user._typing.get(this.id); entry.count = count || entry.count + 1; + return; } const entry = {
fix(startTyping): return, to not overwrite already existing entries
discordjs_discord.js
train
js
4ee1256a033b2df59f847bbd68f8dfba12f97940
diff --git a/src/actions/query.js b/src/actions/query.js index <HASH>..<HASH> 100644 --- a/src/actions/query.js +++ b/src/actions/query.js @@ -464,6 +464,8 @@ function appbaseSearch( } else { dispatch(setPromotedResults([], component)); } + // set raw response in rawData + dispatch(setRawData(component, response)); // Update custom data if (response.customData) { dispatch(setCustomData(response.customData, component));
fix: rawData for RS API
appbaseio_reactivecore
train
js
b8632b3b2c1ce380c0f0a3df4ad68c27ebfea412
diff --git a/lib/index.js b/lib/index.js index <HASH>..<HASH> 100644 --- a/lib/index.js +++ b/lib/index.js @@ -32,7 +32,7 @@ function CordovaSQLitePouch (opts, callback) { websql: websql }, opts) - if (typeof cordova === 'undefined' || typeof sqlitePlugin === 'undefined' || typeof openDatabase === 'undefined') { + if (typeof cordova === 'undefined' || (typeof sqlitePlugin === 'undefined' && typeof openDatabase === 'undefined')) { console.error( 'PouchDB error: you must install a SQLite plugin ' + 'in order for PouchDB to work on this platform. Options:' +
fix: change condition to show you must install a SQLite plugin error
pouchdb-community_pouchdb-adapter-cordova-sqlite
train
js
a03690bd70afed74b8d514928092b652da7f2ee9
diff --git a/lib/datasource/rubygems/retriable.js b/lib/datasource/rubygems/retriable.js index <HASH>..<HASH> 100644 --- a/lib/datasource/rubygems/retriable.js +++ b/lib/datasource/rubygems/retriable.js @@ -13,8 +13,9 @@ const NUMBER_OF_RETRIES = 5; const getDelayStep = () => parseInt(process.env.RENOVATE_RUBYGEMS_RETRY_DELAY_STEP || '1000', 10); -const toMs = value => parseInt(value, 10) * getDelayStep(); -const getBannedDelay = retryAfter => (retryAfter || RETRY_AFTER) + 1; +const toMs = value => value * getDelayStep(); +const getBannedDelay = retryAfter => + (parseInt(retryAfter, 10) || RETRY_AFTER) + 1; const getDefaultDelay = count => (NUMBER_OF_RETRIES * getDelayStep()) / count; const getDelayMessage = delay => `Retry in ${delay} seconds.`;
fix(rubygems): fix delay parsing (#<I>) fix(rubygems): fix delay parsing
renovatebot_renovate
train
js
6e17a3bac854cd77723fb62ac44fbb1596f83372
diff --git a/src/State.js b/src/State.js index <HASH>..<HASH> 100644 --- a/src/State.js +++ b/src/State.js @@ -17,6 +17,7 @@ const DEFAULT_SUFFIX = "Controller"; @param {State[]} [opts.children] - List of child states. @param {string} [opts.controllerName] - The name of the controller as seen by angular. @param {Object} [opts.resolve] - Any required resolved. +@param {Object} [opts.data] - Data to associate with this state. @param {Object} [opts.views] - State views @param {string[]} [opts.aliases] - Aliases for the current state. @@ -135,6 +136,14 @@ export function State(opts) { } } + meta.state.data = {}; + if (opts.data !== false) { + Object.assign(meta.state.data, superMeta.state.data); + if (opts.data) { + Object.assign(meta.state.data, opts.data); + } + } + } } @@ -304,6 +313,7 @@ export function buildUiRouterState(obj, options) { children: children, resolve: resolve, views: views, + data: meta.state.data, }; return state;
feat(state): Allow data to be associated with a state
fd_fd-angular-core
train
js
bd23089fca6422c61bbe6d617125fc995cea0ccf
diff --git a/src/plugin/release/generate-changelog.js b/src/plugin/release/generate-changelog.js index <HASH>..<HASH> 100644 --- a/src/plugin/release/generate-changelog.js +++ b/src/plugin/release/generate-changelog.js @@ -45,9 +45,9 @@ export function generateChangelog ({ commits, file, version, url, bugs, previous }) changelog.write('\n\n') - changelog.write(previousFile) if (typeof file === 'string') { + changelog.write(previousFile) changelog.on('finish', () => { resolve(changelog) })
fix(northbrook): only show new stuff in check mode
northbrookjs_northbrook
train
js
29ed6f0e82e921ba760ae63e9cc143bcee809e47
diff --git a/packages/bonde-styleguide/src/components/cards/Panel/Panel.js b/packages/bonde-styleguide/src/components/cards/Panel/Panel.js index <HASH>..<HASH> 100644 --- a/packages/bonde-styleguide/src/components/cards/Panel/Panel.js +++ b/packages/bonde-styleguide/src/components/cards/Panel/Panel.js @@ -87,11 +87,11 @@ const Panel = ({ <Spacing padding={{ x: 16, top: 14 }}> <Title.H4>{title}</Title.H4> - <Spacing margin={{ y: 8 }}> + {description && (<Spacing margin={{ y: 8 }}> <Text fontSize={16} lineHeight={1.31} color={textColor}> {description} </Text> - </Spacing> + </Spacing>)} </Spacing> </div> @@ -112,7 +112,7 @@ Panel.propTypes = { minHeight: number, image: string, title: string.isRequired, - description: string.isRequired, + description: string, author: string.isRequired }
fix(styleguide): render description on Panel only passed
nossas_bonde-client
train
js
99af2601b5c820e522d4be9096b6e22b0337ee5d
diff --git a/generators/deployment/index.js b/generators/deployment/index.js index <HASH>..<HASH> 100644 --- a/generators/deployment/index.js +++ b/generators/deployment/index.js @@ -195,6 +195,7 @@ module.exports = class extends Generator { : `gunicorn ${this.bluemix.name}.wsgi -b 0.0.0.0:$PORT`; this.manifestConfig.memory = this.manifestConfig.memory || '128M'; this.cfIgnoreContent = ['.pyc', '.egg-info']; + this.manifestConfig.env.DISABLE_COLLECTSTATIC = '1'; } cleanUpPass() {
fix: fix bugs with dockertools and manifest with django
ibm-developer_generator-ibm-cloud-enablement
train
js
5f3910ebf412d8706692dc53bb35b4451611f6ec
diff --git a/commitlint.config.js b/commitlint.config.js index <HASH>..<HASH> 100644 --- a/commitlint.config.js +++ b/commitlint.config.js @@ -1,6 +1,8 @@ module.exports = { - extends: ['@commitlint/config-conventional'], + extends: ["@commitlint/config-conventional"], rules: { - 'body-max-line-length': [0, "always", Infinity], + "header-max-length": [0, "always", Infinity], + "body-max-line-length": [0, "always", Infinity], + "footer-max-line-length": [0, "always", Infinity], }, };
chore: remove max-length limits for commitlint
browniebroke_deezer-python
train
js
09f787662e247f102494ce43091503daecc4f86a
diff --git a/sendgrid/helpers/mail/subject.py b/sendgrid/helpers/mail/subject.py index <HASH>..<HASH> 100644 --- a/sendgrid/helpers/mail/subject.py +++ b/sendgrid/helpers/mail/subject.py @@ -2,7 +2,7 @@ class Subject(object): """A subject for an email message.""" def __init__(self, subject, p=None): - """Create a Subjuct. + """Create a Subject. :param subject: The subject for an email :type subject: string
docs: Fixed Subject typo (#<I>)
sendgrid_sendgrid-python
train
py
d62ba27a6da30e9be8a79d310952efe9453f325d
diff --git a/pgjdbc/src/main/java/org/postgresql/jdbc/TypeInfoCache.java b/pgjdbc/src/main/java/org/postgresql/jdbc/TypeInfoCache.java index <HASH>..<HASH> 100644 --- a/pgjdbc/src/main/java/org/postgresql/jdbc/TypeInfoCache.java +++ b/pgjdbc/src/main/java/org/postgresql/jdbc/TypeInfoCache.java @@ -128,7 +128,7 @@ public class TypeInfoCache implements TypeInfo { TYPE_ALIASES.put("long", "int8"); TYPE_ALIASES.put("int8", "int8"); TYPE_ALIASES.put("bigint", "int8"); - TYPE_ALIASES.put("float", "float4"); + TYPE_ALIASES.put("float", "float8"); TYPE_ALIASES.put("float4", "float4"); TYPE_ALIASES.put("double", "float8"); TYPE_ALIASES.put("float8", "float8");
fix: revert change in PR#<I> where float was aliased to float4 from float8. float now aliases to float8 (#<I>)
pgjdbc_pgjdbc
train
java
c02544db2fc2fbd2c12d1faac7d08896ff5f5601
diff --git a/functional/pool_tests.js b/functional/pool_tests.js index <HASH>..<HASH> 100644 --- a/functional/pool_tests.js +++ b/functional/pool_tests.js @@ -39,7 +39,7 @@ describe('Pool tests', function() { } }); - it.only('Should only listen on connect once', { + it('Should only listen on connect once', { metadata: { requires: { topology: 'single' } }, test: function(done) {
test(pool): remove .only in test came in #<I>
mongodb_node-mongodb-native
train
js
5aae57712da14fa998ac40921649e6392138b3a1
diff --git a/tests/test_buku.py b/tests/test_buku.py index <HASH>..<HASH> 100644 --- a/tests/test_buku.py +++ b/tests/test_buku.py @@ -762,4 +762,3 @@ def test_convert_bookmark_set(export_type, exp_res, monkeypatch): res = convert_bookmark_set(bms, export_type=export_type) assert res['count'] == 2 assert exp_res == res['data'] -
fix: test: lint
jarun_Buku
train
py
1714680ed8df66e441b49b9dfd7d324d38c05b0b
diff --git a/android/src/main/java/com/swmansion/reanimated/ReanimatedModule.java b/android/src/main/java/com/swmansion/reanimated/ReanimatedModule.java index <HASH>..<HASH> 100644 --- a/android/src/main/java/com/swmansion/reanimated/ReanimatedModule.java +++ b/android/src/main/java/com/swmansion/reanimated/ReanimatedModule.java @@ -230,6 +230,16 @@ public class ReanimatedModule extends ReactContextBaseJavaModule implements }); } + @ReactMethod + public void addListener(String eventName) { + // Keep: Required for RN built in Event Emitter Calls. + } + + @ReactMethod + public void removeListeners(Integer count) { + // Keep: Required for RN built in Event Emitter Calls. + } + @Override public void onCatalystInstanceDestroy() { super.onCatalystInstanceDestroy();
fix(android): react-native <I> event emitter stubs (#<I>) ## Description Fixes #<I> by adding stub implementations of newly-required methods from react-native <I> See e.g. - <URL>
kmagiera_react-native-reanimated
train
java
a739e7fb32226ed51afec405334a8c4a82353f8a
diff --git a/java-speech/google-cloud-speech/src/test/java/com/google/cloud/speech/v1/it/ITSpeechTest.java b/java-speech/google-cloud-speech/src/test/java/com/google/cloud/speech/v1/it/ITSpeechTest.java index <HASH>..<HASH> 100644 --- a/java-speech/google-cloud-speech/src/test/java/com/google/cloud/speech/v1/it/ITSpeechTest.java +++ b/java-speech/google-cloud-speech/src/test/java/com/google/cloud/speech/v1/it/ITSpeechTest.java @@ -148,6 +148,10 @@ public class ITSpeechTest { } public RecognitionAudio audio() { + String audio_gcs_uri = System.getenv("AUDIO_GCS_URI"); + if (audio_gcs_uri != null) { + return RecognitionAudio.newBuilder().setUri(audio_gcs_uri).build(); + } return RecognitionAudio.newBuilder().setUri("gs://gapic-toolkit/hello.flac").build(); } }
test: allow passing audio gcs uri env variable to Speech integration tests (#<I>)
googleapis_google-cloud-java
train
java
1c3fe2c273e83cd45e914c97087046f94c7ce341
diff --git a/packages/table/src/styledComponents/Table.js b/packages/table/src/styledComponents/Table.js index <HASH>..<HASH> 100644 --- a/packages/table/src/styledComponents/Table.js +++ b/packages/table/src/styledComponents/Table.js @@ -23,18 +23,23 @@ const Table = styled.table` padding-right: 16px; } + &.corner-icon { + position: relative; + padding-left: 40px; + } + /* corner icon for grouped rows */ &.corner-icon:before { content: ""; - display: block; float: left; box-sizing: border-box; width: 8px; height: 8px; - margin-top: 8px; - margin-right: 16px; border-left: 2px solid ${colors.INDIGO_MILK_CAP}; border-bottom: 2px solid ${colors.INDIGO_MILK_CAP}; + position: absolute; + top: calc(50% - 3px); + left: 16px; } /* @HACK checkbox component already have a left padding,
fix(Table): fix vertical align of corner icon affects: @crave/farmblocks-table ISSUES CLOSED: #<I>
CraveFood_farmblocks
train
js
f250fb144e49b7f83cb3ce05cbe1376cf5d5a867
diff --git a/test/test_git_version.py b/test/test_git_version.py index <HASH>..<HASH> 100644 --- a/test/test_git_version.py +++ b/test/test_git_version.py @@ -135,7 +135,7 @@ def _create_branch(branch_name): # noinspection PyTypeChecker REPO.create_branch_and_checkout(branch_name) UML.append(f'{init_branch} ->> {branch_name}: checkout') - time.sleep(0.1) + time.sleep(0.2) def _checkout(branch_name):
fix: dev: text: increase delay after dummy branch creation (AV is lagging a tad)
etcher-be_epab
train
py
ea74da12e5b0c0f6ea626d87e7e978f6acf6db86
diff --git a/packages/@vue/cli-plugin-eslint/generator.js b/packages/@vue/cli-plugin-eslint/generator.js index <HASH>..<HASH> 100644 --- a/packages/@vue/cli-plugin-eslint/generator.js +++ b/packages/@vue/cli-plugin-eslint/generator.js @@ -8,6 +8,7 @@ module.exports = (api, { config, lintOn = [] }) => { lint: 'vue-cli-service lint' }, eslintConfig: { + root: true, extends: ['plugin:vue/essential'] }, devDependencies: {}
fix: eslint config should be root
vuejs_vue-cli
train
js
f63cfab4cf7e3d2b9c046be44c4c2a60fbeea570
diff --git a/packages/functionals/botpress-nlu/src/storage.js b/packages/functionals/botpress-nlu/src/storage.js index <HASH>..<HASH> 100755 --- a/packages/functionals/botpress-nlu/src/storage.js +++ b/packages/functionals/botpress-nlu/src/storage.js @@ -119,7 +119,7 @@ export default class Storage { throw new Error('Invalid entity name, expected at least one character') } - const filename = `${entity}.json` + const filename = `${entity}.entity.json` const definitionContent = await this.ghost.readFile(this.entitiesDir, filename) const definition = JSON.parse(definitionContent)
fix(nlu): fixes loading of custom entities
botpress_botpress
train
js
b6b2d442b4fbcd9dfbcfc7ee8d1e53a57cba87be
diff --git a/scripts/validate-commit-messages.py b/scripts/validate-commit-messages.py index <HASH>..<HASH> 100755 --- a/scripts/validate-commit-messages.py +++ b/scripts/validate-commit-messages.py @@ -48,7 +48,7 @@ for commit in commits: errors.append("First line does not match format") if len(lines) > 1 and lines[1]: - errors.append("Second line must be empty") + errors.append("Second line must be empty. Please put a blank line between the subject (first line) and the body/extended description (third line onward).") long_lines = [i + 1 for i, line in enumerate(lines) if len(line) > 72] if long_lines:
ci(travis): clarify purpose of blank line in commit message validation
tjcsl_ion
train
py
d9cb4853dd64c44e562b430ca21142db6bbbc15c
diff --git a/lib/labeler/label.js b/lib/labeler/label.js index <HASH>..<HASH> 100644 --- a/lib/labeler/label.js +++ b/lib/labeler/label.js @@ -22,7 +22,7 @@ export default class Label { refresh (display) {} setVisibility (visibility) { - if (this.svgGroup) this.svgGroup.attr('visibility', visibility ? 'visible' : 'hidden') + if (this.svgGroup) this.svgGroup.attr('display', visibility ? 'initial' : 'none') } getBBox () {
fix(labeler): Use 'display' rather than 'visibility' for label visibility
conveyal_transitive.js
train
js
eaf5070c0719200d5995c07986fbf6ee0473d089
diff --git a/src/SortableContainer/props.js b/src/SortableContainer/props.js index <HASH>..<HASH> 100644 --- a/src/SortableContainer/props.js +++ b/src/SortableContainer/props.js @@ -36,7 +36,7 @@ export const propTypes = { onSortStart: PropTypes.func, pressDelay: PropTypes.number, pressThreshold: PropTypes.number, - keyCodes: PropTypes.objectOf({ + keyCodes: PropTypes.shape({ lift: PropTypes.arrayOf(PropTypes.number), drop: PropTypes.arrayOf(PropTypes.number), cancel: PropTypes.arrayOf(PropTypes.number),
fix: PropType definition for keyCodes was incorrect
clauderic_react-sortable-hoc
train
js
4b69bb84365a557ac586046416242f4d046b42ac
diff --git a/.jsdoc.js b/.jsdoc.js index <HASH>..<HASH> 100644 --- a/.jsdoc.js +++ b/.jsdoc.js @@ -31,7 +31,8 @@ module.exports = { source: { excludePattern: '(^|\\/|\\\\)[._]', include: [ - 'src' + 'src', + 'protos' ], includePattern: '\\.js$' }, @@ -42,7 +43,7 @@ module.exports = { systemName: 'googleapis', theme: 'lumen', default: { - "outputSourceFiles": false + outputSourceFiles: false } }, markdown: {
chore: update .jsdoc.js by add protos and remove double quotes (#<I>)
googleapis_google-api-nodejs-client
train
js