content_type stringclasses 8
values | main_lang stringclasses 7
values | message stringlengths 1 50 | sha stringlengths 40 40 | patch stringlengths 52 962k | file_count int64 1 300 |
|---|---|---|---|---|---|
Javascript | Javascript | fix typescript regression | a1cfefe821d712eaa3af16353e20e9f7f9dea12b | <ide><path>lib/util/registerExternalSerializer.js
<ide> const {
<ide> SourceMapSource
<ide> } = require("webpack-sources");
<ide>
<add>/** @typedef {import("acorn").Position} Position */
<ide> /** @typedef {import("../Dependency").RealDependencyLocation} RealDependencyLocation */
<ide> /** @typedef {import("../Depend... | 1 |
Javascript | Javascript | simplify fs.promises warning logic | 7ac939e106bf8d878f6e193bfef317f9bd237551 | <ide><path>lib/fs.js
<ide> const {
<ide> validateUint32
<ide> } = require('internal/validators');
<ide>
<del>let promisesWarn = true;
<ide> let truncateWarn = true;
<ide> let fs;
<ide>
<ide> // Lazy loaded
<del>let promises;
<add>let promises = null;
<ide> let watchers;
<ide> let ReadFileContext;
<ide> let ReadStre... | 1 |
PHP | PHP | fix php notice when collation not set | e09d045e77189342e93d14674808d76a6ffc8ea3 | <ide><path>src/Illuminate/Database/Connectors/MySqlConnector.php
<ide> protected function configureEncoding($connection, array $config)
<ide> */
<ide> protected function getCollation(array $config)
<ide> {
<del> return ! is_null($config['collation']) ? " collate '{$config['collation']}'" : '';
<add>... | 1 |
Go | Go | rectify type defination for swarmrouter | ac5d86a672c9b46f2c26540690fcbd92c25715dc | <ide><path>api/server/router/swarm/cluster.go
<ide> import (
<ide> "github.com/docker/docker/daemon"
<ide> )
<ide>
<del>// buildRouter is a router to talk with the build controller
<add>// swarmRouter is a router to talk with the build controller
<ide> type swarmRouter struct {
<ide> backend Backend
<ide> routes [... | 1 |
Mixed | Ruby | return unfrozen strings from to_sentence | 97d428b790f27a79f6cc2ea848fbb5eeba5de42d | <ide><path>activesupport/CHANGELOG.md
<add>* `Array#to_sentence` no longer returns a frozen string.
<add>
<add> Before:
<add> ['one', 'two'].to_sentence.frozen?
<add> # => true
<add>
<add> After:
<add> ['one', 'two'].to_sentence.frozen?
<add> # => false
<add>
<add> *Nicolas Dular*... | 3 |
Text | Text | highlight additional change in tutorial12.js | 24f523a351839496577c6566d8c7f859c75f5a0c | <ide><path>docs/docs/tutorial.md
<ide> So far, each component has rendered itself once based on its props. `props` are
<ide>
<ide> When the server fetches data, we will be changing the comment data we have. Let's add an array of comment data to the `CommentBox` component as its state:
<ide>
<del>```javascript{3-5}
<a... | 1 |
Javascript | Javascript | remove annoying space | 03c812a407f19c683268c50507be58866f1982d9 | <ide><path>lib/formatOutput.js
<ide> module.exports = function(stats, options) {
<ide> });
<ide> Object.keys(stats.fileSizes).forEach(function(file) {
<ide> var name = fileChunkNames[file] && fileChunkNames[file].join(" ") || "";
<del> var fileLine = sprintf("%" + maxLenChunkname + "s", name) + c("\033[1m") + ... | 1 |
Python | Python | add drop_last arg for data loader | 0e1869cc286d607f1598506be7bd1312b76ca82c | <ide><path>src/transformers/trainer.py
<ide> def get_train_dataloader(self) -> DataLoader:
<ide> batch_size=self.args.train_batch_size,
<ide> sampler=train_sampler,
<ide> collate_fn=self.data_collator.collate_batch,
<add> drop_last=self.args.dataloader_drop_last,
<ide> ... | 2 |
Javascript | Javascript | simplify an option hook | cab18353a62d39699310bf8c982e897c391411a1 | <ide><path>src/attributes/val.js
<ide> jQuery.extend({
<ide>
<ide> while ( i-- ) {
<ide> option = options[ i ];
<del> if ( (option.selected = jQuery.inArray( jQuery(option).val(), values ) >= 0) ) {
<add> if ( (option.selected = jQuery.inArray( option.value, values ) >= 0) ) {
<ide> optionSet = ... | 1 |
PHP | PHP | add an integration test | 1312bde85ea4802a1b48d0ea712a9a8444dd1f0e | <ide><path>Cake/Test/TestCase/Model/Behavior/TimestampBehaviorTest.php
<ide> use Cake\Event\Event;
<ide> use Cake\Model\Behavior\TimestampBehavior;
<ide> use Cake\ORM\Entity;
<add>use Cake\ORM\TableRegistry;
<ide> use Cake\TestSuite\TestCase;
<ide>
<ide> /**
<ide> * Behavior test case
<ide> */
<ide> class TimestampB... | 1 |
Go | Go | keep a consistent view of containers rendered | eed4c7b73f0cf98cf48943da1c082f3210b28c82 | <ide><path>container/container_unix.go
<ide> func (container *Container) ConfigMounts() []Mount {
<ide> return mounts
<ide> }
<ide>
<del>// UpdateContainer updates configuration of a container.
<add>// UpdateContainer updates configuration of a container. Callers must hold a Lock on the Container.
<ide> func (contain... | 13 |
Python | Python | improve node image detection | 1e3d3cbc6fcc6f3cc862da31b9e17ca5450b95f6 | <ide><path>libcloud/compute/drivers/gce.py
<ide> def _to_node(self, node):
<ide> extra['canIpForward'] = node.get('canIpForward')
<ide> extra['serviceAccounts'] = node.get('serviceAccounts', [])
<ide> extra['scheduling'] = node.get('scheduling', {})
<add> extra['boot_disk'] = None
<ide>
... | 1 |
Text | Text | fix typo in fast-refresh.md | 24f056c9b3e18ccfca26272234fa231a8411f77a | <ide><path>docs/basic-features/fast-refresh.md
<ide> Sometimes, this can lead to unexpected results. For example, even a `useEffect`
<ide> with an empty array of dependencies would still re-run once during Fast Refresh.
<ide>
<ide> However, writing code resilient to occasional re-running of `useEffect` is a good pract... | 1 |
Go | Go | move daemon config directory | 9ed4400baf21528644c608eeda24fda081dfc4f2 | <ide><path>docker/daemon.go
<ide> import (
<ide> "io"
<ide> "os"
<ide> "path/filepath"
<del> "runtime"
<ide> "strings"
<ide> "time"
<ide>
<ide> func shutdownDaemon(d *daemon.Daemon, timeout time.Duration) {
<ide> logrus.Error("Force shutdown daemon")
<ide> }
<ide> }
<del>
<del>func getDaemonConfDir() string {
... | 3 |
Text | Text | clarify details on connecting with react | 64fee67e29f465efde40ea0df5668b16a2741601 | <ide><path>docs/basics/UsageWithReact.md
<ide> const Footer = () => (
<ide> export default Footer
<ide> ```
<ide>
<del>#### `components/App.js`
<del>
<del>```js
<del>import React from 'react'
<del>import Footer from './Footer'
<del>import AddTodo from '../containers/AddTodo'
<del>import VisibleTodoList from '../contai... | 1 |
Go | Go | add config apis | 772855768785ce678751795c168e056a8db35d09 | <ide><path>api/server/router/swarm/backend.go
<ide> type Backend interface {
<ide> Update(uint64, types.Spec, types.UpdateFlags) error
<ide> GetUnlockKey() (string, error)
<ide> UnlockSwarm(req types.UnlockRequest) error
<add>
<ide> GetServices(basictypes.ServiceListOptions) ([]types.Service, error)
<ide> GetServi... | 12 |
Javascript | Javascript | add test for async contexts in performanceobserver | ef0f5b185d318c48f4331797e7be86241d676902 | <ide><path>test/parallel/test-performanceobserver-asynccontext.js
<add>'use strict';
<add>
<add>const common = require('../common');
<add>const assert = require('assert');
<add>const {
<add> performance,
<add> PerformanceObserver,
<add>} = require('perf_hooks');
<add>const {
<add> executionAsyncId,
<add> triggerAsy... | 1 |
PHP | PHP | add setresult() to query | c6a5ab0a08bea76f8aca61182e11902b4af9b25c | <ide><path>lib/Cake/ORM/Query.php
<ide> class Query extends DatabaseQuery {
<ide> 'matching' => 1
<ide> ];
<ide>
<add>/**
<add> * A hydrated ResultSet.
<add> *
<add> * @var Cake\ORM\ResultSet
<add> * @see setResult()
<add> */
<add> protected $_results;
<add>
<ide> /**
<ide> * Returns the default table object that ... | 2 |
Javascript | Javascript | add weekdaysmin (dd format) and tests | f47cb47a8990ccd731faa4d9b22413d1db995069 | <ide><path>lang/ca.js
<ide> monthsShort : "Gen._Febr._Mar._Abr._Mai._Jun._Jul._Ag._Set._Oct._Nov._Des.".split("_"),
<ide> weekdays : "Diumenge_Dilluns_Dimarts_Dimecres_Dijous_Divendres_Dissabte".split("_"),
<ide> weekdaysShort : "Dg._Dl._Dt._Dc._Dj._Dv._Ds.".split("_"),
<add> ... | 74 |
Python | Python | build morphologizer in setup.py | 031b0d2a3ad5bd8b9a432acb857b4babbc153923 | <ide><path>setup.py
<ide> 'spacy.attrs',
<ide> 'spacy.morphology',
<ide> 'spacy.pipeline',
<add> 'spacy._morphologizer',
<ide> 'spacy.syntax.stateclass',
<ide> 'spacy.syntax._state',
<ide> 'spacy.tokenizer', | 1 |
Javascript | Javascript | fix runtime config in `next export` | bd249180c67e96e609bff92fe3e751015a94861f | <ide><path>packages/next/export/index.js
<ide> import { resolve, join } from 'path'
<ide> import { existsSync, readFileSync } from 'fs'
<ide> import loadConfig from 'next-server/next-config'
<ide> import { PHASE_EXPORT, SERVER_DIRECTORY, PAGES_MANIFEST, CONFIG_FILE, BUILD_ID_FILE, CLIENT_STATIC_FILES_PATH } from 'next-... | 6 |
Javascript | Javascript | create bidi closure | 3b297368820b22738b5000a7ca291634209719c5 | <ide><path>src/bidi.js
<ide>
<ide> 'use strict';
<ide>
<del>// Character types for symbols from 0000 to 00FF.
<del>var baseTypes = [
<del> 'BN', 'BN', 'BN', 'BN', 'BN', 'BN', 'BN', 'BN', 'BN', 'S', 'B', 'S', 'WS',
<del> 'B', 'BN', 'BN', 'BN', 'BN', 'BN', 'BN', 'BN', 'BN', 'BN', 'BN', 'BN', 'BN',
<del> 'BN', 'BN', ... | 1 |
Go | Go | remove unused netnsroot field in builder-next | 8ab9e78ee4ddcffdb91d106948ed3fb6fb322b1e | <ide><path>builder/builder-next/builder.go
<ide> func init() {
<ide> type Opt struct {
<ide> SessionManager *session.Manager
<ide> Root string
<del> NetnsRoot string
<ide> Dist images.DistributionServices
<ide> NetworkController libnetwork.NetworkController
<ide> }
<ide><path>bu... | 5 |
Text | Text | add tag variant for 2.3 | 4d1ba6feb414177457fcec5983038216e32f1a12 | <ide><path>website/docs/api/cli.md
<ide> $ python -m spacy init-model [lang] [output_dir] [--jsonl-loc] [--vectors-loc]
<ide> [--prune-vectors]
<ide> ```
<ide>
<del>| Argument | Type | Description ... | 1 |
Ruby | Ruby | fix default samesite for session cookies | c95780d7c665553dc7e86d5fa4eb3a84478f1e25 | <ide><path>actionpack/lib/action_dispatch/middleware/cookies.rb
<ide> def cookies_serializer
<ide> end
<ide>
<ide> def cookies_same_site_protection
<del> get_header(Cookies::COOKIES_SAME_SITE_PROTECTION) || Proc.new { }
<add> get_header(Cookies::COOKIES_SAME_SITE_PROTECTION)&.call(self)
<ide> end... | 4 |
Javascript | Javascript | skip the windows path test for now | b2b702158213092d73615f1f75b20dd6df0ddec9 | <ide><path>test/NormalModule.test.js
<ide> describe("NormalModule", function() {
<ide> }).should.eql("../userRequest!../other/userRequest!../thing/is/off/here");
<ide> });
<ide> });
<del>
<del> describe("when running on a windows machine", function() {
<del> let sep;
<del> beforeEach(function() {
<del> ... | 1 |
Python | Python | set version to v2.1.0a8 | 7d529ebdfb45fa0e624fe3f5dfd218e14c955c48 | <ide><path>spacy/about.py
<ide> # fmt: off
<ide>
<ide> __title__ = "spacy-nightly"
<del>__version__ = "2.1.0a8.dev1"
<add>__version__ = "2.1.0a8"
<ide> __summary__ = "Industrial-strength Natural Language Processing (NLP) with Python and Cython"
<ide> __uri__ = "https://spacy.io"
<ide> __author__ = "Explosion AI"
<ide>... | 1 |
Python | Python | fix tokenizer exceptions | 615dba9d99df0cd25fbecd8d58b19371da59a719 | <ide><path>spacy/lang/ky/tokenizer_exceptions.py
<ide> from ..tokenizer_exceptions import BASE_EXCEPTIONS
<del>from ...symbols import ORTH, LEMMA, NORM
<add>from ...symbols import ORTH, NORM
<ide> from ...util import update_exc
<ide>
<ide> _exc = {}
<ide>
<ide> _abbrev_exc = [
<ide> # Weekdays abbreviations
<del>... | 1 |
Python | Python | fix tf-idf again | 936360020cbd9e9e174c47554c49bfc9c96898f3 | <ide><path>keras/preprocessing/text.py
<ide> def sequences_to_matrix(self, sequences, mode='binary'):
<ide> # Use weighting scheme 2 in
<ide> # https://en.wikipedia.org/wiki/Tf%E2%80%93idf
<ide> tf = 1 + np.log(c)
<del> df = np.log(1 + sel... | 1 |
Javascript | Javascript | add thai language support | dff274ffb5db889164db04df24dc12b4ec85ab8c | <ide><path>lang/th.js
<add>// moment.js language configuration
<add>// language : thai (th)
<add>// author : Kridsada Thanabulpong : https://github.com/sirn
<add>(function () {
<add> var lang = {
<add> months : "มกราคม_กุมภาพันธ์_มีนาคม_เมษายน_พฤษภาคม_มิถุนายน_กรกฎาคม_สิงหาคม_กันยายน_ตุลาคม_พฤศจิกายน_ธันว... | 2 |
Javascript | Javascript | fix promise.wait() for fired promises | 490cac0d7e9b455de74eb6038e555a60a2fafe13 | <ide><path>src/node.js
<ide> var eventsModule = createInternalModule('events', function (exports) {
<ide> var ret;
<ide> var hadError = false;
<ide>
<add> if (this.hasFired) {
<add> ret = (this._values.length == 1)
<add> ? this._values[0]
<add> : this.values;
<add>
<add> if (this... | 1 |
Text | Text | add note for wikisplit | f3312515b7cf66de65b71b623a4cb719517d4fc0 | <ide><path>model_cards/google/roberta2roberta_L-24_wikisplit/README.md
<ide> Disclaimer: The model card has been written by the Hugging Face team.
<ide>
<ide> You can use this model for sentence splitting, *e.g.*
<ide>
<add>**IMPORTANT**: The model was not trained on the `"` (double quotation mark) character -> so th... | 1 |
Python | Python | use simple git clone call if not sparse | a0fb5e50dbb1e24901f7b1470ee53cc6bce7a4d6 | <ide><path>spacy/cli/_util.py
<ide> def git_checkout(
<ide> msg.fail("Destination of checkout must not exist", exits=1)
<ide> if not dest.parent.exists():
<ide> raise IOError("Parent of destination of checkout must exist")
<add>
<add> if sparse and git_version >= (2, 22):
<add> return git_... | 1 |
Java | Java | remove trailing whitespace in java source code | b6c0e7cba3de036b96fb84c8893cdd0ac316194e | <ide><path>spring-core/src/test/java/org/springframework/util/AntPathMatcherTests.java
<ide> public void patternComparator() {
<ide>
<ide> // longer is better
<ide> assertEquals(1, comparator.compare("/hotels", "/hotels2"));
<del>
<add>
<ide> //SPR-13139
<ide> assertEquals(-1, comparator.compare("*", "*/**"))... | 4 |
Python | Python | add test to catch imports at flask instantiation | 26a9c2079d77aba93dde6f95472f3d89d2d9783d | <ide><path>flask/testsuite/helpers.py
<ide> def post(self):
<ide> '/myview/create')
<ide>
<ide>
<add>class NoImportsTestCase(FlaskTestCase):
<add> "Test Flasks are created without __import__."
<add>
<add> def test_name_with_import_error(self):
<add> try:
<add> fla... | 2 |
Javascript | Javascript | use strict equalities in src/core/jbig2.js | 4899e9e54fb8af24d25367d283662afcfcf215f5 | <ide><path>src/core/jbig2.js
<ide> var Jbig2Image = (function Jbig2ImageClosure() {
<ide> firstS += deltaFirstS;
<ide> var currentS = firstS;
<ide> do {
<del> var currentT = (stripSize == 1 ? 0 :
<add> var currentT = (stripSize === 1 ? 0 :
<ide> decodeInteger(cont... | 1 |
Javascript | Javascript | add fixer for no-let-in-for-declaration | 04ffa36e2307ede5a5d94afc3cca659b70fb4011 | <ide><path>test/parallel/test-eslint-no-let-in-for-declaration.js
<ide> ruleTester.run('no-let-in-for-declaration', rule, {
<ide> invalid: [
<ide> {
<ide> code: 'for (let foo = 1;;);',
<add> output: 'for (var foo = 1;;);',
<ide> errors: [{ message }]
<ide> },
<ide> {
<ide> code: 'fo... | 2 |
Python | Python | fix paramiko tests on python 2.7 | 987a22d7c384c8fff4a0a02ec4d1f6f93d043e7d | <ide><path>libcloud/__init__.py
<ide>
<ide> :var __version__: Current version of libcloud
<ide> """
<add>import logging
<ide> import os
<ide> import codecs
<ide>
<ide> def _init_once():
<ide> enable_debug(fo)
<ide>
<ide> if have_paramiko:
<del> paramiko.common.logging.basicConfig(level=par... | 2 |
Python | Python | fix syntaxerror on 2.5 in call to print_exception | 1f2113c2c3677fd3eed2b8eb2c08c7e7271cd09a | <ide><path>celery/utils/threads.py
<ide> def body(self):
<ide>
<ide> def on_crash(self, exc_info, msg, *fmt, **kwargs):
<ide> sys.stderr.write((msg + "\n") % fmt)
<del> traceback.print_exception(*exc_info, file=sys.stderr)
<add> traceback.print_exception(exc_info[0],
<add> ... | 2 |
Text | Text | add faq about guide articles | 7deecf8245148dca8703953955462b58ff90e1d3 | <ide><path>CONTRIBUTING.md
<ide> Essentially, we expect basic familiarity with some of the aforementioned technol
<ide>
<ide> ## Frequently Asked Questions
<ide>
<add>### Where are the Guide articles (guide.freecodecamp.org)? How can I contribute to them?
<add>
<add>We will not have the general guide articles anymore... | 1 |
PHP | PHP | fix auth class comments | b8e534a117596c078b46a8c14d5f3226f62420ee | <ide><path>system/auth.php
<ide> public static function user()
<ide> * by the Hash class when authenticating.
<ide> *
<ide> * <code>
<del> * if (Auth::login('test@gmail.com', 'secret'))
<add> * if (Auth::attempt('test@gmail.com', 'secret'))
<ide> * {
<ide> * // The credentials are valid...
<ide> * } | 1 |
Ruby | Ruby | write the code in a more natural way | 2c89d1dda4077b2a99ddcced59bdd7a9a21b39a0 | <ide><path>actionpack/lib/action_dispatch/journey/nodes/node.rb
<ide> def to_sym
<ide> end
<ide>
<ide> def name
<del> -(left.tr "*:", "")
<add> -left.tr("*:", "")
<ide> end
<ide>
<ide> def type
<ide> class Symbol < Terminal # :nodoc:
<ide> def initialize(left)... | 1 |
Javascript | Javascript | improve zlib errors | da886d9a4cd923bd5fc33eff7df22ff7d855a00b | <ide><path>lib/zlib.js
<ide> function flushCallback(level, strategy, callback) {
<ide> }
<ide> }
<ide>
<add>// 1. Returns false for undefined and NaN
<add>// 2. Returns true for finite numbers
<add>// 3. Throws ERR_INVALID_ARG_TYPE for non-numbers
<add>// 4. Throws ERR_OUT_OF_RANGE for infinite numbers
<add>function... | 4 |
Javascript | Javascript | remove the use of fs.access (#625) | 6d6ef1ca9fc4f0fb0dc400619232f51b53df9901 | <ide><path>server/render.js
<ide> import { join } from 'path'
<ide> import { createElement } from 'react'
<ide> import { renderToString, renderToStaticMarkup } from 'react-dom/server'
<del>import fs from 'mz/fs'
<ide> import send from 'send'
<ide> import accepts from 'accepts'
<ide> import requireModule from './require... | 1 |
Javascript | Javascript | fix util.inspect with proxied function | 6c7c77ef05a04ffa5532056f8a1ea44a946c2014 | <ide><path>lib/internal/util/inspect.js
<ide> function formatRaw(ctx, value, recurseTimes) {
<ide> }
<ide> } else if (typeof value === 'function') {
<ide> const type = constructor || tag || 'Function';
<del> const name = `${type}${value.name ? `: ${value.name}` : ''}`;
<add> let name = `${type... | 2 |
Javascript | Javascript | fix eslint issues | c987968dd9796ea90462f9d54e0d3cf81e981920 | <ide><path>node-tests/blueprints/acceptance-test-test.js
<ide> describe('Blueprint: acceptance-test', function() {
<ide>
<ide> describe('with ember-mocha@0.14.0', function() {
<ide> beforeEach(function() {
<del> modifyPackages([
<del> { name: 'ember-qunit', delete: true },
<del> { na... | 16 |
Text | Text | add article for javascript string.tostring() | e40c55b02a6fea72c55a080953f145f076ae7d15 | <ide><path>guide/english/javascript/standard-objects/string/string-prototype-tostring/index.md
<ide> title: String.prototype.toString
<ide> ---
<ide> ## String.prototype.toString
<ide>
<del>This is a stub. <a href='https://github.com/freecodecamp/guides/tree/master/src/pages/javascript/standard-objects/string/string-p... | 1 |
Javascript | Javascript | avoid dynamic dispatch for scheduler calls | 02404d793b84c057e0f3f712f8ce565f81d4b7ab | <ide><path>packages/react-art/src/ReactARTHostConfig.js
<ide> * LICENSE file in the root directory of this source tree.
<ide> */
<ide>
<del>import {
<del> unstable_scheduleCallback as scheduleDeferredCallback,
<del> unstable_cancelCallback as cancelDeferredCallback,
<del>} from 'scheduler';
<del>export {
<del> un... | 5 |
Ruby | Ruby | handle homebrew_no_github_api case | cbb91c5516ac6d2a673670edf5b7d509abe6df56 | <ide><path>Library/Homebrew/exceptions.rb
<ide> def dump
<ide> end
<ide> end
<ide> puts
<del> unless RUBY_VERSION < "1.8.7" || issues.empty?
<add> if RUBY_VERSION >= "1.8.7" && issues && issues.any?
<ide> puts "These open issues may also help:"
<ide> puts issues.map { |i| "#{i["title"]} ... | 1 |
PHP | PHP | fix bug and add regression test | 2704bace3a7187205db03d55f6e8304743eb8396 | <ide><path>src/Illuminate/Http/JsonResponse.php
<ide>
<ide> class JsonResponse extends \Symfony\Component\HttpFoundation\JsonResponse {
<ide>
<del> /**
<del> * The json encoding options.
<del> *
<del> * @var int
<del> */
<del> protected $jsonOptions;
<del>
<ide> /**
<ide> * Constructor.
<ide> *
<ide> public ... | 2 |
Javascript | Javascript | fix priority inference of next level of work | ce126fbb231f9110151b4c93cff765fd882a9f64 | <ide><path>packages/react-reconciler/src/ReactFiberExpirationTime.js
<ide> export function inferPriorityFromExpirationTime(
<ide> return IdlePriority;
<ide> }
<ide> const msUntil =
<del> msToExpirationTime(expirationTime) - msToExpirationTime(currentTime);
<add> expirationTimeToMs(expirationTime) - expira... | 2 |
PHP | PHP | fix style issue | 2bcdbb0d13e3d9d7bcbc5ba20c4ddead67cf77fc | <ide><path>src/Illuminate/Database/Query/Grammars/SqlServerGrammar.php
<ide> protected function compileAnsiOffset(Builder $query, $components)
<ide> // As this moves the order statement to be part of the "select" statement, we need to
<ide> // move the bindings to the right position: right after "select... | 1 |
Javascript | Javascript | add maintemplateplugin tests | ecb63b9742c218ee01dfad2f43ef19e873af43cb | <ide><path>test/AmdMainTemplatePlugin.test.js
<add>var should = require("should");
<add>var sinon = require("sinon");
<add>var TemplatePluginEnvironment = require("./helpers/TemplatePluginEnvironment");
<add>var ConcatSource = require("webpack-sources").ConcatSource;
<add>var AmdMainTemplatePlugin = require("../lib/Amd... | 3 |
Go | Go | enable docker run -it | 3839e3a0f63c8acc4cb11a87b862f159e5b2aedc | <ide><path>pkg/mflag/example/example.go
<ide> func main() {
<ide> fmt.Printf("b: %b\n", b)
<ide> fmt.Printf("-bool: %b\n", b2)
<ide> fmt.Printf("s/#hidden/-string(via lookup): %s\n", flag.Lookup("s").Value.String())
<add> fmt.Printf("ARGS: %v\n", flag.Args())
<ide> }
<ide><path>pkg/mflag/flag.go
<ide> import (
<ide>... | 2 |
PHP | PHP | pass status when redirecting to route | 0b3ecf8973acc1fe8d0e409458b97b0f38a4ba8b | <ide><path>laravel/redirect.php
<ide> public static function __callStatic($method, $parameters)
<ide> {
<ide> $parameters = (isset($parameters[0])) ? $parameters[0] : array();
<ide>
<add> $status = (isset($parameters[1])) ? $parameters[1] : 302;
<add>
<ide> if (strpos($method, 'to_secure_') === 0)
<ide> {
<del... | 1 |
Text | Text | remove leading slash from path | 1b9e2bc5aa10813bc91c621aef5d1f5c62495123 | <ide><path>guides/source/engines.md
<ide> However, because you are developing the `blorgh` engine on your local machine,
<ide> you will need to specify the `:path` option in your `Gemfile`:
<ide>
<ide> ```ruby
<del>gem 'blorgh', path: "/path/to/blorgh"
<add>gem 'blorgh', path: "path/to/blorgh"
<ide> ```
<ide>
<ide> T... | 1 |
Javascript | Javascript | add test case for delegatedmodule#updatehash | 5cb7bfa81f100953e520d195ee54eac644b1bc3c | <ide><path>test/DelegatedModule.test.js
<add>/* globals describe, it, beforeEach */
<add>"use strict";
<add>require("should");
<add>const DelegatedModule = require("../lib/DelegatedModule");
<add>
<add>describe("DelegatedModule", function() {
<add> describe("#updateHash", function() {
<add> const sourceRequest = "dll-... | 1 |
Mixed | Ruby | add where.associated to check association presence | ccdf6b8d42b2d32e0618870c87b1de83c06542c7 | <ide><path>activerecord/CHANGELOG.md
<add>* Add `where.associated` to check for the presence of an association.
<add>
<add> ```ruby
<add> # Before:
<add> account.users.joins(:contact).where.not(contact_id: nil)
<add>
<add> # After:
<add> account.users.where.associated(:contact)
<add> ```
<add>
<add>... | 3 |
Text | Text | add the word "programming" in the article | 12da60565a8b56864df4be08e7e3bf8029bef7fd | <ide><path>guide/english/python/if-elif-else-statements/index.md
<ide> title: If / Elif / Else Statements
<ide> ## If / Elif / Else Statements
<ide>
<ide> The `if`/`elif`/`else` structure is a common way to control the flow of a program, allowing you to execute specific blocks of code depending on the value of some da... | 1 |
Javascript | Javascript | ignore duplicate welcome "message" events | ba0aee5d71874202ebf8760a802bb1d6f2f61a5e | <ide><path>packages/react-devtools-extensions/src/backend.js
<ide>
<ide> 'use strict';
<ide>
<add>let welcomeHasInitialized = false;
<add>
<ide> function welcome(event) {
<ide> if (
<ide> event.source !== window ||
<ide> function welcome(event) {
<ide> return;
<ide> }
<ide>
<add> // In some circumstance... | 2 |
Python | Python | fix windows failure to remove temp file | ffca68fc86718b133668f341ddd8c2635d7e29ec | <ide><path>examples/flaskr/tests/test_flaskr.py
<ide>
<ide>
<ide> @pytest.fixture
<del>def app(request):
<del>
<del> db_fd, temp_db_location = tempfile.mkstemp()
<add>def app():
<add> db_fd, db_path = tempfile.mkstemp()
<ide> config = {
<del> 'DATABASE': temp_db_location,
<add> 'DATABASE': db_... | 1 |
Python | Python | increase test coverage | bbbd585f25c25ee6c0ab95af474c40a3bc427ddd | <ide><path>keras/backend/cntk_backend.py
<ide> def permute_dimensions(x, pattern):
<ide> return C.transpose(x, axis)
<ide>
<ide>
<del>def resize_images(X, height_factor, width_factor, data_format):
<add>def resize_images(x, height_factor, width_factor, data_format):
<ide> if data_format == 'channels_first':
<... | 3 |
Text | Text | fix reference to basicauthentication in settings | 4df1172665f6df3d4c4df53b4836e2c6ed462da5 | <ide><path>docs/api-guide/settings.md
<ide> Default:
<ide>
<ide> (
<ide> 'rest_framework.authentication.SessionAuthentication',
<del> 'rest_framework.authentication.UserBasicAuthentication'
<add> 'rest_framework.authentication.BasicAuthentication'
<ide> )
<ide>
<ide> ## DEFAULT_PERMISSIO... | 1 |
Javascript | Javascript | use primordials in domexception.js | 914d6c9ab8cd7154c075867f3894bd90b8e252ea | <ide><path>lib/internal/per_context/domexception.js
<ide> 'use strict';
<ide>
<del>// `per_context` scripts are executed before creating the primordials so we
<del>// cannot use them here.
<del>/* eslint-disable no-restricted-globals */
<add>const {
<add> SafeWeakMap,
<add> SafeMap,
<add> Object,
<add> Symbol
<add... | 1 |
Text | Text | use path where extensions are defined, not used | 9efab213d29adcc708cc08e8f45933223900fc70 | <ide><path>guides/source/active_support_core_extensions.md
<ide> NOTE: Defined in `active_support/core_ext/hash/indifferent_access.rb`.
<ide>
<ide> ### Compacting
<ide>
<del>The methods `compact` and `compact!` return a Hash without items with `nil` value.
<add>The methods `compact` and `compact!` return a Hash with... | 1 |
PHP | PHP | avoid php bug | cdd314ebdcf079ff5d2fd700d1670f0386b3f500 | <ide><path>src/I18n/Number.php
<ide> public static function formatter(array $options = []): NumberFormatter
<ide> /** @var \NumberFormatter $formatter */
<ide> $formatter = static::$_formatters[$locale][$type];
<ide>
<del> $options = array_intersect_key($options, [
<del> 'places' => n... | 1 |
Python | Python | simplify lstm example | 8c73c6f218abc2b7345bab8928e5c5bcf192f4d1 | <ide><path>examples/imdb_lstm.py
<ide> - LSTM loss decrease patterns during training can be quite different
<ide> from what you see with CNNs/MLPs/etc.
<ide> '''
<del>
<ide> from __future__ import print_function
<ide> import numpy as np
<ide> np.random.seed(1337) # for reproducibility
<ide>
<ide> print('Build model..... | 1 |
PHP | PHP | add missing onlastpage to cursorpaginator | dc724350ac1e9bf5491c6cc1e436b38f6f0973df | <ide><path>src/Illuminate/Pagination/CursorPaginator.php
<ide> public function onFirstPage()
<ide> return is_null($this->cursor) || ($this->cursor->pointsToPreviousItems() && ! $this->hasMore);
<ide> }
<ide>
<add> /**
<add> * Determine if the paginator is on the last page.
<add> *
<add> * @r... | 2 |
Javascript | Javascript | upgrade commonschunkplugin to es6 | 9215b6affd5d4ea485fa3f28eaa4ef6eae894172 | <ide><path>lib/optimize/CommonsChunkPlugin.js
<ide> MIT License http://www.opensource.org/licenses/mit-license.php
<ide> Author Tobias Koppers @sokra
<ide> */
<del>var nextIdent = 0;
<add>"use strict";
<add>let nextIdent = 0;
<ide>
<del>function CommonsChunkPlugin(options) {
<del> if(arguments.length > 1) {
<del> t... | 1 |
Java | Java | add log message to bridge init | e55cefc476e720dd3c3b1726f21d2b63ee41a19c | <ide><path>ReactAndroid/src/main/java/com/facebook/react/bridge/CatalystInstanceImpl.java
<ide> private CatalystInstanceImpl(
<ide> final JavaScriptModulesConfig jsModulesConfig,
<ide> final JSBundleLoader jsBundleLoader,
<ide> NativeModuleCallExceptionHandler nativeModuleCallExceptionHandler) {
<add>... | 1 |
Text | Text | add reference to nlp dataset | 0c55a384f86a41baad87b90faf865537f7844bf1 | <ide><path>model_cards/mrm8488/t5-base-finetuned-squadv2/README.md
<ide> ---
<ide> language: english
<del>thumbnail:
<add>datasets:
<add>- squad_v2
<ide> ---
<ide>
<ide> # T5-base fine-tuned on SQuAD v2
<ide> Transfer learning, where a model is first pre-trained on a data-rich task before
<ide>
<ide> ## Details of th... | 1 |
Javascript | Javascript | enable experimental cache api in www testrenderer | 61455a25b7d5783f398b0a463f45b9b8d14a6ed6 | <ide><path>packages/shared/forks/ReactFeatureFlags.testing.www.js
<ide> export const enableUpdaterTracking = false;
<ide> export const enableSuspenseServerRenderer = true;
<ide> export const enableSelectiveHydration = true;
<ide> export const enableLazyElements = false;
<del>export const enableCache = false;
<add>expor... | 1 |
Javascript | Javascript | fix french weekdaysmin | 9f9287508321647ae2897f48bf4e4a1a7275fe23 | <ide><path>lang/fr.js
<ide> monthsShort : "janv._févr._mars_avr._mai_juin_juil._août_sept._oct._nov._déc.".split("_"),
<ide> weekdays : "dimanche_lundi_mardi_mercredi_jeudi_vendredi_samedi".split("_"),
<ide> weekdaysShort : "dim._lun._mar._mer._jeu._ven._sam.".split("_"),
<del> ... | 4 |
Javascript | Javascript | use array push chunk format for web workers too | e5ba0356f5c446c233a2274b7d33fea30cb88db0 | <ide><path>lib/webworker/ImportScriptsChunkLoadingRuntimeModule.js
<ide> class ImportScriptsChunkLoadingRuntimeModule extends RuntimeModule {
<ide> const {
<ide> chunk,
<ide> compilation: {
<add> runtimeTemplate,
<ide> outputOptions: { globalObject, chunkLoadingGlobal, hotUpdateGlobal }
<ide> }
<ide> ... | 2 |
Python | Python | remove dag parsing from db init command | 8079b4cb69eff3d04a00d897a76e182b575c754c | <ide><path>airflow/utils/db.py
<ide> def initdb(session: Session = NEW_SESSION):
<ide>
<ide> with create_global_lock(session=session, lock=DBLocks.MIGRATIONS):
<ide>
<del> dagbag = DagBag()
<del> # Save DAGs in the ORM
<del> dagbag.sync_to_db(session=session)
<del>
<del> # Deactivate t... | 2 |
Python | Python | fix math block in hermmulx, lagmulx | 927feff8788f27f29e76e803f187a4c041098ced | <ide><path>numpy/polynomial/hermite.py
<ide> def hermmulx(c):
<ide>
<ide> .. math::
<ide>
<del> xP_i(x) = (P_{i + 1}(x)/2 + i*P_{i - 1}(x))
<add> xP_i(x) = (P_{i + 1}(x)/2 + i*P_{i - 1}(x))
<ide>
<ide> Examples
<ide> --------
<ide><path>numpy/polynomial/hermite_e.py
<ide> def hermemulx(c):
<ide... | 3 |
Go | Go | add resize endpoint to api | 70d2123efda0e92760b96b03ce27cb4f1fb61cb3 | <ide><path>api.go
<ide> func writeJson(w http.ResponseWriter, b []byte) {
<ide> w.Write(b)
<ide> }
<ide>
<add>// FIXME: Use stvconv.ParseBool() instead?
<ide> func getBoolParam(value string) (bool, error) {
<ide> if value == "1" || strings.ToLower(value) == "true" {
<ide> return true, nil
<ide> func postContainers... | 3 |
Python | Python | fix bug with m2m in browseable api | aa72f8d63d2a7b33a2e74eaba216b56c803af70c | <ide><path>rest_framework/renderers.py
<ide> from rest_framework.utils import encoders
<ide> from rest_framework.utils.breadcrumbs import get_breadcrumbs
<ide> from rest_framework import VERSION, status
<del>from rest_framework import serializers, parsers
<add>from rest_framework import parsers
<ide>
<ide>
<ide> clas... | 3 |
PHP | PHP | fix failing test | fcb7714e2e8dfc355f2d0f78b6b9d38e6b8ebf2c | <ide><path>lib/Cake/Test/Case/Controller/Component/EmailComponentTest.php
<ide> public function testMessageId() {
<ide> $this->assertTrue($this->Controller->EmailTest->send('This is the body of the message'));
<ide> $result = DebugCompTransport::$lastEmail;
<ide>
<del> $this->assertRegExp('/Message-ID: \<[a-f0-9]... | 1 |
Ruby | Ruby | reword formula up to date message | 2d99bc39723aeece8533e5b4f4314165a548420a | <ide><path>Library/Homebrew/dev-cmd/bump.rb
<ide> def bump
<ide> end
<ide>
<ide> if requested_formula && outdated_repology_packages.nil?
<del> ohai "The requested formula, #{requested_formula}, is up-to-date."
<add> ohai "#{requested_formula} is up-to-date!"
<ide> puts "Current version: #{get_f... | 1 |
Ruby | Ruby | fix touch and update_column/s for readonly records | 0c508aeb61e746f0e8cd4fc492ee56b1c6048181 | <ide><path>activerecord/lib/active_record/persistence.rb
<ide> def update_column(name, value)
<ide> def update_columns(attributes)
<ide> raise ActiveRecordError, "cannot update a new record" if new_record?
<ide> raise ActiveRecordError, "cannot update a destroyed record" if destroyed?
<add> _raise_... | 2 |
PHP | PHP | add additional file tests | d2839b190ff589868a5d269146e974ccc07a4c86 | <ide><path>tests/TestCase/Http/ServerRequestTest.php
<ide> public function testFilesObject()
<ide> $this->assertSame(['avatar' => $file], $request->getUploadedFiles());
<ide> }
<ide>
<add> /**
<add> * Test passing an invalid data type for the files list.
<add> *
<add> * @return void
<add> ... | 1 |
PHP | PHP | fix calls to sortby revealed by hhvm tests | de713c4c907170b88334aaf110d99bca28fef502 | <ide><path>src/Illuminate/Support/Collection.php
<ide> public function sortBy(Closure $callback, $options = SORT_REGULAR, $descending =
<ide> return $this;
<ide> }
<ide>
<add> /**
<add> * Sort the collection in descending order using the given Closure.
<add> *
<add> * @param \Closure $callback
<add> * @param ... | 2 |
Python | Python | fix merge conflict | e846f57b57f70d93d7ff4d18e12bda32f921e9da | <ide><path>libcloud/common/dimensiondata.py
<ide> """
<ide> from base64 import b64encode
<ide> from time import sleep
<add>from distutils.version import LooseVersion, StrictVersion
<ide> from libcloud.utils.py3 import httplib
<ide> from libcloud.utils.py3 import b
<ide> from libcloud.common.base import ConnectionUserAn... | 1 |
Javascript | Javascript | remove `extern` option | 8fc3b48c65820f7a66d0154002c47014a69cef8a | <ide><path>packager/src/JSTransformer/worker/__tests__/worker-test.js
<ide> describe('code transformation worker:', () => {
<ide> }
<ide> );
<ide>
<del> it('does not extract requires if files are marked as "extern"', done => {
<del> const opts = {extern: true};
<del> transformCode(transformer, '... | 5 |
Ruby | Ruby | remove deprecated dispatch test | b8f3b262e091ad31f2aa2859e58bed541eeca8ec | <ide><path>railties/test/application/rackup_test.rb
<ide> def setup
<ide> assert_kind_of Rails::Application, Rails.application
<ide> end
<ide>
<del> # Passenger still uses AC::Dispatcher, so we need to
<del> # keep it working for now
<del> test "deprecated ActionController::Dispatcher still works" d... | 1 |
Ruby | Ruby | fix typo asser url [ci skip] | b0e17b9af4b98e279ca380d52f5daee2db5c6540 | <ide><path>actionview/lib/action_view/helpers/asset_url_helper.rb
<ide> def javascript_path(source, options = {})
<ide>
<ide> # Computes the full URL to a JavaScript asset in the public javascripts directory.
<ide> # This will use +javascript_path+ internally, so most of their behaviors will be the same.
<... | 1 |
Javascript | Javascript | allow nested @media | b5c0c1964fbd71ac14061b481c0f65e156d1082c | <ide><path>lib/css/CssParser.js
<ide> class CssParser extends Parser {
<ide> },
<ide> atKeyword: (input, start, end) => {
<ide> const name = input.slice(start, end);
<del> if (mode !== CSS_MODE_TOP_LEVEL) {
<del> throw new Error(
<del> `Unexpected ${name} at ${start} during ${explainMode(mode)}`
<... | 1 |
Python | Python | use return dict for rag encoder | 5f7a07c0c867abedbb3ebf135915eeee56add24b | <ide><path>src/transformers/models/rag/modeling_rag.py
<ide> def generate(
<ide> batch_size = context_input_ids.shape[0] // n_docs
<ide>
<ide> encoder = self.rag.generator.get_encoder()
<del> encoder_outputs = encoder(input_ids=context_input_ids, attention_mask=context_attention_mask)
<add> ... | 1 |
Python | Python | apply suggestions from code review | 3a573b5c601bae21aa6c9a4fd0716b27320f69c9 | <ide><path>numpy/core/function_base.py
<ide> def linspace(start, stop, num=50, endpoint=True, retstep=False, dtype=None,
<ide> _mult_inplace = _nx.isscalar(delta)
<ide> step = delta / div
<ide> any_step_zero = (
<del> step == 0 if _mult_inplace else _nx.asarray(step == 0).any())
<add>... | 1 |
Text | Text | add a section about job testing [ci skip] | 98626e27c1bd4f55915dbf94a24868785638094d | <ide><path>guides/source/testing.md
<ide> end
<ide> Moreover, since the test class extends from `ActionView::TestCase`, you have
<ide> access to Rails' helper methods such as `link_to` or `pluralize`.
<ide>
<add>Testing Jobs
<add>------------
<add>
<add>Since your custom jobs can be queued at different levels inside y... | 1 |
Java | Java | remove references to csslayoutdeprecated | 2030c783556e4338c0f64f85771a3725b3f6f84b | <ide><path>ReactAndroid/src/main/java/com/facebook/react/flat/FlatARTSurfaceViewManager.java
<ide>
<ide> import com.facebook.yoga.YogaMeasureMode;
<ide> import com.facebook.yoga.YogaMeasureFunction;
<del>import com.facebook.yoga.YogaNodeAPI;
<add>import com.facebook.yoga.YogaNode;
<ide> import com.facebook.react.uiman... | 13 |
Javascript | Javascript | add ember.binding#isnull to mixin | a81d638f5ab5c4d174d2f05b239f09476f59395b | <ide><path>packages/ember-metal/lib/binding.js
<ide> mixinProperties(Binding,
<ide> return binding.not();
<ide> },
<ide>
<add> /**
<add> @see Ember.Binding.prototype.isNull
<add> */
<add> isNull: function(from) {
<add> var C = this, binding = new C(null, from);
<add> return binding.isNull();
<add> }... | 1 |
Javascript | Javascript | remove unused filterinternalstackframes param | 801814686d4745840743d45c54abb41940fb41e2 | <ide><path>lib/repl.js
<ide> function REPLServer(prompt,
<ide> self.writer.options = Object.assign({}, writer.options, { colors: true });
<ide> }
<ide>
<del> function filterInternalStackFrames(error, structuredStack) {
<add> function filterInternalStackFrames(structuredStack) {
<ide> // Search from the bot... | 1 |
Javascript | Javascript | use unique file names in fs trace test | a7c9130e02ccf7e0627b068ef5ea488d4c422015 | <ide><path>test/parallel/test-trace-events-fs-sync.js
<ide> if (!common.isWindows) {
<ide> uid = process.getuid();
<ide> }
<ide>
<del>tests['fs.sync.access'] = 'fs.writeFileSync("fs.txt", "123", "utf8");' +
<del> 'fs.accessSync("fs.txt");' +
<del> 'fs.unlinkSync("fs.... | 1 |
Python | Python | add tokenizer scoring to ja / ko / zh | 013b66de05ee31e5e05a440ab5b29173530929fa | <ide><path>spacy/lang/ja/__init__.py
<ide> from ...compat import copy_reg
<ide> from ...errors import Errors
<ide> from ...language import Language
<add>from ...scorer import Scorer
<ide> from ...symbols import POS
<ide> from ...tokens import Doc
<add>from ...training import validate_examples
<ide> from ...util import ... | 3 |
Text | Text | fix broken link in crypto.md | 3aab64cd5f60ff2cfb6e902846df21942c910884 | <ide><path>doc/api/crypto.md
<ide> See the [list of SSL OP Flags][] for details.
<ide> [RFC 5208]: https://www.rfc-editor.org/rfc/rfc5208.txt
<ide> [encoding]: buffer.html#buffer_buffers_and_character_encodings
<ide> [initialization vector]: https://en.wikipedia.org/wiki/Initialization_vector
<del>[list of SSL OP Flags... | 1 |
Text | Text | add npm to arch build instructions | 0e01bde10750e5f6acd6e532d2ff83ab2868d2d9 | <ide><path>docs/build-instructions/linux.md
<ide> Ubuntu LTS 12.04 64-bit is the recommended platform.
<ide>
<ide> ### Arch
<ide>
<del>* `sudo pacman -S gconf base-devel git nodejs libgnome-keyring python2`
<add>* `sudo pacman -S gconf base-devel git nodejs npm libgnome-keyring python2`
<ide> * `export PYTHON=/usr/bi... | 1 |
Mixed | Javascript | move examples out of code into docs | 642ad4b5cf3636431b840740d0d62a033ac1e5c1 | <ide><path>docs/guides/components.md
<ide> The architecture of the Video.js player is centered around components. The `Play
<ide> * [What is a Component?](#what-is-a-component)
<ide> * [Creating a Component](#creating-a-component)
<ide> * [Component Children](#component-children)
<add> * [Basic Example](#basic-example... | 23 |
Javascript | Javascript | avoid negative lookahead in regular expression | 86b44349dec8db499935927260821cdee211ece4 | <ide><path>src/isomorphic/children/ReactChildren.js
<ide> var twoArgumentPooler = PooledClass.twoArgumentPooler;
<ide> var fourArgumentPooler = PooledClass.fourArgumentPooler;
<ide>
<ide>
<del>var userProvidedKeyEscapeRegex = /\/(?!\/)/g;
<add>var userProvidedKeyEscapeRegex = /\/+/g;
<ide> function escapeUserProvided... | 1 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.