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 |
|---|---|---|---|---|---|
Java | Java | synchronize message sending | b796c1e87eea10bb6ddd7dc5c3b6b1befa3806a7 | <ide><path>spring-websocket/src/main/java/org/springframework/web/socket/sockjs/transport/session/AbstractHttpSockJsSession.java
<ide> public abstract class AbstractHttpSockJsSession extends AbstractSockJsSession {
<ide>
<ide> private final Object responseLock = new Object();
<ide>
<del> private volatile boolean req... | 4 |
PHP | PHP | use a collection | cb2eb7963b29aafe63c87e1d2b1e633ecd0c25b0 | <ide><path>src/Illuminate/Foundation/Console/RouteListCommand.php
<ide> protected function displayRoutes(array $routes)
<ide> */
<ide> protected function getMiddleware($route)
<ide> {
<del> $middlewares = $route->gatherMiddleware();
<del>
<del> foreach ($middlewares as $i => $middleware) {
<d... | 1 |
Ruby | Ruby | fix use of formbuilder.field_helpers | 1c0eece9ebfaf81b09ea9f7735020e714823314a | <ide><path>actionpack/lib/action_view/helpers/form_helper.rb
<ide> def initialize(object_name, object, template, options, proc)
<ide> @multipart = nil
<ide> end
<ide>
<del> (field_helpers - %w(label check_box radio_button fields_for hidden_field file_field)).each do |selector|
<add> (field_help... | 1 |
Text | Text | add a note | b173abaf49164e3a7fb0f41a3ca81a48fb58bd2e | <ide><path>docs/api-reference/next/link.md
<ide> export default Home
<ide>
<ide> `Link` accepts the following props:
<ide>
<del>- `href` - The path or URL to navigate to. This is the only required prop
<add>- `href` - The path or URL to navigate to. This is the only required prop. It can also be an object, see [examp... | 1 |
Mixed | Ruby | do nothing when the same block is included again | 8212dfcf14c63c006b9e1c37595f3d62eab052cf | <ide><path>activesupport/CHANGELOG.md
<add>* If the same block is `included` multiple times for a Concern, an exception is no longer raised.
<add>
<add> *Mark J. Titorenko*, *Vlad Bokov*
<add>
<ide> * Fix bug where `#to_options` for `ActiveSupport::HashWithIndifferentAccess`
<ide> would not act as alias for ... | 4 |
Javascript | Javascript | remove redundant word "the" | c8ef2feda98d8cc9fb59829148b3db1671ac3b9b | <ide><path>packages/react-dom/src/client/ReactDOMInput.js
<ide> export function postMountWrapper(
<ide> }
<ide> } else {
<ide> // When syncing the value attribute, the value property should use
<del> // the the wrapperState._initialValue property. This uses:
<add> // the wrapperState... | 1 |
Javascript | Javascript | simplify code for action helper | 4bed6d0e6bdae99574b2af1efb1b86b05f18ec95 | <ide><path>packages/ember-routing/lib/helpers/action.js
<ide> Ember.onLoad('Ember.Handlebars', function(Handlebars) {
<ide> contexts = a_slice.call(arguments, 1, -1);
<ide>
<ide> var hash = options.hash,
<del> controller;
<add> controller = options.data.keywords.controller;
<ide>
<ide> /... | 1 |
Ruby | Ruby | use time#compare_without_coercion for super speed | fcde948e43e07d2c4e32988e05f5920501a26364 | <ide><path>activesupport/lib/active_support/file_update_checker.rb
<ide> def max_mtime(paths)
<ide> paths.each do |path|
<ide> time = File.mtime(path)
<ide>
<del> if time < time_now && time > max_time
<add> # This avoids ActiveSupport::CoreExt::Time#time_with_coercion
<add> # which i... | 1 |
Ruby | Ruby | handle some github repo audit edge cases | c0c68b2b3fc258f7d1cbc7284fda1c99d51f6052 | <ide><path>Library/Homebrew/cmd/audit.rb
<ide> def audit_github_repository
<ide> _, user, repo = *regex.match(formula.homepage) unless user
<ide> return if !user || !repo
<ide>
<del> metadata = GitHub.repository(user, repo)
<add> repo.gsub!(/.git$/, "")
<add>
<add> begin
<add> metadata = GitHub.r... | 1 |
Text | Text | add backticks [ci-skip] | a84788e117de633cef89d996f90c6959756c41d7 | <ide><path>guides/source/action_controller_overview.md
<ide> Your application has a session for each user in which you can store small amount
<ide> * [`ActionDispatch::Session::CookieStore`][] - Stores everything on the client.
<ide> * [`ActionDispatch::Session::CacheStore`][] - Stores the data in the Rails cache.
<ide... | 4 |
PHP | PHP | fix scope nesting | d9cc1bdc6c624f81222ca8b467374409ebcd737b | <ide><path>src/Illuminate/Database/Eloquent/Builder.php
<ide> protected function applyScope($scope, $builder)
<ide> */
<ide> protected function shouldNestWheresForScope(QueryBuilder $query, $originalWhereCount)
<ide> {
<del> return $originalWhereCount && count($query->wheres) > $originalWhereCount;
... | 2 |
Ruby | Ruby | fix broken output on ci | 9ecdf117b3f8b68dde5bc98407ffffc9f73cc5bc | <ide><path>Library/Homebrew/brew.rb
<ide> class MissingEnvironmentVariables < RuntimeError; end
<ide> begin
<ide> trap("INT", std_trap) # restore default CTRL-C handler
<ide>
<add> if ENV["CI"]
<add> $stdout.sync = true
<add> $stderr.sync = true
<add> end
<add>
<ide> empty_argv = ARGV.empty?
<ide> help_f... | 1 |
PHP | PHP | fix arg passing in doesntcontain | 739d8472eb2c97c4a8d8f86eb699c526e42f57fa | <ide><path>src/Illuminate/Collections/Collection.php
<ide> public function contains($key, $operator = null, $value = null)
<ide> */
<ide> public function doesntContain($key, $operator = null, $value = null)
<ide> {
<del> return ! $this->contains($key, $operator, $value);
<add> return ! $this-... | 2 |
Ruby | Ruby | calculate actual delta in usage | b9b1b24e4e0c607bd27137f3a1928e1b6ee97908 | <ide><path>Library/Homebrew/cleanup.rb
<ide> def cleanup_path(path)
<ide> yield
<ide> end
<ide>
<del> @disk_cleanup_size += disk_usage
<add> @disk_cleanup_size += disk_usage - path.disk_usage
<ide> end
<ide>
<ide> def cleanup_lockfiles(*lockfiles) | 1 |
Javascript | Javascript | remove unused local variables | c5e39622b5799d03b5ae8e7a73415e1210d920eb | <ide><path>packages/ember-metal/lib/computed.js
<ide> function mkCpSetter(keyName, desc) {
<ide> return function(value) {
<ide> var m = meta(this, cacheable),
<ide> watched = (m.source===this) && m.watching[keyName]>0,
<del> ret, oldSuspended, lastSetValues;
<add> ret, oldSuspended;
<ide>
<... | 1 |
Javascript | Javascript | update islocal logic to enforce protocol and port | fb0b7534d7ccec36b582e819436bfc7c07062187 | <ide><path>lib/link.js
<ide> export default class Link extends Component {
<ide> function isLocal (href) {
<ide> const url = parse(href, false, true)
<ide> const origin = parse(getLocationOrigin(), false, true)
<del> return (!url.host || !url.hostname) ||
<del> (origin.host === url.host || origin.hostname === u... | 1 |
Python | Python | define xrange() in python 3 | bade0fedcdd0db1148d840eaa17d7dbed2511bf7 | <ide><path>tools/cpplint.py
<ide> import sys
<ide> import unicodedata
<ide>
<add>try:
<add> xrange
<add>except NameError:
<add> xrange = range
<add>
<ide>
<ide> logger = logging.getLogger('testrunner')
<ide> | 1 |
Javascript | Javascript | improve accuracy of offline warning | 22e24dfb5409cfb721fc0e1b80feeffd9156c86d | <ide><path>client/src/components/OfflineWarning/OfflineWarning.js
<ide> const propTypes = {
<ide> function OfflineWarning({ isOnline, isSignedIn }) {
<ide> return !isSignedIn || isOnline ? null : (
<ide> <div className='offline-warning'>
<del> We cannot reach the server to update your progress.
<add> Yo... | 1 |
Ruby | Ruby | check default_formula requirements | 395d798bc293aae877a92f9535c5621fea226876 | <ide><path>Library/Homebrew/cmd/test-bot.rb
<ide> def skip formula_name
<ide> puts "#{Tty.blue}==>#{Tty.white} SKIPPING: #{formula_name}#{Tty.reset}"
<ide> end
<ide>
<del> def satisfied_requirements? formula, spec
<add> def satisfied_requirements? formula, spec, dependency=nil
<ide> requirements ... | 1 |
Text | Text | add the syntax "for infinite loop " | 5a99e02a875c1cf19f56352d0f3cc5f212005930 | <ide><path>guide/english/c/for/index.md
<ide> The initialization statement is executed only once. Then, the test expression is
<ide>
<ide> The for loop is commonly used when the number of iterations is known.
<ide>
<del>## Example
<add>#### Example
<ide> ```c
<ide> #include <stdio.h>
<ide>
<ide> int main () {
<ide> ... | 1 |
Ruby | Ruby | update time_zone_options_for_select docs | 5ee4a57a26a7863c7ff610dd3a46c04e0f53f7f7 | <ide><path>actionview/lib/action_view/helpers/form_options_helper.rb
<ide> def grouped_options_for_select(grouped_options, selected_key = nil, options = {}
<ide> # an ActiveSupport::TimeZone.
<ide> #
<ide> # By default, +model+ is the ActiveSupport::TimeZone constant (which can
<del> # be obtaine... | 1 |
Javascript | Javascript | fix atom --dev with json config files | 18a308de575a463d20eb1d4e8852816c71f8ec51 | <ide><path>src/main-process/atom-application.js
<ide> class AtomApplication extends EventEmitter {
<ide> if (devMode) {
<ide> try {
<ide> windowInitializationScript = require.resolve(
<del> path.join(this.devResourcePath, 'src', 'initialize-application-window')
<add> path.j... | 1 |
Ruby | Ruby | add docs to collectionassociation#empty? | bf55f28af159ccfaa0bb8e5e0b52e50e14ede406 | <ide><path>activerecord/lib/active_record/associations/collection_association.rb
<ide> def length
<ide> load_target.size
<ide> end
<ide>
<del> # Equivalent to <tt>collection.size.zero?</tt>. If the collection has
<del> # not been already loaded and you are going to fetch the records anyway
<del... | 1 |
Ruby | Ruby | move existence check into helper script | aceb02125461be3f2224fa31fa5b9c3090d5d2d7 | <ide><path>Library/Homebrew/cask/pkg.rb
<ide> def special?(path)
<ide> set -euo pipefail
<ide>
<ide> for path in "${@}"; do
<add> if [[ ! -e "${path}" ]]; then
<add> continue
<add> fi
<add>
<ide> if [[ -e "${path}/.DS_Store" ]]; then
<ide> /bin/rm -f "${path}/.DS_St... | 1 |
PHP | PHP | fix case sensitive issue in table alias | 48e457ec5beede17f86bea433027906d248d0135 | <ide><path>tests/TestCase/ORM/ResultSetTest.php
<ide> public function testHasOneEagerLoaderLeavesEmptyAssocation() {
<ide> $this->assertEquals(1, $article->id);
<ide> $this->assertNotEmpty($article->title);
<ide>
<del> $article = $this->table->find()->where(['Articles.id' => 1])
<add> $article = $this->table->fi... | 1 |
Javascript | Javascript | destroy folds on fold marker click | c2206b88dac8158193b7743381f914628a96c677 | <ide><path>spec/text-editor-component-spec.js
<ide> describe('TextEditorComponent', () => {
<ide> expect(editor.getSelectedScreenRange()).toEqual([[2, 0], [5, 0]])
<ide> })
<ide>
<add> it('destroys folds when clicking on their fold markers', async () => {
<add> const {component, element, edit... | 2 |
Python | Python | update relatedfield#field_from_native coding style | f8a1256b1c006ee9ab46645a11ef19123b429a56 | <ide><path>rest_framework/fields.py
<ide> def field_from_native(self, data, files, field_name, into):
<ide> if self.read_only:
<ide> return
<ide>
<del> if field_name not in data and self.required:
<del> raise ValidationError(self.error_messages['required'])
<del> elif field... | 1 |
Javascript | Javascript | handle navigation keys when viewer is not focused | ce9400dc8b7a3dc74f7c531e93120797a66bbc07 | <ide><path>web/viewer.js
<ide> window.addEventListener('keydown', function keydown(evt) {
<ide> // Some shortcuts should not get handled if a control/input element
<ide> // is selected.
<ide> var curElement = document.activeElement || document.querySelector(':focus');
<del> if (curElement && (curElement.tagName.... | 1 |
Javascript | Javascript | execute backend challenge saga | c43dfe1eb7678d04dc9a6f5b29335efb957fdbe2 | <ide><path>client/src/templates/Challenges/redux/execute-challenge-saga.js
<ide> import {
<ide> challengeFilesSelector
<ide> } from './';
<ide>
<del>import { buildJSFromFiles, buildFromFiles } from '../utils/build';
<add>import {
<add> buildJSFromFiles,
<add> buildFromFiles,
<add> buildBackendChallenge
<add>} fro... | 2 |
PHP | PHP | fix incorrect triggering of callable strings | c68a773912328bd9684d89988a952cafb8eca157 | <ide><path>src/Http/Response.php
<ide> public function body($content = null)
<ide> }
<ide>
<ide> // Compatibility with closure/streaming responses
<del> if (is_callable($content)) {
<add> if (!is_string($content) && is_callable($content)) {
<ide> $this->stream = new CallbackSt... | 2 |
Ruby | Ruby | add tests for non glob dirs audit | a73c29fef21ccb7f45243500f04f1ed9965fdf38 | <ide><path>Library/Homebrew/rubocops/lines_cop.rb
<ide> def audit_formula(_node, _class_node, _parent_class_node, body_node)
<ide> problem "\"#{m.source}\" is deprecated, use a comparison to MacOS.version instead"
<ide> end
<ide> end
<del> #
<del> # dirPattern(body_... | 2 |
Ruby | Ruby | remove a redundant test assertion | 7a80ab54393b500ae08cc1cf93c93ece89097112 | <ide><path>activerecord/test/cases/finder_test.rb
<ide> def test_find_on_multiple_hash_conditions
<ide> assert Topic.where(author_name: "David", title: "The First Topic", replies_count: 1, approved: false).find(1)
<ide> assert_raise(ActiveRecord::RecordNotFound) { Topic.where(author_name: "David", title: "The F... | 1 |
PHP | PHP | remove duplicate method | a6e1aa68b47903c54410bcca62ae96ee8fd7a630 | <ide><path>src/Illuminate/Foundation/Console/Kernel.php
<ide> public function all()
<ide> return $this->getArtisan()->all();
<ide> }
<ide>
<del> /**
<del> * Get all of the commands registered with the console.
<del> *
<del> * @return array
<del> */
<del> public function all()
<del> {
<del> $this->bootstrap();
... | 1 |
PHP | PHP | log query execution time and rows | ba917d38a4aab270d28de48543a5a2936ea1a2c2 | <ide><path>src/Database/Log/LoggedQuery.php
<ide> class LoggedQuery
<ide> */
<ide> public function __toString()
<ide> {
<del> return $this->query;
<add> return "duration={$this->took} rows={$this->numRows} {$this->query}";
<ide> }
<ide> }
<ide><path>tests/TestCase/Database/Log/LoggedQuery... | 3 |
Javascript | Javascript | run the new integration tests in htmlbars | dd38edea81ae142946eb1290f5495334bf7bd59b | <ide><path>packages/ember-glimmer/tests/utils/test-case.js
<ide> let assert = QUnit.assert;
<ide>
<ide> const TextNode = window.Text;
<ide> const HTMLElement = window.HTMLElement;
<add>const Comment = window.Comment;
<ide>
<ide> export class TestCase {
<ide> teardown() {}
<ide> }
<ide>
<add>function isMarker(node)... | 6 |
Text | Text | update changelog for new patch release | c306e4f7f38447f24f197ec3c4d34661996f9620 | <ide><path>CHANGELOG.md
<ide> CHANGELOG
<ide> =========
<ide>
<ide> ## HEAD (Unreleased)
<del>_(none)_
<add>* @gkatsev re-published to make sure that the audio button has css
<ide>
<ide> --------------------
<ide> | 1 |
Python | Python | add bootstrap task | 57fc6f53283986d221651a434145ea3510f07040 | <ide><path>pavement.py
<ide> import os
<add>import sys
<ide> import subprocess
<ide> try:
<ide> from hash import md5
<ide> RELEASE = 'doc/release/1.3.0-notes.rst'
<ide> LOG_START = 'tags/1.2.0'
<ide> LOG_END = 'master'
<add>BOOTSTRAP_DIR = "bootstrap"
<add>BOOTSTRAP_PYEXEC = "%s/bin/python" % BOOTSTRAP_DIR
<add>BOO... | 1 |
Python | Python | combine test_sparse functions together | 5c224403d3948983035682a1f71bc2e0e64cbb87 | <ide><path>tests/keras/engine/test_training.py
<ide> def gen_data(batch_sz):
<ide>
<ide>
<ide> @keras_test
<del>def test_sparse_input_target_fit():
<del> test_inputs = [sparse.random(6, 3, density=0.25).tocsr() for _ in range(2)]
<del> test_outputs = [sparse.random(6, i, density=0.25).tocsr() for i in range(3, ... | 1 |
Text | Text | add link to v8 | 6a2314acd7c23b0aa9761751fe304184bdedb155 | <ide><path>doc/api/addons.md
<ide> Node-API.
<ide> When not using Node-API, implementing addons is complicated,
<ide> involving knowledge of several components and APIs:
<ide>
<del>* V8: the C++ library Node.js uses to provide the
<add>* [V8][]: the C++ library Node.js uses to provide the
<ide> JavaScript implementa... | 1 |
Python | Python | fix variable substitution in error message | 4f30cb7c57c4b5d74ba98953f59670a647623f7a | <ide><path>flask/cli.py
<ide> def locate_app(script_info, app_id, raise_if_not_found=True):
<ide> )
<ide> elif raise_if_not_found:
<ide> raise NoAppException(
<del> 'The file/path provided (%s) does not appear to exist. Please'
<del> ' verify the path is cor... | 1 |
Javascript | Javascript | fix a url regression | 307f39ce9ed8f4d3de06f63cd1855157be2db82f | <ide><path>lib/url.js
<ide> var protocolPattern = /^([a-z0-9]+:)/i,
<ide> // them.
<ide> nonHostChars = ['%', '/', '?', ';', '#']
<ide> .concat(unwise).concat(autoEscape),
<add> nonAuthChars = ['/', '@', '?', '#'].concat(delims),
<ide> hostnameMaxLen = 255,
<ide> hostnamePartPattern = /^[a-zA-Z... | 2 |
Javascript | Javascript | fix intersect test parameters to translate | 1ef8062877113d4e2c7b473368d2f93536e49359 | <ide><path>src/math/Box3.js
<ide> Object.assign( Box3.prototype, {
<ide>
<ide> translate: function ( offset ) {
<ide>
<add> if ( ! offset.isVector3 ) {
<add>
<add> throw new Error( 'THREE.Box3: .translate() expects a Vector3.' );
<add>
<add> }
<add>
<ide> this.min.add( offset );
<ide> this.max.add( offset );... | 2 |
Text | Text | remove the mock guide | 19312f361913bf1ff9eccfc2aaf498b2264cc6ec | <ide><path>mock-guide/README.md
<del># Mock Guide Articles
<del>
<del>This directory contains mock guide articles for testing while developing the client source code. If you are looking forward to contribute to a guide article you should check this directory instead: [`/guide`](/guide)
<ide><path>mock-guide/english/acc... | 300 |
Text | Text | add documentation for activations and objectives | 0eddec222ee1a68d613a8ecfb4f5ee2ef41de188 | <ide><path>docs/sources/activations.md
<add># Activations
<add>
<add>## Usage of activations
<add>
<add>Activations can either be used through an `Activation` layer, or through the `activation` argument supported by all forward layers:
<add>
<add>```python
<add>from keras.layers.core import Activation, Dense
<add>
<add... | 4 |
Javascript | Javascript | eliminate redundancy of deferred.then() | 412d910697f7c33a29066009930e1373fd80b27a | <ide><path>src/deferred.js
<ide> jQuery.extend({
<ide> return jQuery.Deferred(function( newDefer ) {
<ide> jQuery.each( tuples, function( i, tuple ) {
<ide> var action = tuple[ 0 ],
<del> fn = fns[ i ];
<add> fn = jQuery.isFunction( fns[ i ] ) && fns[ i ];
<ide> // deferred[ done ... | 1 |
Python | Python | fix one small error in test(all=1) | f5df20ee8a938f8504ed23cd5dc8913e01219f5d | <ide><path>numpy/ma/tests/test_old_ma.py
<ide> import types, time
<ide> from numpy.ma import *
<ide> from numpy.core.numerictypes import float32
<add>from numpy.ma.core import umath
<ide> from numpy.testing import NumpyTestCase, NumpyTest
<ide> pi = numpy.pi
<ide> def eq(v,w, msg=''): | 1 |
PHP | PHP | remove extra whitespace | 527fa04661cc9557158269691fd8e37f1cf2ffb4 | <ide><path>src/Mailer/Mailer.php
<ide> * The onRegistration method converts the application event into a mailer method.
<ide> * Our mailer could either be registered in the application bootstrap, or
<ide> * in the Table class' initialize() hook.
<del> *
<add> *
<ide> * @method Email to($email = null, $name = null)... | 1 |
Python | Python | add new module numpy.f2py.symbolic | 96e63aaf5c2720c4adc6c4440f2732ee6a73b260 | <ide><path>numpy/f2py/crackfortran.py
<ide> # As the needed functions cannot be determined by static inspection of the
<ide> # code, it is safest to use import * pending a major refactoring of f2py.
<ide> from .auxfuncs import *
<del>from .symbolic import Expr, Language
<ide> from . import symbolic
<ide>
<ide> f2py_ve... | 2 |
PHP | PHP | fix tests for cli runner | 15d01bf901c3c3451f7a1d36f9b7ef6e3ec1e7ba | <ide><path>lib/Cake/Test/Case/BasicsTest.php
<ide> public function testDebug() {
<ide> * @return void
<ide> */
<ide> public function testPr() {
<add> $this->skipIf(php_sapi_name() == 'cli', 'Skipping web test in cli mode');
<ide> ob_start();
<ide> pr('this is a test');
<ide> $result = ob_get_clean();
<ide> pu... | 1 |
Text | Text | add link to first mention of d3.map | c5b9069d4ee0af7cbf99edbad42fc2a81df2d4d0 | <ide><path>CHANGES.md
<ide> var yields = [
<ide> var sites = d3.set(yields, function(d) { return d.site; }); // Grand Rapids, Duluth, Waseca, Crookston, Morris
<ide> ```
<ide>
<del>The d3.map constructor also follows the standard array accessor argument pattern.
<add>The [d3.map](https://github.com/d3/d3-collection#ma... | 1 |
Text | Text | remove line break between badges (#330) | 9950ee73a3b8b45c98d095b880bf1ca4c257a2b8 | <ide><path>README.md
<ide>
<ide> [](https://travis-ci.org/zeit/next.js)
<ide> [](https://coveralls.io/r/zeit/next.js?branch=master)
<del>
<ide> [:
<ide> mape = MAPE = mean_absolute_percentage_error
<ide> msle = MSLE = mean_squared_logarithmic_error
<ide> cosine = cosine_similarity = cosine_proximity
<del>MeanIoU = K.MeanIoU
<add>if K.backend() == 'tensorflow':
<add> MeanIoU = K.MeanIoU
<ide>
<ide> ... | 1 |
Ruby | Ruby | fix configuration names | 3c9a28d6e4a56e4aae475dbf6051e4ee33150bba | <ide><path>lib/active_vault/railtie.rb
<ide>
<ide> module ActiveVault
<ide> class Railtie < Rails::Railtie # :nodoc:
<del> config.action_file = ActiveSupport::OrderedOptions.new
<add> config.active_vault = ActiveSupport::OrderedOptions.new
<ide>
<ide> config.eager_load_namespaces << ActiveVault
<ide>
<de... | 1 |
Python | Python | fix logic in handling of dtype in append_fields | 3b8cf12ee19994389ae3261666dd32cced4787be | <ide><path>numpy/lib/recfunctions.py
<ide> def append_fields(base, names, data=None, dtypes=None,
<ide> if dtypes is None:
<ide> data = [np.array(a, copy=False, subok=True) for a in data]
<ide> data = [a.view([(name, a.dtype)]) for (name, a) in zip(names, data)]
<del> elif not hasattr(dtypes, '__... | 1 |
Python | Python | move some tests and add some new ones | 5eb8a3e812d74fdd54a98f01570ae5d3391c915c | <ide><path>test/storage/test_s3.py
<ide> import unittest
<ide>
<ide> from libcloud.common.types import InvalidCredsError
<add>from libcloud.common.types import LibcloudError
<ide> from libcloud.storage.base import Container, Object
<ide> from libcloud.storage.types import ContainerDoesNotExistError
<ide> from libcloud... | 1 |
Javascript | Javascript | fix permanent deoptimizations | e9c02c6762dd5fe9664e5972b8e6307e6da8e68f | <ide><path>lib/_stream_readable.js
<ide> Readable.prototype.unpipe = function(dest) {
<ide> }
<ide>
<ide> // try to find the right one.
<del> const index = state.pipes.indexOf(dest);
<add> var index = state.pipes.indexOf(dest);
<ide> if (index === -1)
<ide> return this;
<ide> | 1 |
Ruby | Ruby | fix upsert method comment | ab6da0c4a88480d932051f0a2f6dc0c96593d948 | <ide><path>activerecord/lib/active_record/persistence.rb
<ide> def insert_all!(attributes, returning: nil)
<ide> InsertAll.new(self, attributes, on_duplicate: :raise, returning: returning).execute
<ide> end
<ide>
<del> # Updates or inserts (upserts) multiple records into the database in a
<add> ... | 1 |
Ruby | Ruby | fix typo in formula.rb | c4972e218f0fbea3deae73e9af3efb2ae1cecf18 | <ide><path>Library/Homebrew/formula.rb
<ide> def self.class name
<ide> end
<ide>
<ide> def self.path name
<del> Pathanme.new(HOMEBREW_PREFIX)+'Formula'+(name.downcase+'.rb')
<add> Pathname.new(HOMEBREW_PREFIX)+'Library'+'Formula'+(name.downcase+'.rb')
<ide> end
<ide>
<ide> def self.create name | 1 |
Javascript | Javascript | add `kemptyobject` to internal/util | a9b1fd3987fae5ad5340859a6088b86179b576c5 | <ide><path>lib/internal/util.js
<ide> const {
<ide> ObjectGetOwnPropertyDescriptor,
<ide> ObjectGetOwnPropertyDescriptors,
<ide> ObjectGetPrototypeOf,
<add> ObjectFreeze,
<ide> ObjectSetPrototypeOf,
<ide> Promise,
<ide> ReflectApply,
<ide> const lazyDOMException = hideStackFrames((message, name) => {
<ide>... | 2 |
Text | Text | fix typos in doc/api/cli.md | 5ba5cc861987a3f9fd3de9dfe638af53f92a7852 | <ide><path>doc/api/cli.md
<ide> changes:
<ide>
<ide> Enable [Source Map v3][Source Map] support for stack traces.
<ide>
<del>When using a transpiler, such as TypeScript, strack traces thrown by an
<add>When using a transpiler, such as TypeScript, stack traces thrown by an
<ide> application reference the transpiled co... | 1 |
Text | Text | improve build script | 140be99343c23801504e443ad7ab9e747f874ccf | <ide><path>examples/README.md
<ide> If you think an example is missing, please report it as issue. :)
<ide>
<ide> # Building an Example
<del>1. Run `yarn setup` in the root of the project.
<del>2. Run `yarn link webpack` in the root of the project.
<add>1. Run `yarn` in the root of the project.
<add>2. Run `yarn setup... | 1 |
PHP | PHP | correct greedy replace | 9e0e19c5acaf00f5310a501d96687e9415c40dd2 | <ide><path>lib/Cake/bootstrap.php
<ide> /**
<ide> * Path to the application's libs directory.
<ide> */
<del> define('APPCAKE', APP.'Lib'.DS);
<add> define('APPLIBS', APP.'Lib'.DS);
<ide>
<ide> /**
<ide> * Path to the configuration files directory. | 1 |
Javascript | Javascript | allow empty json response | 9ba24c54d60e643b1450cc5cfa8f990bd524c130 | <ide><path>src/ng/http.js
<ide> function $HttpProvider() {
<ide> function transformResponse(response) {
<ide> // make a copy since the response must be cacheable
<ide> var resp = extend({}, response);
<del> if(config.method === 'HEAD'){
<add> if (!response.data) {
<ide> res... | 2 |
Go | Go | correct some daemon spelling mistakes | 906974b185b431a8c493479f748677f3c0bc4ca3 | <ide><path>daemon/monitor.go
<ide> func (m *containerMonitor) Start() error {
<ide> }
<ide>
<ide> // resetMonitor resets the stateful fields on the containerMonitor based on the
<del>// previous runs success or failure. Reguardless of success, if the container had
<add>// previous runs success or failure. Regardless... | 3 |
Text | Text | update security section of readme | 60b8f08d3d71b531f13e52037c019ae451654a0b | <ide><path>README.md
<ide> If you're confident it's a new bug and have confirmed that someone else is facin
<ide>
<ide> ### Reporting Security Issues and Responsible Disclosure
<ide>
<del>If you think you have found a vulnerability, _please report responsibly_. Don't create GitHub issues for security issues. Instead,... | 1 |
Ruby | Ruby | remove unused code | 24b75fc40c59bf987630286b1f4007b2688834b6 | <ide><path>activesupport/lib/active_support/callbacks.rb
<ide> module Callbacks
<ide> #
<ide> # Calls the before and around callbacks in the order they were set, yields
<ide> # the block (if given one), and then runs the after callbacks in reverse order.
<del> # Optionally accepts a key, which will be us... | 1 |
Javascript | Javascript | fix the node warnings that show up during build | 4949586a76e0dd2baf47f519219011bd36dc52fa | <ide><path>docs/src/ngdoc.js
<ide> function Doc(text, file, line) {
<ide> this.links = this.links || [];
<ide> }
<ide> Doc.METADATA_IGNORE = (function() {
<del> var words = require('fs').readFileSync(__dirname + '/ignore.words', 'utf8');
<add> var words = fs.readFileSync(__dirname + '/ignore.words', 'utf8');
<ide> ... | 1 |
Javascript | Javascript | remove warning in 'sys' - too aggressive | 6ce007e89a54084edd42e44a85a0c46702ad6639 | <ide><path>lib/sys.js
<ide> var util = require("util");
<ide> var sysWarning;
<ide> if (!sysWarning) {
<ide> sysWarning = "The 'sys' module is now called 'util'. It should have a similar interface.";
<del> util.error(sysWarning);
<add> // Uncomment in 2011
<add> //util.error(sysWarning);
<ide> }
<ide>
<ide> expor... | 1 |
Javascript | Javascript | use a set for module.chunks | e8bc9c2b3b121d97d9040d76856a4f33f75d56a3 | <ide><path>lib/Compilation.js
<ide> class Compilation extends Tapable {
<ide> if(err) return callback(err);
<ide> deps.forEach(d => {
<ide> if(d.module && d.module.removeReason(module, d)) {
<del> module.chunks.forEach(chunk => {
<add> module.forEachChunk(chunk => {
<ide> if(!d.module.hasR... | 6 |
Ruby | Ruby | match domain language | 2571d1a8491169ab3ef78eec5b891f782a533496 | <ide><path>lib/active_file/blob.rb
<ide> require "active_file/site"
<ide>
<del># Schema: id, key, filename, content_type, metadata, byte_size, digest, created_at
<add># Schema: id, key, filename, content_type, metadata, byte_size, checksum, created_at
<ide> class ActiveFile::Blob < ActiveRecord::Base
<ide> self.tabl... | 2 |
Ruby | Ruby | manage sandbox test resources in setup/teardown | ba26567b0309d70030df9929d949c7988b250c4c | <ide><path>Library/Homebrew/test/test_sandbox.rb
<ide> class SandboxTest < Homebrew::TestCase
<ide> def setup
<ide> skip "sandbox not implemented" unless Sandbox.available?
<add> @sandbox = Sandbox.new
<add> @dir = Pathname.new(Dir.mktmpdir)
<add> @file = @dir/"foo"
<add> end
<add>
<add> def teardown
<... | 1 |
PHP | PHP | convert percentage sign in fallback filename | 5ac66a8c341d659d61d128d52cc79f5a0de66219 | <ide><path>src/Illuminate/Filesystem/FilesystemAdapter.php
<ide> public function response($path, $name = null, array $headers = [], $disposition
<ide> $filename = $name ?? basename($path);
<ide>
<ide> $disposition = $response->headers->makeDisposition(
<del> $disposition, $filename, Str::asc... | 1 |
PHP | PHP | use short widget names instead of fqcn | c154d4eaffc58408103e8f277803ec0f49d972e1 | <ide><path>src/View/Helper/FormHelper.php
<ide> class FormHelper extends Helper
<ide> * @var array
<ide> */
<ide> protected $_defaultWidgets = [
<del> 'button' => ['Cake\View\Widget\ButtonWidget'],
<del> 'checkbox' => ['Cake\View\Widget\CheckboxWidget'],
<del> 'file' => ['Cake\View\Wi... | 1 |
Go | Go | add regression test from @crosbymichael | 2b5386f039b5c99cf0f64fb3091cc14e4446dc64 | <ide><path>utils_test.go
<ide> func TestMergeConfig(t *testing.T) {
<ide> }
<ide> }
<ide> }
<add>
<add>func TestMergeConfigPublicPortNotHonored(t *testing.T) {
<add> volumesImage := make(map[string]struct{})
<add> volumesImage["/test1"] = struct{}{}
<add> volumesImage["/test2"] = struct{}{}
<add> configImage := &Con... | 1 |
PHP | PHP | consolidate doc block descriptions | 01086798af68a193f2c0a37cf0ffa770ace9d77e | <ide><path>src/Database/Type.php
<ide> class Type implements TypeInterface
<ide>
<ide> /**
<ide> * List of basic type mappings, used to avoid having to instantiate a class
<del> * for doing conversion on these
<add> * for doing conversion on these.
<ide> *
<ide> * @var array
<ide> * @de... | 1 |
PHP | PHP | define the protocol property on the response | 1bf62e02fd5788c917289b0b321633f3d64d22d7 | <ide><path>src/Http/Client/Response.php
<ide> */
<ide> class Response extends Message
<ide> {
<add> /**
<add> * This is temporary until the response is made PSR7 compliant as well.
<add> *
<add> * @var string
<add> */
<add> protected $protocol = '1.1';
<ide>
<ide> /**
<ide> * The status... | 1 |
Python | Python | add note to memleak tests | 588cfa9c91c841f4bb3f5a9c91d1c1331f5b8ad3 | <ide><path>tests/test_regression.py
<ide> def __exit__(self, exc_type, exc_value, tb):
<ide> gc.enable()
<ide>
<ide>
<add># XXX: untitaker: These tests need to be revised. They broke around the time we
<add># ported Flask to Python 3.
<ide> @pytest.mark.skipif(os.environ.get('RUN_FLASK_MEMORY_TESTS') != '1',
... | 1 |
Ruby | Ruby | improve the task to generate the release summary | e91bf5966e9f6f58bc0ea9e92f94b9d892ef29bc | <ide><path>tasks/release.rb
<ide> end
<ide> end
<ide>
<del> task :release_summary do
<del> (FRAMEWORKS + ["guides"]).each do |fw|
<del> puts "## #{fw}"
<add> task :release_summary, [:base_release] do |_, args|
<add> release_regexp = args[:base_release] ? Regexp.escape(args[:base_release]) : /\d+\.\d... | 1 |
Text | Text | update binary locations | 371dd7feec38ffda3c140dc0afae1b10fc5311c4 | <ide><path>docs/Homebrew-and-Python.md
<ide> Homebrew provides formulae to brew 3.x and a more up-to-date Python 2.7.x.
<ide> Homebrew provides one formula for Python 3.x (`python`) and another for Python 2.7.x (`python@2`).
<ide>
<ide> The executables are organized as follows so that Python 2 and Python 3 can both be... | 1 |
Javascript | Javascript | make tab completion work on non-objects | a118f2172880d338101f80647437b8832ac1f768 | <ide><path>lib/repl.js
<ide> REPLServer.prototype.complete = function(line, callback) {
<ide> }
<ide> // works for non-objects
<ide> try {
<del> var p = Object.getPrototypeOf(obj);
<ide> var sentinel = 5;
<add> var p;
<add> if (typ... | 2 |
Javascript | Javascript | update metamorph to latest version | f701bff1e4eb52112e7b125f034e1bb68acdb6d8 | <ide><path>packages/metamorph/lib/main.js
<ide>
<ide> var K = function(){},
<ide> guid = 0,
<add> document = window.document,
<ide>
<ide> // Feature-detect the W3C range API
<ide> supportsRange = ('createRange' in document);
<ide> if (this instanceof Metamorph) {
<ide> self = this;
... | 1 |
Text | Text | add note about preloading to routing introduction. | b874bc7f821f8cb39d888fdb94b66405abcd0eb1 | <ide><path>docs/routing/introduction.md
<ide> In the example above we have multiple links, each one maps a path (`href`) to a
<ide> - `/about` → `pages/about.js`
<ide> - `/blog/hello-world` → `pages/blog/[slug].js`
<ide>
<add>Any `<Link />` in the viewport (initially or through scroll) will be prefetched by default (i... | 1 |
Ruby | Ruby | remove unused variable | 80714aaa7cd6278c5864e31b068a5d017ba6baed | <ide><path>Library/Homebrew/cmd/uses.rb
<ide> def uses
<ide> deps.any? { |dep| dep.to_formula.name == ff.name } ||
<ide> f.requirements.any? { |req| req.name == ff.name }
<ide> end
<del> rescue FormulaUnavailableError => e
<add> rescue FormulaUnavailableError
<ide> ... | 1 |
Ruby | Ruby | add abstractcookiejar class | 143d047d659799acad1563c4ca902c0b7c062f6b | <ide><path>actionpack/lib/action_dispatch/middleware/cookies.rb
<ide> def write_cookie?(cookie)
<ide> end
<ide> end
<ide>
<del> class PermanentCookieJar #:nodoc:
<add> class AbstractCookieJar # :nodoc:
<ide> include ChainedCookieJars
<ide>
<ide> def initialize(parent_jar)
<ide> def initi... | 1 |
Javascript | Javascript | correct support comment | 361a0d5150a1c57b1857611cde1b05bd0ef21a50 | <ide><path>src/event.js
<ide> jQuery.Event.prototype = {
<ide> // Create mouseenter/leave events using mouseover/out and event-time checks
<ide> // so that event delegation works in jQuery.
<ide> // Do the same for pointerenter/pointerleave and pointerover/pointerout
<add>//
<ide> // Support: Safari<7.0
<ide> // Safari... | 1 |
Ruby | Ruby | require yaml for time_with_zone isolation test | 2f26f61154292091fc988b4b5f70a0c21326ae19 | <ide><path>activesupport/test/core_ext/time_with_zone_test.rb
<ide> require 'active_support/time'
<ide> require 'time_zone_test_helpers'
<ide> require 'active_support/core_ext/string/strip'
<add>require 'yaml'
<ide>
<ide> class TimeWithZoneTest < ActiveSupport::TestCase
<ide> include TimeZoneTestHelpers | 1 |
Javascript | Javascript | add more recursive fs.rmdir() tests | 27507ca10846592a928cb3b6e7f8152d8090a24d | <ide><path>test/parallel/test-fs-rmdir-recursive.js
<ide> let count = 0;
<ide>
<ide> tmpdir.refresh();
<ide>
<del>function makeNonEmptyDirectory() {
<del> const dirname = `rmdir-recursive-${count}`;
<del> fs.mkdirSync(path.join(dirname, 'foo', 'bar', 'baz'), { recursive: true });
<add>function makeNonEmptyDirectory... | 1 |
Python | Python | add bits attribute to np.finfo, closes | 3071778e37112377b592b180769f0a44496dc2da | <ide><path>numpy/core/getlimits.py
<ide> class finfo(object):
<ide>
<ide> Attributes
<ide> ----------
<add> bits : int
<add> The number of bits occupied by the type.
<ide> eps : float
<ide> The smallest representable positive number such that
<ide> ``1.0 + eps != 1.0``. Type of `... | 2 |
Python | Python | add a test case for it | e87ee8314e8a88ee908d109ac877dc3f36046e7d | <ide><path>libcloud/test/storage/test_azure_blobs.py
<ide> def test_get_container_success(self):
<ide> self.assertTrue(container.extra["lease"]["state"], "available")
<ide> self.assertTrue(container.extra["meta_data"]["meta1"], "value1")
<ide>
<add> if self.driver.secure:
<add> expect... | 1 |
Javascript | Javascript | use callback to properly propagate error | 8f86986985b161b7fb5aa41283d792417329bc2c | <ide><path>lib/_stream_readable.js
<ide> function ReadableState(options, stream, isDuplex) {
<ide> // Has it been destroyed
<ide> this.destroyed = false;
<ide>
<del> // Indicates whether the stream has errored.
<add> // Indicates whether the stream has errored. When true no further
<add> // _read calls, 'data' ... | 7 |
Ruby | Ruby | fix some types in schema_test.rb | 924975a34aa3337cdf7a68f76bcae205815778f1 | <ide><path>activeresource/test/cases/base/schema_test.rb
<ide> def teardown
<ide> assert_nothing_raised {
<ide> Person.schema = new_schema
<ide> assert_equal new_schema, Person.schema, "should have saved the schema on the class"
<del> assert_equal new_schema, Person.new.schema, "should have mde the... | 1 |
Text | Text | expand explanation of `config.setdefaults` in docs | 65d13b538399851a943dcf00cf83be0b1ef3ea73 | <ide><path>docs/configuring-and-extending.md
<ide> config.get("fuzzyFinder.ignoredPaths").push "vendor"
<ide> config.update() # be sure to call `config.update` after the change
<ide> ```
<ide>
<del>You can also use `setDefaults`, which will assign keys on the object at the given
<del>only if they are currently undefin... | 1 |
Java | Java | fix initialization issue in resourceurlprovider | d85c1fbdd5edb6b2ba906f8a20009317ff7faa98 | <ide><path>spring-webmvc/src/main/java/org/springframework/web/servlet/resource/ResourceUrlProvider.java
<ide> protected void detectResourceHandlers(ApplicationContext appContext) {
<ide> Collections.sort(handlerMappings, new OrderComparator());
<ide>
<ide> for (SimpleUrlHandlerMapping hm : handlerMappings) {
<del... | 1 |
Text | Text | add plans for tree-sitter this week | 29665713c6fc7e51bd53233dcf37c64f15155548 | <ide><path>docs/focus/2018-04-02.md
<ide> - Teletype
<ide> - Publish patch release with [potential fix](https://github.com/atom/teletype-client/pull/58) for [atom/teletype#233](https://github.com/atom/teletype/issues/233)
<ide> - Incorporate any new feedback and finalize RFC for streamlining collaboration set-up ([... | 1 |
Go | Go | fix incorrect assumption in testapiswarmraftquorum | c27603238c5493909ec9b657b342b67b23e615e3 | <ide><path>integration-cli/docker_api_swarm_test.go
<ide> func (s *DockerSwarmSuite) TestAPISwarmRaftQuorum(c *check.C) {
<ide>
<ide> d3.Stop(c)
<ide>
<del> // make sure there is a leader
<del> waitAndAssert(c, defaultReconciliationTimeout, d1.CheckLeader, checker.IsNil)
<del>
<ide> var service swarm.Service
<ide> ... | 1 |
Javascript | Javascript | fix eslint errors | 2757794e4a8f80767e228fd2882c254c1b872e68 | <ide><path>packages/loader/lib/index.js
<add>/*global process */
<ide> var enifed, requireModule, Ember;
<ide> var mainContext = this; // Used in ember-environment/lib/global.js
<ide>
<ide> (function() {
<del> var isNode = typeof window === 'undefined' &&
<del> typeof process !== 'undefined' && {}.toString.call(pr... | 2 |
Javascript | Javascript | add clientrequest creation benchmark | c5d0fd9641b9cc4b6340a34dd75119d899a98017 | <ide><path>benchmark/http/create-clientrequest.js
<add>'use strict';
<add>
<add>var common = require('../common.js');
<add>var ClientRequest = require('http').ClientRequest;
<add>
<add>var bench = common.createBenchmark(main, {
<add> pathlen: [1, 8, 16, 32, 64, 128],
<add> n: [1e6]
<add>});
<add>
<add>function main(c... | 1 |
PHP | PHP | add doc blocks for type constants | 3b46044b1783424e529a837f1a7371495385a7ed | <ide><path>Cake/ORM/Association.php
<ide> abstract class Association {
<ide> */
<ide> const STRATEGY_SELECT = 'select';
<ide>
<add>/**
<add> * Association type for one to one associations.
<add> *
<add> * @var string
<add> */
<ide> const ONE_TO_ONE = 'oneToOne';
<ide>
<add>/**
<add> * Association type for one to m... | 1 |
PHP | PHP | add file() method to response factory | a96ea3c8c95657832f3d534d42db4b5efc7b8515 | <ide><path>src/Illuminate/Routing/ResponseFactory.php
<ide> public function download($file, $name = null, array $headers = [], $disposition
<ide> return $response;
<ide> }
<ide>
<add> /**
<add> * Return the raw contents of a binary file.
<add> *
<add> * @param \SplFileInfo|string $file
<add>... | 1 |
Python | Python | improve coding style | 192719eed0ffc8ecd423b18e07bf52921dbfbcc2 | <ide><path>rest_framework/authentication.py
<ide> def authenticate_credentials(self, userid, password):
<ide> """
<ide> Authenticate the userid and password against username and password.
<ide> """
<del> user_model = get_user_model()
<del> if hasattr(user_model, 'USERNAME_FIELD'):
... | 1 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.