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 |
|---|---|---|---|---|---|
PHP | PHP | return all possible form context attributes | f82b76878750e170265ce5ccf610295762882c66 | <ide><path>src/View/Form/ArrayContext.php
<ide> public function attributes(string $field): array
<ide> if ($schema === null) {
<ide> $schema = Hash::get($this->_context['schema'], $this->stripNesting($field));
<ide> }
<del> $allowed = ['length' => null, 'precision' => null];
<ide>
<d... | 6 |
Text | Text | fix a typo on the engine guide | 20985257a1866e29b7251a218aca275d886939df | <ide><path>guides/source/engines.md
<ide> def create
<ide> @post = Post.find(params[:post_id])
<ide> @comment = @post.comments.create(params[:comment])
<ide> flash[:notice] = "Comment has been created!"
<del> redirect_to post_path
<add> redirect_to posts_path
<ide> end
<ide> ```
<ide> | 1 |
Mixed | Javascript | add string shortcut for fork stdio | 3268863ebc40d1f0beee61b044c492b43fa57fa5 | <ide><path>doc/api/child_process.md
<ide> added: v0.5.0
<ide> piped to the parent, otherwise they will be inherited from the parent, see
<ide> the `'pipe'` and `'inherit'` options for [`child_process.spawn()`][]'s
<ide> [`stdio`][] for more details (Default: `false`)
<del> * `stdio` {Array} Supports the ar... | 3 |
Ruby | Ruby | add failing test for where with joins | b42e594a43e00d00b018868481927584d358f756 | <ide><path>activerecord/test/cases/associations/has_one_associations_test.rb
<ide> def test_with_polymorphic_has_one_with_custom_columns_name
<ide> class SpecialBook < ActiveRecord::Base
<ide> self.table_name = "books"
<ide> belongs_to :author, class_name: "SpecialAuthor"
<add> has_one :subscription, class... | 1 |
Javascript | Javascript | add helper to decode the debug hash when needed | e320176d4d099d2408f5bb573fda9a0d06c09d45 | <ide><path>tooling/decode-debug-hash.js
<add>const fs = require("fs");
<add>
<add>const file = process.argv[2];
<add>
<add>let content = fs.readFileSync(file, "utf-8");
<add>content = content.replace(/debug-digest-([a-f0-9]+)/g, (match, bin) => {
<add> return Buffer.from(bin, "hex").toString("utf-8");
<add>});
<add>
<a... | 1 |
Python | Python | add labels param to google mlengine operators | c29533888fadd40f5e9ce63e728bd8691182e542 | <ide><path>airflow/providers/google/cloud/example_dags/example_mlengine.py
<ide> package_uris=[TRAINER_URI],
<ide> training_python_module=TRAINER_PY_MODULE,
<ide> training_args=[],
<add> labels={"job_type": "training"},
<ide> )
<ide> # [END howto_operator_gcp_mlengine_training]
<i... | 3 |
PHP | PHP | remove cruft related to csrf protection token | 6091811e6d66b48bceda05c285f4f42974003cdd | <ide><path>src/Controller/Component/SecurityComponent.php
<ide> protected function _fieldsList(array $check): array
<ide> if (strpos($token, ':')) {
<ide> [$token, $locked] = explode(':', $token, 2);
<ide> }
<del> unset($check['_Token'], $check['_csrfToken']);
<add> unset($chec... | 2 |
Python | Python | restore tests for beam parser | de7e8703e35f1e0d6090e2e4ce81779e8e17e03f | <ide><path>spacy/tests/parser/test_neural_parser.py
<ide> def test_predict_doc_beam(parser, tok2vec, model, doc):
<ide> parser(doc, beam_width=32, beam_density=0.001)
<ide> for word in doc:
<ide> print(word.text, word.head, word.dep_)
<add>
<add>
<add>def test_update_doc_beam(parser, tok2vec, model, doc... | 2 |
PHP | PHP | change some syntax | 19317c9a545c58d8274df23da96c0d2a9c261fc6 | <ide><path>src/Illuminate/Console/Scheduling/Schedule.php
<ide> public function call($callback, array $parameters = array())
<ide> * @param string $command
<ide> * @return \Illuminate\Console\Scheduling\Event
<ide> */
<del> public function artisan($command)
<add> public function command($command)
<ide> {
<del>... | 1 |
Ruby | Ruby | change gid calls to to_gid | a7dbfcf532650118a7522cb02e696188bb53ef50 | <ide><path>activejob/test/cases/parameters_test.rb
<ide> class ParameterSerializationTest < ActiveSupport::TestCase
<ide> end
<ide>
<ide> test 'should dive deep into arrays or hashes' do
<del> assert_equal [ { "a" => Person.find(5).gid.to_s }.with_indifferent_access ], ActiveJob::Arguments.serialize([ { a: Pers... | 1 |
Python | Python | remove unused old test | fa8f67596daa1a658ddabceea07b346e9c4ad375 | <ide><path>spacy/tests/spans/test_times.py
<del>from __future__ import unicode_literals
<del>
<del>import pytest
<del>
<del># This approach is deprecated for now
<del>#
<del>#@pytest.mark.models
<del>#def test_am_pm(en_nlp):
<del># numbers = ['1', '2', '3', '4', '5', '6', '7', '8', '9', '10', '11', '12']
<del># v... | 1 |
Go | Go | fix exec form of healthcheck cmd | e95b6b51daed868094c7b66113381d5088e831b4 | <ide><path>builder/dockerfile/parser/line_parsers.go
<ide> func parseHealthConfig(rest string, d *Directive) (*Node, map[string]bool, error
<ide> return nil, nil, err
<ide> }
<ide>
<del> return &Node{Value: typ, Next: cmd, Attributes: attrs}, nil, err
<add> return &Node{Value: typ, Next: cmd}, attrs, err
<ide> }
<i... | 2 |
PHP | PHP | use better exception | 79c3905a595e328d9df83005e8f3b15b3999028c | <ide><path>src/View/Helper/PaginatorHelper.php
<ide> use Cake\View\Helper;
<ide> use Cake\View\StringTemplateTrait;
<ide> use Cake\View\View;
<del>use RuntimeException;
<add>use InvalidArgumentException;
<ide>
<ide> /**
<ide> * Pagination Helper class for easy generation of pagination links.
<ide> public function has... | 1 |
Javascript | Javascript | use custom element on text editor element | 510d04bffe34d2ff5102920316f6501572055110 | <ide><path>spec/text-editor-element-spec.js
<ide> describe('TextEditorElement', () => {
<ide> });
<ide>
<ide> function buildTextEditorElement(options = {}) {
<del> const element = new TextEditorElement();
<add> const element = TextEditorElement.createTextEditorElement();
<ide> element.setUpdatedSynchrono... | 3 |
Javascript | Javascript | change @param to use valid types | f296e2ee12bb60f9ff988d2be4fbe9ec7c5dc42f | <ide><path>src/ng/animate.js
<ide> var $AnimateProvider = ['$provide', function($provide) {
<ide> * @function
<ide> * @description Inserts the element into the DOM either after the `after` element or within
<ide> * the `parent` element. Once complete, the done() callback will be fired (if provide... | 2 |
Go | Go | add event logs for pause/unpuase | e1ec91fc582f10d57025e39f0f7e7d6695f7454e | <ide><path>integration-cli/docker_cli_events_test.go
<ide> package main
<ide>
<ide> import (
<add> "fmt"
<ide> "os/exec"
<ide> "strings"
<ide> "testing"
<add> "time"
<ide> )
<ide>
<del>func TestCLIGetEvents(t *testing.T) {
<add>func TestCLIGetEventsUntag(t *testing.T) {
<ide> out, _, _ := cmd(t, "images", "-q")
<... | 2 |
Ruby | Ruby | fix argument order in test_comparableset | 646102c31118144545127b7ed70512de753d1d40 | <ide><path>Library/Homebrew/test/test_comparableset.rb
<ide> def setup
<ide> def test_merging_multiple_dependencies
<ide> @set << X11Dependency.new
<ide> @set << X11Dependency.new
<del> assert_equal @set.count, 1
<add> assert_equal 1, @set.count
<ide> @set << Requirement.new
<del> assert_equal @s... | 1 |
Javascript | Javascript | parse numbers correctly | a89f5c21562fe75b083a270090eadfbe318e5954 | <ide><path>lib/querystring.js
<ide> var hexTable = new Array(256);
<ide> for (var i = 0; i < 256; ++i)
<ide> hexTable[i] = '%' + ((i < 16 ? '0' : '') + i.toString(16)).toUpperCase();
<ide> QueryString.escape = function(str) {
<add> // replaces encodeURIComponent
<add> // http://www.ecma-international.org/ecma-262/5... | 2 |
PHP | PHP | add test case for default sort fallback | f3c89fc5e2461574f26a04aca06e69d7b273981a | <ide><path>tests/TestCase/View/Helper/PaginatorHelperTest.php
<ide> public function testDefaultSortRemovedFromUrl()
<ide> $this->assertHtml($expected, $result);
<ide> }
<ide>
<add> /**
<add> * Tests that generated default order URL doesn't include sort and direction parameters.
<add> *
<add> ... | 1 |
Javascript | Javascript | remove use of reactcomponentexpect in our tests | c567b6e6187538b996db0da605806b0b91fc9c96 | <ide><path>src/isomorphic/classic/__tests__/ReactContextValidator-test.js
<ide> var React;
<ide> var ReactDOM;
<ide> var ReactTestUtils;
<ide>
<del>var reactComponentExpect;
<del>
<ide> describe('ReactContextValidator', () => {
<ide> function normalizeCodeLocInfo(str) {
<ide> return str.replace(/\(at .+?:\d+\)/g... | 7 |
PHP | PHP | add session support for psr7 requests | 61ef064686e6eac5599ef566e1796b291d521225 | <ide><path>src/TestSuite/MiddlewareDispatcher.php
<ide> public function execute($request)
<ide> $request['post'],
<ide> $request['cookies']
<ide> );
<add> $psrRequest = $psrRequest->withAttribute('session', $request['session']);
<ide> $response = $server->run($psrRequest);... | 2 |
Python | Python | update celery to 4.4.2 | 876ca9bb645ac7f3e49063bf7a8d4639d9cd72b5 | <ide><path>setup.py
<ide> def write_version(filename: str = os.path.join(*[my_dir, "airflow", "git_version
<ide> 'cassandra-driver>=3.13.0,<3.21.0',
<ide> ]
<ide> celery = [
<del> 'celery~=4.3',
<add> 'celery~=4.4.2',
<ide> 'flower>=0.7.3, <1.0',
<ide> 'tornado>=4.2.0, <6.0', # Dep of flower. Pin to ... | 1 |
Text | Text | update the runtime version in bash script | fc918584cf35b093928a96916c503c9a17de1633 | <ide><path>research/object_detection/g3doc/running_pets.md
<ide> To start training and evaluation, execute the following command from the
<ide> ```bash
<ide> # From tensorflow/models/research/
<ide> gcloud ml-engine jobs submit training `whoami`_object_detection_pets_`date +%m_%d_%Y_%H_%M_%S` \
<del> --runtime-versi... | 1 |
Ruby | Ruby | expect xcode 8.3.3 | a88350425bbee7a610143911badaca933baad05e | <ide><path>Library/Homebrew/os/mac/xcode.rb
<ide> def latest_version
<ide> when "10.9" then "6.2"
<ide> when "10.10" then "7.2.1"
<ide> when "10.11" then "8.2.1"
<del> when "10.12" then "8.3.2"
<add> when "10.12" then "8.3.3"
<ide> else
<ide> raise "macOS '#{MacO... | 1 |
Ruby | Ruby | fix typo in actionview error message | 328ae33d78103de242e9d64fa471c64a76aae348 | <ide><path>actionview/lib/action_view/helpers/url_helper.rb
<ide> def method_tag(method)
<ide> def to_form_params(attribute, namespace = nil)
<ide> attribute = if attribute.respond_to?(:permitted?)
<ide> unless attribute.permitted?
<del> raise ArgumentError, "Attempting to gen... | 1 |
Javascript | Javascript | fix material accessors | d4ee29216cfbd37cff37d02efbf0ed5179745376 | <ide><path>src/materials/Material.js
<ide> function Material() {
<ide>
<ide> }
<ide>
<del>Object.assign( Material.prototype, EventDispatcher.prototype, {
<del>
<del> constructor: Material,
<del>
<del> isMaterial: true,
<add>Object.defineProperty( Material.prototype, "needsUpdate", {
<ide>
<del> get needsUpdate() {
<... | 1 |
Ruby | Ruby | fix bad require for rake test | 427d0a8d14aaca59bbf2d33dba6b4a1232f895f0 | <ide><path>actionpack/test/controller/routing_test.rb
<ide> require File.dirname(__FILE__) + '/../abstract_unit'
<ide> require 'test/unit'
<del>require 'fake_controllers'
<add>require File.dirname(__FILE__) + '/fake_controllers'
<ide> require 'stringio'
<ide>
<ide> RunTimeTests = ARGV.include? 'time' | 1 |
Javascript | Javascript | apply promises api to fourth appendfile test | 8530b58493c1da6c7bf21b4bb59824eda45521b2 | <ide><path>test/parallel/test-fs-append-file.js
<ide> const s = '南越国是前203年至前111年存在于岭南地区的一个国家
<ide> '历经五代君主。南越国是岭南地区的第一个有记载的政权国家,采用封建制和郡县制并存的制度,' +
<ide> '它的建立保证了秦末乱世岭南地区社会秩序的稳定,有效的改善了岭南地区落后的政治、##济现状。\n';
<ide>
<del>let ncallbacks = 0;
<del>
<ide> tmpdir.refresh();
<ide>
<ide> const throwNextTick =... | 1 |
Text | Text | fix module name in section 2 | af8beb90c256586d9016d9e6411ecd9ac01f4f22 | <ide><path>docs/tutorial/2-requests-and-responses.md
<ide> Now update the `urls.py` file slightly, to append a set of `format_suffix_patter
<ide> from django.conf.urls import patterns, url
<ide> from rest_framework.urlpatterns import format_suffix_patterns
<ide>
<del> urlpatterns = patterns('snippet.views',... | 1 |
Python | Python | update some annotations updated from the spec | 7ce435c610fcd7fee01da9d9e7ff5c1ab4ae6ef6 | <ide><path>numpy/_array_api/_array_object.py
<ide> def __and__(self: array, other: array, /) -> array:
<ide> res = self._array.__and__(asarray(other)._array)
<ide> return self.__class__._new(res)
<ide>
<del> def __array_namespace__(self, /, *, api_version=None):
<add> def __array_namespace__(self... | 3 |
Ruby | Ruby | remove another call to rendered_format= | df12a1b2413906ee38a977e3cbb325512c184837 | <ide><path>actionview/lib/action_view/digestor.rb
<ide> def tree(name, finder, partial = false, seen = {})
<ide> logical_name = name.gsub(%r|/_|, "/")
<ide>
<ide> if template = find_template(finder, logical_name, [], partial, [])
<del> finder.rendered_format ||= template.formats.first
<del>
<i... | 1 |
Python | Python | remove testing change | 2e0a2a718ac8d9094576f3efcfb4cfa8fe1246d3 | <ide><path>libcloud/compute/drivers/ec2.py
<ide> class EC2Connection(SignedAWSConnection):
<ide> """
<ide>
<ide> version = API_VERSION
<del> host = "aaa.com"
<add> host = REGION_DETAILS['us-east-1']['endpoint']
<ide> responseCls = EC2Response
<ide> service_name = 'ec2'
<ide> | 1 |
Javascript | Javascript | trim cat output for windows | 9826159bf102aaa5dad6eaea7998ede8460de471 | <ide><path>test/simple/test-child-process-stdio-inherit.js
<ide> function grandparent() {
<ide> child.on('close', function(code, signal) {
<ide> assert.equal(code, 0);
<ide> assert.equal(signal, null);
<del> assert.equal(output, input);
<add> // cat on windows adds a \r\n at the end.
<add> assert.equ... | 1 |
Javascript | Javascript | fix rgbatodepth artefacts | 247b93f14e3f883ec285c0ba76264ec3286c85a8 | <ide><path>src/renderers/shaders/ShaderChunk/packing.glsl.js
<ide> vec4 packDepthToRGBA( const in float v ) {
<ide> }
<ide>
<ide> float unpackRGBAToDepth( const in vec4 v ) {
<del> return dot( v, UnpackFactors );
<add> return dot( floor( v * 255.0 + 0.5 ) / 255.0, UnpackFactors );
<ide> }
<ide>
<ide> vec4 encodeHalfR... | 1 |
Text | Text | update slim readme as well | 7b4d025aa03d2cdd684970e0dc7404f12bb98cd4 | <ide><path>slim/README.md
<ide> prerequisite packages.
<ide>
<ide> ## Installing latest version of TF-slim
<ide>
<del>As of 8/28/16, the latest [stable release of TF](https://www.tensorflow.org/versions/r0.10/get_started/os_setup.html#pip-installation)
<del>is r0.10, which contains most of TF-Slim but not some later ... | 1 |
Text | Text | add devtools monitors to ecosystem | 03134a881025c5c4ea4d400bb4129014e97476da | <ide><path>docs/introduction/Ecosystem.md
<ide> On this page we will only feature a few of them that the Redux maintainers have
<ide> * [redux-tcomb](https://github.com/gcanti/redux-tcomb) — Immutable and type-checked state and actions for Redux
<ide> * [redux-mock-store](https://github.com/arnaudbenard/redux-mock-stor... | 1 |
PHP | PHP | add allowdynamicproperties attribute to component | c1f24403b58bafb3c2d2fc206b803d40e045679f | <ide><path>src/Controller/Component.php
<ide> * @link https://book.cakephp.org/4/en/controllers/components.html
<ide> * @see \Cake\Controller\Controller::$components
<ide> */
<add>#[\AllowDynamicPropeties]
<ide> class Component implements EventListenerInterface
<ide> {
<ide> use InstanceConfigTrait; | 1 |
PHP | PHP | use correct interface in tests | 982c68121c2645a6ec812b6a5eae1b0244e16094 | <ide><path>tests/Auth/AuthGuardTest.php
<ide> public function testLoginStoresIdentifierInSession()
<ide> $user = m::mock('Illuminate\Contracts\Auth\User');
<ide> $mock->expects($this->once())->method('getName')->will($this->returnValue('foo'));
<ide> $user->shouldReceive('getAuthIdentifier')->once()->andReturn('b... | 1 |
Ruby | Ruby | extract exec_migration [] | 24653c945ad3fdce4cb5890a9cc7565753decda0 | <ide><path>activerecord/lib/active_record/migration.rb
<ide> def migrate(direction)
<ide> time = nil
<ide> ActiveRecord::Base.connection_pool.with_connection do |conn|
<ide> time = Benchmark.measure do
<del> @connection = conn
<del> if respond_to?(:change)
<del> if dir... | 1 |
Javascript | Javascript | do jquery.trim in less bytes (-5) | 26bdbb806eeb1d8e1881b3fc11ff298eb4d1dca0 | <ide><path>src/core.js
<ide> var
<ide> // Used for detecting and trimming whitespace
<ide> core_rnotwhite = /\S/,
<ide> core_rspace = /\s+/,
<del> trimLeft = /^\s+/,
<del> trimRight = /\s+$/,
<add>
<add> // IE doesn't match non-breaking spaces with \s
<add> rtrim = core_rnotwhite.test("\xA0") ? (/^[\s\xA0]+|[\s\xA0]... | 1 |
PHP | PHP | prefix seeders automatically if necessary | cadad245ff1d5e294ef6d3f312d66dc63f728619 | <ide><path>src/Illuminate/Database/Console/Seeds/SeedCommand.php
<ide> protected function getSeeder()
<ide> {
<ide> $class = $this->input->getOption('class');
<ide>
<add> if (strpos($class, '\\') === false) {
<add> $class = 'Database\\Seeders\\'.$class;
<add> }
<add>
<ide> ... | 1 |
Python | Python | update mgrid test from code review | f82c7d73ce116471f8009d481ded4449dfec3106 | <ide><path>numpy/lib/tests/test_index_tricks.py
<ide> def test_accepts_npfloating(self):
<ide> assert_array_almost_equal(grid64, grid32)
<ide>
<ide> def test_accepts_npcomplexfloating(self):
<del> grid = mgrid[0.1:0.3:np.complex64(3j), ]
<del> assert_array_almost_equal(grid, np.array([[0.1, 0... | 1 |
Text | Text | introduce bundler and gemfiles in a note | 83cb6fbd13f3c5ea3106b9a57964b1a6fb243682 | <ide><path>guides/source/getting_started.md
<ide> $ rails new blog
<ide>
<ide> This will create a Rails application called Blog in a directory called blog and install the gem dependencies that are already mentioned in `Gemfile` using `bundle install`.
<ide>
<add>NOTE: A Gemfile is a file that contains the list of all... | 1 |
Ruby | Ruby | remove stubs from logsubscriber tests | 731bb2fe6815ac6a1888d9fb54bb1782e4768c0b | <ide><path>actionpack/test/template/log_subscriber_test.rb
<ide> class AVLogSubscriberTest < ActiveSupport::TestCase
<ide>
<ide> def setup
<ide> super
<del> @controller = Object.new
<del> @controller.stubs(:_prefixes).returns(%w(test))
<del> @view = ActionView::Base.new(ActionController::Base.view_paths... | 1 |
Javascript | Javascript | run all of test-timers-blocking-callback | 2c6ca32e8bcc6759a704bb525df71ac7b3b151ca | <ide><path>test/parallel/test-timers-blocking-callback.js
<ide> function blockingCallback(callback) {
<ide> common.busyLoop(TIMEOUT);
<ide>
<ide> timeCallbackScheduled = Timer.now();
<del> setTimeout(blockingCallback, TIMEOUT);
<add> setTimeout(blockingCallback.bind(null, callback), TIMEOUT);
<ide> }
<... | 1 |
Javascript | Javascript | fix todo in `freeze_intrinsics` | 411fb2172314588a6503f8f7aa14263b117c04df | <ide><path>lib/internal/freeze_intrinsics.js
<ide> module.exports = function() {
<ide> const descs = ObjectGetOwnPropertyDescriptors(obj);
<ide> enqueue(proto);
<ide> ArrayPrototypeForEach(ReflectOwnKeys(descs), (name) => {
<del> // TODO: Uncurried form
<del> // TODO: getOwnPro... | 1 |
Python | Python | set version to 2.0.12.dev1 | 1a1c7304cfd1fb3f8544cb8a55e1012db799f5ee | <ide><path>spacy/about.py
<ide> # https://github.com/pypa/warehouse/blob/master/warehouse/__about__.py
<ide>
<ide> __title__ = 'spacy'
<del>__version__ = '2.0.12.dev0'
<add>__version__ = '2.0.12.dev1'
<ide> __summary__ = 'Industrial-strength Natural Language Processing (NLP) with Python and Cython'
<ide> __uri__ = 'ht... | 1 |
Javascript | Javascript | use private field in abortcontroller | 73ba8830d59015e8554903301245ee32c31baa9f | <ide><path>lib/internal/abort_controller.js
<ide> function abortSignal(signal, reason) {
<ide> signal.dispatchEvent(event);
<ide> }
<ide>
<del>// TODO(joyeecheung): use private fields and we'll get invalid access
<del>// validation from V8 instead of throwing ERR_INVALID_THIS ourselves.
<del>const kSignal = Symbol('... | 2 |
Ruby | Ruby | require rubygems for activesupport | 6670ae620229d7030b0e0feee96cd550c686e117 | <ide><path>Library/Homebrew/cask/dsl/depends_on.rb
<ide> # frozen_string_literal: true
<ide>
<del>require "rubygems"
<del>
<ide> module Cask
<ide> class DSL
<ide> class DependsOn < DelegateClass(Hash)
<ide><path>Library/Homebrew/cask/installer.rb
<ide> # frozen_string_literal: true
<ide>
<del>require "rubygems"... | 6 |
Text | Text | fix typo in obj detection's running_pets.md | c9bb58f2c86375dce38a80853f55fcf282a8b6cd | <ide><path>object_detection/g3doc/running_pets.md
<ide> command from `tensorflow/models/object_detection`:
<ide> ``` bash
<ide> # From tensorflow/models
<ide> gsutil cp gs://${YOUR_GCS_BUCKET}/train/model.ckpt-${CHECKPOINT_NUMBER}.* .
<del>python object_detection/export_inference_graph \
<add>python object_detection/ex... | 1 |
Java | Java | improve javadoc on requestentity#geturl | ae8b7973b408fac8dd666cbd03486227e440e820 | <ide><path>spring-web/src/main/java/org/springframework/http/RequestEntity.java
<ide> import org.springframework.lang.Nullable;
<ide> import org.springframework.util.MultiValueMap;
<ide> import org.springframework.util.ObjectUtils;
<add>import org.springframework.web.util.UriTemplateHandler;
<ide>
<ide> /**
<ide> * E... | 1 |
Ruby | Ruby | show information based on build options | 5b321ffb5a5308f1de96e7bfa79e83828e9c9552 | <ide><path>Library/Homebrew/caveats.rb
<ide> def initialize(f)
<ide>
<ide> def caveats
<ide> caveats = []
<del> s = f.caveats.to_s
<del> caveats << s.chomp + "\n" if s.length > 0
<add> begin
<add> build, f.build = f.build, Tab.for_formula(f)
<add> s = f.caveats.to_s
<add> caveats << s.cho... | 1 |
Java | Java | allow custom urlpathhelper for websocket requests | fc91add35ee7c51e854d80838bfceed545873801 | <ide><path>spring-websocket/src/main/java/org/springframework/web/socket/config/annotation/ServletWebSocketHandlerRegistry.java
<ide> import org.springframework.web.servlet.handler.AbstractHandlerMapping;
<ide> import org.springframework.web.servlet.handler.SimpleUrlHandlerMapping;
<ide> import org.springframework.web.... | 4 |
Java | Java | update copyright date | 63c6a7e15efe741adc38a4bccaef389468bb808b | <ide><path>spring-aop/src/main/java/org/springframework/aop/aspectj/AbstractAspectJAdvice.java
<ide> /*
<del> * Copyright 2002-2020 the original author or authors.
<add> * Copyright 2002-2021 the original author or authors.
<ide> *
<ide> * Licensed under the Apache License, Version 2.0 (the "License");
<ide> * you m... | 22 |
Text | Text | keep the names in sorted order | 0a1859d33add447a75d858254f39c6d8639ab772 | <ide><path>README.md
<ide> Releases of Node.js and io.js will be signed with one of the following GPG keys:
<ide>
<ide> * **Chris Dickinson** <christopher.s.dickinson@gmail.com> `9554F04D7259F04124DE6B476D5A82AC7E37093B`
<ide> * **Colin Ihrig** <cjihrig@gmail.com> `94AE36675C464D64BAFA68DD7434390BDBE9B9C5`... | 1 |
PHP | PHP | change allowedsort -> sortablefields | d5d19497acfb8918a3c41393196ceca5ee00df19 | <ide><path>src/Controller/Component/PaginatorComponent.php
<ide> public function implementedEvents(): array
<ide> * $settings = [
<ide> * 'Articles' => [
<ide> * 'finder' => 'custom',
<del> * 'allowedSort' => ['title', 'author_id', 'comment_count'],
<add> * 'sortableFields' => ['tit... | 4 |
Python | Python | remove bad security advice about send_file | 29f7c10a5dea499f64188e29a4e08161dbf14eff | <ide><path>flask/helpers.py
<ide> def send_file(filename_or_fp, mimetype=None, as_attachment=False,
<ide> guessing requires a `filename` or an `attachment_filename` to be
<ide> provided.
<ide>
<del> Please never pass filenames to this function from user sources without
<del> checking them first. Somethi... | 1 |
Text | Text | add energy solutions to inthewild.md | fd62f603028319bb4ae7d857d9d70feddb6633bd | <ide><path>INTHEWILD.md
<ide> Currently, **officially** using Airflow:
<ide> 1. [Elai Data](https://www.elaidata.com/) [[@lgov](https://github.com/lgov)]
<ide> 1. [EllisDon](http://www.ellisdon.com/) [[@d2kalra](https://github.com/d2kalra) & [@zbasama](https://github.com/zbasama)]
<ide> 1. [Endesa](https://www.endesa.c... | 1 |
Go | Go | keep parser.directive internal to parser | 64c4c1c3d5e0fe364d83db5a8dc99a24fd121754 | <ide><path>builder/dockerfile/builder.go
<ide> type Builder struct {
<ide> disableCommit bool
<ide> cacheBusted bool
<ide> buildArgs *buildArgs
<del> directive *parser.Directive
<add> escapeToken rune
<ide>
<ide> imageCache builder.ImageCache
<ide> from builder.Image
<ide> func NewBuilder(client... | 11 |
Ruby | Ruby | add migrate command for migrating renamed | abf6b6f6cf31277ec1350fc7f7d16a7d23de882a | <ide><path>Library/Homebrew/cmd/migrate.rb
<add>require "migrator"
<add>require "formula_renames"
<add>
<add>module Homebrew
<add> def migrate
<add> raise FormulaUnspecifiedError if ARGV.named.empty?
<add>
<add> ARGV.resolved_formulae.each do |f|
<add> if f.oldname
<add> unless (rack = HOMEBREW_CELLA... | 1 |
Python | Python | implement batch shuffle | 48ea8dfb4748a57c90801f1cfd570b26996e365a | <ide><path>keras/models.py
<ide> def standardize_y(y):
<ide> y = np.expand_dims(y, 1)
<ide> return y
<ide>
<add>def batch_shuffle(index_array, batch_size):
<add> batch_count = int(len(index_array)/batch_size)
<add> # to reshape we need to be cleanly divisible by batch size
<add> # we stash extra i... | 1 |
Go | Go | remove old struct | da1a77defd765b5caf3336825292e1ecd8a7d320 | <ide><path>daemon/inspect.go
<ide> import (
<ide> "fmt"
<ide>
<ide> "github.com/docker/docker/api/types"
<del> "github.com/docker/docker/runconfig"
<ide> )
<ide>
<del>type ContainerJSONRaw struct {
<del> *Container
<del> HostConfig *runconfig.HostConfig
<del>
<del> // Unused fields for backward compatibility with A... | 1 |
Javascript | Javascript | remove settimeout in test-net-connect-unref | 586a7a4b1326dbc0603593edbc12aaec43dbe682 | <ide><path>test/internet/test-net-connect-unref.js
<ide> const common = require('../common');
<ide> const net = require('net');
<ide>
<del>const TIMEOUT = 10 * 1000;
<del>
<ide> const client = net.createConnection(53, '8.8.8.8', function() {
<ide> client.unref();
<ide> });
<ide>
<ide> client.on('close', common.must... | 1 |
Ruby | Ruby | add fuzzy search results | d455ca937784aa4e1b282579064202cafb780c34 | <ide><path>Library/Homebrew/search.rb
<ide> def search_formulae(string_or_regex)
<ide> .search(string_or_regex)
<ide> .sort
<ide>
<add> results += Formula.fuzzy_search(string_or_regex)
<add>
<ide> results.map do |name|
<ide> formula, canonical_full_name = begin
<ide> ... | 1 |
Javascript | Javascript | load all babel libs dynamically | 21833ab508194ed27a5b2fb8cb782a41a6e789dd | <ide><path>client/src/templates/Challenges/rechallenge/transformers.js
<ide> import {
<ide> stubTrue
<ide> } from 'lodash';
<ide>
<del>import * as Babel from '@babel/standalone';
<del>import presetEnv from '@babel/preset-env';
<del>import presetReact from '@babel/preset-react';
<ide> import protect from '@freecodeca... | 1 |
Text | Text | fix createportal link in api docs | e3d710e60a691b4d7dddbf90e33b0d624e89dd7a | <ide><path>docs/docs/reference-react-dom.md
<ide> The `react-dom` package provides DOM-specific methods that can be used at the to
<ide> - [`hydrate()`](#hydrate)
<ide> - [`unmountComponentAtNode()`](#unmountcomponentatnode)
<ide> - [`findDOMNode()`](#finddomnode)
<del>- [`createPortal()`](#createPortal)
<add>- [`creat... | 1 |
Javascript | Javascript | move generate() to construct() | 40de5a9c99eea7f1952e13c4aaf18f9cf8d96abc | <ide><path>examples/jsm/nodes/utils/MatcapUVNode.js
<ide> class MatcapUVNode extends TempNode {
<ide>
<ide> }
<ide>
<del> generate( builder ) {
<add> construct() {
<ide>
<ide> const x = normalize( vec3( positionViewDirection.z, 0, negate( positionViewDirection.x ) ) );
<ide> const y = cross( positionViewDirecti... | 2 |
Ruby | Ruby | add new module | 35e2209c10ffcf6a666ac4a8051a1f20801895ea | <ide><path>Library/Homebrew/os/mac/architecture_list.rb
<add>module ArchitectureListExtension
<add> # @private
<add> def fat?
<add> length > 1
<add> end
<add>
<add> # @private
<add> def intel_universal?
<add> intersects_all?(Hardware::CPU::INTEL_32BIT_ARCHS, Hardware::CPU::INTEL_64BIT_ARCHS)
<add> end
<add>... | 2 |
Javascript | Javascript | remove socket ondata/onend in parser cleanup | bce68134b647e6f102acf8e8f8ab3b153858d32c | <ide><path>lib/http.js
<ide> ClientRequest.prototype.onSocket = function(socket) {
<ide> var freeParser = function() {
<ide> if (parser) {
<ide> parsers.free(parser);
<add> parser.socket.onend = null;
<add> parser.socket.ondata = null;
<add> parser.socket = null;
<ide> par... | 1 |
Python | Python | divide commands into "actions"/"groups" sections | 22d6dcfe55b11eea7b734188dfeb012725984d3c | <ide><path>airflow/cli/cli_parser.py
<ide> import json
<ide> import os
<ide> import textwrap
<del>from argparse import ArgumentError, RawTextHelpFormatter
<add>from argparse import Action, ArgumentError, RawTextHelpFormatter
<ide> from typing import Callable, Dict, Iterable, List, NamedTuple, Set, Union
<ide>
<ide> fr... | 2 |
Ruby | Ruby | add tests for simple match with namespace | 5a5760828b998997048dc04ce3e83ecf50ae6e7b | <ide><path>actionpack/test/dispatch/routing_test.rb
<ide> def self.matches?(request)
<ide> match 'articles/:year/:month/:day/:title', :to => "articles#show", :as => :article
<ide>
<ide> namespace :account do
<add> match 'description', :to => "account#description", :as => "description"
<ide> ... | 1 |
Javascript | Javascript | add child_process customfds test | d0ed173d6d3e1ee394901da167cb836ce1c83772 | <ide><path>test/parallel/test-child-process-custom-fds.js
<add>'use strict';
<add>const common = require('../common');
<add>const assert = require('assert');
<add>
<add>// Verify that customFds is used if stdio is not provided.
<add>{
<add> const msg = 'child_process: options.customFds option is deprecated. ' +
<add> ... | 1 |
Ruby | Ruby | update list_spec.rb for cask full_name | 65d5c11f15644bc0103e5cb87011d4ba7a61b586 | <ide><path>Library/Homebrew/test/cask/cmd/list_spec.rb
<ide> let(:casks) { ["local-caffeine", "local-transmission", "third-party/tap/third-party-cask"] }
<ide> let(:expected_output) {
<ide> <<~EOS
<del> [{"token":"local-caffeine","full_token":"homebrew/cask/local-caffeine","tap":"homebrew/cask","na... | 1 |
Text | Text | fix nits in tools/doc/readme.md | d28edf97fa5cb863b5497cc3964c103f782d8b62 | <ide><path>tools/doc/README.md
<ide> Here's how the node docs work.
<ide>
<del>1:1 relationship from `lib/<module>.js` to `doc/api/<module>.md`
<add>1:1 relationship from `lib/<module>.js` to `doc/api/<module>.md`.
<ide>
<ide> Each type of heading has a description block.
<ide>
<ide> ```md
<del>## module
<del><!-- Y... | 1 |
Python | Python | add missing entries in mappings | 3b1bbefc476cdd710273c79f55f521a6d91083c3 | <ide><path>src/transformers/models/auto/feature_extraction_auto.py
<ide> ("regnet", "ConvNextFeatureExtractor"),
<ide> ("poolformer", "PoolFormerFeatureExtractor"),
<ide> ("maskformer", "MaskFormerFeatureExtractor"),
<add> ("data2vec-audio", "Wav2Vec2FeatureExtractor"),
<add> ("dat... | 3 |
Ruby | Ruby | allow retrieving tabs from arbitrary kegs | dc1be896d8edb63cf1afd168a331a86b6fe2f289 | <ide><path>Library/Homebrew/tab.rb
<ide> def self.from_file path
<ide> return tab
<ide> end
<ide>
<add> def self.for_keg keg
<add> path = keg+'INSTALL_RECEIPT.json'
<add>
<add> if path.exist?
<add> self.from_file path
<add> else
<add> self.dummy_tab Formula.factory(keg.parent.basename)
<add> ... | 1 |
Go | Go | fix import path | 5af8cfd3b16b6bc1754537fb5424365839ad2fc4 | <ide><path>volume/local/local_unix.go
<ide> import (
<ide> "path/filepath"
<ide> "strings"
<ide>
<del> "src/github.com/pkg/errors"
<add> "github.com/pkg/errors"
<ide>
<ide> "github.com/docker/docker/pkg/mount"
<ide> ) | 1 |
PHP | PHP | improve api documentation for typeinterface | 83c3a682993c921301af4f45465fc7fd027346de | <ide><path>src/Database/TypeInterface.php
<ide> namespace Cake\Database;
<ide>
<ide> /**
<del> * Encapsulates all conversion functions for values coming from database into PHP and
<del> * going from PHP into database.
<add> * Encapsulates all conversion functions for values coming from a database into PHP and
<add> * ... | 1 |
PHP | PHP | change default red to use the high intensity code | 38ed099e265f685b0682573e2ee752a0601a5d9f | <ide><path>src/Console/ConsoleOutput.php
<ide> class ConsoleOutput
<ide> */
<ide> protected static $_foregroundColors = [
<ide> 'black' => 30,
<del> 'red' => 31,
<add> 'red' => 91,
<ide> 'green' => 32,
<ide> 'yellow' => 33,
<ide> 'blue' => 34,
<ide><path>tests/Test... | 2 |
Python | Python | add solution for project euler problem 72 | d8f5b31fab57cc009e87a8d62c8d03075f66e9bd | <ide><path>project_euler/problem_072/sol2.py
<add>"""
<add>Project Euler Problem 72: https://projecteuler.net/problem=72
<add>
<add>Consider the fraction, n/d, where n and d are positive integers. If n<d and HCF(n,d)=1,
<add>it is called a reduced proper fraction.
<add>
<add>If we list the set of reduced proper fractio... | 1 |
PHP | PHP | limit repeated queries when token is not valid | 3f0269f97344deed0b7b5279d368a099837c7483 | <ide><path>src/Illuminate/Auth/Guard.php
<ide> class Guard {
<ide> */
<ide> protected $loggedOut = false;
<ide>
<add> /**
<add> * Indicates if a token user retrieval has been attempted.
<add> *
<add> * @var bool
<add> */
<add> protected $tokenRetrievalAttempted = false;
<add>
<ide> /**
<ide> * Create a new a... | 1 |
Python | Python | fix decoding errors | 5652b078516bb33520e9e7db5c21802bcec17003 | <ide><path>numpy/distutils/exec_command.py
<ide> import os
<ide> import sys
<ide> import subprocess
<add>import locale
<ide>
<ide> from numpy.distutils.misc_util import is_sequence, make_temp_file
<ide> from numpy.distutils import log
<ide> def _exec_command(command, use_shell=None, use_tee = None, **env):
<ide> #... | 1 |
Javascript | Javascript | fix experiments loading npm wasm | 616e0d7ee88dd33d3fda793b790adee92468fee0 | <ide><path>examples/with-webassembly/next.config.js
<ide> module.exports = {
<ide> config.output.webassemblyModuleFilename = 'static/wasm/[modulehash].wasm'
<ide>
<ide> // Since Webpack 5 doesn't enable WebAssembly by default, we should do it manually
<del> config.experiments = { asyncWebAssembly: true }
<a... | 1 |
Python | Python | add check for token_type_ids before tensorizing | c76c3cebed3c707178d9f721349c5abd5206a57f | <ide><path>src/transformers/tokenization_utils.py
<ide> def prepare_for_model(
<ide> # Prepare inputs as tensors if asked
<ide> if return_tensors == "tf" and is_tf_available():
<ide> encoded_inputs["input_ids"] = tf.constant([encoded_inputs["input_ids"]])
<del> encoded_inputs["tok... | 1 |
Go | Go | remove api, as it's no longer used | c425188bc07b3f6fe5826021cdd99cf72bf310ed | <ide><path>libnetwork/api/api.go
<del>package api
<del>
<del>import (
<del> "encoding/json"
<del> "fmt"
<del> "io"
<del> "net/http"
<del> "strconv"
<del> "strings"
<del>
<del> "github.com/docker/docker/libnetwork"
<del> "github.com/docker/docker/libnetwork/netlabel"
<del> "github.com/docker/docker/libnetwork/netutils"
... | 3 |
Text | Text | add a section on decentralized apps | 31ff1b08ea28304a124ed150be438f48622a5c55 | <ide><path>guide/english/blockchain/smart-contracts/index.md
<ide> First conceived in [1994](http://www.fon.hum.uva.nl/rob/Courses/InformationInSp
<ide>
<ide> A smart contract is a computer code running on top of a blockchain containing a set of rules under which the parties to that smart contract agree to interact w... | 1 |
Go | Go | remove unused parameter in download | 12180948be8040a4cdf99a0e660098cd33e32832 | <ide><path>api.go
<ide> func postBuild(srv *Server, version float64, w http.ResponseWriter, r *http.Requ
<ide> }
<ide> context = c
<ide> } else if utils.IsURL(remoteURL) {
<del> f, err := utils.Download(remoteURL, ioutil.Discard)
<add> f, err := utils.Download(remoteURL)
<ide> if err != nil {
<ide> return e... | 4 |
Text | Text | fix typo in nativemodulesios.md | d1f42a82d235af405bd0bb4fcbaf4f4f27075f09 | <ide><path>docs/NativeModulesIOS.md
<ide> This is a more advanced guide that shows how to build a native module. It assume
<ide>
<ide> This guide will use [iOS Calendar API](https://developer.apple.com/library/mac/documentation/DataManagement/Conceptual/EventKitProgGuide/Introduction/Introduction.html) example. Let's ... | 1 |
Text | Text | add redux-analytics to ecosystem | 0d9b44c7c7a5bc1be00f9ce6a18541a16eef8610 | <ide><path>docs/introduction/Ecosystem.md
<ide> On this page we will only feature a few of them that the Redux maintainers have
<ide> * [redux-rx](https://github.com/acdlite/redux-rx) — RxJS utilities for Redux, including a middleware for Observable
<ide> * [redux-logger](https://github.com/fcomb/redux-logger) — Log ev... | 1 |
Javascript | Javascript | add tests for daysinmonth overflow behavior | dfd7bcedfbd360a6f012faf4f90d78bb6f6044cc | <ide><path>src/test/moment/days_in_month.js
<ide> import { module, test } from '../qunit';
<ide> import moment from '../../moment';
<ide> import each from '../helpers/each';
<add>import { daysInMonth } from '../../lib/units/month';
<ide>
<ide> module('days in month');
<ide>
<ide> test('days in month leap years', func... | 1 |
Python | Python | update the codes due to recent change in deeplab. | f0899f18e178afb4b57c50ec32a7e8952e6f6a99 | <ide><path>research/feelvos/common.py
<ide> def __new__(cls,
<ide> self.classification_loss = FLAGS.classification_loss
<ide>
<ide> return self
<add>
<add>
<add>def parse_decoder_output_stride():
<add> """Parses decoder output stride.
<add>
<add> FEELVOS assumes decoder_output_stride = 4. Thus, this function... | 5 |
Python | Python | add type hints for convbert model | 41bfc1e2620b56219bab5ea4d8f4cf2769479461 | <ide><path>src/transformers/models/convbert/modeling_convbert.py
<ide> import math
<ide> import os
<ide> from operator import attrgetter
<add>from typing import Optional, Tuple, Union
<ide>
<ide> import torch
<ide> import torch.utils.checkpoint
<ide> def set_output_embeddings(self, word_embeddings):
<ide> )
<ide> ... | 2 |
Go | Go | remove unneeded sleep and imagelist call | f9fedf1308cc2730edb6cf650c0655946f008b29 | <ide><path>integration/build/build_test.go
<ide> import (
<ide> "io/ioutil"
<ide> "strings"
<ide> "testing"
<del> "time"
<ide>
<ide> "github.com/docker/docker/api/types"
<ide> "github.com/docker/docker/api/types/filters"
<ide> func TestBuildMultiStageParentConfig(t *testing.T) {
<ide> resp.Body.Close()
<ide> as... | 1 |
Java | Java | fix javadoc for maybe.tosingle | ea6c7de9bbac58bec6cc286d31255febc6c74ed8 | <ide><path>src/main/java/io/reactivex/Maybe.java
<ide> public final Observable<T> toObservable() {
<ide>
<ide> /**
<ide> * Converts this Maybe into a Single instance composing cancellation
<del> * through and turning an empty Maybe into a signal of NoSuchElementException.
<add> * through and turning a... | 1 |
Text | Text | add a new solution using reduce | 9d30fe70279d5e82e1bd15e89771060b67b94442 | <ide><path>guide/english/certifications/javascript-algorithms-and-data-structures/basic-algorithm-scripting/factorialize-a-number/index.md
<ide> factorialize(5);
<ide>
<ide> * <a href='https://www.geeksforgeeks.org/tail-recursion/' target='_blank' rel='nofollow'>Tail Recursion</a>
<ide> </details>
<add>
<add><detail... | 1 |
Python | Python | fallback celery_timezone to django's time_zone | 43de06a2d24746802e4a5231e8a580fa3d0f015b | <ide><path>celery/app/utils.py
<ide> def BROKER_HOST(self):
<ide> return (os.environ.get('CELERY_BROKER_URL') or
<ide> self.first('BROKER_URL', 'BROKER_HOST'))
<ide>
<add> @property
<add> def CELERY_TIMEZONE(self):
<add> # this way we also support django's time zone.
<add> r... | 1 |
Ruby | Ruby | add raises for invalid input | 90e830c19e1b37215b19af10c7d131f4c209c10d | <ide><path>Library/Homebrew/cmd/info.rb
<ide> def info
<ide>
<ide> if args.json
<ide> raise UsageError, "Invalid JSON version: #{args.json}" unless ["v1", true].include? args.json
<add> raise UsageError, "This command's option requires a formula argument" if ARGV.named.empty?
<ide>
<ide> print_js... | 5 |
Javascript | Javascript | add delimiter to regex for trackname | bc0696718d5fc2ee4c83acd0906559a83a547983 | <ide><path>src/animation/PropertyBinding.js
<ide> PropertyBinding.parseTrackName = function( trackName ) {
<ide> // uuid.objectName[objectIndex].propertyName[propertyIndex]
<ide> // parentName/nodeName.property
<ide> // parentName/parentName/nodeName.property[index]
<del> // .bone[Armature.DEF_cog].positi... | 1 |
Javascript | Javascript | add classid property for <object/> tag | a185f09943a2488cd4ea6dc99288da4cdd7d4cad | <ide><path>src/browser/ui/dom/HTMLDOMPropertyConfig.js
<ide> var HTMLDOMPropertyConfig = {
<ide> cellSpacing: null,
<ide> charSet: MUST_USE_ATTRIBUTE,
<ide> checked: MUST_USE_PROPERTY | HAS_BOOLEAN_VALUE,
<add> classID: MUST_USE_ATTRIBUTE,
<ide> // To set className on SVG elements, it's necessary to ... | 1 |
Javascript | Javascript | avoid unnecessary buffer allocations | ebedf6b653ac2a5cb49f5c9d3e6ac6fffedbf369 | <ide><path>lib/adapters/http.js
<ide> module.exports = function httpAdapter(config) {
<ide> });
<ide>
<ide> stream.on('end', function handleStreamEnd() {
<del> var responseData = Buffer.concat(responseBuffer);
<add> var responseData = responseBuffer.length === 1 ? responseBuffer[0] : ... | 1 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.