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
@@ -34,7 +34,13 @@ type payoutInfo struct { // in Ethereum address format // required: true // example: 0x000000000000000000000000000000000000000a - EthAddress string `json:"ethAddress"` + EthAddress string `json:"ethAddress"` +} + +// swagger:model ReferralInfoDTO +type referralInfo struct { + // required: tru...
1
/* * Copyright (C) 2019 The "MysteriumNetwork/node" Authors. * * This program 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 3 of the License, or * (at your option) any later version. * ...
1
14,793
We are using a different style for JSON tags. `ethAddress` - camalCase `referral_code` - snake_case
mysteriumnetwork-node
go
@@ -10,6 +10,7 @@ namespace Datadog.Trace.ClrProfiler.Integrations public static class HttpContextIntegration { private const string IntegrationName = "HttpContext"; + private const string DefaultHttpContextTypeName = "HttpContext"; private static readonly ILog Log = LogProvider.GetLo...
1
using System; using Datadog.Trace.ClrProfiler.Emit; using Datadog.Trace.Logging; namespace Datadog.Trace.ClrProfiler.Integrations { /// <summary> /// Tracer integration ambient base for web server integrations. /// </summary> public static class HttpContextIntegration { private const string...
1
15,611
Should this be `"Microsoft.AspNetCore.Http.DefaultHttpContext"`?
DataDog-dd-trace-dotnet
.cs
@@ -68,7 +68,6 @@ interface ArrayType<T> { /** Repeatedly group an array into equal sized sub-trees */ default Object grouped(Object array, int groupSize) { final int arrayLength = lengthOf(array); - assert arrayLength > groupSize; final Object results = obj().newInstance(1 + ((arrayL...
1
/* / \____ _ _ ____ ______ / \ ____ __ _______ * / / \/ \ / \/ \ / /\__\/ // \/ \ // /\__\ JΛVΛSLΛNG * _/ / /\ \ \/ / /\ \\__\\ \ // /\ \ /\\/ \ /__\ \ Copyright 2014-2016 Javaslang, http://javaslang.io * /___/\_/ \_/\____/\_/ \_/\__\/__/\__\_/ \_// \__/\_____/ ...
1
11,456
removed asserts from `Vector` as it's stable enough and it may hinder inlining, even if turned off :/
vavr-io-vavr
java
@@ -47,8 +47,14 @@ class MessageDefinitionStore: self._messages_definitions[message.msgid] = message self._msgs_by_category[message.msgid[0]].append(message.msgid) + # We disable the message here because MessageDefinitionStore is only + # initialized once and due to the size of the class does ...
1
# Licensed under the GPL: https://www.gnu.org/licenses/old-licenses/gpl-2.0.html # For details: https://github.com/PyCQA/pylint/blob/main/LICENSE import collections import functools from typing import TYPE_CHECKING, Dict, List, Tuple, ValuesView from pylint.exceptions import UnknownMessageError from pylint.message.me...
1
20,320
Do we want to raise on the function or on the decorator?
PyCQA-pylint
py
@@ -38,7 +38,7 @@ class Listen(object): user_name=j.get('user_name', ""), timestamp=datetime.utcfromtimestamp(float(j['listened_at'])), artist_msid=j['track_metadata']['additional_info'].get('artist_msid'), - album_msid=j['track_metadata']['additional_info'].get('album_...
1
# coding=utf-8 from __future__ import division, absolute_import, print_function, unicode_literals import ujson from datetime import datetime import calendar class Listen(object): """ Represents a listen object """ def __init__(self, user_id=None, user_name=None, timestamp=None, artist_msid=None, album_msid=Non...
1
14,140
How complex is to to replace `album_*` with `release_*` everywhere in the `Listen` class and places that use it?
metabrainz-listenbrainz-server
py
@@ -96,13 +96,13 @@ func (n *Namespaces) Remove(t NamespaceType) bool { return true } -func (n *Namespaces) Add(t NamespaceType, path string) { +func (n *Namespaces) Add(t NamespaceType, path string) bool { i := n.index(t) if i == -1 { *n = append(*n, Namespace{Type: t, Path: path}) - return + return true...
1
// +build linux freebsd package configs import ( "fmt" "os" "sync" ) const ( NEWNET NamespaceType = "NEWNET" NEWPID NamespaceType = "NEWPID" NEWNS NamespaceType = "NEWNS" NEWUTS NamespaceType = "NEWUTS" NEWIPC NamespaceType = "NEWIPC" NEWUSER NamespaceType = "NEWUSER" ) var ( nsLock syn...
1
13,369
You haven't changed any of the callers of `.Add` to check the return value, so we're now ignoring duplicates. Please fix that.
opencontainers-runc
go
@@ -10,6 +10,16 @@ * @return {Boolean} the element's hidden status */ dom.isHiddenWithCSS = function isHiddenWithCSS(el, descendentVisibilityValue) { + const vNode = axe.utils.getNodeFromTree(el); + + if (vNode._isHiddenWithCSS === void 0) { + vNode._isHiddenWithCSS = _isHiddenWithCSS(el, descendentVisibilityValu...
1
/* global dom */ /** * Determine whether an element is hidden based on css * @method isHiddenWithCSS * @memberof axe.commons.dom * @instance * @param {HTMLElement} el The HTML Element * @param {Boolean} descendentVisibilityValue (Optional) immediate descendant visibility value used for recursive computation * @...
1
15,054
@straker should this not push to `vnode._cache.isHiddenWithCSS`?
dequelabs-axe-core
js
@@ -12,8 +12,8 @@ // See the License for the specific language governing permissions and // limitations under the License. -// Package driver provides the interface for providers of runtimevar. This serves as a contract -// of how the runtimevar API uses a provider implementation. +// Package driver defines an int...
1
// Copyright 2018 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
19,314
"an interface" in conceptual sense vs "interfaces" or "set of interfaces", referring to the Go interfaces - database/sql uses the latter, should we?
google-go-cloud
go
@@ -335,8 +335,11 @@ public class DownloadService extends Service { && String.valueOf(HttpURLConnection.HTTP_GONE).equals(status.getReasonDetailed()); boolean httpBadReq = status.getReason() == DownloadError.ERROR_HTTP_DATA_ERROR && String.v...
1
package de.danoeh.antennapod.core.service.download; import android.app.Notification; import android.app.NotificationManager; import android.app.Service; import android.content.BroadcastReceiver; import android.content.Context; import android.content.Intent; import android.content.IntentFilter; import android.os.Binder...
1
18,126
This now checks nearly all errors that can occur. How about explicitly listing cases where we want it to retry? I think there are not many cases where we want that, as the many added conditions in the last years show :)
AntennaPod-AntennaPod
java
@@ -247,7 +247,8 @@ func (brq *blockRetrievalQueue) PutInCaches(ctx context.Context, // checkCaches copies a block into `block` if it's in one of our caches. func (brq *blockRetrievalQueue) checkCaches(ctx context.Context, - kmd KeyMetadata, ptr BlockPointer, block Block) (PrefetchStatus, error) { + kmd KeyMetadata...
1
// Copyright 2016 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 libkbfs import ( "container/heap" "io" "reflect" "sync" "github.com/keybase/client/go/logger" "github.com/keybase/kbfs/tlf" "github.com/pkg/errors" "go...
1
20,702
Can you make this accept an action instead?
keybase-kbfs
go
@@ -33,3 +33,16 @@ When /^I should see an image with name "([^"]*)"$/ do |image_name| page.should have_selector("img", src: /#{image_name}/) end +When /^a product named "([^"]*)"$/ do |product_name| + create(:product, fulfillment_method: "fetch", name: product_name, product_type: "screencast") +end + +When /^a ...
1
When /^I add a download with file name "([^"]*)" and description "([^"]*)"$/ do |file_name, description| click_link "Add a download" path = File.join(Rails.root,"tmp/",file_name) File.open(path, 'w+') do |f| f.puts "Ths is a test file" end attach_file "Download", path fill_in "Download Description", w...
1
6,396
Tab inconsistency here (3 spaces instead of 2 spaces)
thoughtbot-upcase
rb
@@ -56,14 +56,15 @@ func defaultConfig() Genesis { EnableGravityChainVoting: true, }, Rewarding: Rewarding{ - InitBalanceStr: unit.ConvertIotxToRau(1200000000).String(), + InitBalanceStr: unit.ConvertIotxToRau(200000000).String(), BlockRewardStr: unit.Co...
1
// Copyright (c) 2019 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
18,204
these change means we are changing epoch to 1 hour?
iotexproject-iotex-core
go
@@ -46,6 +46,11 @@ import core import keyboardHandler import characterProcessing from . import guiHelper + +#: The size that settings panel text descriptions should be wrapped at. +# Ensure self.scaleSize is used to adjust for OS scaling adjustments. +PANEL_DESCRIPTION_WIDTH = 544 + try: import updateCheck excep...
1
# -*- coding: UTF-8 -*- # A part of NonVisual Desktop Access (NVDA) # Copyright (C) 2006-2021 NV Access Limited, Peter Vágner, Aleksey Sadovoy, # Rui Batista, Joseph Lee, Heiko Folkerts, Zahari Yurukov, Leonard de Ruijter, # Derek Riemer, Babbage B.V., Davy Kager, Ethan Holliger, Bill Dengler, Thomas Stivers, # Ju...
1
34,098
Why this is defined in the middle of imports?
nvaccess-nvda
py
@@ -14,8 +14,10 @@ # limitations under the License. # +import importlib from distutils.version import LooseVersion +_backends = {} import matplotlib import numpy as np import pandas as pd
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
15,741
Could you move this to the original position?
databricks-koalas
py
@@ -160,7 +160,7 @@ func (s *Source) Owner() (string, error) { if err != nil { return "", err } - return oAndR.repo, nil + return oAndR.owner, nil } // PipelineStage represents configuration for each deployment stage
1
// Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. // SPDX-License-Identifier: Apache-2.0 // Package deploy holds the structures to deploy applications and environments. package deploy import ( "errors" "fmt" "strings" "github.com/aws/aws-sdk-go/aws/arn" "github.com/aws/amazon-ecs-cli-v...
1
10,987
Is there a test that'd have caught this?
aws-copilot-cli
go
@@ -419,7 +419,7 @@ func (s *VisibilityPersistenceSuite) TestFilteringByType() { // List open with filtering resp, err2 := s.VisibilityMgr.ListOpenWorkflowExecutionsByType(&visibility.ListWorkflowExecutionsByTypeRequest{ - ListWorkflowExecutionsRequest: visibility.ListWorkflowExecutionsRequest{ + ListWorkflowEx...
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,464
ListWorkflowExecutionsRequest <- this can be nil?
temporalio-temporal
go
@@ -809,10 +809,14 @@ module Beaker # This wraps the method `stub_hosts_on` and makes the stub specific to # the forge alias. # + # forge api v1 canonical source is forge.puppetlabs.com + # forge api v3 canonical source is forgeapi.puppetlabs.com + # # @param machine [String] ...
1
require 'resolv' require 'inifile' require 'timeout' require 'beaker/dsl/outcomes' module Beaker module DSL # This is the heart of the Puppet Acceptance DSL. Here you find a helper # to proxy commands to hosts, more commands to move files between hosts # and execute remote scripts, confine test cases to ...
1
5,026
Do we need to continue to support the old link, or is it dead dead dead?
voxpupuli-beaker
rb
@@ -108,6 +108,14 @@ namespace Datadog.Trace.Configuration GlobalTags = GlobalTags.Where(kvp => !string.IsNullOrEmpty(kvp.Key) && !string.IsNullOrEmpty(kvp.Value)) .ToDictionary(kvp => kvp.Key.Trim(), kvp => kvp.Value.Trim()); + HeaderTags = source?.GetDicti...
1
using System; using System.Collections.Concurrent; using System.Collections.Generic; using System.Linq; using Datadog.Trace.Sampling; using Datadog.Trace.Util; namespace Datadog.Trace.Configuration { /// <summary> /// Contains Tracer settings. /// </summary> public class TracerSettings { //...
1
17,320
Do we need `ConcurrentDictionary`? `Dictionary` can be safely read from multiple threads. See `GlobalTags`.
DataDog-dd-trace-dotnet
.cs
@@ -325,10 +325,12 @@ func validateRegisteredAttributes(expectedAttributes, actualAttributes []*ecs.At } func (client *APIECSClient) getAdditionalAttributes() []*ecs.Attribute { + osFamilyStr := config.GetOSFamilyType() + seelog.Infof("Server OSFamily string: %s", osFamilyStr) return []*ecs.Attribute{ { Na...
1
// Copyright Amazon.com Inc. or its affiliates. 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. A copy of the // License is located at // // http://aws.amazon.com/apache2.0/ // // or in the "license" file acco...
1
25,841
this seems like more of a Debugf statement
aws-amazon-ecs-agent
go
@@ -972,10 +972,11 @@ void CoreChecks::RecordBarrierArrayValidationInfo(const char *func_name, CMD_BUF bool mode_concurrent = handle_state ? handle_state->createInfo.sharingMode == VK_SHARING_MODE_CONCURRENT : false; if (!mode_concurrent) { const auto typed_handle = BarrierTyp...
1
/* Copyright (c) 2015-2019 The Khronos Group Inc. * Copyright (c) 2015-2019 Valve Corporation * Copyright (c) 2015-2019 LunarG, Inc. * Copyright (C) 2015-2019 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 m...
1
12,054
We're capturing cb_state non-const, but the function is const so, safe enough, but after going to reader/writer locks we're all going to have to key a careful eye on anything in this pattern.
KhronosGroup-Vulkan-ValidationLayers
cpp
@@ -194,6 +194,12 @@ func (c *AwsEndpointDiscoveryTest) TestDiscoveryIdentifiersRequiredRequest(input output = &TestDiscoveryIdentifiersRequiredOutput{} req = c.newRequest(op, input, output) + + // if a custom endpoint is provided for the request, + // we skip endpoint discovery workflow + if req.Config.Endpoint ...
1
// Code generated by private/model/cli/gen-api/main.go. DO NOT EDIT. package awsendpointdiscoverytest import ( "fmt" "net/url" "strings" "time" "github.com/aws/aws-sdk-go/aws" "github.com/aws/aws-sdk-go/aws/awsutil" "github.com/aws/aws-sdk-go/aws/crr" "github.com/aws/aws-sdk-go/aws/request" ) const opDescri...
1
10,154
Probably want to wrap the endpoint discovery work that follows in this `if` statement instead of returning early. This will make it easier to add additional request code generation logic in the future. e.g. if we add any code generation after the endpoint discovery block this check will cause it to be skipped.
aws-aws-sdk-go
go
@@ -80,7 +80,7 @@ describe('debug', () => { it('should print an error on double jsx conversion', () => { let Foo = <div />; let fn = () => render(h(<Foo />), scratch); - expect(fn).to.throw(/createElement/); + expect(fn).to.throw(/JSX twice/); }); it('should add __source to the vnode in debug mode.', ()...
1
import { createElement, render, createRef, Component, Fragment } from 'preact'; import { setupScratch, teardown, serializeHtml } from '../../../test/_util/helpers'; import 'preact/debug'; import * as PropTypes from 'prop-types'; const h = createElement; /** @jsx createElement */ describe('debug', () => { let scra...
1
15,137
This test was giving a false positive because my change caused it to throw a different error that contained `createElement` when it should've been throwing this error. Caught this by looking at the code coverage and noticing that the line under the condition I changed was no longer covered lol.
preactjs-preact
js
@@ -40,3 +40,8 @@ func (i *Initializer) initHostNetworkFlows() error { func (i *Initializer) getTunnelPortLocalIP() net.IP { return nil } + +// registerServiceforOS returns immediately on Linux. +func (i *Initializer) registerServiceforOS() error { + return nil +}
1
// +build linux // Copyright 2020 Antrea 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 ...
1
37,871
I think this is added to wrong file. You wanted to add to cmd/agent/, right?
antrea-io-antrea
go
@@ -348,10 +348,12 @@ public class ExpectedConditions { final String text) { return new ExpectedCondition<Boolean>() { + private String elementText = null; + @Override public Boolean apply(WebDriver driver) { try { -...
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
18,003
Each `ExpectedCondition` implements `java.util.Function` These are expected to be stateless. This condition will leak previous `elementText` on the second usage, which doesn't seem ideal.
SeleniumHQ-selenium
java
@@ -117,6 +117,7 @@ type NetworkConfig struct { CNIVersion string `json:"cniVersion,omitempty"` Name string `json:"name,omitempty"` Type string `json:"type,omitempty"` + DeviceID string `json:"deviceID"` // PCI address of a VF MTU int `json:"m...
1
// Copyright 2019 Antrea 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 ...
1
18,646
Could we consider a more explicit name, like `devicePciAddress`?
antrea-io-antrea
go
@@ -109,10 +109,14 @@ public class WindowsUtils { * quote (\"?) */ // TODO We should be careful, in case Windows has ~1-ified the executable name as well - pattern.append("\"?.*?\\\\"); - pattern.append(executable.getName()); + pattern.append("(\"?.*?\\\\)?"); + String execName = executable...
1
/* * Copyright 2011 Software Freedom Conservancy. * * 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 appli...
1
10,241
Why change this from a foreach? I can't see it gaining anything here and code styles shouldn't change just for the sake of it.
SeleniumHQ-selenium
rb
@@ -610,8 +610,9 @@ class SolrService extends \Apache_Solr_Service $solrconfigXmlUrl = $this->_scheme . '://' . $this->_host . ':' . $this->_port . $this->_path . 'admin/file/?file=solrconfig.xml'; + $response= $this->_sendRawGet($solrconfigXmlUrl); - ...
1
<?php namespace ApacheSolrForTypo3\Solr; /*************************************************************** * Copyright notice * * (c) 2009-2015 Ingo Renner <ingo@typo3.org> * All rights reserved * * This script is part of the TYPO3 project. The TYPO3 project is * free software; you can redistribute it and/o...
1
5,942
Is this supposed to be part of this PR?
TYPO3-Solr-ext-solr
php
@@ -17,6 +17,13 @@ const getHasListItem = (hasListItem, tagName, isListItemRole) => { return hasListItem || (tagName === 'LI' && isListItemRole) || isListItemRole; }; +const getIsHidden = actualNode => { + return ( + window.getComputedStyle(actualNode, null).getPropertyValue('display') === + 'none' + ); +}; + l...
1
const ALLOWED_TAGS = [ 'STYLE', 'META', 'LINK', 'MAP', 'AREA', 'SCRIPT', 'DATALIST', 'TEMPLATE' ]; const getIsListItemRole = (role, tagName) => { return role === 'listitem' || (tagName === 'LI' && !role); }; const getHasListItem = (hasListItem, tagName, isListItemRole) => { return hasListItem || (tagName ==...
1
13,008
DRY, worth extracting this method to axe.utils
dequelabs-axe-core
js
@@ -35,6 +35,7 @@ public interface CapabilityType { String PROXY = "proxy"; String SUPPORTS_WEB_STORAGE = "webStorageEnabled"; String ROTATABLE = "rotatable"; + String APPLICATION_NAME = "applicationName"; // Enable this capability to accept all SSL certs by defaults. String ACCEPT_SSL_CERTS = "acceptSs...
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
13,114
I think there's another spot for this in DefaultCapabilityMatcher
SeleniumHQ-selenium
java
@@ -142,9 +142,14 @@ class KeyConfigParser(QObject): def save(self): """Save the key config file.""" log.destroy.debug("Saving key config to {}".format(self._configfile)) - with qtutils.savefile_open(self._configfile, encoding='utf-8') as f: - data = str(self) - f.wri...
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
17,949
`QtOSError` inherits `OSError`, so I don't think it's needed to list them both here.
qutebrowser-qutebrowser
py
@@ -228,7 +228,6 @@ func (t *Transport) startSubscriber(ctx context.Context, sub subscriptionWithTop } // Ok, ready to start pulling. err := conn.Receive(ctx, func(ctx context.Context, m *pubsub.Message) { - logger.Info("got an event!") msg := &Message{ Attributes: m.Attributes, Data: m.Data,
1
package pubsub import ( "context" "errors" "fmt" "go.uber.org/zap" "strings" "sync" "cloud.google.com/go/pubsub" "github.com/cloudevents/sdk-go/pkg/cloudevents" cecontext "github.com/cloudevents/sdk-go/pkg/cloudevents/context" "github.com/cloudevents/sdk-go/pkg/cloudevents/transport" "github.com/cloudeven...
1
9,452
Instead of patching vendor, let's update the version of sdk-go to a more recent one that doesn't have this line.
google-knative-gcp
go
@@ -185,6 +185,7 @@ func DefaultConfiguration() *Configuration { config.Please.DownloadLocation = "https://get.please.build" config.Please.NumOldVersions = 10 config.Parse.BuiltinPleasings = true + config.Parse.BuildFileName = []string{"BUILD"} config.Build.Arch = cli.NewArch(runtime.GOOS, runtime.GOARCH) con...
1
// Utilities for reading the Please config files. package core import ( "crypto/sha1" "encoding/gob" "fmt" "io" "os" "path" "reflect" "runtime" "sort" "strconv" "strings" "sync" "time" "github.com/google/shlex" "github.com/jessevdk/go-flags" "gopkg.in/gcfg.v1" "cli" ) // OsArch is the os/arch pair...
1
8,527
Don't think this should be here. The default is set somewhere else.
thought-machine-please
go
@@ -1229,7 +1229,13 @@ class CloudTaurusTest(BaseCloudTest): def stop_test(self): if self.master: self.log.info("Ending cloud test...") - self.master.stop() + if not self._last_status: + self.get_master_status() + + if self._last_status["progres...
1
""" Module for reporting into http://www.blazemeter.com/ service Copyright 2015 BlazeMeter 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 Unles...
1
14,809
Not really important in this PR, but does BlazeMeter describe "progress" values anywhere? It might be nice to have a set of constants like `PROGRESS_DOWNLOADING_IMAGE`, `PROGRESS_BOOTING`, `PROGRESS_RUNNING_TEST`, etc in our BZA client.
Blazemeter-taurus
py
@@ -124,6 +124,14 @@ public interface ContentFile<F> { */ List<Integer> equalityFieldIds(); + /** + * Returns the sort order id of this file, which describes how the file is ordered. + * This information will be useful for merging data and equality delete files more efficiently + * when they share the s...
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
30,850
nit: `<p>` after the line
apache-iceberg
java
@@ -228,6 +228,7 @@ setup( ("libArm64/%s"%version, glob("libArm64/*.dll") + glob("libArm64/*.exe")), ("waves", glob("waves/*.wav")), ("images", glob("images/*.ico")), + ("fonts", glob("fonts/*.ttf")), ("louis/tables",glob("louis/tables/*")), ("COMRegistrationFixes", glob("COMRegistrationFixes/*.reg")), ...
1
# -*- coding: UTF-8 -*- #setup.py #A part of NonVisual Desktop Access (NVDA) #Copyright (C) 2006-2018 NV Access Limited, Peter Vágner, Joseph Lee #This file is covered by the GNU General Public License. #See the file COPYING for more details. import os import copy import gettext gettext.install("nvda") from...
1
28,270
Should we include the files with otf extension here, too? If not, I wonder why we do allow them in the source but we don't include them as per the setup
nvaccess-nvda
py
@@ -33,9 +33,6 @@ func (uq *uniQueue) enque(blk *peerBlock) { } func (uq *uniQueue) dequeAll() []*peerBlock { - if len(uq.blocks) == 0 { - return nil - } blks := uq.blocks uq.blocks = []*peerBlock{} uq.hashes = map[hash.Hash256]bool{}
1
// Copyright (c) 2021 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
24,711
i think it's OK to leave this?
iotexproject-iotex-core
go
@@ -30,7 +30,7 @@ import org.apache.flink.table.types.logical.SymbolType; import org.apache.flink.table.types.logical.YearMonthIntervalType; import org.apache.flink.table.types.logical.ZonedTimestampType; -abstract class FlinkTypeVisitor<T> implements LogicalTypeVisitor<T> { +public abstract class FlinkTypeVisitor<...
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
22,024
Does this need to be public? The only reference to `FlinkTypeVisitor` that I see in this PR is here, so I'm not sure why this is needed.
apache-iceberg
java
@@ -3,11 +3,11 @@ WELCOME_DIALOG_TEXT = ( "down the NVDA key while pressing other keys. By default, the numpad Insert and main Insert keys " "may both be used as the NVDA key. You can also configure NVDA to use the Caps Lock as the NVDA " "key. Press NVDA plus n at any time to activate the NVDA menu. From this me...
1
WELCOME_DIALOG_TEXT = ( "Welcome to NVDA dialog Welcome to NVDA! Most commands for controlling NVDA require you to hold " "down the NVDA key while pressing other keys. By default, the numpad Insert and main Insert keys " "may both be used as the NVDA key. You can also configure NVDA to use the Caps Lock as the ...
1
27,746
No line at end of file warning
nvaccess-nvda
py
@@ -24,6 +24,8 @@ namespace Nethermind.Blockchain.Processing { public class OneTimeChainProcessor : IBlockchainProcessor { + public CompositeBlockTracerFactory BlockTracerFactory { get; } = new(); + private readonly IBlockchainProcessor _processor; private readonly IReadOnlyDbProvide...
1
// Copyright (c) 2021 Demerzel Solutions Limited // This file is part of the Nethermind library. // // The Nethermind library is free software: you can redistribute it and/or modify // it under the terms of the GNU Lesser General Public License as published by // the Free Software Foundation, either version 3 of ...
1
25,270
This looks unused, shouldn't it point to inner processor in any way?
NethermindEth-nethermind
.cs
@@ -6995,11 +6995,6 @@ NABoolean RelRoot::isUpdatableBasic(NABoolean isView, // QSTUFF { - // if child is a FirstN node, skip it. - if ((child(0)->castToRelExpr()->getOperatorType() == REL_FIRST_N) && - (child(0)->child(0))) - scan = (Scan *)child(0)->child(0)->castToRelExpr(); - else scan ...
1
/********************************************************************** // @@@ START COPYRIGHT @@@ // // 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. ...
1
18,942
There may be a few isolated cases where the FirstN node is added during preCodeGen. Please see GenPreCode.cpp RelRoot::preCodeGen(). The example given there about Order by where sort is added in optimizer, or a FirstN where the N value is to be specified with a param seem to be cases where we would add the FirstN later...
apache-trafodion
cpp
@@ -213,4 +213,14 @@ public class GoSurfaceNamer extends SurfaceNamer { public String getCreateStubFunctionName(Interface service) { return getGrpcClientTypeName(service).replace(".", ".New"); } + + @Override + public String getStaticLangStreamingReturnTypeName(Method method, MethodConfig methodConfig) { +...
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
18,249
I think you should compose the %sClient part using the Name class, and then do the remaining composition with plain concatenation. Side question: why does the return type name look like it is a client type name?
googleapis-gapic-generator
java
@@ -63,6 +63,8 @@ storiesOf( 'PageSpeed Insights Module/Components', module ) <DashboardPageSpeedWidget { ...widgetComponentProps } /> </WithTestRegistry> ); + }, { + padding: 0, } ) .add( 'Dashboard widget (loading)', () => { freezeFetch( /^\/google-site-kit\/v1\/modules\/pagespeed-insights\/data\/...
1
/** * PageSpeed Insights Module Component Stories. * * Site Kit by Google, Copyright 2021 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/li...
1
38,278
All stories in this file also need the default padding.
google-site-kit-wp
js
@@ -26,13 +26,14 @@ using Microsoft.AspNetCore.TestHost; using Microsoft.Extensions.DependencyInjection; using Microsoft.Extensions.Hosting; using OpenTelemetry.Metrics; +using OpenTelemetry.Tests; using Xunit; namespace OpenTelemetry.Exporter.Prometheus.Tests { public sealed class PrometheusExporterMiddle...
1
// <copyright file="PrometheusExporterMiddlewareTests.cs" company="OpenTelemetry Authors"> // Copyright The OpenTelemetry 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 // // ...
1
22,295
Curious - what would be the actual value?
open-telemetry-opentelemetry-dotnet
.cs
@@ -168,7 +168,8 @@ def main(): # checkpoints as meta data cfg.checkpoint_config.meta = dict( mmdet_version=__version__ + get_git_hash()[:7], - CLASSES=datasets[0].CLASSES) + CLASSES=datasets[0].CLASSES, + PALETTE=datasets[0].PALETTE) # add an attribu...
1
# Copyright (c) OpenMMLab. All rights reserved. import argparse import copy import os import os.path as osp import time import warnings import mmcv import torch from mmcv import Config, DictAction from mmcv.runner import get_dist_info, init_dist from mmcv.utils import get_git_hash from mmdet import __version__ from m...
1
26,763
Is it necessary to record the palette in the checkpoint? Any reason?
open-mmlab-mmdetection
py
@@ -3,9 +3,10 @@ import listenbrainz.webserver import pika import time import threading +import socketio from flask import current_app - +from listenbrainz.webserver.views.api_tools import LISTEN_TYPE_PLAYING_NOW, LISTEN_TYPE_IMPORT class FollowDispatcher(threading.Thread):
1
import json import listenbrainz.webserver import pika import time import threading from flask import current_app class FollowDispatcher(threading.Thread): def __init__(self, app): threading.Thread.__init__(self) self.app = app def callback_listen(self, channel, method, properties, body): ...
1
15,162
Not sure how to best do this without creating a new connection to the server everytime. Do this in another thread?
metabrainz-listenbrainz-server
py
@@ -167,6 +167,13 @@ describe Ncr::WorkOrder do user = create(:user, client_slug: 'ncr') expect(wo.slug_matches?(user)).to eq(true) end + + it "identifies eligible observers" do + wo = create(:ba80_ncr_work_order) + user = create(:user, client_slug: 'ncr') + expect(wo.proposal.eligi...
1
describe Ncr::WorkOrder do include ProposalSpecHelper describe '#relevant_fields' do it "shows BA61 fields" do wo = Ncr::WorkOrder.new expect(wo.relevant_fields.sort).to eq([ :amount, :building_number, :cl_number, # No :code :description, :direct_pay,...
1
15,332
should we have a similar test for gsa18f procurements?
18F-C2
rb
@@ -113,9 +113,9 @@ func TestProtocol_HandleTransfer(t *testing.T) { GasLimit: testutil.TestGasLimit, }) - sender, err := accountutil.AccountState(sm, v.caller.String()) + sender, err := accountutil.AccountState(sm, v.caller) require.NoError(err) - recipient, err := accountutil.AccountState(sm, v.reci...
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
23,689
change `v.recipient` to address.Address, so can use `AccountState(v,recipient)`
iotexproject-iotex-core
go
@@ -0,0 +1,6 @@ +class NcrDispatcher < LinearDispatcher + + def requires_approval_notice? approval + approval.cart_approvals.approvable.order('position ASC').last == approval + end +end
1
1
12,371
Open to doing away with this altogether and maybe injecting this logic somehow into `requires_approval_notice?` in LinearDispatcher.
18F-C2
rb
@@ -26,6 +26,12 @@ namespace Nethermind.JsonRpc [ConfigItem(Description = "Host for JSON RPC calls. Ensure the firewall is configured when enabling JSON RPC. If it does not work with 117.0.0.1 try something like 10.0.0.4 or 192.168.0.1", DefaultValue = "\"127.0.0.1\"")] string Host { get; set; } + ...
1
// Copyright (c) 2018 Demerzel Solutions Limited // This file is part of the Nethermind library. // // The Nethermind library is free software: you can redistribute it and/or modify // it under the terms of the GNU Lesser General Public License as published by // the Free Software Foundation, either version 3 of...
1
24,195
remove this and always enable tracer, just set the default timeout to something higher (20 seconds)
NethermindEth-nethermind
.cs
@@ -39,6 +39,7 @@ public class ScriptDTO { private final Boolean free; private final Boolean requiresPatch; private final String script; + private final URI icon; private ScriptDTO(Builder builder) { this.scriptName = builder.scriptName;
1
/* * Copyright (C) 2015-2017 PÂRIS Quentin * * This program 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 * (at your option) any later version. * * This program is...
1
11,455
Can we give this field a more descriptive name? When I use a variable named `icon` I normally expect an `Image` object.
PhoenicisOrg-phoenicis
java
@@ -333,6 +333,13 @@ var opts struct { Targets []core.BuildLabel `positional-arg-name:"targets" description:"Targets to query" required:"true"` } `positional-args:"true"` } `command:"roots" description:"Show build labels with no dependents in the given list, from the list."` + Filter struct { + IncludeLa...
1
package main import ( "fmt" "net/http" _ "net/http/pprof" "os" "path" "runtime" "runtime/pprof" "strings" "syscall" "time" "github.com/jessevdk/go-flags" "gopkg.in/op/go-logging.v1" "build" "cache" "clean" "cli" "core" "export" "follow" "fs" "gc" "hashes" "help" "metrics" "output" "parse" ...
1
8,307
can't these just use the global `include` and `exclude` flags?
thought-machine-please
go
@@ -28,7 +28,7 @@ def bbox2delta(proposals, gt, means=[0, 0, 0, 0], stds=[1, 1, 1, 1]): stds = deltas.new_tensor(stds).unsqueeze(0) deltas = deltas.sub_(means).div_(stds) - return deltas + return deltas.cuda() def delta2bbox(rois,
1
import mmcv import numpy as np import torch def bbox2delta(proposals, gt, means=[0, 0, 0, 0], stds=[1, 1, 1, 1]): assert proposals.size() == gt.size() proposals = proposals.float() gt = gt.float() px = (proposals[..., 0] + proposals[..., 2]) * 0.5 py = (proposals[..., 1] + proposals[..., 3]) * 0....
1
17,268
Is this still necessary?
open-mmlab-mmdetection
py
@@ -52,7 +52,7 @@ namespace Examples.Console .AddPrometheusExporter(opt => { opt.StartHttpListener = true; - opt.HttpListenerPrefixes = new string[] { $"http://*:{port}/" }; + opt.HttpListenerPrefixes = new string[] { $"http://...
1
// <copyright file="TestPrometheusExporter.cs" company="OpenTelemetry Authors"> // Copyright The OpenTelemetry 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...
1
21,736
Interesting! Happen to catch an exception message or anything I can look into?
open-telemetry-opentelemetry-dotnet
.cs
@@ -103,15 +103,10 @@ Promise.prototype.error = function (err) { * @api public */ -Promise.prototype.resolve = function (err, val) { - if (err) return this.error(err); - return this.fulfill(val); -} - /** * Adds a single function as a listener to both err and complete. * - * It will be executed with tradit...
1
/*! * Module dependencies */ var MPromise = require('mpromise'); /** * Promise constructor. * * Promises are returned from executed queries. Example: * * var query = Candy.find({ bar: true }); * var promise = query.exec(); * * @param {Function} fn a function which will be called when the promise is...
1
12,181
did this get moved to mpromise? I don't recall if it's in that lib or not.
Automattic-mongoose
js
@@ -81,14 +81,16 @@ type ProviderModeConfig struct { type ConsumerConfig struct { PublicKey string `json:"PublicKey"` // IP is needed when provider is behind NAT. In such case provider parses this IP and tries to ping consumer. - IP string `json:"IP,omitempty"` + IP string `json:"IP,omitempty"` + Ports []int `...
1
/* * Copyright (C) 2018 The "MysteriumNetwork/node" Authors. * * This program 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 3 of the License, or * (at your option) any later version. * ...
1
15,782
json objects should be `camelCase`
mysteriumnetwork-node
go
@@ -0,0 +1,11 @@ +package types + +// SectorSize is the amount of bytes in a sector. This amount will be slightly +// greater than the number of user bytes which can be written to a sector due to +// bit-padding. +type SectorSize uint64 + +const ( + OneKiBSectorSize = SectorSize(iota) + TwoHundredFiftySixMiBSectorSize ...
1
1
18,530
QuarterGiBSectorSize? SectorSize265MiB? Spelling out 256 seems overly verbose.
filecoin-project-venus
go
@@ -23,10 +23,11 @@ using System.Linq; using Microsoft.Extensions.Logging; using OpenTelemetry.Exporter; using OpenTelemetry.Logs; +using OpenTelemetry.Tests; using OpenTelemetry.Trace; using Xunit; -namespace OpenTelemetry.Tests.Logs +namespace OpenTelemetry.Logs.Tests { public sealed class LogRecordTest ...
1
// <copyright file="LogRecordTest.cs" company="OpenTelemetry Authors"> // Copyright The OpenTelemetry 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.o...
1
20,832
Maybe with this change we can remove `using OpenTelemetry.Logs`.
open-telemetry-opentelemetry-dotnet
.cs
@@ -164,9 +164,10 @@ func (h *Handler) handleAddProject(w http.ResponseWriter, r *http.Request) { } var ( - id = r.FormValue("ID") - description = r.FormValue("Description") - sharedSSOName = r.FormValue("SharedSSO") + id = r.FormValue("ID") + description = r.FormValue("...
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
19,103
Fix this name too.
pipe-cd-pipe
go
@@ -2018,7 +2018,7 @@ class BibFormatObject(object): # If record is given as parameter self.xml_record = xml_record self.record = create_record(xml_record)[0] - recID = record_get_field_value(self.record, "001") or None + recID = int(record_get_field_value(se...
1
# -*- coding: utf-8 -*- ## ## This file is part of Invenio. ## Copyright (C) 2006, 2007, 2008, 2009, 2010, 2011, 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 ve...
1
14,541
why this is an issue?
inveniosoftware-invenio
py
@@ -110,9 +110,13 @@ abstract class Type ?string $namespace, array $aliased_classes, ?string $this_class, - bool $allow_self = false + bool $allow_self = false, + bool $was_static = false ) : string { if ($allow_self && $value === $this_class) { + ...
1
<?php namespace Psalm; use function array_merge; use function array_pop; use function array_shift; use function array_values; use function explode; use function implode; use function preg_quote; use function preg_replace; use Psalm\Internal\Type\Comparator\AtomicTypeComparator; use Psalm\Internal\Type\TypeCombination;...
1
9,369
The condition should be inverse?
vimeo-psalm
php
@@ -33,12 +33,16 @@ package azkaban; public class Constants { // Azkaban Flow Versions - public static final String AZKABAN_FLOW_VERSION_2_0 = "2.0"; + public static final String AZKABAN_FLOW_VERSION = "Azkaban-Flow-Version"; + public static final Double VERSION_2_0 = 2.0; // Flow 2.0 file suffix publi...
1
/* * Copyright 2017 LinkedIn Corp. * * 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
15,150
this seems to be a property key name, so should it be a inside configurationkey.java?
azkaban-azkaban
java
@@ -105,7 +105,7 @@ func (v *VolumeDestroy) Execute() ([]byte, error) { return nil, err } // execute command here - return exec.Command(bin.ZFS, v.Command).CombinedOutput() + return exec.Command(bin.BASH, "-c", v.Command).CombinedOutput() } // Build returns the VolumeDestroy object generated by builder
1
/* Copyright 2019 The OpenEBS 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, sof...
1
16,751
G204: Subprocess launching should be audited (from `gosec`)
openebs-maya
go
@@ -284,6 +284,10 @@ class Task(object): # TODO(erikbern): we should think about a language-agnostic mechanism return self.__class__.__module__ + @property + def run_on_main_process(self): + return False + _visible_in_registry = True # TODO: Consider using in luigi.util as well ...
1
# -*- coding: utf-8 -*- # # Copyright 2012-2015 Spotify AB # # 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...
1
17,872
Please add docs here. And also warn users that this mode should be avoided whenever possible, because any blocking IO will make the keep-alive-thread not run.
spotify-luigi
py
@@ -57,3 +57,18 @@ export function isValidDimensions( dimensions ) { return dimension.hasOwnProperty( 'name' ) && typeof dimension.name === 'string'; } ); } + +/** + * Verifies provided dimensionFilters to make sure they match allowed values found in dimensions. + * + * @since n.e.x.t + * + * @param {Object} dime...
1
/** * Reporting API validation utilities. * * Site Kit by Google, Copyright 2020 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/LI...
1
34,545
We shouldn't require dimension values to be a string. They just need to be scalar values (probably we could check whether it's either a string or a number). Something more important to cover in the validation here though is to ensure that a map of `dimensionName => dimensionValue` is passed. The keys here actually need...
google-site-kit-wp
js
@@ -31,7 +31,8 @@ import ( ) var ( - _ yarpc.Router = (*MapRouter)(nil) + _ yarpc.Router = (*MapRouter)(nil) + _ yarpc.UnaryTransportHandler = &unaryTransportHandler{} ) type serviceProcedure struct {
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
17,721
let's do a pointer cast of nil, similar to the `MapRouter` above
yarpc-yarpc-go
go
@@ -280,6 +280,8 @@ abstract class Abstract_Builder implements Builder { 'default' => '{ "mobile": "0", "tablet": "0", "desktop": "0" }', ] ); + + do_action( 'neve_add_settings_to_hfg_rows', SettingsManager::get_instance(), $row_setting_id, $row_id ); } SettingsManager::get_instance()...
1
<?php /** * Abstract Builder class for Header Footer Grid. * * Name: Header Footer Grid * Author: Bogdan Preda <bogdan.preda@themeisle.com> * * @version 1.0.0 * @package HFG */ namespace HFG\Core\Builder; use HFG\Core\Components\Abstract_Component; use HFG\Core\Interfaces\Builder; use HFG\Core\Interfaces\...
1
19,233
action should use a prefix of `hfg` rather than `neve` as we plan to bootstrap this as a standalone library. Moreover, previously filter/actions used in this library was using the same pattern.
Codeinwp-neve
php
@@ -158,6 +158,8 @@ namespace Microsoft.AspNetCore.Server.Kestrel.Https.Internal if ((_options.HttpProtocols & HttpProtocols.Http2) != 0) { sslOptions.ApplicationProtocols.Add(SslApplicationProtocol.Http2); + // https://tools.ietf.org/html/rfc754...
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.IO; using System.Net.Security; using System.Security.Authentication; using System.Security....
1
15,878
I'm halfway tempted to disable this for all https connections. Do you know of any clients that actually renegotiate for any reason?
aspnet-KestrelHttpServer
.cs
@@ -102,7 +102,7 @@ class presence_of_all_elements_located(object): def __call__(self, driver): return _find_elements(driver, self.locator) -class visibility_of_all_elements_located(object): +class visibility_of_any_elements_located(object): """ An expectation for checking that there is at ...
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 may not...
1
13,212
shouldn't **call** return a boolean?
SeleniumHQ-selenium
js
@@ -25,9 +25,8 @@ import ( ) func ExampleOpenCollection() { - // This example is used in https://gocloud.dev/howto/docstore#dynamodb-ctor. - - // import _ "gocloud.dev/docstore/awsdynamodb" + // PRAGMA(gocloud.dev): Package this example for gocloud.dev. + // PRAGMA(gocloud.dev): Add a blank import: _ "gocloud.dev/d...
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
19,587
I don't think you need the blank import here. This one uses awsdynamodb directly.
google-go-cloud
go
@@ -121,11 +121,11 @@ public abstract class DeleteFilter<T> { return applyEqDeletes(applyPosDeletes(records)); } - private List<Predicate<T>> applyEqDeletes() { - List<Predicate<T>> isInDeleteSets = Lists.newArrayList(); + private Predicate<T> buildEqDeletePredicate() { if (eqDeletes.isEmpty()) { - ...
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,480
I think this should be initialized to `null` instead of a predicate. There is no need to run an extra predicate (with an extra method dispatch for each row in a data file. That's a tight loop so we should do more work here to avoid it. Instead of using `isDeleted.or`, this should test whether `isDeleted` is `null` and ...
apache-iceberg
java
@@ -246,6 +246,15 @@ def __build_clangsa_config_handler(args, context): config_handler.compiler_sysroot = context.compiler_sysroot config_handler.system_includes = context.extra_system_includes config_handler.includes = context.extra_includes + + if 'ctu_phases' in args: + config_handler.ctu_di...
1
# ------------------------------------------------------------------------- # The CodeChecker Infrastructure # This file is distributed under the University of Illinois Open Source # License. See LICENSE.TXT for details. # -------------------------------------------------------------------------...
1
7,188
What is this and the next entry in config_handler used for?
Ericsson-codechecker
c
@@ -244,3 +244,9 @@ func NewWithDefault(keyFilePath string, certFilePath string) (m upstreamca.Upstr return m, err } + +func NewEmpty () (m upstreamca.UpstreamCa) { + return &memoryPlugin{ + mtx:&sync.RWMutex{}, + } +}
1
package pkg import ( "crypto/ecdsa" "crypto/rand" "crypto/x509" "encoding/json" "encoding/pem" "errors" "fmt" "io/ioutil" "math/big" "net/url" "sync" "sync/atomic" "time" "github.com/hashicorp/hcl" "github.com/spiffe/go-spiffe/uri" "github.com/spiffe/spire/pkg/common/plugin" common "github.com/spiff...
1
8,525
will your editor integrate `gofmt`, `goimports`, etc...?
spiffe-spire
go
@@ -78,7 +78,12 @@ public class ProductPhotosFragment extends BaseFragment implements ImagesAdapter public void onViewCreated(@NonNull View view, @Nullable Bundle savedInstanceState) { super.onViewCreated(view, savedInstanceState); Intent intent = getActivity().getIntent(); - final State s...
1
package openfoodfacts.github.scrachx.openfood.fragments; import android.content.Context; import android.content.Intent; import android.content.SharedPreferences; import android.net.Uri; import android.os.Bundle; import android.provider.MediaStore; import android.provider.Settings; import android.support.annotation.Non...
1
66,339
looks like the code is not properly formatted. for example here are some missing spaces in **if** command. please take care and reformat the code using default android formatting.
openfoodfacts-openfoodfacts-androidapp
java
@@ -218,6 +218,15 @@ def __add_filtering_arguments(parser, defaults=None, diff_mode=False): default=init_default('severity'), help="Filter results by severities.") + f_group.add_argument('--bug-path-length', + type=str, + ...
1
# ------------------------------------------------------------------------- # The CodeChecker Infrastructure # This file is distributed under the University of Illinois Open Source # License. See LICENSE.TXT for details. # -------------------------------------------------------------------------...
1
10,601
Please add some valid examples to help message like `"4:10"`, `"4:"`, `":10"`
Ericsson-codechecker
c
@@ -490,7 +490,10 @@ EOS # end def its(attribute, &block) RSpec.deprecate("Use of rspec-core's `its` method", :replacement => 'the rspec-its gem') - describe(attribute) do + description = attribute + description = description.to_s if Symbol === description + + ...
1
module RSpec module Core module MemoizedHelpers # @note `subject` was contributed by Joe Ferris to support the one-liner # syntax embraced by shoulda matchers: # # describe Widget do # it { is_expected.to validate_presence_of(:name) } # # or # ...
1
12,189
Is it only Symbols we're worried about converting? Is it not safe to just call `to_s` anyway?
rspec-rspec-core
rb
@@ -15,9 +15,6 @@ import ( "github.com/stretchr/testify/require" ) -// BlockTimeTest is the block time used by workers during testing -const BlockTimeTest = time.Second - // MineDelayTest is the mining delay used by schedulers during testing const MineDelayTest = time.Millisecond * 500
1
package mining import ( "context" "sync" "time" "gx/ipfs/QmcmpX42gtDv1fz24kau4wjS9hfwWj5VexWBKgGnWzsyag/go-ipfs-blockstore" "github.com/filecoin-project/go-filecoin/address" "github.com/filecoin-project/go-filecoin/consensus" "github.com/filecoin-project/go-filecoin/state" "github.com/stretchr/testify/mock"...
1
14,705
Note for those who come across this later: It was moved to `testhelpers.mining.go` so that `testhelpers.NewDaemon` and the `mining/worker_test.go` can share it.
filecoin-project-venus
go
@@ -12,7 +12,7 @@ class Practice end def incomplete_trails - trails.select(&:incomplete?) + trails.select(&:incomplete?).partition(&:in_progress?).flatten end private
1
class Practice def initialize(user) @user = user end def has_completed_trails? completed_trails.any? end def just_finished_trails trails.select(&:just_finished?) end def incomplete_trails trails.select(&:incomplete?) end private attr_reader :user def trails Trail. m...
1
14,347
What about `sort_by(&:in_progress?)`? Maybe with a `.reverse` thrown in?
thoughtbot-upcase
rb
@@ -205,7 +205,6 @@ const ( FlagTLSKeyPath = "tls_key_path" FlagTLSCaPath = "tls_ca_path" FlagTLSEnableHostVerification = "tls_enable_host_verification" - FlagGRPC = "grpc" ) var flagsForExecution = []cli.Flag{
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,215
Flag is removed because it is only gRPC now.
temporalio-temporal
go
@@ -38,6 +38,17 @@ class Role(base.Base): .. option:: molecule init role --role-name foo Initialize a new role. + + .. program:: molecule init role --role-name foo --template path + + .. option:: molecule init role --role-name foo --template path + + Initialize a new role using a local *coo...
1
# Copyright (c) 2015-2018 Cisco Systems, 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
7,910
Might be better to rephrase to: Please refer to the ``init scenario`` command in order to generate a custom ``molecule`` scenario. Since you aren't customizing the default scenario since it already exists, right?
ansible-community-molecule
py
@@ -640,9 +640,17 @@ class StdlibChecker(DeprecatedMixin, BaseChecker): encoding_arg = utils.get_argument_from_call( node, position=0, keyword="encoding" ) + elif open_module == "pathlib" and node.func.attrname == "write_text": + ...
1
# Copyright (c) 2013-2014 LOGILAB S.A. (Paris, FRANCE) <contact@logilab.fr> # Copyright (c) 2013-2014 Google, Inc. # Copyright (c) 2014-2020 Claudiu Popa <pcmanticore@gmail.com> # Copyright (c) 2014 Cosmin Poieana <cmin@ropython.org> # Copyright (c) 2014 Vlad Temian <vladtemian@gmail.com> # Copyright (c) 2014 Arun Pers...
1
20,106
Shall we merge these `if` for `path lib` and then do the `attrname` one. I'm trying to count `if`-calls and its getting late but I think we can reduce the number checks needed to get into L648 from 3 to 2 if you understand what I mean
PyCQA-pylint
py
@@ -9,6 +9,7 @@ import ( "errors" "sync" + "github.com/ethersphere/bee/pkg/recovery" "github.com/ethersphere/bee/pkg/storage" "github.com/ethersphere/bee/pkg/swarm" "github.com/ethersphere/bee/pkg/tags"
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 mock import ( "context" "errors" "sync" "github.com/ethersphere/bee/pkg/storage" "github.com/ethersphere/bee/pkg/swarm" "github.com/ethersphe...
1
11,678
why depend on recovery???
ethersphere-bee
go
@@ -388,7 +388,7 @@ func initializeDynamicConfig( // the done channel is used by dynamic config to stop refreshing // and CLI does not need that, so just close the done channel - doneChan := make(chan struct{}) + doneChan := make(chan interface{}) close(doneChan) dynamicConfigClient, err := dynamicconfig.NewF...
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
11,475
the done channel only aims to be closed, so `chan struct{}` is better then `chan interface{}`
temporalio-temporal
go
@@ -196,7 +196,7 @@ func NewGasPriceOracle(cfg *Config) (*GasPriceOracle, error) { address := cfg.gasPriceOracleAddress contract, err := bindings.NewGasPriceOracle(address, l2Client) if err != nil { - return nil, err + return nil, wrapErr(err, "error creating contract binding") } // Fetch the current gas ...
1
package oracle import ( "context" "errors" "fmt" "math/big" "time" "github.com/ethereum-optimism/optimism/go/gas-oracle/bindings" "github.com/ethereum-optimism/optimism/go/gas-oracle/gasprices" "github.com/ethereum/go-ethereum/accounts/abi/bind" "github.com/ethereum/go-ethereum/crypto" "github.com/ethereum...
1
21,269
Do you mean to have gas_oracle changes in this PR?
ethereum-optimism-optimism
go
@@ -1,6 +1,5 @@ -<%= render Blacklight::System::ModalComponent.new do |component| %> - <% component.title { t('blacklight.email.form.title') } %> - - <%= render partial: '/shared/flash_msg' %> - <span data-blacklight-modal="close"></span> -<% end %> +<turbo-stream action="append" target="main-flashes"> + <template>...
1
<%= render Blacklight::System::ModalComponent.new do |component| %> <% component.title { t('blacklight.email.form.title') } %> <%= render partial: '/shared/flash_msg' %> <span data-blacklight-modal="close"></span> <% end %>
1
8,954
Is this effectively requiring browsers support javascript?
projectblacklight-blacklight
rb
@@ -61,10 +61,11 @@ public class FingerprintAuthDialogFragment extends DialogFragment { @Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); + Boolean isDarkTheme = SalesforceSDKManager.getInstance().isDarkTheme(getActivity()); // Do not cr...
1
/* * Copyright (c) 2016-present, 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 noti...
1
17,594
Lowercase `boolean` - use the primitive type.
forcedotcom-SalesforceMobileSDK-Android
java
@@ -174,7 +174,12 @@ namespace Microsoft.DotNet.Build.Tasks.Feed } else { - Log.LogError($"Item '{item}' already exists in {relativeBlobPath}."); + bool blobExists = await feed.CheckIfBlobExists(relativeBlobPath); + + ...
1
// Licensed to the .NET Foundation under one or more agreements. // The .NET Foundation licenses this file to you under the MIT license. // See the LICENSE file in the project root for more information. using Microsoft.Build.Framework; using Microsoft.DotNet.Build.CloudTestTasks; using Microsoft.WindowsAzure.Storage;...
1
14,040
This isn't the correct logic. if allowOverride == true and !blobExists then upload. Just don't do the exist check if allowOverride is set to true.
dotnet-buildtools
.cs
@@ -480,12 +480,15 @@ static void read_surface_net_wm_state(struct wlr_xwm *xwm, xsurface->fullscreen = 0; xcb_atom_t *atom = xcb_get_property_value(reply); for (uint32_t i = 0; i < reply->value_len; i++) { - if (atom[i] == xwm->atoms[_NET_WM_STATE_FULLSCREEN]) + if (atom[i] == xwm->atoms[_NET_WM_STATE_FULLSCRE...
1
#ifndef _POSIX_C_SOURCE #define _POSIX_C_SOURCE 200809L #endif #include <stdlib.h> #include <unistd.h> #include <xcb/composite.h> #include <xcb/xfixes.h> #include <xcb/xcb_image.h> #include <xcb/render.h> #include <wlr/config.h> #include "wlr/util/log.h" #include "wlr/util/edges.h" #include "wlr/types/wlr_surface.h" #i...
1
9,677
Can you replace these by `else if` please?
swaywm-wlroots
c
@@ -0,0 +1,12 @@ +/** + * Changes the currently selected date range. + * + * Currently only identifiable by the option values. + * + * @param {string} fromRange The currently selected date range. + * @param {string} toRange The new date range to select. + */ +export async function switchDateRange( fromRange, toRange ) ...
1
1
25,040
Would be nice if the field had a unique class name that could be used to target it, instead of `fromRange` But doesn't seem to be a common thing in the code base.
google-site-kit-wp
js
@@ -30,7 +30,10 @@ var tableGrid = tableUtils.toGrid(node); // Look for all the bad headers var out = headers.reduce(function (res, header) { - if (header.id && reffedHeaders.indexOf(header.id) !== -1) { + if ( + header.getAttribute('id') && + reffedHeaders.includes(header.getAttribute('id')) + ) { return (!re...
1
var tableUtils = axe.commons.table; var cells = tableUtils.getAllCells(node); var checkResult = this; // Get a list of all headers reffed to in this rule var reffedHeaders = []; cells.forEach(function (cell) { var headers = cell.getAttribute('headers'); if (headers) { reffedHeaders = reffedHeaders.concat(headers.s...
1
11,198
Does this code fit on one line under 80 characters? It would be more consistent with our existing style.
dequelabs-axe-core
js
@@ -61,8 +61,13 @@ func ParseArtifactListFromMultipleYamls(multipleYamls MultiYamlFetcher) (artifac // installed func RegisteredArtifactsFor070() (list ArtifactList) { + //Note: CRDs have to be installed first. Keep this at top of the list. + list.Items = append(list.Items, OpenEBSCRDArtifactsFor070().Items...) + ...
1
/* Copyright 2018 The OpenEBS 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, soft...
1
9,536
Not a requirement here. But i see a change in naming convention. We can rename the function to `CstorSparsePoolArtifactsFor070`.
openebs-maya
go
@@ -0,0 +1,9 @@ +// +build pico + +package main + +import "machine" + +var ( + interruptPin = machine.GP10 +)
1
1
12,926
Why do you configure the UART like this? It's already configured by default.
tinygo-org-tinygo
go
@@ -39,7 +39,8 @@ #include "opae/access.h" #include "opae/utils.h" #include "opae/manage.h" -#include "opae/manage.h" +#include "opae/enum.h" +#include "opae/properties.h" #include "bitstream_int.h" #include "common_int.h" #include "intel-fpga.h"
1
// Copyright(c) 2017, Intel Corporation // // Redistribution and use 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 list of conditions and the ...
1
15,535
Wow. Good catch. "This `#include` was brought to you by the department of redundancy department." ;)
OPAE-opae-sdk
c
@@ -20,10 +20,11 @@ import ( "context" "time" + "github.com/go-logr/logr" "golang.org/x/crypto/acme" - "k8s.io/klog" "github.com/jetstack/cert-manager/pkg/acme/client" + logf "github.com/jetstack/cert-manager/pkg/logs" ) const (
1
/* Copyright 2019 The Jetstack cert-manager contributors. 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...
1
22,862
Well it's actually calling `AuthorizeOrder` and this seems like a DebugLevel message to me, maybe it should be dropped entirely.
jetstack-cert-manager
go
@@ -917,6 +917,7 @@ void *cuda_resize_scratch_space(std::int64_t bytes, bool force_shrink) { void cuda_prefetch_pointer(const Cuda &space, const void *ptr, size_t bytes, bool to_device) { + if ((ptr == nullptr) || (bytes == 0)) return; cudaPointerAttributes attr; cudaPointerGetAttr...
1
/* //@HEADER // ************************************************************************ // // Kokkos v. 3.0 // Copyright (2020) National Technology & Engineering // Solutions of Sandia, LLC (NTESS). // // Under the terms of Contract DE-NA0003525 with NTESS, // the U.S. Govern...
1
22,726
Should this be using the `CUDA_SAFE_CALL` macro here?
kokkos-kokkos
cpp
@@ -298,8 +298,8 @@ namespace Xunit.ConsoleClient { lock (consoleLock) { - Console.ForegroundColor = ConsoleColor.Red; - Console.WriteLine("ERROR: {0} has no tests to run", Path.GetFileName...
1
using System; using System.Collections.Concurrent; using System.Diagnostics; using System.IO; using System.Linq; using System.Reflection; using System.Threading.Tasks; using System.Xml.Linq; namespace Xunit.ConsoleClient { public class Program { volatile static bool cancel; static bool failed; ...
1
6,044
What cases do you see as being valid for not having any tests to run? If a test project doesn't have any tests to run we should avoid running it at the project level.
dotnet-buildtools
.cs
@@ -1139,6 +1139,10 @@ func (mset *stream) processMirrorMsgs() { // Grab stream quit channel. mset.mu.Lock() + if mset.mirror == nil { + mset.mu.Unlock() + return + } msgs, mch, qch := mset.mirror.msgs, mset.mirror.msgs.mch, mset.qch // Set the last seen as now so that we don't fail at the first check. ms...
1
// Copyright 2019-2021 The NATS 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 ...
1
12,995
and is it possible that mset.mirror.msgs be nil? because if so, then you would get a panic also because of that.
nats-io-nats-server
go
@@ -258,6 +258,7 @@ static void surface_move_state(struct wlr_surface *surface, } if ((next->invalid & WLR_SURFACE_INVALID_OPAQUE_REGION)) { // TODO: process buffer + pixman_region32_copy(&state->opaque, &next->opaque); pixman_region32_clear(&next->opaque); } if ((next->invalid & WLR_SURFACE_INVALID_INPU...
1
#include <assert.h> #include <stdlib.h> #include <wayland-server.h> #include <wlr/render/interface.h> #include <wlr/types/wlr_buffer.h> #include <wlr/types/wlr_compositor.h> #include <wlr/types/wlr_matrix.h> #include <wlr/types/wlr_region.h> #include <wlr/types/wlr_surface.h> #include <wlr/util/log.h> #include <wlr/uti...
1
12,001
`next->opaque` should not be cleared.
swaywm-wlroots
c
@@ -525,6 +525,7 @@ func (s *Server) processClientOrLeafAuthentication(c *client, opts *Options) boo c.Debugf("Account JWT not signed by trusted operator") return false } + // this only executes IF there's an issuer on the Juc - otherwise the account is already if juc.IssuerAccount != "" && !acc.hasIssue...
1
// Copyright 2012-2019 The NATS 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 ...
1
12,005
already what? I know what, but seems like smth. is missing in this sentence
nats-io-nats-server
go
@@ -1,6 +1 @@ -$("div.card-for-activity").replaceWith('<%=j render partial: 'proposals/details/activity', locals: {events: @events} %>'); -$("div.card-for-activity textarea:first").focus(); -$("#add_a_comment").attr('disabled', true); -$("div.card-for-activity textarea:first").on('input',function(){ - $("#add_a_commen...
1
$("div.card-for-activity").replaceWith('<%=j render partial: 'proposals/details/activity', locals: {events: @events} %>'); $("div.card-for-activity textarea:first").focus(); $("#add_a_comment").attr('disabled', true); $("div.card-for-activity textarea:first").on('input',function(){ $("#add_a_comment").attr('disabled'...
1
17,511
Can you put spaces after the `{`and before the `}`
18F-C2
rb
@@ -21,11 +21,12 @@ import logging import logging.handlers import os +from google.cloud.forseti import __version__ DEFAULT_LOG_FMT = ('%(asctime)s %(levelname)s ' '%(name)s(%(funcName)s): %(message).1024s') -SYSLOG_LOG_FMT = ('%(levelname)s [forseti-security] ' +SYSLOG_LOG_FMT = ('%(levelna...
1
# Copyright 2017 The Forseti Security Authors. 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 ap...
1
32,010
We said we would put `[ ]` around the version. `[forseti-security] [v2.3.0]`
forseti-security-forseti-security
py