patch
stringlengths
17
31.2k
y
int64
1
1
oldf
stringlengths
0
2.21M
idx
int64
1
1
id
int64
4.29k
68.4k
msg
stringlengths
8
843
proj
stringclasses
212 values
lang
stringclasses
9 values
@@ -79,7 +79,7 @@ public class TestHiveShell { public void start() { // Create a copy of the HiveConf for the metastore - metastore.start(new HiveConf(hs2Conf)); + metastore.start(new HiveConf(hs2Conf), 10); hs2Conf.setVar(HiveConf.ConfVars.METASTOREURIS, metastore.hiveConf().getVar(HiveConf.ConfVa...
1
/* * Licensed to the Apache Software Foundation (ASF) under one * or more contributor license agreements. See the NOTICE file * distributed with this work for additional information * regarding copyright ownership. The ASF licenses this file * to you under the Apache License, Version 2.0 (the * "License"); you ...
1
35,986
Do we know why the pool is exhausted? In the past, we had a few leaks in the Spark catalog code which led to this. It can be also a valid use case too if we simply need a larger pool.
apache-iceberg
java
@@ -228,6 +228,11 @@ module Bolt # Set console log to debug if in debug mode if options[:debug] overrides['log'] = { 'console' => { 'level' => :debug } } + elsif options[:verbose] + configured_level = overrides.dig('log', 'console', 'level') + if configured_level.nil? || Bolt::...
1
# frozen_string_literal: true require 'etc' require 'logging' require 'pathname' require 'bolt/project' require 'bolt/logger' require 'bolt/util' # Transport config objects require 'bolt/config/transport/ssh' require 'bolt/config/transport/winrm' require 'bolt/config/transport/orch' require 'bolt/config/transport/loca...
1
15,115
Logging in Bolt still seems to be a little messy. I think this is more correct than what I had before, but made sure I wouldn't overwrite an existing level. And if console logging gets more options, both debug and verbose need to be fixed here.
puppetlabs-bolt
rb
@@ -7,6 +7,13 @@ std::shared_ptr<request_type> nano::work_peer_request::get_prepared_json_request auto request (std::make_shared<boost::beast::http::request<boost::beast::http::string_body>> ()); request->method (boost::beast::http::verb::post); request->set (boost::beast::http::field::content_type, "application/...
1
#include <nano/node/distributed_work.hpp> #include <nano/node/node.hpp> #include <nano/node/websocket.hpp> std::shared_ptr<request_type> nano::work_peer_request::get_prepared_json_request (std::string const & request_string_a) const { auto request (std::make_shared<boost::beast::http::request<boost::beast::http::stri...
1
16,021
This could be simplified (if including <boost/algorithm/string/erase.hpp> is fine): `auto address_string = boost::algorithm::erase_first_copy (address.to_string (), "::ffff:");`
nanocurrency-nano-node
cpp
@@ -304,7 +304,7 @@ public class DefaultGridRegistry extends BaseGridRegistry implements GridRegistr if (proxy == null) { return; } - LOG.info("Registered a node " + proxy); + LOG.finest("Registered a node " + proxy); try { lock.lock();
1
// Licensed to the Software Freedom Conservancy (SFC) under one // or more contributor license agreements. See the NOTICE file // distributed with this work for additional information // regarding copyright ownership. The SFC licenses this file // to you under the Apache License, Version 2.0 (the // "License"); you m...
1
16,452
This is wildly unhelpful to users --- they need to know when a proxy has been registered.
SeleniumHQ-selenium
java
@@ -16,8 +16,13 @@ class Topic < ActiveRecord::Base has_one :legacy_trail has_many :trails + has_attached_file :image, { + path: "topics/:attachment/:id_partition/:style/:filename" + }.merge(PAPERCLIP_STORAGE_OPTIONS) + validates :name, presence: true validates :slug, presence: true, uniqueness: true...
1
class Topic < ActiveRecord::Base extend FriendlyId has_many :classifications, dependent: :destroy with_options(through: :classifications, source: :classifiable) do |options| options.has_many :exercises, source_type: 'Exercise' options.has_many :products, source_type: 'Product' options.has_many :topi...
1
13,968
Why do we need `do_not_validate_attachment_file_type` is we're doing it in the previous line?
thoughtbot-upcase
rb
@@ -107,10 +107,9 @@ public class LoginActivity extends AccountAuthenticatorActivity if (shouldUseCertBasedAuth()) { final String alias = RuntimeConfig.getRuntimeConfig(this).getString(ConfigKey.ManagedAppCertAlias); KeyChain.choosePrivateKeyAlias(this, webviewHelper, null, null, null, 0, alias); + } else {...
1
/* * Copyright (c) 2011-2015, salesforce.com, inc. * All rights reserved. * Redistribution and use of this software in source and binary forms, with or * without modification, are permitted provided that the following conditions * are met: * - Redistributions of source code must retain the above copyright notice,...
1
14,580
Loading login page right away only for the regular use case.
forcedotcom-SalesforceMobileSDK-Android
java
@@ -1,13 +1,17 @@ // render modes +/** Do not recursively re-render a component */ export const NO_RENDER = 0; +/** Recursively re-render a component and it's children */ export const SYNC_RENDER = 1; +/** Force a re-render of a component */ export const FORCE_RENDER = 2; +/** Queue asynchronous re-render of a co...
1
// render modes export const NO_RENDER = 0; export const SYNC_RENDER = 1; export const FORCE_RENDER = 2; export const ASYNC_RENDER = 3; export const ATTR_KEY = '__preactattr_'; // DOM properties that should NOT have "px" added when numeric export const IS_NON_DIMENSIONAL = /acit|ex(?:s|g|n|p|$)|rph|ows|mnc|ntw|ine[...
1
11,997
IIRC this flag disables re-rendering entirely (`s/recursively //`)
preactjs-preact
js
@@ -6,17 +6,11 @@ define(["loading"], function(loading) { url: ApiClient.getUrl("Startup/Complete"), type: "POST" }).then(function() { - Dashboard.navigate("dashboard.html"); loading.hide(); + window.location.href = "index.html"; }); } ...
1
define(["loading"], function(loading) { "use strict"; function onFinish() { loading.show(), ApiClient.ajax({ url: ApiClient.getUrl("Startup/Complete"), type: "POST" }).then(function() { Dashboard.navigate("dashboard.html"); loading.hide(); ...
1
12,067
Did you test this redirect? @thornbill mentioned it might need `web` at the front, but if this works fine I'd rather leave it this way.
jellyfin-jellyfin-web
js
@@ -30,7 +30,6 @@ namespace Microsoft.AspNetCore.Server.Kestrel.Core.Tests headers["custom"] = new[] { "value" }; - Assert.NotNull(headers["custom"]); Assert.Equal(1, headers["custom"].Count); Assert.Equal("value", headers["custom"][0]); }
1
// Copyright (c) .NET Foundation. All rights reserved. // Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information. using System; using System.Collections.Generic; using System.Text; using Microsoft.AspNetCore.Http; using Microsoft.AspNetCore.Server.Kestrel.Core; usin...
1
13,200
FYI, this returned `StringValues` which is a value type (aka can never be null).
aspnet-KestrelHttpServer
.cs
@@ -1425,7 +1425,16 @@ func (c *Compiler) parseExpr(frame *Frame, expr ssa.Value) (llvm.Value, error) { valueSize := c.targetData.TypeAllocSize(llvmValueType) llvmKeySize := llvm.ConstInt(c.ctx.Int8Type(), keySize, false) llvmValueSize := llvm.ConstInt(c.ctx.Int8Type(), valueSize, false) - hashmap := c.create...
1
package compiler import ( "errors" "fmt" "go/build" "go/constant" "go/token" "go/types" "os" "path/filepath" "strconv" "strings" "github.com/tinygo-org/tinygo/ir" "github.com/tinygo-org/tinygo/loader" "golang.org/x/tools/go/ssa" "tinygo.org/x/go-llvm" ) func init() { llvm.InitializeAllTargets() llvm....
1
7,070
Oh no, that's a bug.
tinygo-org-tinygo
go
@@ -23,5 +23,5 @@ package yarpc // Response is the low level response representation. type Response struct { Headers Headers - ApplicationError bool + ApplicationError error }
1
// Copyright (c) 2018 Uber Technologies, Inc. // // Permission is hereby granted, free of charge, to any person obtaining a copy // of this software and associated documentation files (the "Software"), to deal // in the Software without restriction, including without limitation the rights // to use, copy, modify, merge...
1
18,039
Let's leave a note in CHANGES to replace this with an error metadata struct or interface, unless it would be less effort overall to take a run at it in this change.
yarpc-yarpc-go
go
@@ -455,6 +455,10 @@ class Realm { * This is not supported for `"list"` properties of object types and `"linkingObjects"` properties. * @property {boolean} [indexed] - Signals if this property should be indexed. Only supported for * `"string"`, `"int"`, and `"bool"` properties. + * @property {string} [mapTo] ...
1
//////////////////////////////////////////////////////////////////////////// // // Copyright 2016 Realm Inc. // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apache.org/li...
1
17,694
The changelog entry does a better job of explaining how this is used than this description. In particular, this says that you need to set `mapTo` if the underlying name is different, but not that `mapTo` *is* the underlying name.
realm-realm-js
js
@@ -13,6 +13,7 @@ import ( "github.com/influxdata/flux/plan" "github.com/influxdata/flux/semantic" _ "github.com/lib/pq" + _ "github.com/mattn/go-sqlite3" ) const FromSQLKind = "fromSQL"
1
package sql import ( "context" "database/sql" _ "github.com/go-sql-driver/mysql" "github.com/influxdata/flux" "github.com/influxdata/flux/codes" "github.com/influxdata/flux/execute" "github.com/influxdata/flux/internal/errors" "github.com/influxdata/flux/memory" "github.com/influxdata/flux/plan" "github.com...
1
12,212
These imports will probably need to be refactored so they aren't here. That applies for all of the database drivers. The reason for this is because we sometimes want a driver to be available and sometimes we don't. When we include this library in our cloud offering, the sqlite3 connector needs to be gone because it's a...
influxdata-flux
go
@@ -414,7 +414,7 @@ class RelationController extends ControllerBehavior */ protected function findExistingRelationIds($checkIds = null) { - $foreignKeyName = $this->relationModel->getKeyName(); + $foreignKeyName = $this->relationModel->table . '.' . $this->relationModel->getKeyName(); ...
1
<?php namespace Backend\Behaviors; use DB; use Lang; use Event; use Form as FormHelper; use Backend\Classes\ControllerBehavior; use System\Classes\ApplicationException; use October\Rain\Database\Model; /** * Relation Controller Behavior * Uses a combination of lists and forms for managing Model relations. * * @pa...
1
10,557
We can use `getQualifiedKeyName` here instead. I will update.
octobercms-october
php
@@ -115,7 +115,7 @@ module.exports = function getIconByMime (fileType) { } // Archive - const archiveTypes = ['zip', 'x-7z-compressed', 'x-rar-compressed', 'x-gtar', 'x-apple-diskimage', 'x-diskcopy'] + const archiveTypes = ['zip', 'x-7z-compressed', 'x-rar-compressed', 'x-tar', 'x-gzip', 'x-apple-diskimage']...
1
const { h } = require('preact') function iconImage () { return ( <svg aria-hidden="true" focusable="false" width="25" height="25" viewBox="0 0 25 25"> <g fill="#686DE0" fill-rule="evenodd"> <path d="M5 7v10h15V7H5zm0-1h15a1 1 0 0 1 1 1v10a1 1 0 0 1-1 1H5a1 1 0 0 1-1-1V7a1 1 0 0 1 1-1z" fill-rule="n...
1
13,740
Could you clarifty why some of those are removed?
transloadit-uppy
js
@@ -774,3 +774,7 @@ func (a *FakeWebAPI) GetCommand(ctx context.Context, req *webservice.GetCommandR Command: &cmd, }, nil } + +func (a *FakeWebAPI) ListDeploymentConfigTemplates(ctx context.Context, req *webservice.ListDeploymentConfigTemplatesRequest) (*webservice.ListDeploymentConfigTemplatesResponse, error) {...
1
// Copyright 2020 The PipeCD Authors. // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agree...
1
8,579
`ctx` is unused in ListDeploymentConfigTemplates
pipe-cd-pipe
go
@@ -1,10 +1,13 @@ <% if id.nil? || id.identifier == '' %> <% if scheme.name.downcase == 'orcid' %> - <%= link_to _("Create or connect your ORCID iD"), - Rails.application.routes.url_helpers.send("user_orcid_omniauth_authorize_path"), + <%= link_to Rails.application.routes.url_he...
1
<% if id.nil? || id.identifier == '' %> <% if scheme.name.downcase == 'orcid' %> <%= link_to _("Create or connect your ORCID iD"), Rails.application.routes.url_helpers.send("user_orcid_omniauth_authorize_path"), id: "connect-orcid-button", target: '_blank', ...
1
17,441
nice to see the usage of block for a more readable link name
DMPRoadmap-roadmap
rb
@@ -329,9 +329,10 @@ int MPI_File_read(MPI_File fh, void *buf, int count, MPI_Datatype datatype, if (bytes_read != bytes_to_read) { std::snprintf(mpierrmsg, MPI_MAX_ERROR_STRING, - "could not read %" PRId64 " bytes. read only: %" PRId64 + "could not read %llu...
1
/* * Distributed under the OSI-approved Apache License, Version 2.0. See * accompanying file Copyright.txt for details. * * ADIOS is freely available under the terms of the BSD license described * in the COPYING file in the top level directory of this source distribution. * * Copyright (c) 2008 - 2009. UT-BATT...
1
11,721
Can these use `static_cast<unsigned long long>` instead? Other than that, it's fine.
ornladios-ADIOS2
cpp
@@ -258,7 +258,6 @@ def create_app(instance_path=None, static_folder=None, **kwargs_config): except (SyntaxError, ValueError): pass app.config[cfg_name] = cfg_value - app.logger.debug("{0} = {1}".format(cfg_name, cfg_value)) # ==================== # Appl...
1
# -*- coding: utf-8 -*- # # This file is part of Invenio. # Copyright (C) 2011, 2012, 2013, 2014, 2015 CERN. # # Invenio is free software; you can redistribute it and/or # modify it under the terms of the GNU General Public License as # published by the Free Software Foundation; either version 2 of the # License, or (a...
1
16,498
This output is only present when `DEBUG=True`. Does it really bother so much?
inveniosoftware-invenio
py
@@ -1194,11 +1194,7 @@ bool nano::wallet::search_pending () if (wallets.node.ledger.block_confirmed (block_transaction, hash)) { // Receive confirmed block - auto node_l (wallets.node.shared ()); - wallets.node.background ([node_l, block, hash]() { - auto transaction (node_l->st...
1
#include <nano/crypto_lib/random_pool.hpp> #include <nano/lib/threading.hpp> #include <nano/lib/utility.hpp> #include <nano/node/election.hpp> #include <nano/node/lmdb/lmdb_iterator.hpp> #include <nano/node/node.hpp> #include <nano/node/wallet.hpp> #include <boost/filesystem.hpp> #include <boost/format.hpp> #include <...
1
16,534
I think it should pass wallet transaction as well, otherwise there will be 2 wallet read transactions in 1 threads (next in scan_receivable)
nanocurrency-nano-node
cpp
@@ -3651,14 +3651,14 @@ bool MMFFMolProperties::getMMFFVdWParams(const unsigned int idx1, const MMFFVdW *mmffVdWParamsIAtom = (*mmffVdW)(iAtomType); const MMFFVdW *mmffVdWParamsJAtom = (*mmffVdW)(jAtomType); if (mmffVdWParamsIAtom && mmffVdWParamsJAtom) { - mmffVdWParams.R_ij_starUnscaled = Utils::c...
1
// $Id$ // // Copyright (C) 2013 Paolo Tosco // // Copyright (C) 2004-2006 Rational Discovery LLC // // @@ All Rights Reserved @@ // This file is part of the RDKit. // The contents are covered by the terms of the BSD license // which is included in the file license.txt, found at the root // of the RDKit source ...
1
15,042
RDKit::Utils is now in the namespace for localeswitcer... We could change it to something else.
rdkit-rdkit
cpp
@@ -211,6 +211,10 @@ class GroupBy(object): kdf = kdf.reset_index(drop=self._should_drop_index) if relabeling: + + # For MultiIndex, we need to flatten the tuple, e.g. (('y', 'A'), 'max') needs to be + # flattened to ('y', 'A', 'max'), it won't do anything on normal Index. ...
1
# # Copyright (C) 2019 Databricks, Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to i...
1
14,946
@itholic, can we fix it in `_normalize_keyword_aggregation`?
databricks-koalas
py
@@ -1,6 +1,7 @@ # This class represents a user's subscription to Learn content class Subscription < ActiveRecord::Base MAILING_LIST = 'Active Subscribers' + DOWNGRADED_PLAN = 'prime-maintain' belongs_to :user belongs_to :mentor, class_name: User
1
# This class represents a user's subscription to Learn content class Subscription < ActiveRecord::Base MAILING_LIST = 'Active Subscribers' belongs_to :user belongs_to :mentor, class_name: User delegate :stripe_customer_id, to: :user validates :mentor_id, presence: true before_validation :assign_mentor, ...
1
7,699
It seems like we have the main plan in the database but the downgrade plan in the code. Probably okay for now, but as our thinking of how downgrades/plans develops we may want to consolidate.
thoughtbot-upcase
rb
@@ -44,6 +44,10 @@ import java.util.List; * </code> */ public abstract class By { + static { + WebDriverException.scheduleIpHostResolving(); + } + /** * @param id The value of the "id" attribute to search for * @return a By which locates elements by the value of the "id" attribute.
1
// Licensed to the Software Freedom Conservancy (SFC) under one // or more contributor license agreements. See the NOTICE file // distributed with this work for additional information // regarding copyright ownership. The SFC licenses this file // to you under the Apache License, Version 2.0 (the // "License"); you m...
1
12,103
we shouldn't add a bunch of static initializers 'everywhere' in the code. Probably just one would be good, during the construction of the 'RemoteWebDriver' class.
SeleniumHQ-selenium
java
@@ -42,6 +42,8 @@ const ( optionNamePaymentTolerance = "payment-tolerance" optionNameResolverEndpoints = "resolver-options" optionNameGatewayMode = "gateway-mode" + optionNameClefSignerEnable = "clef-signer-enable" + optionNameClefSignerEndpoint = "clef-signer-endpoint" ) func init() {
1
// Copyright 2020 The Swarm Authors. All rights reserved. // Use of this source code is governed by a BSD-style // license that can be found in the LICENSE file. package cmd import ( "errors" "fmt" "os" "path/filepath" "strings" "github.com/ethersphere/bee/pkg/swarm" "github.com/spf13/cobra" "github.com/spf1...
1
12,374
do we need both flags? maybe infer that `clef-signer-enabled` whenever `clef-signer-endpoint` is defined?
ethersphere-bee
go
@@ -40,7 +40,7 @@ module.exports = { '<rootDir>/test', ], moduleNameMapper: { - '\\.(scss)$': '<rootDir>/node_modules/identity-obj-proxy', + '\\.(scss|css)$': '<rootDir>/node_modules/identity-obj-proxy', 'github-markdown-css': '<rootDir>/node_modules/identity-obj-proxy', '\\.(png)$': '<rootDi...
1
/* eslint comma-dangle: 0 */ module.exports = { name: 'verdaccio-unit-jest', verbose: true, collectCoverage: true, testEnvironment: 'jest-environment-jsdom-global', testURL: 'http://localhost', testRegex: '(test/unit.*\\.spec|test/unit/webui/.*\\.spec)\\.js', setupFiles: [ './test/unit/setup.js' ],...
1
18,905
Do we need this? I didn't see css files (only scss).
verdaccio-verdaccio
js
@@ -29,7 +29,7 @@ class Store: if hosts is None: hosts = settings.CLUSTER_SERVERS - remote_hosts = [host for host in hosts if not is_local_interface(host)] + remote_hosts = [host for host in hosts if not settings.REMOTE_EXCLUDE_LOCAL or not is_local_interface(host)] self.remote_stores = [ Remot...
1
import time try: from importlib import import_module except ImportError: # python < 2.7 compatibility from django.utils.importlib import import_module from django.conf import settings from graphite.util import is_local_interface, is_pattern from graphite.remote_storage import RemoteStore from graphite.node impo...
1
9,769
This feels like a weird `if not ... or not` to me. Can you talk out the intent here?
graphite-project-graphite-web
py
@@ -0,0 +1,17 @@ +class AnnualBillingsController < ApplicationController + before_filter :authorize + + def new + @annualized_payment = current_user.annualized_payment + @discounted_annual_payment = current_user.discounted_annual_payment + end + + def create + AnnualBillingMailer.notification(current_user)...
1
1
10,708
Align the parameters of a method call if they span more than one line.
thoughtbot-upcase
rb
@@ -17,7 +17,7 @@ namespace ApacheSolrForTypo3\Solr\Domain\Search\ResultSet\Facets\OptionBased\Opt use ApacheSolrForTypo3\Solr\Domain\Search\ResultSet\Facets\AbstractFacetPackage; /** - * Class HierarchyPackage + * Class OptionsPackage * @package ApacheSolrForTypo3\Solr\Domain\Search\ResultSet\Facets\OptionBased\...
1
<?php namespace ApacheSolrForTypo3\Solr\Domain\Search\ResultSet\Facets\OptionBased\Options; /* * This file is part of the TYPO3 CMS project. * * It is free software; you can redistribute it and/or modify it under * the terms of the GNU General Public License, either version 2 * of the License, or any later versio...
1
6,655
`@package *` can be removed as well.
TYPO3-Solr-ext-solr
php
@@ -3,7 +3,7 @@ module Beaker # all String methods while adding several platform-specific use cases. class Platform < String # Supported platforms - PLATFORMS = /^(huaweios|cisco_nexus|cisco_ios_xr|(free|open)bsd|osx|centos|fedora|debian|oracle|redhat|scientific|sles|ubuntu|windows|solaris|aix|archlinux|e...
1
module Beaker # This class create a Platform object inheriting from String. It supports # all String methods while adding several platform-specific use cases. class Platform < String # Supported platforms PLATFORMS = /^(huaweios|cisco_nexus|cisco_ios_xr|(free|open)bsd|osx|centos|fedora|debian|oracle|redh...
1
15,727
@ScottGarman is there a reason that `redhat_fips` needs to be a beaker platform? Why can't it be another platform that beaker just understands as `redhat`?
voxpupuli-beaker
rb
@@ -274,8 +274,6 @@ void NebulaStore::removePart(GraphSpaceID spaceId, PartitionID partId) { if (partIt != spaceIt->second->parts_.end()) { auto* e = partIt->second->engine(); CHECK_NOTNULL(e); - // Stop the raft - partIt->second->stop(); raftService...
1
/* Copyright (c) 2018 vesoft inc. All rights reserved. * * This source code is licensed under Apache 2.0 License, * attached with Common Clause Condition 1.0, found in the LICENSES directory. */ #include "base/Base.h" #include "kvstore/NebulaStore.h" #include <folly/Likely.h> #include <algorithm> #include <cstdint...
1
19,827
Where is the other place?
vesoft-inc-nebula
cpp
@@ -19,10 +19,13 @@ # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS # IN THE SOFTWARE. +from collections import Sequence +from boto.vendored.six.moves import UserList + from boto.s3.user import User -class ResultSet(list): +class ResultSet(UserList): """ The ResultSet is used...
1
# Copyright (c) 2006,2007 Mitch Garnaat http://garnaat.org/ # # Permission is hereby granted, free of charge, to any person obtaining a # copy of this software and associated documentation files (the # "Software"), to deal in the Software without restriction, including # without limitation the rights to use, copy, modi...
1
11,618
Are you subclassing from `UserList` instead of `list` to satisfy some constraint of Jython? My main concern here is that this is a subtle breaking change to the API because `UserList` is not a subclass of `list`. This has the unfortunate side effect of breaking any user that is using `isinstance` checks to see if a `Re...
boto-boto
py
@@ -32,6 +32,14 @@ module AvatarHelper "<img src='/assets/icons/sm_laurel_#{rank || 1}.png' alt='KudoRank #{rank || 1}'/>".html_safe end + def avatar_laurels(rank) + "<img src='/assets/icons/laurel_#{rank || 1}.png' alt='KudoRank #{rank || 1}'/>".html_safe + end + + def avatar_tiny_laurels(rank) + "<...
1
module AvatarHelper def avatar_for(who, options = {}) return '' unless who title = (options[:title] == true) ? avatar_title(who) : options[:title] attributes = { title: title, class: options[:class] || 'avatar' } url = options[:url] || avatar_path(who) link_to avatar_img_for(who, options[:size] ||...
1
7,040
We can DRY the above three functions
blackducksoftware-ohloh-ui
rb
@@ -55,14 +55,7 @@ public final class HashMap<K, V> implements Map<K, V>, Serializable { * @return A {@link HashMap} Collector. */ public static <K, V> Collector<Tuple2<K, V>, ArrayList<Tuple2<K, V>>, HashMap<K, V>> collector() { - final Supplier<ArrayList<Tuple2<K, V>>> supplier = ArrayList::ne...
1
/* ____ ______________ ________________________ __________ * \ \/ / \ \/ / __/ / \ \/ / \ * \______/___/\___\______/___/_____/___/\___\______/___/\___\ * * Copyright 2019 Vavr, http://vavr.io * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use ...
1
13,336
Only no good is good code. Nice that you were able to remove all this duplicate stuff!
vavr-io-vavr
java
@@ -121,7 +121,7 @@ public class PhpSurfaceNamer extends SurfaceNamer { @Override public String getRetrySettingsTypeName() { - return "\\Google\\ApiCore\\RetrySettings"; + return "RetrySettings"; } @Override
1
/* Copyright 2016 Google LLC * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * https://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in...
1
24,410
Looking at the code, it seems very odd that this method even exists in the SurfaceNamer, since it is only implemented and used in the PhpSurfaceNamer, and in fact the RetrySettings class name is hardcoded elsewhere. WDYT of just removing this method from SurfaceNamer and PhpSurfaceNamer?
googleapis-gapic-generator
java
@@ -107,3 +107,18 @@ func SplitWriteAll(ctx context.Context, s Splitter, r io.Reader, l int64, toEncr } return addr, nil } + +type Loader interface { + // Load a reference in byte slice representation and return all content associated with the reference. + Load(context.Context, []byte) ([]byte, error) +} + +type S...
1
// Copyright 2020 The Swarm Authors. All rights reserved. // Use of this source code is governed by a BSD-style // license that can be found in the LICENSE file. package file import ( "bytes" "context" "errors" "fmt" "io" "github.com/ethersphere/bee/pkg/swarm" ) // simpleReadCloser wraps a byte slice in a io...
1
12,972
these interfaces are defined twice. we should use only one and have it in `storage` package maybe
ethersphere-bee
go
@@ -24,12 +24,16 @@ import cPickle as pickle import os import shutil +import logging from abc import ABCMeta, abstractmethod import nupic.frameworks.opf.opfutils as opfutils - ############################################################### +# global variable +global globalModelsStorage +globalModelsStorage={}...
1
# ---------------------------------------------------------------------- # Numenta Platform for Intelligent Computing (NuPIC) # Copyright (C) 2013, Numenta, Inc. Unless you have an agreement # with Numenta, Inc., for a separate license for this software code, the # following terms and conditions apply: # # This progra...
1
17,743
This is the wrong context for usage of `global` keyword. It need only be used inside functions.
numenta-nupic
py
@@ -278,7 +278,7 @@ public abstract class AbstractNode implements Node { for (int i = 0; i < node.jjtGetNumChildren(); i++) { Node child = node.jjtGetChild(i); - if (child.getClass() == targetType) { + if (targetType.isAssignableFrom(child.getClass())) { re...
1
/** * BSD-style license; for more info see http://pmd.sourceforge.net/license.html */ package net.sourceforge.pmd.lang.ast; import java.util.ArrayList; import java.util.Iterator; import java.util.List; import java.util.Objects; import java.util.logging.Logger; import javax.xml.parsers.DocumentBuilder; import javax....
1
14,445
this change should be described in the changelog. I'll update it when merging if nothing else arises.
pmd-pmd
java
@@ -52,9 +52,11 @@ const ( type ( // RPCFactory Creates a dispatcher that knows how to transport requests. RPCFactory interface { - CreateDispatcher() *yarpc.Dispatcher + CreateTChannelDispatcher() *yarpc.Dispatcher + CreateGRPCDispatcher() *yarpc.Dispatcher CreateRingpopDispatcher() *yarpc.Dispatcher Cre...
1
// Copyright (c) 2017 Uber Technologies, Inc. // // Permission is hereby granted, free of charge, to any person obtaining a copy // of this software and associated documentation files (the "Software"), to deal // in the Software without restriction, including without limitation the rights // to use, copy, modify, merge...
1
9,083
Just to stay consistent with naming let's call it CreateGRPCDispatcherForOutbound. Also rename 'CreateDispatcherForOutbound' to 'CreateTChannelDispatcherForOutbound'
temporalio-temporal
go
@@ -88,7 +88,7 @@ public class Docker { findImage(new ImageNamePredicate(name, tag)); - LOG.info(String.format("Pulling %s:%s", name, tag)); + LOG.finest(String.format("Pulling %s:%s", name, tag)); HttpRequest request = new HttpRequest(POST, "/images/create"); request.addQueryParameter("fromI...
1
// Licensed to the Software Freedom Conservancy (SFC) under one // or more contributor license agreements. See the NOTICE file // distributed with this work for additional information // regarding copyright ownership. The SFC licenses this file // to you under the Apache License, Version 2.0 (the // "License"); you m...
1
16,460
This will always need to be displayed to users.
SeleniumHQ-selenium
java
@@ -431,3 +431,6 @@ def safe_subn(pattern, repl, target, *args, **kwargs): need a better solution that is aware of the actual content ecoding. """ return re.subn(str(pattern), str(repl), target, *args, **kwargs) + +def bin_safe(s): + return ''.join(["\\x{:02x}".format(ord(i)) if ord(i) < 32 else i...
1
from __future__ import absolute_import, print_function, division import os.path import re import codecs import unicodedata from abc import ABCMeta, abstractmethod import importlib import inspect import six from six.moves import urllib import hyperframe @six.add_metaclass(ABCMeta) class Serializable(object): """...
1
11,388
This looks very much like `repr` now (we miss 127 though) - maybe just do `repr(x)` + strip outer parantheses?
mitmproxy-mitmproxy
py
@@ -386,6 +386,7 @@ func (p *replicatorQueueProcessorImpl) generateSyncActivityTask( VersionHistory: versionHistory, }, }, + VisibilityTime: &taskInfo.VisibilityTimestamp, }, nil }, )
1
// The MIT License // // Copyright (c) 2020 Temporal Technologies Inc. All rights reserved. // // Copyright (c) 2020 Uber Technologies, Inc. // // Permission is hereby granted, free of charge, to any person obtaining a copy // of this software and associated documentation files (the "Software"), to deal // in the Soft...
1
13,264
I don't see this field is set in task_generator.go. worth to double check if we put the timestamp when creating replication tasks.
temporalio-temporal
go
@@ -236,7 +236,9 @@ const hasNext = (self, callback) => { if (self.s.currentDoc) { return callback(null, true); } - + if (self.isNotified()) { + return callback(null, false); + } nextObject(self, function(err, doc) { if (err) return callback(err, null); if (self.s.state === Cursor.CLOSED ||...
1
'use strict'; const inherits = require('util').inherits; const f = require('util').format; const deprecate = require('util').deprecate; const formattedOrderClause = require('./utils').formattedOrderClause; const handleCallback = require('./utils').handleCallback; const ReadPreference = require('mongodb-core').ReadPref...
1
14,406
nit: I prefer the space before and after this check to make it very easy to scan when reading through code
mongodb-node-mongodb-native
js
@@ -454,6 +454,15 @@ Morbi Nulla justo Aenean orci Vestibulum ullamcorper tincidunt mollis et hendrer logger.Info(createdMessage); } + // Make triple-flush to fully exercise the async flushing logic + try + { + LogMa...
1
// // Copyright (c) 2004-2016 Jaroslaw Kowalski <jaak@jkowalski.net>, Kim Christensen, Julian Verdurmen // // All rights reserved. // // Redistribution and use in source and binary forms, with or without // modification, are permitted provided that the following conditions // are met: // // * Redistributions of ...
1
14,514
should users also do a triple-flush?
NLog-NLog
.cs
@@ -302,9 +302,7 @@ func testCodec(t *testing.T, ct CodecTester) { type S struct { N *int I int - U uint F float64 - C complex64 St string B bool By []byte
1
// Copyright 2019 The Go Cloud Development Kit Authors // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // https://www.apache.org/licenses/LICENSE-2.0 // // Unless required by appli...
1
15,583
What is the implication of removing these from the test? I thought the idea was to have all types supported by `docstore` here, and do things in the drivers to make them support them (e.g., list of size 2 for complex). If you're removing them because firestore doesn't have native support, then we're going to end up onl...
google-go-cloud
go
@@ -217,7 +217,7 @@ class DataViewer(base.GridEditor, layoutwidget.LayoutWidget): ]) -> None: if vals: # Whatever vals is, make it a list of rows containing lists of column values. - if isinstance(vals, str): + if not isinstance(vals, list): vals...
1
import urwid import typing from mitmproxy import exceptions from mitmproxy.http import Headers from mitmproxy.tools.console import layoutwidget from mitmproxy.tools.console import signals from mitmproxy.tools.console.grideditor import base from mitmproxy.tools.console.grideditor import col_bytes from mitmproxy.tools.c...
1
15,989
Let's also adjust the somewhat weird type signature here as well. This probably should be `typing.Any` instead of `str` in the last line if we intend to support ints.
mitmproxy-mitmproxy
py
@@ -36,7 +36,7 @@ func makeBucket(t *testing.T) (*blob.Bucket, func()) { if err != nil { t.Fatal(err) } - return b, func() {} + return b, func() { _ = os.RemoveAll(dir) } } func TestConformance(t *testing.T) { drivertest.RunConformanceTests(t, makeBucket, "../testdata")
1
// Copyright 2018 The Go Cloud Authors // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // https://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agr...
1
10,891
The body can just be `os.RemoveAll(dir)`
google-go-cloud
go
@@ -42,7 +42,7 @@ public class Cast extends NoOp { } else if (targetDataType instanceof RealType) { casted = castToDouble(value); } else { - throw new UnsupportedOperationException("only support cast to Long, Double and String"); + casted = value; } row.set(pos, targetDataType, cast...
1
/* * * Copyright 2017 PingCAP, Inc. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agre...
1
8,025
Is this covered by regression tests? Also you might make a patch onto refactor branch.
pingcap-tispark
java
@@ -54,6 +54,11 @@ public class SolrPing extends SolrRequest<SolrPingResponse> { public ModifiableSolrParams getParams() { return params; } + + @Override + public String getRequestType() { + return SolrRequestType.QUERY.toString(); + } /** * Remove the action parameter from this request. Thi...
1
/* * Licensed to the Apache Software Foundation (ASF) under one or more * contributor license agreements. See the NOTICE file distributed with * this work for additional information regarding copyright ownership. * The ASF licenses this file to You under the Apache License, Version 2.0 * (the "License"); you may ...
1
35,748
This is maybe more of an admin request? WDYT?
apache-lucene-solr
java
@@ -109,16 +109,16 @@ public interface TraversableOnce<T> extends Iterable<T> { } /** - * Converts this TraversableOnce to a HashMap. + * Converts this TraversableOnce to a Map. * * @param f A function that maps an element to a Map.Entry * @param <K> The key type of a Map Entry ...
1
/* / \____ _ ______ _____ / \____ ____ _____ * / \__ \/ \ / \__ \ / __// \__ \ / \/ __ \ Javaslang * _/ // _\ \ \/ / _\ \\_ \/ // _\ \ /\ \__/ / Copyright 2014-2015 Daniel Dietrich * /___/ \_____/\____/\_____/____/\___\_____/_/ \_/____/ Licensed under the Apache License...
1
6,094
Here I thought of `toHashMap` and later add `toTreeMap`. But I start to see, what you may have in mind. Alternatively we could provide a `toMap` and `toSortedMap`, which is great, too. On the other hand is always good to be as specific as possible. What do you think?
vavr-io-vavr
java
@@ -79,13 +79,13 @@ type appDeployOpts struct { projectService projectService ecrService ecr.Service - workspaceService *workspace.Workspace + workspaceService archer.Workspace prompt prompter spinner progress - projectApplications []*archer.Application - projectEnvironments []*archer.Environment...
1
// Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. // SPDX-License-Identifier: Apache-2.0 package cli import ( "bytes" "errors" "fmt" "io/ioutil" "os/exec" "strings" "github.com/spf13/cobra" "github.com/aws/amazon-ecs-cli-v2/internal/pkg/archer" "github.com/aws/amazon-ecs-cli-v2/int...
1
10,994
maybe localProjectAppNames? Just a thought.
aws-copilot-cli
go
@@ -354,6 +354,7 @@ Blockly.BlockSvg.prototype.getHeightWidth = function() { if (nextBlock) { var nextHeightWidth = nextBlock.getHeightWidth(); height += nextHeightWidth.height; + height -= Blockly.BlockSvg.NOTCH_HEIGHT; // Exclude height of connected notch. width = Math.max(width, nextHeightWidth....
1
/** * @license * Visual Blocks Editor * * Copyright 2012 Google Inc. * https://developers.google.com/blockly/ * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apach...
1
7,809
This isn't new, but getHeightWidth is now defined in block_svg.js, block_render_svg_horizontal.js, and block_render_svg_vertical.js. One of these should be unnecessary.
LLK-scratch-blocks
js
@@ -156,7 +156,7 @@ func TestGroupTransactionsDifferentSizes(t *testing.T) { // wait for the txids and check balances _, curRound := fixture.GetBalanceAndRound(account0) - confirmed := fixture.WaitForAllTxnsToConfirm(curRound+5, txids) + confirmed := fixture.WaitForAllTxnsToConfirm(curRound+10, txids) a.Tr...
1
// Copyright (C) 2019-2020 Algorand, Inc. // This file is part of go-algorand // // go-algorand is free software: you can redistribute it and/or modify // it under the terms of the GNU Affero General Public License as // published by the Free Software Foundation, either version 3 of the // License, or (at your option) ...
1
38,661
I can't see any reason why this would fix a failure in `a.True(confirmed, "txgroup")`. We might have an issue elsewhere, but increasing the wait time wouldn't help.
algorand-go-algorand
go
@@ -46,6 +46,10 @@ module Beaker @logger.perf_output("Creating symlink from /etc/sysstat/sysstat.cron to /etc/cron.d") host.exec(Command.new('ln -s /etc/sysstat/sysstat.cron /etc/cron.d'),:acceptable_exit_codes => [0,1]) end + if @options[:collect_perf_data] =~ /aggressive/ + @logge...
1
module Beaker # The Beaker Perf class. A single instance is created per Beaker run. class Perf PERF_PACKAGES = ['sysstat'] # SLES does not treat sysstat as a service that can be started PERF_SUPPORTED_PLATFORMS = /debian|ubuntu|redhat|centos|oracle|scientific|fedora|el|eos|cumulus|sles/ PERF_START_...
1
11,340
This section needs to be modified; crontab format differs between OS releases (Debian and CentOS, at least).
voxpupuli-beaker
rb
@@ -54,7 +54,10 @@ from .results import PipelineExecutionResult def execute_run_iterator( - pipeline: IPipeline, pipeline_run: PipelineRun, instance: DagsterInstance + pipeline: IPipeline, + pipeline_run: PipelineRun, + instance: DagsterInstance, + resume_from_failure: bool = False, ) -> Iterator[D...
1
import sys from contextlib import contextmanager from typing import Any, Dict, FrozenSet, Iterator, List, Optional, Tuple, Union from dagster import check from dagster.core.definitions import IPipeline, JobDefinition, PipelineDefinition from dagster.core.definitions.pipeline import PipelineSubsetDefinition from dagste...
1
16,026
if we think this is likely to be augmented with a additional 'run coordination' features or configuration in the future, we could make it an object of some kind instead (or an enum, if we think there may be other resume modes in the future besides just on/off). Just imagining 6 months in the future, it would be unfortu...
dagster-io-dagster
py
@@ -1,8 +1,10 @@ +from .affine_grid_generator import affine_grid from .context_block import ContextBlock from .dcn import (DeformConv, DeformConvPack, DeformRoIPooling, DeformRoIPoolingPack, ModulatedDeformConv, ModulatedDeformConvPack, ModulatedDeformRoIPoolingPack, ...
1
from .context_block import ContextBlock from .dcn import (DeformConv, DeformConvPack, DeformRoIPooling, DeformRoIPoolingPack, ModulatedDeformConv, ModulatedDeformConvPack, ModulatedDeformRoIPoolingPack, deform_conv, deform_roi_pooling, modulated_deform_conv) from .m...
1
18,623
`affine_grid` and `grid_sample` are currently unused. We may remove it from `ops/__init__.py` to speedup the loading of mmdet.
open-mmlab-mmdetection
py
@@ -215,6 +215,12 @@ func populateClientConfig(config *Config, createdPacketConn bool) *Config { if config.IdleTimeout != 0 { idleTimeout = config.IdleTimeout } + attackTimeout := protocol.DefaultAttackTimeout + if config.AttackTimeout > 0 { + attackTimeout = config.AttackTimeout + } else if config.AttackTimeou...
1
package quic import ( "context" "crypto/tls" "errors" "fmt" "net" "strings" "sync" "github.com/lucas-clemente/quic-go/internal/handshake" "github.com/lucas-clemente/quic-go/internal/protocol" "github.com/lucas-clemente/quic-go/internal/utils" "github.com/lucas-clemente/quic-go/internal/wire" ) type client...
1
8,342
Is there a reason why you need to support negative `AttackTimeout`? Why not just throw an error?
lucas-clemente-quic-go
go
@@ -25,6 +25,7 @@ from typing import Any, Optional, List, Tuple, Union, Generic, TypeVar import numpy as np import pandas as pd +import pyspark.sql.functions as F from pandas.api.types import is_list_like, is_dict_like from pandas.core.dtypes.common import infer_dtype_from_object from pandas.core.dtypes.inferenc...
1
# # Copyright (C) 2019 Databricks, Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to i...
1
10,381
nit: an unnecessary change?
databricks-koalas
py
@@ -1,15 +1,17 @@ package http3 import ( - "fmt" "io" "github.com/lucas-clemente/quic-go" + "github.com/marten-seemann/qpack" ) +type trailerFunc func([]qpack.HeaderField, error) + // The body of a http.Request or http.Response. type body struct { - str quic.Stream + str RequestStream // only set for...
1
package http3 import ( "fmt" "io" "github.com/lucas-clemente/quic-go" ) // The body of a http.Request or http.Response. type body struct { str quic.Stream // only set for the http.Response // The channel is closed when the user is done with this response: // either when Read() errors, or when Close() is call...
1
10,000
Is trailer parsing something we have to do in this PR? It would be really helpful to separate stuff like this into smaller, self-contained PRs.
lucas-clemente-quic-go
go
@@ -153,6 +153,7 @@ module Beaker vm.volumes.each do |vol| @logger.debug "Deleting volume #{vol.name} for OpenStack host #{vm.name}" vm.detach_volume(vol.id) + vol.wait_for { ready? } vol.destroy end end
1
module Beaker #Beaker support for OpenStack #This code is EXPERIMENTAL! #Please file any issues/concerns at https://github.com/puppetlabs/beaker/issues class OpenStack < Beaker::Hypervisor SLEEPWAIT = 5 #Create a new instance of the OpenStack hypervisor object #@param [<Host>] openstack_hosts The ...
1
10,564
Any chance of a wait-forever situation here? Is there a reasonable timeout?
voxpupuli-beaker
rb
@@ -79,12 +79,10 @@ func (bs *blockSyncer) P2P() network.Overlay { // Start starts a block syncer func (bs *blockSyncer) Start(ctx context.Context) error { logger.Debug().Msg("Starting block syncer") - startHeight, err := findSyncStartHeight(bs.bc) - if err != nil { - return err - } - bs.buf.startHeight = startHei...
1
// Copyright (c) 2018 IoTeX // This is an alpha (internal) release and is not suitable for production. This source code is provided 'as is' and no // warranties are given as to title or non-infringement, merchantability or fitness for purpose and, to the extent // permitted by law, all liability for your use of the cod...
1
12,980
line is 165 characters
iotexproject-iotex-core
go
@@ -107,9 +107,13 @@ func (s *IntegrationBase) setupSuite(defaultClusterConfigFile string) { s.Require().NoError(s.registerArchivalNamespace()) - // this sleep is necessary because namespacev2 cache gets refreshed in the - // background only every namespaceCacheRefreshInterval period - time.Sleep(namespace.CacheR...
1
// The MIT License // // Copyright (c) 2020 Temporal Technologies Inc. All rights reserved. // // Copyright (c) 2020 Uber Technologies, Inc. // // Permission is hereby granted, free of charge, to any person obtaining a copy // of this software and associated documentation files (the "Software"), to deal // in the Soft...
1
12,547
is this for cross DC case?
temporalio-temporal
go
@@ -199,7 +199,7 @@ if __name__ == '__main__': keywords='computer vision, object detection', url='https://github.com/open-mmlab/mmdetection', packages=find_packages(exclude=('configs', 'tools', 'demo')), - package_data={'mmdet.ops': ['*/*.so']}, + package_data={'mmcv.ops': ['*/*...
1
#!/usr/bin/env python import os import subprocess import time from setuptools import find_packages, setup import torch from torch.utils.cpp_extension import (BuildExtension, CppExtension, CUDAExtension) def readme(): with open('README.md', encoding='utf-8') as f: co...
1
20,662
Remove this line.
open-mmlab-mmdetection
py
@@ -668,10 +668,11 @@ import browser from './browser'; } if (canPlayVp8) { + // TODO: Remove vpx entry once servers are migrated profile.TranscodingProfiles.push({ Container: 'webm', Type: 'Video', - AudioCodec: 'vorbis', + ...
1
import appSettings from './settings/appSettings'; import * as userSettings from './settings/userSettings'; import browser from './browser'; /* eslint-disable indent */ function canPlayH264(videoTestElement) { return !!(videoTestElement.canPlayType && videoTestElement.canPlayType('video/mp4; codecs="avc1.42...
1
19,507
Maybe it would make sense to use `webmVideoCodecs` here and just append `vpx`. I'm not sure if av1 is currently supported when transcoding to webm though. It looks like it can be included in the mp4 transcoding profile now.
jellyfin-jellyfin-web
js
@@ -182,7 +182,7 @@ public class StatsValuesFactory { // "NumericValueSourceStatsValues" which would have diff parent classes // // part of the complexity here being that the StatsValues API serves two - // masters: collecting concrete Values from things like DocValuesStats and + // prima...
1
/* * Licensed to the Apache Software Foundation (ASF) under one or more * contributor license agreements. See the NOTICE file distributed with * this work for additional information regarding copyright ownership. * The ASF licenses this file to You under the Apache License, Version 2.0 * (the "License"); you may ...
1
36,008
Interestingly, this has nothing to do with replication, no clue what this means here
apache-lucene-solr
java
@@ -251,8 +251,14 @@ func (r *runner) initRepoIfNeeded(ctx context.Context, forCmd string) ( }() } - fs, _, err = libgit.GetOrCreateRepoAndID( - ctx, r.config, r.h, r.repo, r.uniqID) + // Only allow lazy creates for public and multi-user TLFs. + if r.h.Type() == tlf.Public || len(r.h.ResolvedWriters()) > 1 { + ...
1
// Copyright 2017 Keybase Inc. All rights reserved. // Use of this source code is governed by a BSD // license that can be found in the LICENSE file. package kbfsgit import ( "bufio" "context" "fmt" "io" "os" "path/filepath" "runtime" "runtime/pprof" "strconv" "strings" "sync" "time" "github.com/keybase...
1
17,982
Is that because we don't provide a UI for these?
keybase-kbfs
go
@@ -7,9 +7,11 @@ import ( "time" "github.com/influxdata/flux" + "github.com/influxdata/flux/codes" "github.com/influxdata/flux/execute" "github.com/influxdata/flux/execute/executetest" _ "github.com/influxdata/flux/fluxinit/static" // We need to init flux for the tests to work. + "github.com/influxdata/flux...
1
package csv_test import ( "context" "strings" "testing" "time" "github.com/influxdata/flux" "github.com/influxdata/flux/execute" "github.com/influxdata/flux/execute/executetest" _ "github.com/influxdata/flux/fluxinit/static" // We need to init flux for the tests to work. "github.com/influxdata/flux/mock" "g...
1
15,467
Standard is either to use `HappyPath` (CamelCase) or `happy path` (lowercase sentence). I usually prefer the latter.
influxdata-flux
go
@@ -46,7 +46,7 @@ func TestSuggestGasPriceForUserAction(t *testing.T) { blkState := blockchain.InMemStateFactoryOption() blkMemDao := blockchain.InMemDaoOption() blkRegistryOption := blockchain.RegistryOption(&registry) - bc := blockchain.NewBlockchain(cfg, blkState, blkMemDao, blkRegistryOption) + bc := blockcha...
1
// Copyright (c) 2019 IoTeX Foundation // This is an alpha (internal) release and is not suitable for production. This source code is provided 'as is' and no // warranties are given as to title or non-infringement, merchantability or fitness for purpose and, to the extent // permitted by law, all liability for your use...
1
19,364
instead of using blkMemDao, we could generate a blockMemDao, and then use it as the second parameter.
iotexproject-iotex-core
go
@@ -147,6 +147,10 @@ function eachAsync(arr, eachFn, callback) { } } +function isUnifiedTopology(topology) { + return topology.description != null; +} + module.exports = { uuidV4, calculateDurationInMs,
1
'use strict'; const crypto = require('crypto'); const requireOptional = require('require_optional'); /** * Generate a UUIDv4 */ const uuidV4 = () => { const result = crypto.randomBytes(16); result[6] = (result[6] & 0x0f) | 0x40; result[8] = (result[8] & 0x3f) | 0x80; return result; }; /** * Returns the du...
1
16,019
nit(2/10): `topology && topology.description != null`;
mongodb-node-mongodb-native
js
@@ -1,6 +1,8 @@ """ Wrappers around spark that correspond to common pandas functions. """ +import sys + import pyspark.sql import numpy as np import pandas as pd
1
""" Wrappers around spark that correspond to common pandas functions. """ import pyspark.sql import numpy as np import pandas as pd from .typing import Col, pandas_wrap from pyspark.sql import Column from pyspark.sql.types import StructType def default_session(): return pyspark.sql.SparkSession.builder.getOrCreat...
1
7,986
why the space? I may not know all the style conventions.
databricks-koalas
py
@@ -21,6 +21,12 @@ describe('dlitem', function () { assert.isFalse(checks.dlitem.evaluate.apply(null, checkArgs)); }); + it('should fail if the dlitem has a parent <dl> with a changed role', function(){ + var checkArgs = checkSetup('<dl role="menubar"><dt id="target">My list item</dl>'); + + assert.isFalse(che...
1
describe('dlitem', function () { 'use strict'; var fixture = document.getElementById('fixture'); var checkSetup = axe.testUtils.checkSetup; var shadowSupport = axe.testUtils.shadowSupport; afterEach(function () { fixture.innerHTML = ''; }); it('should pass if the dlitem has a parent <dl>', function () { v...
1
11,595
Should be "should fail if the **dt element** has a parent <dl> with a changed role"
dequelabs-axe-core
js
@@ -10,7 +10,15 @@ Workshops::Application.configure do config.assets.digest = true config.assets.js_compressor = :uglifier config.assets.precompile += %w( print.css prefilled_input.js ) - config.serve_static_assets = false + + # Serve static assets, which allows us to populate the CDN with compressed + # as...
1
require Rails.root.join('config/initializers/mail') Workshops::Application.configure do config.cache_classes = true config.consider_all_requests_local = false config.action_controller.perform_caching = true config.action_controller.asset_host = "//d3v2mfwlau8x6c.cloudfront.net" config.assets.compile =...
1
8,604
Just to be clear: 1. This is required for compression, right? 2. This won't actually result in our dynos serving the assets, since they'll be served via the CDN, correct?
thoughtbot-upcase
rb
@@ -17,10 +17,6 @@ class MediaManager extends BasePHPCRManager { /** * {@inheritdoc} - * - * Warning: previous method signature was : save(MediaInterface $media, $context = null, $providerName = null) - * - * @throws \InvalidArgumentException When entity is an invalid object */ pu...
1
<?php /* * This file is part of the Sonata project. * * (c) Thomas Rabaix <thomas.rabaix@sonata-project.org> * * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ namespace Sonata\MediaBundle\PHPCR; use Sonata\CoreBundle\Model\BasePHP...
1
7,135
not sure about removing this ping @Soullivaneuh
sonata-project-SonataMediaBundle
php
@@ -12,7 +12,12 @@ class User < ActiveRecord::Base validates :github_username, uniqueness: true, presence: true delegate :plan, to: :subscription, allow_nil: true - delegate :scheduled_for_deactivation_on, to: :subscription, allow_nil: true + delegate( + :scheduled_for_deactivation_on, + :scheduled_for_...
1
class User < ActiveRecord::Base include Clearance::User has_many :attempts, dependent: :destroy has_many :beta_replies, dependent: :destroy, class_name: "Beta::Reply" has_many :collaborations, dependent: :destroy has_many :statuses, dependent: :destroy has_many :subscriptions, dependent: :destroy belongs...
1
17,247
Put a comma after the last parameter of a multiline method call.
thoughtbot-upcase
rb
@@ -61,8 +61,8 @@ func TestInstanceIfExists(t *testing.T) { Return(nil, awserrors.NewNotFound("not found")) }, check: func(instance *infrav1.Instance, err error) { - if err != nil { - t.Fatalf("did not expect error: %v", err) + if err == nil { + t.Fatalf("expects error when instance could no...
1
/* Copyright 2018 The Kubernetes Authors. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, ...
1
21,897
If instance could not be found when the provider id is set, `findInstance()` returns `ErrInstanceNotFoundByID` error. So that during reconcileNormal(), we don't create a new instance. In `reconcileDelete()`, when ErrInstanceNotFoundByID is seen, deletion continues to clean up even if the instance is gone (may be manual...
kubernetes-sigs-cluster-api-provider-aws
go
@@ -38,6 +38,10 @@ namespace pwiz.Skyline.EditUI private readonly bool _originalAlignRtPrediction; private readonly ChromFileInfoId _originalAlignFile; + private int _idxLastSelected = -1; + + private Tuple<string, HashSet<string>> _memory = Tuple.Create((string)null, new HashSet<strin...
1
/* * Original author: Kaipo Tamura <kaipot .at. u.washington.edu>, * MacCoss Lab, Department of Genome Sciences, UW * * Copyright 2021 University of Washington - Seattle, WA * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with...
1
14,771
I would recommend making this a Tuple&lt;ReplicateValue, IColllection&lt;object>> You only need to convert things to strings if you need to persist them in Settings or something. If they only need to live for the life of dialog, you can keep everything as objects. You can use "null" for the ReplicateValue for when they...
ProteoWizard-pwiz
.cs
@@ -33,14 +33,14 @@ _source: ["https://www.google.lv", "https://www.google.co.in/", "https://www.google.ru/", "http://stackoverflow.com/questions", "http://stackoverflow.com/unanswered", "http://stackoverflow.com/tags", "http://r.search.yahoo.com/"] }; var eventsMap = { - "Login": ["Lost", "Won","[CLY]_st...
1
(function (countlyPopulator, $, undefined) { var metric_props = {mobile: ["_os", "_os_version", "_resolution", "_device", "_carrier", "_app_version", "_density", "_locale", "_store"], web:["_os", "_os_version", "_resolution", "_device", "_app_version", "_density", "_locale", "_store", "_browser"], desktop:[...
1
13,121
I think there is no point providing action key here, as it will be called specifically, rather than randomly
Countly-countly-server
js
@@ -31,14 +31,13 @@ namespace Datadog.Trace.ClrProfiler.Integrations.Testing private static readonly IntegrationInfo IntegrationId = IntegrationRegistry.GetIntegrationInfo(nameof(IntegrationIds.XUnit)); private static readonly Vendors.Serilog.ILogger Log = DatadogLogging.GetLogger(typeof(XUnitIntegr...
1
using System; using System.Collections.Generic; using System.Reflection; using Datadog.Trace.Ci; using Datadog.Trace.ClrProfiler.Emit; using Datadog.Trace.Configuration; using Datadog.Trace.ExtensionMethods; using Datadog.Trace.Logging; namespace Datadog.Trace.ClrProfiler.Integrations.Testing { /// <summary> /...
1
18,666
`XUnitIntegration` doesn't need to cache this anymore.
DataDog-dd-trace-dotnet
.cs
@@ -13,11 +13,13 @@ files["awesomerc.lua"].allow_defined_top = true -- This file itself files[".luacheckrc"].ignore = {"111", "112", "131"} +-- Theme files, ignore max line length +files["themes/*"].ignore = {"631"} + -- Global objects defined by the C code read_globals = { "awesome", "button", - "cl...
1
-- Only allow symbols available in all Lua versions std = "min" -- Get rid of "unused argument self"-warnings self = false -- The unit tests can use busted files["spec"].std = "+busted" -- The default config may set global variables files["awesomerc.lua"].allow_defined_top = true -- This file itself files[".luachec...
1
12,718
Can we have something line `# noqa` there instead? I think it's fine like this though.
awesomeWM-awesome
c
@@ -309,16 +309,17 @@ class AbstractNode # # Returns A String reference or data URI for the target image def image_uri(target_image, asset_dir_key = 'imagesdir') + images_base = asset_dir_key ? (attr asset_dir_key, nil, true) : nil if (doc = @document).safe < SafeMode::SECURE && (doc.attr? 'data-uri') ...
1
# frozen_string_literal: true module Asciidoctor # Public: An abstract base class that provides state and methods for managing a # node of AsciiDoc content. The state and methods on this class are common to # all content segments in an AsciiDoc document. class AbstractNode include Substitutors, Logging # Public: G...
1
6,740
this variable is used in both branches so I've decided to declare it above
asciidoctor-asciidoctor
rb
@@ -382,11 +382,11 @@ public class PasscodeManager { return; } Intent i = new Intent(ctx, PasscodeActivity.class); - i.setFlags(Intent.FLAG_ACTIVITY_SINGLE_TOP); - i.setFlags(Intent.FLAG_ACTIVITY_NO_HISTORY); - i.setFlags(Intent.FLAG_ACTIVITY_REORDER_TO_FRONT); + ...
1
/* * Copyright (c) 2011, salesforce.com, inc. * All rights reserved. * Redistribution and use of this software in source and binary forms, with or * without modification, are permitted provided that the following conditions * are met: * - Redistributions of source code must retain the above copyright notice, this...
1
13,754
`setFlags()` overwrites the previous flag, we should be using `addFlags()` to append flags.
forcedotcom-SalesforceMobileSDK-Android
java
@@ -105,6 +105,15 @@ func SettingsPost(ctx *context.Context, form auth.RepoSettingForm) { } if repo.IsMirror { + if isNameChanged { + var err error + ctx.Repo.Mirror, err = models.GetMirror(repo.ID) + if err != nil { + ctx.Handle(500, "RefreshRepositoryMirror", err) + return + } + } + ...
1
// Copyright 2014 The Gogs Authors. All rights reserved. // Use of this source code is governed by a MIT-style // license that can be found in the LICENSE file. package repo import ( "strings" "time" "github.com/gogits/git-module" "github.com/gogits/gogs/models" "github.com/gogits/gogs/modules/auth" "github.c...
1
11,434
Need `return` after this.
gogs-gogs
go
@@ -13,12 +13,14 @@ use RootedData\Exception\ValidationException; * Json Response Trait. */ trait JsonResponseTrait { + use CacheableResponseTrait; /** * Private. */ private function getResponse($message, int $code = 200): JsonResponse { - return new JsonResponse($message, $code, []); + $res...
1
<?php namespace Drupal\common; use Symfony\Component\HttpFoundation\JsonResponse; use OpisErrorPresenter\Implementation\MessageFormatterFactory; use OpisErrorPresenter\Implementation\PresentedValidationErrorFactory; use OpisErrorPresenter\Implementation\Strategies\BestMatchError; use OpisErrorPresenter\Implementation...
1
21,020
I would say we should not use the `CacheableResponseTrait` within the `JsonResponseTrait`. Traits within traits tend to lead to a bad developer experience as it can be really hard to find the actual method you're seeing in the implementing class, and in this case it looks like we're using _both_ the cacheable and the J...
GetDKAN-dkan
php
@@ -43,7 +43,7 @@ class BoundZmqEventBus implements EventBus { Addresses xpubAddr = deriveAddresses(address, publishConnection); Addresses xsubAddr = deriveAddresses(address, subscribeConnection); - LOG.info(String.format("XPUB binding to %s, XSUB binding to %s", xpubAddr, xsubAddr)); + LOG.finest(Str...
1
// Licensed to the Software Freedom Conservancy (SFC) under one // or more contributor license agreements. See the NOTICE file // distributed with this work for additional information // regarding copyright ownership. The SFC licenses this file // to you under the Apache License, Version 2.0 (the // "License"); you m...
1
16,463
This change is unhelpful: it precludes users from knowing which ports are being used for what purpose within the system.
SeleniumHQ-selenium
java
@@ -5,7 +5,8 @@ class ApplicationController < ActionController::Base private def current_user - User.find_by(email_address: session[:user]['email']) if session[:user].present? + # User.find_by(email_address: session[:user]['email']) if session[:user].present? + @current_user ||= User.find_or_create_by(...
1
class ApplicationController < ActionController::Base protect_from_forgery with: :exception helper_method :current_user, :signed_in? private def current_user User.find_by(email_address: session[:user]['email']) if session[:user].present? end def signed_in? !!current_user end def authenticate_...
1
12,147
Whoa, we weren't doing this before?? Derp.
18F-C2
rb
@@ -134,11 +134,16 @@ func (f *ofFlow) CopyToBuilder(priority uint16) FlowBuilder { // ToBuilder returns a new FlowBuilder with all the contents of the original Flow. func (f *ofFlow) ToBuilder() FlowBuilder { - // TODO: use exported fields from ofFlow and remove nolint:govet - flow := *f.Flow //nolint:govet + flow...
1
package openflow import ( "fmt" "strings" "github.com/contiv/libOpenflow/openflow13" "github.com/contiv/ofnet/ofctrl" ) type FlowStates struct { TableID uint8 PacketCount uint64 DurationNSecond uint32 } type ofFlow struct { table *ofTable // The Flow.Table field can be updated by Reset(), which...
1
22,486
I'm surprised we didn't go with something like `flow := f.Flow.Copy()` to take care of all the fields at once, but as long as it works it's good enough for me
antrea-io-antrea
go
@@ -467,7 +467,7 @@ func NewIntDataplaneDriver(config Config) *InternalDataplane { } // TODO Integrate XDP and BPF infra. - if !config.BPFEnabled && dp.xdpState == nil { + if !config.BPFEnabled && config.XDPEnabled && dp.xdpState == nil { xdpState, err := NewXDPState(config.XDPAllowGeneric) if err == nil { ...
1
// Copyright (c) 2020-2021 Tigera, Inc. All rights reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by ...
1
19,174
We would like this code to run, even when `config.XDPEnabled` is false, so that Felix can clean up its own XDP state after a restart.
projectcalico-felix
c
@@ -5,7 +5,10 @@ package net.sourceforge.pmd.lang.java.ast; -public class ASTAnnotationTypeDeclaration extends AbstractJavaAccessTypeNode { +public class ASTAnnotationTypeDeclaration extends AbstractJavaAccessTypeNode implements ASTAnyTypeDeclaration { + + QualifiedName qualifiedName; + public ASTAnnotatio...
1
/** * BSD-style license; for more info see http://pmd.sourceforge.net/license.html */ /* Generated By:JJTree: Do not edit this line. ASTAnnotationTypeDeclaration.java */ package net.sourceforge.pmd.lang.java.ast; public class ASTAnnotationTypeDeclaration extends AbstractJavaAccessTypeNode { public ASTAnnotation...
1
12,391
I'd declare this field `qualifiedName` private to hide it. Unless it really needs to be modified from somewhere else... (e.g. unit tests..), but then, we should find a solution, where this field can stay private.
pmd-pmd
java
@@ -53,7 +53,18 @@ var ( _ introspection.IntrospectableOutbound = (*Outbound)(nil) ) -var defaultURLTemplate, _ = url.Parse("http://localhost") +const http2AuthorityPseudoHeader = ":authority" + +var ( + defaultURLTemplate, _ = url.Parse("http://localhost") + // from https://tools.ietf.org/html/rfc7540#section-8.1...
1
// Copyright (c) 2021 Uber Technologies, Inc. // // Permission is hereby granted, free of charge, to any person obtaining a copy // of this software and associated documentation files (the "Software"), to deal // in the Software without restriction, including without limitation the rights // to use, copy, modify, merge...
1
19,492
is this exhaustive? or rather, any psudo header started with `:` is un-parsable/invalid in HTTP/1 right?
yarpc-yarpc-go
go
@@ -113,8 +113,10 @@ describe('Sessions', function () { return client .withSession(testCase.operation(client)) - .catch(() => expect(client.topology.s.sessionPool.sessions).to.have.length(1)) - .then(() => expect(client.topology.s.sessionPool.sessions).to.have.length(1)) ...
1
'use strict'; const expect = require('chai').expect; const setupDatabase = require('./shared').setupDatabase; const withMonitoredClient = require('./shared').withMonitoredClient; const TestRunnerContext = require('./spec-runner').TestRunnerContext; const generateTopologyTests = require('./spec-runner').generateTopolog...
1
19,226
Is this change implying something or just seems fit b/c regardless of outcome the sessions should still be length 1?
mongodb-node-mongodb-native
js
@@ -48,12 +48,15 @@ public class DiscoveryFragmentGenerator { ApiaryConfig apiaryConfig = discovery.getConfig(); + // TODO: Support multiple templates; don't hard-code the zero-index here. + Preconditions.checkArgument(configProto.getTemplatesCount() == 1); DiscoveryLanguageProvider languageProvider...
1
/* Copyright 2016 Google Inc * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in ...
1
14,751
Maybe throw an exception if there is more than one, so that discovering the lack of support is easier when someone tries to use it down the road.
googleapis-gapic-generator
java
@@ -85,8 +85,7 @@ Upcase::Application.routes.draw do resource :trail, controller: "exercise_trails", only: [:show] end - get "/new-languages", to: "marketing#new_languages" - get "/new-languages-thanks", to: "marketing#new_languages_thanks" + get "/new-language-confirmation", to: "new_language_co...
1
# NOTE: There are several rewrite rules defined in # config/initializers/rack_rewrite.rb which run before these routes. Upcase::Application.routes.draw do scope "upcase" do root to: "marketing#show" use_doorkeeper scope module: "admin" do resources :users, only: [] do resource :masquerade,...
1
18,282
Prefer single-quoted strings when you don't need string interpolation or special symbols.
thoughtbot-upcase
rb
@@ -334,3 +334,11 @@ func NewGCPDialOptions(t *testing.T, recording bool, filename string) (opts []gr } return opts, done } + +// RunTestsDependingOnDocker returns true when either: +// 1) Not on Travis. +// 2) On Travis Linux environment, where Docker is available. +func RunTestsDependingOnDocker() bool { + s := ...
1
// Copyright 2019 The Go Cloud Development Kit Authors // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // https://www.apache.org/licenses/LICENSE-2.0 // // Unless required by appli...
1
17,549
I feel the name of this function could be better, conveying it's a predicate. Something like `HasDockerTestEnvironment` or `CanRunLocalServerTests`, etc.
google-go-cloud
go
@@ -30,14 +30,14 @@ func NewMonsterStorageClient(cc *grpc.ClientConn) MonsterStorageClient { func (c *monsterStorageClient) Store(ctx context.Context, in *flatbuffers.Builder, opts... grpc.CallOption) (* Stat, error) { out := new(Stat) - err := grpc.Invoke(ctx, "/Example.MonsterStorage/Store", in, out, c.cc, op...
1
//Generated by gRPC Go plugin //If you make any local changes, they will be lost //source: monster_test package Example import "github.com/google/flatbuffers/go" import ( context "golang.org/x/net/context" grpc "google.golang.org/grpc" ) // Client API for MonsterStorage service type MonsterStorageClient interfa...
1
13,630
This seems unrelated to your PR, how did this end up in here?
google-flatbuffers
java
@@ -143,7 +143,7 @@ public class InMemoryUserDetailsManager implements UserDetailsManager, @Override public UserDetails updatePassword(UserDetails user, String newPassword) { String username = user.getUsername(); - MutableUserDetails mutableUser = this.users.get(username); + MutableUserDetails mutableUser = th...
1
/* * Copyright 2002-2016 the original author or authors. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by ap...
1
11,211
Is `username` expected to be case insensitive?
spring-projects-spring-security
java
@@ -18,16 +18,13 @@ import ( "testing" "time" - "github.com/iotexproject/iotex-core/pkg/util/fileutil" - - "github.com/iotexproject/iotex-core/pkg/unit" - - "github.com/iotexproject/iotex-core/test/identityset" - "github.com/pkg/errors" "github.com/stretchr/testify/assert" "github.com/stretchr/testify/requi...
1
// Copyright (c) 2018 IoTeX // This is an alpha (internal) release and is not suitable for production. This source code is provided 'as is' and no // warranties are given as to title or non-infringement, merchantability or fitness for purpose and, to the extent // permitted by law, all liability for your use of the cod...
1
17,450
File is not `gofmt`-ed with `-s` (from `gofmt`)
iotexproject-iotex-core
go
@@ -37,9 +37,9 @@ import net.sourceforge.pmd.util.FileUtil; import net.sourceforge.pmd.util.datasource.DataSource; /** - * - * + * @deprecated use {@link TimeTracker} instead */ +@Deprecated public final class Benchmarker { private static final Map<String, BenchmarkResult> BENCHMARKS_BY_NAME = new HashMap...
1
/** * BSD-style license; for more info see http://pmd.sourceforge.net/license.html */ package net.sourceforge.pmd.benchmark; import java.io.BufferedInputStream; import java.io.IOException; import java.io.InputStream; import java.io.InputStreamReader; import java.util.HashMap; import java.util.Iterator; import java....
1
14,069
Is there any point to the deprecation? If someone was using these APIs, can they continue to do so in any meaningful fashion now that you've disconnected them from the PMD internals? Normally "compiles but doesn't work" is considered a bug.
pmd-pmd
java
@@ -104,7 +104,7 @@ class CompletionView(QTreeView): """ resize_completion = pyqtSignal() - selection_changed = pyqtSignal(QItemSelection) + selection_changed = pyqtSignal(str) def __init__(self, win_id, parent=None): super().__init__(parent)
1
# vim: ft=python fileencoding=utf-8 sts=4 sw=4 et: # Copyright 2014-2016 Florian Bruhin (The Compiler) <mail@qutebrowser.org> # # This file is part of qutebrowser. # # qutebrowser is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free S...
1
16,543
You can remove the `QItemSelection` import in this file now.
qutebrowser-qutebrowser
py
@@ -11,12 +11,17 @@ namespace meta { void ListSpacesProcessor::process(const cpp2::ListSpacesReq& req) { UNUSED(req); - guard_ = std::make_unique<std::lock_guard<std::mutex>>( - BaseProcessor<cpp2::ListSpacesResp>::lock_); + auto& spaceLock = LockUtils::spaceLock(); + if ...
1
/* Copyright (c) 2018 - present, VE Software Inc. All rights reserved * * This source code is licensed under Apache 2.0 License * (found in the LICENSE.Apache file in the root directory) */ #include "meta/processors/ListSpacesProcessor.h" namespace nebula { namespace meta { void ListSpacesProcessor::process(con...
1
15,536
Use `std::shared_lock` and `std::try_to_lock_t`. BTW. Why we fail on contention?
vesoft-inc-nebula
cpp
@@ -37,7 +37,10 @@ module.exports = function(config) { new webpack.DefinePlugin({ "process.env.NODE_ENV": JSON.stringify("test") }) - ] + ], + resolve: { + extensions: ["", ".jsx", ".js"] + } }, webpackServer: {
1
// Karma configuration // Generated on Tue Jul 28 2015 16:29:51 GMT+0200 (CEST) var webpack = require("webpack"); var CONTINUOUS_INTEGRATION = process.env.CONTINUOUS_INTEGRATION === "true"; module.exports = function(config) { config.set({ frameworks: ["mocha", "sinon", "chai"], browsers: [CONTINUOUS_INTEGR...
1
5,045
Not sure what this actually does, but do you need to add `""` here? Or does `[".jsx", ".js"]` work too?
Hacker0x01-react-datepicker
js