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 |
|---|---|---|---|---|---|
Ruby | Ruby | write bottles with new syntax | 727ac9b47f0b0726e1bc18bf5d2d4aa7817b1a14 | <ide><path>Library/Homebrew/dev-cmd/bottle.rb
<ide> def keg_contain_absolute_symlink_starting_with?(string, keg, args:)
<ide> !absolute_symlinks_start_with_string.empty?
<ide> end
<ide>
<del> def generate_sha256_line(tag, digest, cellar)
<add> def cellar_parameter_needed?(cellar)
<ide> default_cellars = [
... | 2 |
Go | Go | join groups by writing to cgroups.procs, not tasks | 9294d7f2af6ecb7c18be11fb5043fad4a61d8f09 | <ide><path>pkg/cgroups/apply_raw.go
<ide> func (raw *rawCgroup) join(subsystem string, pid int) (string, error) {
<ide> if err := os.MkdirAll(path, 0755); err != nil && !os.IsExist(err) {
<ide> return "", err
<ide> }
<del> if err := writeFile(path, "tasks", strconv.Itoa(pid)); err != nil {
<add> if err := writeFile... | 1 |
Javascript | Javascript | fix aes crash when tag length too small | 7a9635b094b11201c9098312c805f8f72ac775ed | <ide><path>lib/internal/crypto/aes.js
<ide> const {
<ide> kKeyObject,
<ide> } = require('internal/crypto/util');
<ide>
<add>const { PromiseReject } = primordials;
<add>
<ide> const {
<ide> codes: {
<ide> ERR_INVALID_ARG_TYPE,
<ide> function asyncAesGcmCipher(
<ide> data,
<ide> { iv, additionalData, tagLeng... | 2 |
Ruby | Ruby | convert reinstall test to spec | 20b77dfdcc4332f1d21e39571e1bbc7eefc6d4dd | <ide><path>Library/Homebrew/cask/spec/cask/cli/reinstall_spec.rb
<add>require "spec_helper"
<add>
<add>describe Hbc::CLI::Reinstall do
<add> it "allows reinstalling a Cask" do
<add> shutup do
<add> Hbc::CLI::Install.run("local-transmission")
<add> end
<add> expect(Hbc::CaskLoader.load_from_file(TEST_FIXT... | 2 |
Python | Python | load the pretrained weights for encoder-decoder | 1c71ecc880ae8f04c8462e1368dc0678fdb92fc9 | <ide><path>examples/run_summarization_finetuning.py
<ide> def evaluate(args, model, tokenizer, prefix=""):
<ide> return result
<ide>
<ide>
<add>def save_model_checkpoints(args, model, tokenizer):
<add> if not os.path.exists(args.output_dir):
<add> os.makedirs(args.output_dir)
<add>
<add> logger.info(... | 2 |
Text | Text | add peter-samir to hof | 7613df56e1736ae6c53fac3eaedc3570cdb636a9 | <ide><path>HoF.md
<ide> We appreciate any responsible disclosure of vulnerabilities that might impact the integrity of our platforms and users. While we do not offer any bounties or swags at the moment, we are grateful to these awesome people for helping us keep the platform safe for everyone:
<ide>
<ide> - Mehul Moha... | 1 |
Text | Text | add azure pipelines example to no-cache docs | bdc20c26578e40ad88335c919d78057e6ddbec65 | <ide><path>errors/no-cache.md
<ide> Using Heroku's [custom cache](https://devcenter.heroku.com/articles/nodejs-suppo
<ide> ```javascript
<ide> "cacheDirectories": [".next/cache"]
<ide> ```
<add>
<add>#### Azure Pipelines
<add>
<add>Using Azure Pipelines' [Cache task](https://docs.microsoft.com/en-us/azure/devops/pipeli... | 1 |
Python | Python | use full python dot path to extension | d9d34e4886c283653bc7d9e50a414ab07ee8bb93 | <ide><path>rest_framework/compat.py
<ide> def apply_markdown(text):
<ide> of '#' style headers to <h2>.
<ide> """
<ide>
<del> extensions = ['headerid(level=2)']
<add> extensions = ['markdown.extensions.headerid(level=2)']
<ide> md = markdown.Markdown(extensions=extensions)
<ide> ... | 1 |
Text | Text | add text line 7 "i" to article | 9c817a6f9c274480185d24ed422ee6828140b15c | <ide><path>guide/english/mobile-app-development/cordova-ios-application-development-setup-to-deployment/index.md
<ide> title: Cordova iOS Application Development Setup to Deployment
<ide> # Cordova iOS Application Development Setup to Deployment
<ide> <img src="https://image.ibb.co/iKCSuQ/Xz_J197k8_QI32.jpg" alt="iphon... | 1 |
Ruby | Ruby | move common env methods to a shared module | 9a5b15bb61e3c043c1121d51e12a55b8d5dba50a | <ide><path>Library/Homebrew/extend/ENV.rb
<ide> require 'hardware'
<add>require 'extend/ENV/shared'
<ide> require 'extend/ENV/super'
<ide>
<ide> def superenv?
<ide> def activate_extensions!
<ide> ENV.extend(EnvActivation)
<ide>
<ide> module HomebrewEnvExtension
<add> include SharedEnvExtension
<add>
<ide> SAFE_CFL... | 2 |
Text | Text | fix typo in relations docs | f3c5802872505c9304b1d27a7e5bc38af012816b | <ide><path>docs/api-guide/relations.md
<ide> For example, given the following model for a tag, which has a generic relationsh
<ide> def __unicode__(self):
<ide> return self.tag_name
<ide>
<del>And the following two models, which may be have associated tags:
<add>And the following two models, which ... | 1 |
Mixed | PHP | add an "addselect" clause to the query builder | bf376dad59d4cd414bf43369e0891cdae0fa9022 | <ide><path>readme.md
<ide> - Changed cache stores to be implementors of a `StoreInterface` rather than extenders of a `Store` abstract class. Injected implementations into a `Cache\Repository` class.
<ide> - Added `array_fetch` and `array_flatten`. Added `fetch` and `flatten` to `Collection` class.
<ide> - Added `merge... | 2 |
Python | Python | fix test_fromfile_tofile_seeks to work on windows | 98484bb6e3958a26d8f7a4742975e13713003c64 | <ide><path>numpy/core/tests/test_regression.py
<ide> def test_take_refcount(self):
<ide> def test_fromfile_tofile_seeks(self):
<ide> # On Python 3, tofile/fromfile used to get (#1610) the Python
<ide> # file handle out of sync
<del> f = tempfile.TemporaryFile()
<add> f0 = tempfile.Name... | 1 |
Mixed | Ruby | deprecate unused quoted_locking_column method | bb54fcdfadcab3d69b46da384d00abfd09626031 | <ide><path>activerecord/CHANGELOG.md
<add>* Deprecate `quoted_locking_column` method, which isn't used anywhere.
<add>
<add> *kennyj*
<add>
<ide> * Migration dump UUID default functions to schema.rb.
<ide>
<ide> Fixes #10751.
<ide><path>activerecord/lib/active_record/locking/optimistic.rb
<ide> def locking_... | 3 |
Text | Text | add a changelog entry for 165785e | 5ce1f66d7ac50492f4cd1e6bd0170b2c888ec73d | <ide><path>activestorage/CHANGELOG.md
<add>* Image analysis is skipped if ImageMagick returns an error.
<add>
<add> `ActiveStorage::Analyzer::ImageAnalyzer#metadata` would previously raise a
<add> `MiniMagick::Error`, which caused persistent `ActiveStorage::AnalyzeJob`
<add> failures. It now logs the error and r... | 1 |
PHP | PHP | wrap method | f57b9e23ad4f8552bd5c2c958b9fbed4d2478389 | <ide><path>src/Illuminate/Support/Collection.php
<ide> public static function make($items = [])
<ide> return new static($items);
<ide> }
<ide>
<add> /**
<add> * If the given value is not a collection, wrap it in one.
<add> *
<add> * @param mixed $value
<add> * @return static
<add> ... | 2 |
Text | Text | add changelog for 1.2.16 and 1.3.0-beta.5 | 7227f1a47930a6af6b9e9fb37ee919257514bcd0 | <ide><path>CHANGELOG.md
<add><a name="1.3.0-beta.5"></a>
<add># 1.3.0-beta.5 chimeric-glitterfication (2014-04-03)
<add>
<add>
<add>## Bug Fixes
<add>
<add>- **$animate:**
<add> - insert elements at the start of the parent container instead of at the end
<add> ([1cb8584e](https://github.com/angular/angular.js/commit/... | 1 |
Javascript | Javascript | use webvr 1.1 view matrices correctly in vreffect | 8d122e7777000ecb5988615a29b3045a91f1672e | <ide><path>examples/js/effects/VREffect.js
<ide> THREE.VREffect = function ( renderer, onError ) {
<ide> var eyeTranslationL = new THREE.Vector3();
<ide> var eyeTranslationR = new THREE.Vector3();
<ide> var renderRectL, renderRectR;
<add> var headMatrix = new THREE.Matrix4();
<add> var eyeMatrixL = new THREE.Matrix4... | 1 |
PHP | PHP | replace application contract with container | 5c7ece78e17b581990838f9b7b81d7c311d2f0d8 | <ide><path>src/Illuminate/Hashing/HashManager.php
<ide> class HashManager extends Manager implements Hasher
<ide> */
<ide> public function createBcryptDriver()
<ide> {
<del> return new BcryptHasher($this->app['config']['hashing.bcrypt'] ?? []);
<add> return new BcryptHasher($this->config->get... | 5 |
Text | Text | fix a typo | e0544300261bd6048089f887fdac3ff382da3966 | <ide><path>readme.md
<ide> Next.js is a minimalistic framework for server-rendered React applications.
<ide>
<ide> ## How to use
<ide>
<del>### Gettin Started
<add>### Getting Started
<add>
<ide> A step by step interactive guide of next features is available at [learnnextjs.com](https://learnnextjs.com/)
<ide>
<ide>... | 1 |
Mixed | Ruby | add `rfc3339` aliases to `xmlschema` | f0aeecda1450ba17701ccba68e5a796ce4ac4c3b | <ide><path>activesupport/CHANGELOG.md
<add>* Add `rfc3339` aliases to `xmlschema` for `Time` and `ActiveSupport::TimeWithZone`
<add>
<add> For naming consistency when using the RFC 3339 profile of ISO 8601 in applications.
<add>
<add> *Andrew White*
<add>
<ide> * Add `Time.rfc3339` parsing method
<ide>
<ide>... | 5 |
Python | Python | improve changes with upstream's advices | efe26e3a3281c4663a5e500f764fb9a7068049cd | <ide><path>mkdocs.py
<ide> import shutil
<ide> import sys
<ide>
<del>root_dir = os.path.abspath(os.path.split(__file__)[0])
<add>root_dir = os.path.abspath(os.path.dirname(__file__))
<ide> docs_dir = os.path.join(root_dir, 'docs')
<ide> html_dir = os.path.join(root_dir, 'html')
<ide>
<ide>
<ide> content = ma... | 1 |
Javascript | Javascript | convert `src/core/ps_parser.js` to use es6 classes | a963d139dc192a1bc7e3081cd68301880f0b07ee | <ide><path>src/core/ps_parser.js
<ide> * limitations under the License.
<ide> */
<ide>
<del>import { FormatError, isSpace } from '../shared/util';
<add>import { FormatError, isSpace, shadow } from '../shared/util';
<ide> import { EOF } from './primitives';
<ide>
<del>var PostScriptParser = (function PostScriptParse... | 1 |
Ruby | Ruby | use the type object for quoting pg ranges | 02579b56bbe0de17ce8657f453ad4f02acc4ab84 | <ide><path>activerecord/lib/active_record/connection_adapters/postgresql/cast.rb
<del>module ActiveRecord
<del> module ConnectionAdapters
<del> module PostgreSQL
<del> module Cast # :nodoc:
<del> def range_to_string(object) # :nodoc:
<del> from = object.begin.respond_to?(:infinite?) && object.b... | 6 |
Text | Text | fix typos in fundamentals article | 23a43c854d5e8c2f76d8291d1f69ef43ca9831eb | <ide><path>threejs/lessons/threejs-fundamentals.md
<ide> it as easy as possible to get 3D content on a webpage.
<ide>
<ide> Three.js is often confused with WebGL since more often than
<ide> not, but not always, three.js uses WebGL to draw 3D.
<del>[WebGL is a very low-level system that only draws points, lines, and tr... | 1 |
Text | Text | remove broken links from react art readme | 56e5288b042523729d5f8b84a3e569b0b96a329a | <ide><path>packages/react-art/README.md
<ide> React ART is a JavaScript library for drawing vector graphics using [React](http
<ide> It provides declarative and reactive bindings to the [ART library](https://github.com/sebmarkbage/art/).
<ide>
<ide> Using the same declarative API you can render the output to either Ca... | 1 |
Text | Text | update russian translation | 4b0b7ba567ce8460d56f4bfddb5a7b98bf691b20 | <ide><path>guide/russian/php/constants/index.md
<ide> localeTitle: Константы
<ide>
<ide> Константы - это тип переменной в PHP. Функция `define()` для установки константы принимает три аргумента - имя ключа, значение ключа и логическое (true или false), которое определяет, не является ли имя ключа нечувствительным к ре... | 1 |
Javascript | Javascript | fix challenge ordering | 382393e1f2adbd8db9390930a66d3a422505bc2a | <ide><path>index.js
<ide> Challenge.destroyAll(function(err, info) {
<ide> .toLowerCase()
<ide> .replace(/\:/g, '')
<ide> .replace(/\s/g, '-');
<del> challenge.order = +('' + order + (index + 1));
<add> challenge.order = order;
<add> challenge.suborder = index + 1;
<id... | 1 |
Mixed | Text | fix some typos! | cf0dd4a71da69cf7f39da59a992f04b3c7bcbb19 | <ide><path>actionview/CHANGELOG.md
<ide> * ActionView::Template.finalize_compiled_template_methods is deprecated with
<ide> no replacement.
<ide>
<add> *tenderlove*
<add>
<ide> * config.action_view.finalize_compiled_template_methods is deprecated with
<ide> no replacement.
<ide>
<add> *tenderlove*
<... | 2 |
PHP | PHP | cover exception cases in config()/engine() | 0cddc14415763b0a802d4168af86a74b8c60b03d | <ide><path>tests/TestCase/Cache/CacheTest.php
<ide> public function testNullEngineWhenCacheDisable()
<ide> $this->assertInstanceOf('Cake\Cache\Engine\NullEngine', $result);
<ide> }
<ide>
<add> /**
<add> * Test configuring an invalid class fails
<add> *
<add> * @expectedException \RuntimeExce... | 1 |
Python | Python | use state in api consistently over status | 8432fdc5f0ccc166af6065fc7904fc3afdbf2ebb | <ide><path>celery/backends/amqp.py
<ide> def destination_for(self, task_id, request):
<ide> return self.rkey(task_id), request.correlation_id or task_id
<ide> return self.rkey(task_id), task_id
<ide>
<del> def store_result(self, task_id, result, status,
<add> def store_result(self, task_id, r... | 13 |
Python | Python | convert openapi.autoschema methods to public api | b2497fc2456c607a3c639ed2355c28dac672a70f | <ide><path>rest_framework/schemas/openapi.py
<ide> from django.db import models
<ide> from django.utils.encoding import force_str
<ide>
<del>from rest_framework import exceptions, renderers, serializers
<add>from rest_framework import (
<add> RemovedInDRF314Warning, exceptions, renderers, serializers
<add>)
<ide> f... | 2 |
PHP | PHP | remove obsolete code | bf172272da78d9ef0ff3b6712c3ab7fe57df7c74 | <ide><path>laravel/lang.php
<del><?php namespace Laravel; use Closure;
<add><?php namespace Laravel;
<ide>
<ide> class Lang {
<ide> | 1 |
Ruby | Ruby | handle additional use cases | 504bdd2816815af45a62d2535265e3e41b4f61cb | <ide><path>Library/Homebrew/cask/dsl.rb
<ide> class DSL
<ide> :discontinued?,
<ide> :livecheck,
<ide> :livecheckable?,
<add> :on_system_blocks_exist?,
<ide> *ORDINARY_ARTIFACT_CLASSES.map(&:dsl_key),
<ide> *ACTIVATABLE_ARTIFACT_CLASSES.map(&:dsl_key),
<ide> *ARTIFACT_BLOCK_CLASS... | 2 |
PHP | PHP | fix datetimetime breaking on timestamp values | 28432272edbadd8cb01a74c71a35a264e7d62366 | <ide><path>src/Database/Type/DateTimeType.php
<ide> public function __construct($name = null) {
<ide> /**
<ide> * Convert DateTime instance into strings.
<ide> *
<del> * @param string|DateTime $value The value to convert.
<add> * @param string|integer|DateTime $value The value to convert.
<ide> * @param Driver $driv... | 2 |
PHP | PHP | include missing exception | a4a8b5c222d11b70ac53ffab7f99c54f0a318050 | <ide><path>src/Core/ObjectRegistry.php
<ide> abstract class ObjectRegistry implements Countable, IteratorAggregate
<ide> * @param string $objectName The name/class of the object to load.
<ide> * @param array $config Additional settings to use when loading the object.
<ide> * @return mixed
<add> * @th... | 1 |
Python | Python | fix siamese example | 05e1d8e5f4bc3eab549fe386f4db24641acffa7b | <ide><path>examples/mnist_siamese_graph.py
<ide> def euclidean_distance(vects):
<ide> return K.sqrt(K.sum(K.square(x - y), axis=1, keepdims=True))
<ide>
<ide>
<add>def eucl_dist_output_shape(shapes):
<add> shape1, shape2 = shapes
<add> return shape1
<add>
<add>
<ide> def contrastive_loss(y_true, y_pred):
<i... | 1 |
Javascript | Javascript | fix sprite raycast intersection distance | 9d72e97f9d5e1bcffd14cb9ed0763be1260731e4 | <ide><path>src/objects/Sprite.js
<ide> Sprite.prototype = Object.assign( Object.create( Object3D.prototype ), {
<ide>
<ide> raycast: ( function () {
<ide>
<add> var intersectPoint = new Vector3();
<ide> var matrixPosition = new Vector3();
<ide>
<ide> return function raycast( raycaster, intersects ) {
<ide>
<i... | 1 |
PHP | PHP | add comment in mysqlgrammar | 1aca4bbde671a1f25bffc9859af34eecc98002f5 | <ide><path>src/Illuminate/Database/Schema/Grammars/MySqlGrammar.php
<ide> class MySqlGrammar extends Grammar {
<ide> *
<ide> * @var array
<ide> */
<del> protected $modifiers = array('Unsigned', 'Nullable', 'Default', 'Increment', 'After');
<add> protected $modifiers = array('Unsigned', 'Nullable', 'Default', 'Inc... | 1 |
Text | Text | fix documentation links | d5de83b00868410cd82e2896d5a267457abfb65e | <ide><path>README.md
<ide> If you enjoyed my course, consider supporting Egghead by [buying a subscription]
<ide>
<ide> ## Documentation
<ide>
<del>* [Introduction](http://redux.js.org/docs/introduction/index.html)
<del>* [Basics](http://redux.js.org/docs/basics/index.html)
<del>* [Advanced](http://redux.js.org/docs/... | 1 |
Text | Text | fix typos in 2.4 release notes | baceb528cb80584285592aa0160b33101cb0ca37 | <ide><path>docs/topics/2.4-announcement.md
<ide> The optional authtoken application now includes support for *both* Django 1.7 sc
<ide>
<ide> ## Deprecation of `.model` view attribute
<ide>
<del>The `.model` attribute on view classes is an optional shortcut for either or both of `.serializer_class` and `.queryset`. I... | 1 |
Text | Text | fix some errors in readme | 03cad7cba56a9bc924052492d4bbb68485f15a93 | <ide><path>readme.md
<ide> For the initial page load, `getInitialProps` will execute on the server only. `g
<ide> _Note: `getInitialProps` can **not** be used in children components. Only in `pages`._
<ide>
<ide> <br/>
<add>
<ide> > If you are using some server only modules inside `getInitialProps`, make sure to [impo... | 1 |
Ruby | Ruby | allow preload grouping of through associations | 9cc8375e065a2b473f6f63c2483db9ae14d0ba0e | <ide><path>activerecord/lib/active_record/associations/preloader/association.rb
<ide> def already_loaded?
<ide> @already_loaded ||= owners.all? { |o| o.association(reflection.name).loaded? }
<ide> end
<ide>
<add> def runnable_loaders
<add> [self]
<add> end
<add>
<ide> d... | 6 |
Python | Python | update json.dumps for http_date changes | 49b7341a491e01cd6a08238ca63bd46ae53a009f | <ide><path>src/flask/json/__init__.py
<ide> import uuid
<ide> import warnings
<ide> from datetime import date
<del>from datetime import datetime
<ide>
<ide> from jinja2.utils import htmlsafe_json_dumps as _jinja_htmlsafe_dumps
<ide> from werkzeug.http import http_date
<ide> def default(self, o):
<ide> overridi... | 3 |
Javascript | Javascript | use entry in `yarn build ...` instead of label | 051272f2012e1c2f75dc8ee9fe72a1d85cdac302 | <ide><path>scripts/rollup/build.js
<ide> const {
<ide> RN_FB_PROFILING,
<ide> } = Bundles.bundleTypes;
<ide>
<del>const requestedBundleTypes = (argv.type || '')
<del> .split(',')
<del> .map(type => type.toUpperCase());
<del>const requestedBundleNames = (argv._[0] || '')
<del> .split(',')
<del> .map(type => type.... | 2 |
Go | Go | remove remaining use of deprecated pkg/mount | 6d243cdf27bc9cd4caf5b33b7096f2cd1f6e735a | <ide><path>api/types/mount/mount.go
<ide> type TmpfsOptions struct {
<ide> // TODO(stevvooe): There are several more tmpfs flags, specified in the
<ide> // daemon, that are accepted. Only the most basic are added for now.
<ide> //
<del> // From docker/docker/pkg/mount/flags.go:
<add> // From https://github.com/moby/... | 2 |
Text | Text | standardize links in curriculum | 3e3da4ec0fb48a4d343c3eda0b405159720494d5 | <ide><path>curriculum/challenges/english/01-responsive-web-design/basic-css/use-hex-code-for-specific-colors.md
<ide> dashedName: use-hex-code-for-specific-colors
<ide>
<ide> Did you know there are other ways to represent colors in CSS? One of these ways is called hexadecimal code, or hex code for short.
<ide>
<del>W... | 117 |
Python | Python | add support for generators in text preprocessing | 7386dff509604d2794df3c3c9af782cbe7b31447 | <ide><path>keras/preprocessing/text.py
<ide>
<ide> def base_filter():
<ide> f = string.punctuation
<add> f = f.replace("'", '')
<ide> f += '\t\n'
<ide> return f
<ide>
<ide> def text_to_word_sequence(text, filters=base_filter(), lower=True, split=" "):
<ide> '''
<ide> if lower:
<ide> tex... | 1 |
Text | Text | add empty focus template for week of 2018-02-19 | cda838250b0968a4c1e9f1665c05ceb26a2c3d61 | <ide><path>docs/focus/2018-02-19.md
<add>## Highlights from the past week
<add>
<add>- Atom IDE
<add>- @atom/watcher
<add>- GitHub Package
<add>- Teletype
<add>- Xray
<add>
<add>## Focus for week ahead
<add>
<add>- Atom IDE
<add>- @atom/watcher
<add>- GitHub Package
<add>- Teletype
<add>- Tree-sitter
<add>- Xray | 1 |
Text | Text | fix small error | 28de4b00dcea3fc54366e0e12ea4b2e9a0c0cb43 | <ide><path>docs/general/options.md
<ide> Options are resolved from top to bottom, using a context dependent route.
<ide>
<ide> ### Dataset element level options
<ide>
<del>Each scope is looked up with `elementType` prefix in the option name first, then wihtout the prefix. For example, `radius` for `point` element is ... | 1 |
Javascript | Javascript | fix error handling | acc3c770e7717673ee87fa37076fc50fcb91e4ea | <ide><path>lib/internal/fs.js
<ide> function isUint32(n) { return n === (n >>> 0); }
<ide> function modeNum(m, def) {
<ide> if (typeof m === 'number')
<ide> return m;
<del> if (typeof m === 'string')
<del> return parseInt(m, 8);
<del> if (def)
<del> return modeNum(def);
<del> return undefined;
<add> if ... | 11 |
Ruby | Ruby | refine tests for assert_select failure messages | ce6f472f28715ad59be802db4280f99e517c4c39 | <ide><path>actionpack/test/controller/assert_select_test.rb
<ide> def assert_failure(message, &block)
<ide> def test_assert_select
<ide> render_html %Q{<div id="1"></div><div id="2"></div>}
<ide> assert_select "div", 2
<del> assert_failure(/Expected at least 1 element matching \"p\", found 0/) { assert_sel... | 1 |
Python | Python | move linalg tests using matrix to matrixlib | 121a2ee8d6ef43cde55b9f66a301c58cc9eb1623 | <ide><path>numpy/linalg/tests/test_linalg.py
<ide> import sys
<ide> import itertools
<ide> import traceback
<del>import warnings
<ide> import pytest
<ide>
<ide> import numpy as np
<ide> from numpy import array, single, double, csingle, cdouble, dot, identity
<del>from numpy import multiply, atleast_2d, inf, asarray, m... | 2 |
Python | Python | fix constraint tests | bba53793057c0cdf068e67d17ae90e39b90ae24c | <ide><path>keras/constraints.py
<ide> def __call__(self, p):
<ide>
<ide> class UnitNorm(Constraint):
<ide> def __call__(self, p):
<del> return e / T.sqrt(T.sum(e**2, axis=-1, keepdims=True))
<add> return p / T.sqrt(T.sum(p**2, axis=-1, keepdims=True))
<ide>
<ide> identity = Constraint
<ide> maxnorm ... | 2 |
Ruby | Ruby | extract rows that should be inserted to a method | ca0501676500471981806993e7ccd7536f7943f0 | <ide><path>activerecord/lib/active_record/fixtures.rb
<ide> def tables
<ide> }.flatten.uniq
<ide> end
<ide>
<del> def insert_fixtures
<add> # Return a hash of rows to be inserted. The key is the table, the value is
<add> # a list of rows to insert to that table.
<add> def rows
<ide> now = ActiveRecord::... | 1 |
Python | Python | add tests for norm from #763 | 023546bfaac366615436f3daceb7d5ffc211c714 | <ide><path>numpy/linalg/tests/test_linalg.py
<ide> from numpy import array, single, double, csingle, cdouble, dot, identity
<ide> from numpy import multiply, atleast_2d, inf, asarray, matrix
<ide> from numpy import linalg
<del>from numpy.linalg import matrix_power
<add>from numpy.linalg import matrix_power, norm
<ide> ... | 1 |
Javascript | Javascript | convert template to es6 | 3992ba3af6bf7e1fd010b478976d7d2ae96721c1 | <ide><path>lib/Template.js
<ide> const MATCH_PADDED_HYPHENS_REPLACE_REGEX = /^-|-$/g;
<ide> /**
<ide> * @typedef {Object} HasId
<ide> * @property {number | string} id
<del> * */
<add> */
<ide>
<ide> /**
<ide> * @typedef {function(Module, number): boolean} ModuleFilterPredicate
<ide> const MATCH_PADDED_HYPHENS_REPLA... | 1 |
PHP | PHP | fix tiny doc typo | f4fc56c1d605145e05545ec07fdb77eaf2525c73 | <ide><path>src/Http/Response.php
<ide> *
<ide> * There are external packages such as `fig/http-message-util` that provide HTTP
<ide> * status code constants. These can be used with any method that accepts or
<del> * returns a status code integer. Keep in mind that these consants might
<add> * returns a status code i... | 1 |
Javascript | Javascript | log original error | d5caafb86e0b0dbeea0713d17d1a0b62bd1792e3 | <ide><path>packages/next/build/index.js
<ide> function runCompiler (compiler) {
<ide> return reject(err)
<ide> }
<ide>
<del> const jsonStats = stats.toJson({ warnings: true, errors: true })
<add> let buildFailed = false
<add> for (const stat of stats.stats) {
<add> for (const error ... | 1 |
Ruby | Ruby | remove duplicated test | 21747560be42d68200060a1d90419717e0ca339e | <ide><path>railties/test/generators/model_generator_test.rb
<ide> def test_database_puts_migrations_in_configured_folder_with_aliases
<ide> end
<ide> end
<ide>
<del> def test_required_polymorphic_belongs_to_generates_correct_model
<del> run_generator ["account", "supplier:references{polymorphic}"]
<del>
<del... | 1 |
Text | Text | improve choco command | 6aea140a331119a21d78a682027470567de59bfa | <ide><path>docs/GettingStarted.md
<ide> We recommend installing Node and Python2 via [Chocolatey](https://chocolatey.org
<ide>
<ide> React Native also requires a recent version of the [Java SE Development Kit (JDK)](http://www.oracle.com/technetwork/java/javase/downloads/jdk8-downloads-2133151.html), as well as Python... | 1 |
Text | Text | expand documentation for --insecure-registries | c66196a9dc0cd7d19eb3535c52fdbccfa2ee628e | <ide><path>docs/sources/reference/commandline/cli.md
<ide> expect an integer, and they can only be specified once.
<ide> -H, --host=[] The socket(s) to bind to in daemon mode or connect to in client mode, specified using one or more tcp://host:port, unix:///path/to/socket, fd://* or f... | 1 |
PHP | PHP | apply geteventmanager() in tests | babd5c43e7717b19037dc6822c545b90b68bd491 | <ide><path>tests/TestCase/Controller/Component/RequestHandlerComponentTest.php
<ide> public function testNoViewClassExtension()
<ide> $event = new Event('Controller.startup', $this->Controller);
<ide> $this->RequestHandler->initialize([]);
<ide> $this->RequestHandler->startup($event);
<del> ... | 22 |
Javascript | Javascript | use react.autobind by default | c9ecbaccb365ba39bd8839f61ae245cdc295317b | <ide><path>src/core/ReactCompositeComponent.js
<ide> var keyMirror = require('keyMirror');
<ide> var merge = require('merge');
<ide> var mixInto = require('mixInto');
<ide>
<add>var invokedBeforeMount = function() {
<add> invariant(
<add> false,
<add> 'You have invoked a method that is automatically bound, befo... | 6 |
Go | Go | fix typo in overlay's create godoc | 5bac5302e59f0759545910ef748cc9a6f87db5c5 | <ide><path>daemon/graphdriver/overlay/overlay.go
<ide> func (d *naiveDiffDriverWithApply) ApplyDiff(id, parent string, diff archive.Arc
<ide> // directory overlaid on the parents root. This is typically the
<ide> // case with the init layer of a container which is based on an image.
<ide> // If there is no "root" in th... | 1 |
Python | Python | add support for function call fixing, add tests | 4cb311b9455375f6497e7ecb6c931e09b1917d60 | <ide><path>scripts/flaskext_migrate.py
<ide> def fix_standard_imports(red):
<ide> """
<ide> Handles import modification in the form:
<ide> import flask.ext.foo" --> import flask_foo
<del>
<del> Does not modify function calls elsewhere in the source outside of the
<del> original import statement.
<ide>... | 2 |
Javascript | Javascript | improve setservers() errors and performance | 872c331a930df3e44e8f5db5a90a0383e8d0491b | <ide><path>lib/dns.js
<ide> function setServers(servers) {
<ide> // servers cares won't have any servers available for resolution
<ide> const orig = this._handle.getServers();
<ide> const newSet = [];
<del> const IPv6RE = /\[(.*)\]/;
<add> const IPv6RE = /^\[([^[\]]*)\]/;
<ide> const addrSplitRE = /(^.+?)(?::... | 2 |
PHP | PHP | fix another test | 96f9f4280b3b5cc86677066a1f800a2ed58e48bc | <ide><path>tests/TestCase/TestSuite/Fixture/SchemaGeneratorTest.php
<ide> */
<ide> class SchemaGeneratorTest extends TestCase
<ide> {
<add> /**
<add> * @var bool|null
<add> */
<add> protected $restore;
<add>
<add> public function setUp(): void
<add> {
<add> parent::setUp();
<add> $thi... | 1 |
Go | Go | maintain container exec-inspect invariant | a09f8dbe6eabd5bf1e9740bc09a721bfaeaa2583 | <ide><path>daemon/exec.go
<ide> func (daemon *Daemon) ContainerExecStart(ctx context.Context, name string, optio
<ide> defer func() {
<ide> if err != nil {
<ide> ec.Lock()
<add> ec.Container.ExecCommands.Delete(ec.ID)
<ide> ec.Running = false
<ide> exitCode := 126
<ide> ec.ExitCode = &exitCode
<ide> ... | 4 |
Ruby | Ruby | remove unneccesary map chaining | 3fe32c355453f517acfda48a87edf2d6928a381a | <ide><path>activesupport/lib/active_support/ordered_hash.rb
<ide> require 'yaml'
<ide>
<ide> YAML.add_builtin_type("omap") do |type, val|
<del> ActiveSupport::OrderedHash[val.map(&:to_a).map(&:first)]
<add> ActiveSupport::OrderedHash[val.map{ |v| v.to_a.first }]
<ide> end
<ide>
<ide> module ActiveSupport | 1 |
Text | Text | add missing emitchange() to flux docs | 6b1c546602dcb436942c2bb69e4ff6a32f530e84 | <ide><path>docs/docs/flux-todo-list.md
<ide> var TodoStore = merge(EventEmitter.prototype, {
<ide>
<ide> case TodoConstants.TODO_DESTROY:
<ide> destroy(action.id);
<add> TodoStore.emitChange();
<ide> break;
<ide>
<del> // add more cases for other actionTypes, like TODO_... | 1 |
Text | Text | add language tags to code blocks | b6b702c50b236fee662c30c9e79c570861270d2d | <ide><path>threejs/lessons/threejs-cameras.md
<ide> To do that we'll make a `MinMaxGUIHelper` for the `near` and `far` settings so `
<ide> is always greater than `near`. It will have `min` and `max` properties that dat.GUI
<ide> will adjust. When adjusted they'll set the 2 properties we specify.
<ide>
<del>```javascr... | 17 |
Javascript | Javascript | remove ballshooter_multivew from files | f4c0cf956a3b682b3c2d21d54b20e5cc6c0f67fa | <ide><path>examples/files.js
<ide> var files = {
<ide> "webgl_multiple_renderers",
<ide> "webgl_multiple_scenes_comparison",
<ide> "webgl_multiple_views",
<del> "webgl_multiple_views_multiview",
<ide> "webgl_nearestneighbour",
<ide> "webgl_panorama_cube",
<ide> "webgl_panorama_dualfisheye", | 1 |
Text | Text | add changelog entry to composed_of removal | 7fe0f27e2b97a2f175b31b97d14f92473688f66a | <ide><path>activerecord/CHANGELOG.md
<ide> ## Rails 4.0.0 (unreleased) ##
<ide>
<add>* `composed_of` has removed. You'll have to write your own accessor
<add> and mutator methods if you'd like to use value objects to represent some
<add> portion of your models.
<add>
<add> *Steve Klabnik*
<add>
<ide> * Po... | 1 |
Java | Java | fix minor issue in handlermethod | b9786ccacac2cf90e7fa10a9a74a42c603376f4c | <ide><path>spring-web/src/main/java/org/springframework/web/method/HandlerMethod.java
<ide> public Method getMethod() {
<ide> * Note that if the bean type is a CGLIB-generated class, the original, user-defined class is returned.
<ide> */
<ide> public Class<?> getBeanType() {
<del> if (bean instanceof String) {
<d... | 1 |
Text | Text | add djangorestframework-features to third-party | 6196e9c8cd4b8a785564310304870ab5ad2873be | <ide><path>docs/community/third-party-packages.md
<ide> To submit new content, [open an issue][drf-create-issue] or [create a pull reque
<ide> * [django-rest-framework-condition][django-rest-framework-condition] - Decorators for managing HTTP cache headers for Django REST framework (ETag and Last-modified).
<ide> * [dj... | 1 |
Javascript | Javascript | pass instance handle to all fabric clone methods | f79227597202336b5a6e62642dc42646d9639cee | <ide><path>packages/react-native-renderer/src/ReactFabricHostConfig.js
<ide> import invariant from 'fbjs/lib/invariant';
<ide>
<ide> // Modules provided by RN:
<ide> import TextInputState from 'TextInputState';
<del>import FabricUIManager from 'FabricUIManager';
<add>import {
<add> createNode,
<add> cloneNode,
<add>... | 4 |
Javascript | Javascript | add length check when normalizing args | a206afec7671944d5b123d207e00300a894fe0df | <ide><path>lib/net.js
<ide> exports.connect = exports.createConnection = function() {
<ide> function normalizeConnectArgs(args) {
<ide> var options = {};
<ide>
<del> if (args[0] !== null && typeof args[0] === 'object') {
<add> if (args.length === 0) {
<add> return [options];
<add> } else if (args[0] !== null &... | 1 |
PHP | PHP | remove default $type argument | e4afd0c7b754fd5f400aaf5d9d22c076907d4a38 | <ide><path>src/Datasource/EntityTrait.php
<ide> public function &get($property)
<ide> }
<ide>
<ide> $value = null;
<del> $method = $this->_accessor($property);
<add> $method = $this->_accessor($property, 'get');
<ide>
<ide> if (isset($this->_properties[$property])) {
<ide> ... | 1 |
Text | Text | add changelog entry for partialiteration | 03d77504be20fbd170a25e948f259ad4047d0d3e | <ide><path>actionview/CHANGELOG.md
<add>* Add `PartialIteration` object used when rendering collections.
<add>
<add> The iteration object is available as the local variable
<add> `#{template_name}_iteration` when rendering partials with collections.
<add>
<add> It gives access to the `size` of the collection... | 1 |
Javascript | Javascript | add tests for order of decorations | 01abe6ae5877ea754b639b6bcff0723c097b90bf | <ide><path>test/loaderSpec.js
<ide> describe('module loader', function() {
<ide> });
<ide>
<ide>
<add> it("should run decorators in order of declaration, even when mixed with provider.decorator", function() {
<add> var log = '';
<add>
<add> angular.module('theModule', [])
<add> .factory('theProvider', f... | 1 |
Text | Text | fix some typos | 4f2b6579bf59b033e5eda27a51d4192e9c2d2623 | <ide><path>docs/source/quickstart.md
<ide> The library was designed with two strong goals in mind:
<ide>
<ide> A few other goals:
<ide>
<del>- expose the models internals as consistently as possible:
<add>- expose the models' internals as consistently as possible:
<ide>
<ide> - we give access, using a single API t... | 1 |
Ruby | Ruby | fix tests with ruby 3 | 9aed046be93e1d8880d39a6b0dd75a7263f4fff3 | <ide><path>actionview/test/template/form_helper/form_with_test.rb
<ide> def test_form_with_label_accesses_object_through_label_tag_builder
<ide> form_with(model: Post.new) do |f|
<ide> concat(
<ide> f.label(:title) do |builder|
<del> concat tag.span(builder, {
<add> concat tag.span(b... | 1 |
Go | Go | fix docker load progressbar, fixes | 96d7db665b06cc0bbede22d818c69dc5f6921f66 | <ide><path>api/client/load.go
<ide> func (cli *DockerCli) CmdLoad(args ...string) error {
<ide> }
<ide> defer response.Body.Close()
<ide>
<del> if response.JSON {
<add> if response.Body != nil && response.JSON {
<ide> return jsonmessage.DisplayJSONMessagesStream(response.Body, cli.out, cli.outFd, cli.isTerminalOut... | 4 |
Javascript | Javascript | add docs for angular.widget.textarea | a46f2a0db37c88465072d0eec22b0439bf003ff7 | <ide><path>src/widget/input.js
<ide> angularWidget('input', function(inputElement){
<ide> });
<ide> }
<ide> });
<del>
<ide> });
<ide>
<add>
<add>/**
<add> * @ngdoc widget
<add> * @name angular.widget.textarea
<add> *
<add> * @description
<add> * HTML textarea element widget with angular data-binding.... | 1 |
Text | Text | fix documentation of 'path' in tokenizer.to_disk | 8df5b7f51392395a896a991732f04382b6731ead | <ide><path>website/docs/api/tokenizer.md
<ide> the
<ide> > tokenizer = nlp.Defaults.create_tokenizer(nlp)
<ide> > ```
<ide>
<del>| Name | Type | Description |
<add>| Name | T... | 1 |
Javascript | Javascript | add support for zero-delay intervals in tests | 32f464531472ca7b5aa0dc81c5f6421096012201 | <ide><path>src/ngMock/angular-mocks.js
<ide> angular.mock.$IntervalProvider = function() {
<ide> }
<ide>
<ide> repeatFns.push({
<del> nextTime:(now + delay),
<del> delay: delay,
<add> nextTime: (now + (delay || 0)),
<add> delay: delay || 1,
<ide> fn: tick,
<ide> ... | 2 |
Javascript | Javascript | use lowercase in function names | 800fc131b8af0806c38b28ce11aff0f9194a3f98 | <ide><path>crypto.js
<ide> var CipherTransformFactory = (function cipherTransformFactory() {
<ide>
<ide> function constructor(dict, fileId, password) {
<ide> var filter = dict.get('Filter');
<del> if (!IsName(filter) || filter.name != 'Standard')
<add> if (!isName(filter) || filter.name != 'Standard')
<ide... | 4 |
Mixed | Ruby | add headless firefox driver to system tests | 82b974813b28748e5affcff1d8c4ad60ab2971be | <ide><path>actionpack/CHANGELOG.md
<add>* Add headless firefox support to System Tests.
<add>
<add> *bogdanvlviv*
<add>
<ide> * Changed the default system test screenshot output from `inline` to `simple`.
<ide>
<ide> `inline` works well for iTerm2 but not everyone uses iTerm2. Some terminals like
<ide><path... | 7 |
Javascript | Javascript | increase getreport() coverage | 9d44950539e51461ede6fc04b63fb97d033f5468 | <ide><path>test/node-report/test-api-getreport.js
<ide> const helper = require('../common/report');
<ide> common.expectWarning('ExperimentalWarning',
<ide> 'report is an experimental feature. This feature could ' +
<ide> 'change at any time');
<del>helper.validateContent(proces... | 1 |
PHP | PHP | fix incorrect handling of url in path | 6a31a7b2b31f293f9c102ac73041652bf702f392 | <ide><path>src/Network/Request.php
<ide> protected static function _url($config)
<ide> if (isset($_SERVER['REQUEST_URI']) && strpos($_SERVER['REQUEST_URI'], '://') === false) {
<ide> $uri = $_SERVER['REQUEST_URI'];
<ide> } elseif (isset($_SERVER['REQUEST_URI'])) {
<del> $qPosition... | 2 |
Javascript | Javascript | name anonymous functions | cb45374c31dc57e4610dfb1e7336a6ceb4d362b4 | <ide><path>lib/_http_agent.js
<ide> Agent.defaultMaxSockets = Infinity;
<ide> Agent.prototype.createConnection = net.createConnection;
<ide>
<ide> // Get the key for a given set of request options
<del>Agent.prototype.getName = function(options) {
<add>Agent.prototype.getName = function getName(options) {
<ide> var ... | 1 |
Javascript | Javascript | remove stray console.log statemente | a23d15ad3ad8f0eb52ffc4b0ac86ec358ae3dfa8 | <ide><path>src/Angular.js
<ide> function assertArg(arg, name, reason) {
<ide> if (!arg) {
<ide> var error = new Error("Argument '" + (name||'?') + "' is " +
<ide> (reason || "required"));
<del> if (window.console) window.console.log(error.stack);
<ide> throw error;
<ide> }
<ide> } | 1 |
Javascript | Javascript | remove unnecessary quote escaping | cd2f022d4302e7f4e4926d709f5011423c40de8c | <ide><path>lib/node/NodeMainTemplatePlugin.js
<ide> module.exports = class NodeMainTemplatePlugin {
<ide> "installedChunks[chunkId] = [resolve, reject];",
<ide> "var filename = __dirname + " + this.applyPluginsWaterfall("asset-path", JSON.stringify(`/${chunkFilename}`), {
<ide> hash: `" + ${this.rend... | 1 |
Ruby | Ruby | add casks to default help text | f2064750f578c58335719ccf0ed33bd09c3d2ee3 | <ide><path>Library/Homebrew/help.rb
<ide> module Help
<ide> HOMEBREW_HELP = <<~EOS
<ide> Example usage:
<ide> brew search [TEXT|/REGEX/]
<del> brew info [FORMULA...]
<del> brew install FORMULA...
<add> brew info [FORMULA|CASK...]
<add> brew install FORMULA|CASK...
<ide> ... | 1 |
Java | Java | use assertthat from hamcrest instead of junit 4 | 47c39304afe43d904a5a48c8273cab187ddeebce | <ide><path>spring-expression/src/test/java/org/springframework/expression/spel/EvaluationTests.java
<ide> import org.springframework.expression.spel.support.StandardTypeLocator;
<ide> import org.springframework.expression.spel.testresources.TestPerson;
<ide>
<add>import static org.hamcrest.MatcherAssert.assertThat;
<i... | 59 |
Javascript | Javascript | use separate features for dev vs prod builds | 00c650cc5443679ff33491be1db183c68b85429d | <ide><path>Brocfile.js
<ide> var testConfig = pickFiles('tests', {
<ide> testConfig = replace(testConfig, {
<ide> files: [ 'tests/ember_configuration.js' ],
<ide> patterns: [
<del> { match: /\{\{FEATURES\}\}/g, replacement: JSON.stringify(defeatureifyConfig().enabled) }
<add> { match: /\{\{DEV_FEATURES\}\}/g,... | 2 |
Text | Text | fix grammatical typo in docs | ee97bc1b206976c202d40d8f234b5a929c62dcd6 | <ide><path>docs/api-reference/next/link.md
<ide> export default Home
<ide>
<ide> ## With URL Object
<ide>
<del>`Link` can also receive an URL object and it will automatically format it to create the URL string. Here's how to do it:
<add>`Link` can also receive a URL object and it will automatically format it to creat... | 2 |
Ruby | Ruby | add content_type to upload in azure | 094fa9277d840fe2061f37b9704f81fecdbbe965 | <ide><path>activestorage/lib/active_storage/service/azure_storage_service.rb
<ide> def initialize(storage_account_name:, storage_access_key:, container:, **options
<ide> @container = container
<ide> end
<ide>
<del> def upload(key, io, checksum: nil, **)
<add> def upload(key, io, checksum: nil, content_... | 2 |
PHP | PHP | fix cs errors | 5d0b2fa0036878f85d70122d4f275657b15a8641 | <ide><path>src/Core/Configure.php
<ide> public static function check($var)
<ide> * possible to store `null` values in Configure.
<ide> *
<ide> * Acts as a wrapper around Configure::read() and Configure::check().
<del> * The configure key/value pair fetched via this method is expected to exist.
<add>... | 1 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.