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 |
|---|---|---|---|---|---|---|---|
@@ -383,6 +383,7 @@ class ConsoleAddon:
part in ("response-headers", "response-body", "set-cookies") and
flow.response is None
)
+ flow.backup()
if require_dummy_response:
flow.response = http.HTTPResponse.make()
if part == "cookies": | 1 | import csv
import typing
from mitmproxy import ctx
from mitmproxy import command
from mitmproxy import exceptions
from mitmproxy import flow
from mitmproxy import http
from mitmproxy import contentviews
from mitmproxy.utils import strutils
import mitmproxy.types
from mitmproxy.tools.console import overlay
from mitmp... | 1 | 13,881 | Nit: Don't move it between `require_dummy_response` definition and usage, this can live above or below :) | mitmproxy-mitmproxy | py |
@@ -377,6 +377,17 @@ type Local struct {
// connections that are originating from the local machine. Setting this to "true", allow to create large
// local-machine networks that won't trip the incoming connection limit observed by relays.
DisableLocalhostConnectionRateLimit bool `version[16]:"true"`
+
+ // BlockS... | 1 | // Copyright (C) 2019-2021 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 | 42,221 | With the current code, it not work if `EnableCatchupFromArchiveServers` is disabled. to fix it: in getDNSAddrs, change the predicate to `if wn.config.EnableCatchupFromArchiveServers || wn.config. EnableCatchupFromArchiveServers {` and in the catchup/service.go and catchup/catchpointService.go, use the `PeersPhonebookAr... | algorand-go-algorand | go |
@@ -910,8 +910,9 @@ func (cr *ConflictResolver) resolveMergedPaths(ctx context.Context,
// cache for the merged branch.
mergedNodeCache := newNodeCacheStandard(cr.fbo.folderBranch)
// Initialize the root node. There will always be at least one
- // unmerged path.
- mergedNodeCache.GetOrCreate(mergedChains.mostRe... | 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 (
"encoding/json"
"fmt"
"sort"
"strings"
"sync"
"github.com/keybase/client/go/logger"
keybase1 "github.com/keybase/client/go/protocol"
"... | 1 | 11,280 | Why not make `SearchForNodes` do a `GetOrCreate` for the root node? (Not advocating for it, but just wondering if there's another reason than avoiding having to pass in the path.) | keybase-kbfs | go |
@@ -224,6 +224,7 @@ public class DefaultP2PNetwork implements P2PNetwork {
}
dnsPeers.set(peers);
});
+ dnsDaemon.start();
}
final int listeningPort = rlpxAgent.start().join(); | 1 | /*
* Copyright ConsenSys AG.
*
* 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 | 26,617 | :+1: amazing that this has been missing since it was originally implemented | hyperledger-besu | java |
@@ -101,7 +101,7 @@ class OrcFileAppender<D> implements FileAppender<D> {
public long length() {
Preconditions.checkState(isClosed,
"Cannot return length while appending to an open file.");
- return writer.getRawDataSize();
+ return file.toInputFile().getLength();
}
@Override | 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 | 27,255 | Just want to note here that although we do check `length` while writing to choose whether to close and start a new file, that doesn't happen for ORC already so it is fine to use a FS call in this method. | apache-iceberg | java |
@@ -67,8 +67,7 @@ public class PartitionField implements Serializable {
public boolean equals(Object other) {
if (this == other) {
return true;
- }
- if (other == null || getClass() != other.getClass()) {
+ } else if (!(other instanceof PartitionField)) {
return false;
}
| 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 | 16,507 | nit: I feel multiple `if (...) { return ... }` is more readable than `if ... else ...`. | apache-iceberg | java |
@@ -32,7 +32,7 @@ def setup_test_logging():
root.debug("Already set up logging")
-setup_test_logging()
+# setup_test_logging()
logging.info("Bootstrapped test")
| 1 | """ unit test """
import difflib
import inspect
import json
import logging
import os
import sys
import tempfile
from io import StringIO
from logging import Handler
from random import random
from unittest.case import TestCase
from bzt.cli import CLI
from bzt.engine import SelfDiagnosable
from bzt.modules.aggregator imp... | 1 | 15,123 | This is needed for us to work in IDE UTs | Blazemeter-taurus | py |
@@ -282,6 +282,12 @@ commands (copy, sync, etc), and with all other commands too.`,
Default: false,
Help: "Only show files that are in the trash.\nThis will show trashed files in their original directory structure.",
Advanced: true,
+ }, {
+ }, {
+ Name: "starred_only",
+ Default: false,
+ ... | 1 | // Package drive interfaces with the Google Drive object storage system
package drive
// FIXME need to deal with some corner cases
// * multiple files with the same name
// * files can be in multiple directories
// * can have directory loops
// * files with / in name
import (
"bytes"
"context"
"crypto/tls"
"fmt"
... | 1 | 10,396 | File is not `goimports`-ed (from `goimports`) | rclone-rclone | go |
@@ -486,14 +486,14 @@ func DupSecOpt(src string) []string {
con["level"] == "" {
return nil
}
- return []string{"label:user:" + con["user"],
- "label:role:" + con["role"],
- "label:type:" + con["type"],
- "label:level:" + con["level"]}
+ return []string{"label=user:" + con["user"],
+ "label=role:" + con["ro... | 1 | // +build linux
package selinux
import (
"bufio"
"crypto/rand"
"encoding/binary"
"fmt"
"io"
"os"
"path/filepath"
"regexp"
"strconv"
"strings"
"sync"
"syscall"
"github.com/opencontainers/runc/libcontainer/system"
)
const (
Enforcing = 1
Permissive = 0
Disabled = -1
selinuxDir ... | 1 | 11,054 | this `label=` is docker specific, while here in libcontainer there shouldn't be any mention to docker. `DisableSecOpt` and `DupSecOpt` should just deal with `disable,role,type,level`. Both CRI-O and docker should just pass `disable,role,type.level` stuff and not `label=...`. | opencontainers-runc | go |
@@ -31,6 +31,7 @@ func init() {
flags.BoolVarP(cmdFlags, ¬CreateNewFile, "no-create", "C", false, "Do not create the file if it does not exist.")
flags.StringVarP(cmdFlags, &timeAsArgument, "timestamp", "t", "", "Use specified time instead of the current time of day.")
flags.BoolVarP(cmdFlags, &localTime, "loc... | 1 | package touch
import (
"bytes"
"context"
"time"
"github.com/pkg/errors"
"github.com/rclone/rclone/cmd"
"github.com/rclone/rclone/fs"
"github.com/rclone/rclone/fs/config/flags"
"github.com/rclone/rclone/fs/object"
"github.com/spf13/cobra"
)
var (
notCreateNewFile bool
timeAsArgument string
localTime ... | 1 | 13,624 | You need to declare variable `recurse` above, same place as `localTime`. | rclone-rclone | go |
@@ -1565,7 +1565,8 @@ class SpreadingOperation(LinkableOperation):
new_data[tuple(vd.name for vd in vdims)] = img
else:
new_data = array
- return element.clone(new_data, **kwargs)
+ return element.clone(new_data, xdensity=element.xdensity,
+ y... | 1 | from __future__ import absolute_import, division
import warnings
from collections import Callable
from functools import partial
import param
import numpy as np
import pandas as pd
import xarray as xr
import datashader as ds
import datashader.reductions as rd
import datashader.transfer_functions as tf
import dask.dat... | 1 | 23,971 | Why does `clone` not already copy `xdensity` and `ydensity` from what it is cloning? | holoviz-holoviews | py |
@@ -52,6 +52,11 @@ namespace OpenTelemetry.Metrics
AggregationTemporality temporality = AggregationTemporality.Cumulative;
+ if (meterSources.Count() == 0)
+ {
+ throw new ArgumentException("No meter was added to the sdk.");
+ }
+
foreach (va... | 1 | // <copyright file="MeterProviderSdk.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.apach... | 1 | 22,038 | Curious - do we do the same for traces (when no ActivitySource / legacy source are added)? (and why we want to do it for metrics?) | open-telemetry-opentelemetry-dotnet | .cs |
@@ -801,11 +801,11 @@ SdMmcHcStartSdClock (
Refer to SD Host Controller Simplified spec 3.0 Section 3.2.1 for details.
- @param[in] Private A pointer to the SD_MMC_HC_PRIVATE_DATA instance.
- @param[in] Slot The slot number of the SD card to send the command to.
- @param[in] BusTiming ... | 1 | /** @file
This driver is used to manage SD/MMC PCI host controllers which are compliance
with SD Host Controller Simplified Specification version 3.00 plus the 64-bit
System Addressing support in SD Host Controller Simplified Specification version
4.20.
It would expose EFI_SD_MMC_PASS_THRU_PROTOCOL for... | 1 | 17,691 | @aimanrosli23 For the changes in file SdMmcPciHci.c, please make sure that you do not revert the changes made by the below commits: SHA-1: 49accdedf956f175041040e677163b7cbb746283 * MdeModulePkg/SdMmcPciHcDxe: Hook SwitchClockFreq after SD clock start SHA-1: c67617f3c677c342efde780e229f841f4e0f6c7e * MdeModulePkg/SdMmc... | tianocore-edk2 | c |
@@ -128,11 +128,18 @@ class SelectionAndFilterTests:
('<link href="javascript://foo" />', [webelem.Group.all,
webelem.Group.url]),
- ('<textarea />', [webelem.Group.all]),
+ ('<textarea />', [webelem.Group.all, webelem.Group.inputs]),
('<s... | 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 | 14,770 | You'll also need to add `webelem.Group.all` everywhere as that matches as well | qutebrowser-qutebrowser | py |
@@ -0,0 +1,14 @@
+$(document).ready(initializeDocument);
+
+function initializeDocument() {
+ //only enable bank account field when BA80 is selected as an expense_type
+ $("input:radio[name='ncr_proposal[expense_type]']").click(function(event){
+ if ($("input:radio[name='ncr_proposal[expense_type]']:checked").val(... | 1 | 1 | 12,271 | Does this need to be an ERB template? | 18F-C2 | rb | |
@@ -0,0 +1,18 @@
+package feedbackmock
+
+import (
+ "context"
+
+ feedbackv1 "github.com/lyft/clutch/backend/api/feedback/v1"
+ "github.com/lyft/clutch/backend/service/feedback"
+)
+
+type svc struct{}
+
+func (s svc) SubmitFeedback(ctx context.Context, id string, feedback *feedbackv1.Feedback, metadata *feedbackv1.Fe... | 1 | 1 | 12,158 | do we want to register this in the mock server for testing? | lyft-clutch | go | |
@@ -231,10 +231,10 @@ class AnomalyLikelihoodTest(TestCaseBase):
# Generate an estimate using fake distribution of anomaly scores.
data1 = _generateSampleData(mean=0.2)
- data1 = data1 + [(2, 2), (2, 2, 2, 2), (), (2)] # Malformed records
+ data1 = data1[0:1000] + [(2, 2), (2, 2, 2, 2), (), (2)] # M... | 1 | #!/usr/bin/env python
# ----------------------------------------------------------------------
# Numenta Platform for Intelligent Computing (NuPIC)
# Copyright (C) 2013-2014, Numenta, Inc. Unless you have an agreement
# with Numenta, Inc., for a separate license for this software code, the
# following terms and condit... | 1 | 17,404 | shouldnt this be `0:996` (+4) so the 1000s below fit? | numenta-nupic | py |
@@ -49,11 +49,11 @@ class sorted_context(object):
self.enabled = enabled
def __enter__(self):
- self._enabled = MultiDimensionalMapping._sorted
- MultiDimensionalMapping._sorted = self.enabled
+ self._enabled = MultiDimensionalMapping.sort
+ MultiDimensionalMapping.sort = sel... | 1 | """
Supplies MultiDimensionalMapping and NdMapping which are multi-dimensional
map types. The former class only allows indexing whereas the latter
also enables slicing over multiple dimension ranges.
"""
from itertools import cycle
from operator import itemgetter
import numpy as np
import param
from . import util
fr... | 1 | 16,877 | The docstring of this context_manager should be updated. As now ``sort=False`` is valid, it should just say it disables sorting regardless of whether the NdMapping has ``sort=True`` or ``sort=False``. I also think the line 'Should only be used if values are guaranteed to be sorted before or after the operation is perfo... | holoviz-holoviews | py |
@@ -52,8 +52,8 @@ describe('Lifecycle methods', () => {
}
}
- spyAll(Receiver.prototype);
spyAll(Receiver);
+ spyAll(Receiver.prototype);
function throwExpectedError() {
throw (expectedError = new Error('Error!')); | 1 | import { setupRerender } from 'preact/test-utils';
import { createElement, render, Component } from 'preact';
import {
setupScratch,
teardown,
spyAll,
resetAllSpies
} from '../../_util/helpers';
/** @jsx createElement */
describe('Lifecycle methods', () => {
/* eslint-disable react/display-name */
/** @type {H... | 1 | 14,570 | This tests failed unless I swapped the order here. Perhaps some new class transform broke the old form? | preactjs-preact | js |
@@ -699,10 +699,14 @@ class Util:
@classmethod
def get_java_opts(cls):
opts = config.LAMBDA_JAVA_OPTS or ''
- if '_debug_port_' in opts:
+ if 'address=_debug_port_' in opts:
if not cls.debug_java_port:
cls.debug_java_port = get_free_tcp_port()
... | 1 | import os
import re
import glob
import json
import time
import logging
import threading
import subprocess
import six
from multiprocessing import Process, Queue
try:
from shlex import quote as cmd_quote
except ImportError:
from pipes import quote as cmd_quote # for Python 2.7
from localstack import config
from ... | 1 | 10,739 | extract the port and set to `debug_java_port` | localstack-localstack | py |
@@ -93,6 +93,13 @@ def parse_compile_commands_json(logfile, add_compiler_defaults=False):
counter = 0
for entry in data:
sourcefile = entry['file']
+
+ if not os.path.isabs(sourcefile):
+ # Newest versions of intercept-build can create the 'file' in the
+ # JSON Compilati... | 1 | # -------------------------------------------------------------------------
# The CodeChecker Infrastructure
# This file is distributed under the University of Illinois Open Source
# License. See LICENSE.TXT for details.
# -------------------------------------------------------------------------... | 1 | 6,593 | When the argument list is `["one", "two three"]` then you concatenate it as you do it here, you won't be able to get the original list back with split. You need to annotate the list items better. (Or if you won't do the split by yourself, the called shell will do it. So you need shell escaping. How portable is that?) T... | Ericsson-codechecker | c |
@@ -95,6 +95,10 @@ func (a *FakeWebAPI) RegisterPiped(ctx context.Context, req *webservice.Register
}, nil
}
+func (a *FakeWebAPI) EnablePiped(ctx context.Context, req *webservice.EnablePipedRequest) (*webservice.EnablePipedResponse, error) {
+ return nil, status.Error(codes.Unimplemented, "")
+}
+
func (a *FakeW... | 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,256 | `ctx` is unused in EnablePiped | pipe-cd-pipe | go |
@@ -57,7 +57,9 @@ class _Session(object):
return hashlib.sha256(auth_string + "@" +
_Session.__initial_salt).hexdigest()
- def __init__(self, token, phash):
+ def __init__(self, token, phash, user, authenticated):
+ self.authenticated = authenticated
+ self.... | 1 | # -------------------------------------------------------------------------
# The CodeChecker Infrastructure
# This file is distributed under the University of Illinois Open Source
# License. See LICENSE.TXT for details.
# -------------------------------------------------------------------------... | 1 | 7,066 | Why do we have both a list of valid sessions and an instance variable if a session is destroyed? | Ericsson-codechecker | c |
@@ -258,10 +258,11 @@ func (au *accountUpdates) committedUpTo(rnd basics.Round) basics.Round {
// Keep track of how many changes to each account we flush to the
// account DB, so that we can drop the corresponding refcounts in
// au.accounts.
- flushcount := make(map[basics.Address]int)
+ var flushcount map[basic... | 1 | // Copyright (C) 2019 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) any l... | 1 | 36,265 | nit : I think that it would be "cleaner" to set the `flushcount` to nil in case of an error nice catch ;-) | algorand-go-algorand | go |
@@ -19,13 +19,12 @@
package org.phoenicis.repository.repositoryTypes;
import org.junit.Test;
-import org.phoenicis.repository.repositoryTypes.NullRepository;
import static org.junit.Assert.assertEquals;
public class NullRepositoryTest {
@Test
public void testNullRepositoryTest() {
- assertEqu... | 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 | 10,215 | You may want to use assertNull | PhoenicisOrg-phoenicis | java |
@@ -58,9 +58,12 @@ public class TracerTest {
public void shouldBeAbleToCreateATracer() {
List<SpanData> allSpans = new ArrayList<>();
Tracer tracer = createTracer(allSpans);
+ long timeStamp = 1593493828L;
try (Span span = tracer.getCurrentContext().createSpan("parent")) {
span.setAttribut... | 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 | 17,762 | Break out tests for events into their own tests rather than placing them in other ones. That makes it easier for us to figure out where problems lie and to do a TDD-driven implementation over new APIs. | SeleniumHQ-selenium | py |
@@ -224,7 +224,6 @@ struct wlr_output *wlr_wl_output_create(struct wlr_backend *_backend) {
wlr_output->width = 640;
wlr_output->height = 480;
- wlr_output->scale = 1;
strncpy(wlr_output->make, "wayland", sizeof(wlr_output->make));
strncpy(wlr_output->model, "wayland", sizeof(wlr_output->model));
snprintf(w... | 1 | #include <stdio.h>
#include <assert.h>
#include <stdint.h>
#include <stdlib.h>
#include <string.h>
#include <unistd.h>
#include <sys/types.h>
#include <sys/mman.h>
#include <wayland-client.h>
#include <GLES3/gl3.h>
#include <wlr/interfaces/wlr_output.h>
#include <wlr/util/log.h>
#include "backend/wayland.h"
#include "x... | 1 | 7,824 | Why did you remove this? | swaywm-wlroots | c |
@@ -72,7 +72,12 @@ func mapPort(m portmap.Interface, c chan struct{}, protocol string, extPort, int
}
}()
for {
- addMapping(m, protocol, extPort, intPort, name, publisher)
+ err := addMapping(m, protocol, extPort, intPort, name, publisher)
+ if err != nil {
+ log.Infof("%s, Mapping for port %d failed: %s",... | 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 | 13,714 | Why we need another error printouts? We already have it inside addMapping.. | mysteriumnetwork-node | go |
@@ -215,7 +215,7 @@ bool CoreChecks::ValidateFsOutputsAgainstDynamicRenderingRenderPass(SHADER_MODUL
const bool alpha_to_coverage_enabled = pipeline->create_info.graphics.pMultisampleState != NULL &&
pipeline->create_info.graphics.pMultisampleState->alphaToCoverageEnable == VK_TRUE;
- for (uint32_t l... | 1 | /* Copyright (c) 2015-2021 The Khronos Group Inc.
* Copyright (c) 2015-2021 Valve Corporation
* Copyright (c) 2015-2021 LunarG, Inc.
* Copyright (C) 2015-2021 Google Inc.
* Modifications Copyright (C) 2020 Advanced Micro Devices, Inc. All rights reserved.
*
* Licensed under the Apache License, Version 2.0 (the "L... | 1 | 23,092 | This LGTM, but I'm curious if this fixed a specific error you were hitting? | KhronosGroup-Vulkan-ValidationLayers | cpp |
@@ -181,7 +181,9 @@ func parseCgroupFromReader(r io.Reader) (map[string]string, error) {
}
for _, subs := range strings.Split(parts[1], ",") {
- cgroups[subs] = parts[2]
+ if subs != "" {
+ cgroups[subs] = parts[2]
+ }
}
}
if err := s.Err(); err != nil { | 1 | // +build linux
package cgroups
import (
"bufio"
"errors"
"fmt"
"io"
"io/ioutil"
"os"
"path/filepath"
"strconv"
"strings"
"sync"
"time"
"github.com/opencontainers/runc/libcontainer/cgroups/fscommon"
"github.com/opencontainers/runc/libcontainer/userns"
"github.com/sirupsen/logrus"
"golang.org/x/sys/uni... | 1 | 23,720 | Actually we rely on this functionality in cgroup v2, where the subsystem is empty. | opencontainers-runc | go |
@@ -1,10 +1,12 @@
-package core
+package core_test
import (
"testing"
"unsafe"
"github.com/google/go-cmp/cmp"
+
+ "go.opentelemetry.io/api/core"
"go.opentelemetry.io/api/registry"
)
| 1 | package core
import (
"testing"
"unsafe"
"github.com/google/go-cmp/cmp"
"go.opentelemetry.io/api/registry"
)
func TestBool(t *testing.T) {
for _, testcase := range []struct {
name string
v bool
want Value
}{
{
name: "value: true",
v: true,
want: Value{
Type: BOOL,
Bool: true,
... | 1 | 9,571 | suggestion: use `core` package name | open-telemetry-opentelemetry-go | go |
@@ -1354,7 +1354,7 @@ defaultdict(<class 'list'>, {'col..., 'col...})]
# TODO: enable doctests once we drop Spark 2.3.x (due to type coercion logic
# when creating arrays)
- def transpose(self, limit: Optional[int] = 1000):
+ def transpose(self, limit: Optional[int] = get_option("compute.max_rows")):... | 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 | 11,238 | I think we can entirely remove this `limit` parameter for now to be consistent with other APIs. | databricks-koalas | py |
@@ -0,0 +1,9 @@
+from localstack.services.infra import start_moto_server
+from localstack import config
+
+
+def start_rg(port=None, asynchronous=False, update_listener=None):
+ port = port or config.PORT_RESOURCE_GROUPS
+
+ return start_moto_server('resource-groups', port, name='Resource Groups Tagging API',
+ ... | 1 | 1 | 12,450 | nit: `Resource Groups Tagging API` -> `Resource Groups API` | localstack-localstack | py | |
@@ -5,10 +5,16 @@
package ecr
import (
+ "encoding/base64"
+ "errors"
"fmt"
"strings"
+ "github.com/aws/aws-sdk-go/aws"
"github.com/aws/aws-sdk-go/aws/arn"
+ "github.com/aws/aws-sdk-go/aws/session"
+ "github.com/aws/aws-sdk-go/service/ecr"
+ "github.com/aws/aws-sdk-go/service/ecr/ecriface"
)
const ( | 1 | // Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved.
// SPDX-License-Identifier: Apache-2.0
// Package ecr contains utility functions for dealing with ECR repos
package ecr
import (
"fmt"
"strings"
"github.com/aws/aws-sdk-go/aws/arn"
)
const (
urlFmtString = "%s.dkr.ecr.%s.amazonaws.c... | 1 | 11,311 | This type of list + delete always make me a bit uneasy but guess there's no atomic way to do this...... Could you put a todo to retry the "ClearRepository + delete repo" flow a few times? Basically, imagine a new image is added right after we call `ListImages`, then `DeleteImages` will not delete that newly added image... | aws-copilot-cli | go |
@@ -1,5 +1,11 @@
-define(['dom', 'scrollManager'], function (dom, scrollManager) {
- 'use strict';
+/* eslint-disable indent */
+
+import dom from 'dom';
+import scrollManager from 'scrollManager';
+
+/* eslint-disable no-unused-expressions */
+'use strict';
+/* eslint-enable no-unused-expressions */
var scop... | 1 | define(['dom', 'scrollManager'], function (dom, scrollManager) {
'use strict';
var scopes = [];
function pushScope(elem) {
scopes.push(elem);
}
function popScope(elem) {
if (scopes.length) {
scopes.length -= 1;
}
}
function autoFocus(view, defaultToFirs... | 1 | 17,169 | You can remove this since ES6 modules are strict by default. And thanks for contributing to the Jellyfin Project. | jellyfin-jellyfin-web | js |
@@ -32,7 +32,7 @@ public class TransactionRLPDecoderTest {
private static final String FRONTIER_TX_RLP =
"0xf901fc8032830138808080b901ae60056013565b6101918061001d6000396000f35b3360008190555056006001600060e060020a6000350480630a874df61461003a57806341c0e1b514610058578063a02b161e14610066578063dbbdf083146100775700... | 1 | /*
* Copyright ConsenSys AG.
*
* 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 | 24,410 | Why did eip1559 go from a list (0xf9020280.....) to a wrapped string (0xb902060ff9020280...) and not just concatenation (0x0ff9020280...)? implementation detail or is this how it sits on the wire now? | hyperledger-besu | java |
@@ -1334,9 +1334,9 @@ func TestConfigCheckIncludes(t *testing.T) {
if err == nil {
t.Errorf("Expected error processing include files with configuration check enabled: %v", err)
}
- expectedErr := errors.New(`configs/include_bad_conf_check_b.conf:10:19: unknown field "monitoring_port"` + "\n")
- if err != nil && ... | 1 | // Copyright 2018 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 in wr... | 1 | 9,682 | @wallyqs Since on Windows it would be `\` instead of `/` I just look at the suffix past `configs/`. Let me know if that's ok or not. | nats-io-nats-server | go |
@@ -1385,5 +1385,12 @@ func (a *WebAPI) GetInsightData(ctx context.Context, req *webservice.GetInsightD
return &webservice.GetInsightDataResponse{
UpdatedAt: updateAt,
DataPoints: idp,
+ Type: model.InsightResultType_MATRIX,
+ Matrix: []*model.InsightSampleStream{
+ {
+ Labels: nil,
+ DataP... | 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 | 14,317 | nit: Remove this assignment because it is not necessary. | pipe-cd-pipe | go |
@@ -217,7 +217,10 @@ ostree_builtin_summary (int argc, char **argv, GCancellable *cancellable, GError
if (opt_raw)
flags |= OSTREE_DUMP_RAW;
- summary_data = ot_file_mapat_bytes (repo->repo_dir_fd, "summary", error);
+ glnx_fd_close int fd = -1;
+ if (!glnx_openat_rdonly (repo->repo_dir... | 1 | /*
* Copyright (C) 2014 Colin Walters <walters@verbum.org>
*
* This 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 2 of the License, or (at your option) any later version... | 1 | 12,771 | This seems like a common enough pattern to offer an equivalent wrapper in `ot-fs-util.c`, no? | ostreedev-ostree | c |
@@ -328,6 +328,7 @@ public abstract class MediaplayerActivity extends CastEnabledActivity implements
boolean isItemHasDownloadLink = media != null && (media instanceof FeedMedia) && ((FeedMedia) media).getDownload_url() != null;
menu.findItem(R.id.share_download_url_item).setVisible(isItemHasDownloadL... | 1 | package de.danoeh.antennapod.activity;
import android.annotation.TargetApi;
import android.app.Activity;
import android.content.Intent;
import android.content.SharedPreferences;
import android.content.res.TypedArray;
import android.graphics.Color;
import android.graphics.PixelFormat;
import android.net.Uri;
import and... | 1 | 13,516 | Wouldn't this crash the app if the user is currently listening to a stream? | AntennaPod-AntennaPod | java |
@@ -530,10 +530,10 @@ type listFn func(remote string, object *swift.Object, isDirectory bool) error
//
// Set recurse to read sub directories
func (f *Fs) listContainerRoot(container, directory, prefix string, addContainer bool, recurse bool, fn listFn) error {
- if prefix != "" {
+ if prefix != "" && !strings.HasSu... | 1 | // Package swift provides an interface to the Swift object storage system
package swift
import (
"bufio"
"bytes"
"context"
"fmt"
"io"
"path"
"strconv"
"strings"
"time"
"github.com/ncw/swift"
"github.com/pkg/errors"
"github.com/rclone/rclone/fs"
"github.com/rclone/rclone/fs/config/configmap"
"github.com/... | 1 | 9,707 | This looks like an unrelated change? What is it for? | rclone-rclone | go |
@@ -0,0 +1,7 @@
+package csv
+
+import "sync/atomic"
+
+func (d *tableDecoder) IsDone() bool {
+ return d.empty || atomic.LoadInt32(&d.used) != 0
+} | 1 | 1 | 11,834 | Wait, what is this doing? Is this a way to create methods that are only accessible from tests? | influxdata-flux | go | |
@@ -93,6 +93,11 @@ func (s *Service) list(c *gin.Context) {
name := c.Query("name")
ns := c.Query("namespace")
+ canList := utils.CanListChaos(c, ns)
+ if !canList {
+ return
+ }
+
metas, err := s.archive.ListMeta(context.Background(), kind, ns, name, true)
if err != nil {
c.Status(http.StatusInternalServ... | 1 | // Copyright 2020 Chaos Mesh 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 | 18,706 | Is it more reasonable to return some errors here, such as returning error codes (403 and so on?) ? | chaos-mesh-chaos-mesh | go |
@@ -68,7 +68,11 @@ export function createVNode(type, props, key, ref) {
_parent: null,
_depth: 0,
_dom: null,
- _lastDomChild: null,
+ // _lastDomChildSibling must be initialized to undefined b/c it will eventually
+ // be set to dom.nextSibling which can return `null` and it is important
+ // to be able t... | 1 | import options from './options';
/**
* Create an virtual node (used for JSX)
* @param {import('./internal').VNode["type"]} type The node name or Component
* constructor for this virtual node
* @param {object | null | undefined} [props] The properties of the virtual node
* @param {Array<import('.').ComponentChildr... | 1 | 15,132 | Thinking out loud... would `_nextDom` be a better name for this? | preactjs-preact | js |
@@ -165,11 +165,6 @@ class TestSuperfluousParentheses(CheckerTestCase):
(Message("superfluous-parens", line=1, args="if"), "if (foo):", 0),
(Message("superfluous-parens", line=1, args="if"), "if ((foo, bar)):", 0),
(Message("superfluous-parens", line=1, args="if"), "if (foo(bar)):... | 1 | # Copyright (c) 2009-2011, 2014 LOGILAB S.A. (Paris, FRANCE) <contact@logilab.fr>
# Copyright (c) 2012 FELD Boris <lothiraldan@gmail.com>
# Copyright (c) 2013-2014 Google, Inc.
# Copyright (c) 2014-2020 Claudiu Popa <pcmanticore@gmail.com>
# Copyright (c) 2014 buck <buck.2019@gmail.com>
# Copyright (c) 2014 Arun Persau... | 1 | 15,503 | Turns out the unittests also had a false positive. | PyCQA-pylint | py |
@@ -24,12 +24,12 @@ namespace OpenTelemetry.Metrics
public abstract class Meter
{
/// <summary>
- /// Creates a counter for long with given name.
+ /// Creates a counter for Int64 with given name.
/// </summary>
/// <param name="name">The name of the counter.</param>
... | 1 | // <copyright file="Meter.cs" company="OpenTelemetry Authors">
// Copyright 2018, 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.org/li... | 1 | 12,613 | I think these method names would be clearer if written as "Create a {type} counter|gauge|measure with given name". eg "Create a int64 counter with given name" "Create a double gauge with given name" | open-telemetry-opentelemetry-dotnet | .cs |
@@ -3530,7 +3530,7 @@ int LuaScriptInterface::luaDoChallengeCreature(lua_State* L)
int LuaScriptInterface::luaIsValidUID(lua_State* L)
{
//isValidUID(uid)
- pushBoolean(L, getScriptEnv()->getThingByUID(getNumber<uint32_t>(L, -1)) != nullptr);
+ pushBoolean(L, getScriptEnv()->getThingByUID(getNumber<uint32_t>(L, -1)... | 1 | /**
* The Forgotten Server - a free and open-source MMORPG server emulator
* Copyright (C) 2019 Mark Samman <mark.samman@gmail.com>
*
* 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; eithe... | 1 | 19,519 | it pushes a boolean, so it has to be explicitly casted to boolean with != nullptr, same with all other similar stuff | otland-forgottenserver | cpp |
@@ -237,6 +237,7 @@ Publisher* ParticipantImpl::createPublisher(
delete(pubimpl);
return nullptr;
}
+ pubimpl->m_history.rebuild_instances();
pubimpl->mp_writer = writer;
//SAVE THE PUBLISHER PAIR
t_p_PublisherPair pubpair; | 1 | // Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima).
//
// 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 re... | 1 | 19,094 | It would be nice to have an equivalent of this call on `DataWriterImpl::enable` | eProsima-Fast-DDS | cpp |
@@ -1112,6 +1112,7 @@ func (a *PipedAPI) CreateDeploymentChain(ctx context.Context, req *pipedservice.
},
},
},
+ Status: model.ChainBlockStatus_DEPLOYMENT_BLOCK_RUNNING,
StartedAt: time.Now().Unix(),
})
| 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 | 22,992 | Isn't this PENDING? | pipe-cd-pipe | go |
@@ -30,16 +30,14 @@ function isLandmark(virtualNode) {
var explictRole = (node.getAttribute('role') || '').trim().toLowerCase();
if (explictRole) {
- if (explictRole === 'form') {
- return !!aria.labelVirtual(virtualNode);
- }
return landmarkRoles.includes(explictRole);
} else {
// Check if the node m... | 1 | const { dom, aria } = axe.commons;
// Return the skplink, if any
function getSkiplink(virtualNode) {
const firstLink = axe.utils.querySelectorAll(virtualNode, 'a[href]')[0];
if (
firstLink &&
axe.commons.dom.getElementByReference(firstLink.actualNode, 'href')
) {
return firstLink.actualNode;
}
}
const skipL... | 1 | 12,960 | minor detail, why aim to sanitize title if tile is empty (in some cases)? worth adding an && to check for that. | dequelabs-axe-core | js |
@@ -28,9 +28,8 @@ package com.salesforce.androidsdk.smartsync.target;
import android.text.TextUtils;
-import com.salesforce.androidsdk.smartstore.store.QuerySpec;
-import com.salesforce.androidsdk.smartstore.store.SmartStore;
import com.salesforce.androidsdk.smartsync.manager.SyncManager;
+import com.salesforce.a... | 1 | /*
* Copyright (c) 2017-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 | 15,915 | Code shared by ParentChildrenSyncDownTarget and ParentChildrenSyncUpTarget moved to ParentChildrenSyncTargetHelper | forcedotcom-SalesforceMobileSDK-Android | java |
@@ -75,12 +75,12 @@ class Local(Provisioning):
def startup(self):
self.start_time = time.time()
- self.available_slots = self.settings.get("capacity", None)
- if not self.available_slots:
- if self.settings.get("sequential", False):
- self.available_slots = 1
- ... | 1 | """
Implementations for `Provisioning` classes
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
Unless required by appl... | 1 | 15,503 | The bug is not about the priority , But we use 2 config items CAPACITY and SEQUENTIAL to control 1 action: thoughput. If 'sequential' is given to 'False' as default in configfile and then I use 'capacity' to 10 in my test.yml , the 'capacity' 's priority should be higher than default 'sequential'. So, I suggest we use ... | Blazemeter-taurus | py |
@@ -9,10 +9,13 @@ import (
"github.com/stretchr/testify/assert"
"github.com/stretchr/testify/require"
+ tf "github.com/filecoin-project/go-filecoin/testhelpers/testflags"
mockplugin "github.com/filecoin-project/go-filecoin/tools/iptb-plugins/filecoin/mock"
)
func TestStartLogCapture(t *testing.T) {
+ tf.Int... | 1 | package fast
import (
"context"
"io/ioutil"
"testing"
iptb "github.com/ipfs/iptb/testbed"
"github.com/stretchr/testify/assert"
"github.com/stretchr/testify/require"
mockplugin "github.com/filecoin-project/go-filecoin/tools/iptb-plugins/filecoin/mock"
)
func TestStartLogCapture(t *testing.T) {
assert := asse... | 1 | 18,525 | I don't know if I'd call any of these FAST tests integration tests. They are unit tests for FAST. They use a mock plugin which doesn't actually start any external processes, etc. | filecoin-project-venus | go |
@@ -27,10 +27,12 @@ const (
invalidVersion version = "invalid.version"
)
+// CurrentVersion returns the version of the calling instance
func CurrentVersion() version {
return version(mver.GetVersion())
}
+// Version returns the version in version type if present
func Version(version string) version {
swit... | 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,661 | Can you provide corresponding UT for this. | openebs-maya | go |
@@ -29,6 +29,8 @@ import (
"testing"
"time"
+ "golang.org/x/net/context"
+
"github.com/yarpc/yarpc-go/encoding/raw"
"github.com/yarpc/yarpc-go/transport"
"github.com/yarpc/yarpc-go/transport/transporttest" | 1 | // Copyright (c) 2016 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 | 10,525 | nit: this should be below the yarpc group | yarpc-yarpc-go | go |
@@ -44,6 +44,10 @@ func New(name, tip string, labelNames []string, defaultLabels []string) (*TimerF
labelNames,
)
err := prometheus.Register(vect)
+ switch err.(type) {
+ case prometheus.AlreadyRegisteredError:
+ err = nil
+ }
return &TimerFactory{
labelNames: labelNames, | 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 | 14,488 | singleCaseSwitch: should rewrite switch statement to if statement (from `gocritic`) | iotexproject-iotex-core | go |
@@ -442,7 +442,17 @@ configRetry:
log.Infof("Starting the Typha connection")
err := typhaConnection.Start(context.Background())
if err != nil {
- log.WithError(err).Fatal("Failed to connect to Typha")
+ retry := 0
+ for err != nil && retry < 10 {
+ // Set Ready and Live to false
+ healthAggregator.... | 1 | // Copyright (c) 2017-2019 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 | 16,830 | Please log once here at Error level "Failed to connect to Typha, will retry..." | projectcalico-felix | c |
@@ -31,7 +31,7 @@ func TestICMPPortUnreachable(t *testing.T) {
_, ipv4, _, _, pktBytes, err := testPacketUDPDefault()
Expect(err).NotTo(HaveOccurred())
- runBpfUnitTest(t, "icmp_port_unreachable.c", func(bpfrun bpfProgRunFn) {
+ runBpfUnitTest(t, "icmp_port_unreachable.c", false, func(bpfrun bpfProgRunFn) {
re... | 1 | // Copyright (c) 2019-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,322 | Do we need the forXDP parameter in runBpfUnitTest? If not, I think better to revert in order to save a few changes. | projectcalico-felix | c |
@@ -6,11 +6,14 @@ from pyramid import httpexceptions
class NameGenerator(generators.Generator):
+ regexp = r'^[a-zA-Z0-9][a-zA-Z0-9_-]*$'
+
def __call__(self):
ascii_letters = ('abcdefghijklmopqrstuvwxyz'
'ABCDEFGHIJKLMOPQRSTUVWXYZ')
- alphabet = ascii_letters + st... | 1 | import random
import string
from cliquet.storage import generators, exceptions
from pyramid import httpexceptions
class NameGenerator(generators.Generator):
def __call__(self):
ascii_letters = ('abcdefghijklmopqrstuvwxyz'
'ABCDEFGHIJKLMOPQRSTUVWXYZ')
alphabet = ascii_lett... | 1 | 7,770 | So we fix it only for kinto and not for all cliquet resources? | Kinto-kinto | py |
@@ -11,9 +11,10 @@ import (
"fmt"
"math/big"
- "github.com/iotexproject/iotex-core/pkg/util/byteutil"
"github.com/pkg/errors"
+ "github.com/iotexproject/iotex-core/pkg/util/byteutil"
+
"github.com/iotexproject/iotex-core/action"
"github.com/iotexproject/iotex-core/action/protocol"
"github.com/iotexproje... | 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 | 13,833 | No empty line between | iotexproject-iotex-core | go |
@@ -141,6 +141,9 @@ func main() {
fatal(err)
}
}
+ if err := reviseRootDir(context); err != nil {
+ return err
+ }
return logs.ConfigureLogging(createLogConfig(context))
}
| 1 | package main
import (
"fmt"
"io"
"os"
"strings"
"github.com/opencontainers/runc/libcontainer/logs"
"github.com/opencontainers/runtime-spec/specs-go"
"github.com/sirupsen/logrus"
"github.com/urfave/cli"
)
// version will be populated by the Makefile, read from
// VERSION file of the source code.
var version... | 1 | 21,520 | We have `ResolveRootfs` in `libcontainer/utils` so maybe use that one here? | opencontainers-runc | go |
@@ -630,6 +630,19 @@ namespace AutoRest.Swagger.Tests
messages.AssertOnlyValidationMessage(typeof(SummaryAndDescriptionMustNotBeSame), 1);
}
+ [Fact]
+ public void LongRunningHasExtensionValidation()
+ {
+ var messages = ValidateSwagger(Path.Combine(Core.Utilities... | 1 | // Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for license information.
using System;
using System.IO;
using System.Linq;
using Xunit;
using System.Collections.Generic;
using AutoRest.Swagger.Validation.Core;
using AutoRest.Core.Logg... | 1 | 25,004 | Just curious, do we have positive test covered somewhere? | Azure-autorest | java |
@@ -101,7 +101,7 @@ static void move_resize(struct roots_view *view, double x, double y,
constrained_height);
if (serial > 0) {
roots_surface->pending_move_resize_configure_serial = serial;
- } else {
+ } else if(roots_surface->pending_move_resize_configure_serial == 0) {
view->x = x;
view->y = y;
} | 1 | #include <assert.h>
#include <stdlib.h>
#include <stdbool.h>
#include <wayland-server.h>
#include <wlr/types/wlr_box.h>
#include <wlr/types/wlr_surface.h>
#include <wlr/types/wlr_xdg_shell_v6.h>
#include <wlr/util/log.h>
#include "rootston/desktop.h"
#include "rootston/server.h"
#include "rootston/input.h"
static void... | 1 | 9,785 | Style error, put a space between `if` and `(` | swaywm-wlroots | c |
@@ -239,6 +239,13 @@ type Config struct {
// Key: aws.String("/foo/bar/moo"),
// })
EnableEndpointDiscovery *bool
+
+ // DisableEndpointHostPrefix will disable the SDK's behavior of prefixing
+ // request endpoint hosts with modeled information.
+ //
+ // Disabling this feature is useful when you want to u... | 1 | package aws
import (
"net/http"
"time"
"github.com/aws/aws-sdk-go/aws/credentials"
"github.com/aws/aws-sdk-go/aws/endpoints"
)
// UseServiceDefaultRetries instructs the config to use the service's own
// default number of retries. This will be the default action if
// Config.MaxRetries is nil also.
const UseServ... | 1 | 9,555 | It's a bit odd to have a "disable<x>" boolean, though it looks like you already do that for a few other flags. | aws-aws-sdk-go | go |
@@ -47,6 +47,7 @@ const (
// Timelimits for docker operations enforced above docker
const (
pullImageTimeout = 2 * time.Hour
+ loadImageTimeout = 2 * time.Hour
createContainerTimeout = 3 * time.Minute
startContainerTimeout = 1*time.Minute + 30*time.Second
stopContainerTimeout = 1 * time.Mi... | 1 | // Copyright 2014-2015 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... | 1 | 13,892 | Why did you pick two hours for this? | aws-amazon-ecs-agent | go |
@@ -110,8 +110,8 @@ func getNewPassword(gopts GlobalOptions) (string, error) {
newopts.password = ""
return ReadPasswordTwice(newopts,
- "enter password for new key: ",
- "enter password again: ")
+ "enter password (new): ",
+ "enter password (again): ")
}
func addKey(gopts GlobalOptions, repo *repository... | 1 | package main
import (
"context"
"encoding/json"
"io/ioutil"
"os"
"strings"
"github.com/restic/restic/internal/errors"
"github.com/restic/restic/internal/repository"
"github.com/restic/restic/internal/restic"
"github.com/restic/restic/internal/ui/table"
"github.com/spf13/cobra"
)
var cmdKey = &cobra.Comman... | 1 | 13,603 | What about "enter new password"? That would be a bit more consistent to the `ReadPasswordTwice` usage in cmd_init. | restic-restic | go |
@@ -20,7 +20,7 @@ if not versionInfo.updateVersionType:
raise RuntimeError("No update version type, update checking not supported")
import addonAPIVersion
# Avoid a E402 'module level import not at top of file' warning, because several checks are performed above.
-from gui.contextHelp import ContextHelpMixin # noq... | 1 | #updateCheck.py
#A part of NonVisual Desktop Access (NVDA)
#This file is covered by the GNU General Public License.
#See the file COPYING for more details.
#Copyright (C) 2012-2019 NV Access Limited, Zahari Yurukov, Babbage B.V., Joseph Lee
"""Update checking functionality.
@note: This module may raise C{Runtim... | 1 | 31,492 | Another redundant import | nvaccess-nvda | py |
@@ -120,7 +120,7 @@ func (c *client) FetchUpdates(ctx context.Context, req *node.FetchX509SVIDReques
// Close the stream whether there was an error or not
stream.CloseSend()
if err != nil {
- // TODO: should we try to create a new stream?
+ c.Release()
return nil, err
}
| 1 | package client
import (
"context"
"crypto/ecdsa"
"crypto/tls"
"crypto/x509"
"errors"
"fmt"
"io"
"net/url"
"sync"
"time"
"github.com/sirupsen/logrus"
spiffe_tls "github.com/spiffe/go-spiffe/tls"
"github.com/spiffe/spire/pkg/common/grpcutil"
"github.com/spiffe/spire/pkg/common/idutil"
"github.com/spiffe/... | 1 | 10,745 | What kind of errors might cause us to reach this point? Could any of them be recoverable i.e. might work if we asked the same server again? Similar question for below, but perhaps with a slightly different answer | spiffe-spire | go |
@@ -212,14 +212,14 @@ public:
class triangle_counting_test {
public:
- using my_graph_type = dal::preview::undirected_adjacency_vector_graph<>;
+ using graph_type = dal::preview::undirected_adjacency_vector_graph<>;
template <typename GraphType>
auto create_graph() {
GraphType graph_data;... | 1 | /*******************************************************************************
* Copyright 2020-2021 Intel Corporation
*
* 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.apa... | 1 | 30,250 | What is the difference between GraphType and graph_type. Naming should be more accurate. | oneapi-src-oneDAL | cpp |
@@ -9,7 +9,7 @@ use Shopsys\FrameworkBundle\Model\Product\Product;
class UnitRepository
{
/**
- * @var \Doctrine\ORM\EntityRepository
+ * @var \Doctrine\ORM\EntityManagerInterface
*/
protected $em;
| 1 | <?php
namespace Shopsys\FrameworkBundle\Model\Product\Unit;
use Doctrine\ORM\AbstractQuery;
use Doctrine\ORM\EntityManagerInterface;
use Shopsys\FrameworkBundle\Model\Product\Product;
class UnitRepository
{
/**
* @var \Doctrine\ORM\EntityRepository
*/
protected $em;
/**
* @param \Doctrine... | 1 | 16,285 | hmmm in docblock of contructor it is EntityManagerInterface....maybe it should be that way.... :confused: | shopsys-shopsys | php |
@@ -54,8 +54,13 @@ struct feat_wrapper {
.def("GetPos",
(RDGeom::Point3D(MolChemicalFeature::*)(int) const) &
MolChemicalFeature::getPos,
- (python::arg("self"), python::arg("confId") = -1),
+ (python::arg("self"), python::arg("confId")),
"G... | 1 | // $Id$
//
// 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 tree.
//
#define NO_IMPORT_ARRAY
#incl... | 1 | 22,271 | I'm curious why you went the route of adding a new method name for this. Given that you it would be possible to just have an an overload of `GetPos()`, and that this change breaks existing code, I wonder why you chose to go this way. | rdkit-rdkit | cpp |
@@ -33,12 +33,14 @@ export default Component.extend({
let subscriptions = this.member.get('stripe');
if (subscriptions && subscriptions.length > 0) {
return subscriptions.map((subscription) => {
+ const statusLabel = subscription.status === 'past_due' ? 'Past due' : subscri... | 1 | import Component from '@ember/component';
import moment from 'moment';
import {computed} from '@ember/object';
import {gt} from '@ember/object/computed';
import {inject as service} from '@ember/service';
import {task} from 'ember-concurrency';
export default Component.extend({
membersUtils: service(),
feature:... | 1 | 9,489 | Does this need to change `'active'` to `'Active'` and that? Or is that done in CSS or something? | TryGhost-Admin | js |
@@ -11,6 +11,13 @@ namespace Microsoft.AspNetCore.Server.Kestrel.Core
public class Http2Limits
{
private int _maxStreamsPerConnection = 100;
+ private int _headerTableSize = MaxAllowedHeaderTableSize;
+ private int _maxFrameSize = MinAllowedMaxFrameSize;
+
+ // These are limits d... | 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;
namespace Microsoft.AspNetCore.Server.Kestrel.Core
{
/// <summary>
/// Limits only applicable to HTTP/2 connections.
/// </s... | 1 | 16,424 | Why are these constants public? They should also be listed above members. | aspnet-KestrelHttpServer | .cs |
@@ -217,6 +217,8 @@ public class MainnetTransactionValidator {
// org.bouncycastle.math.ec.ECCurve.AbstractFp.decompressPoint throws an
// IllegalArgumentException for "Invalid point compression" for bad signatures.
try {
+ // TODO: this is where we are checking the signature. We have to fix the v v... | 1 | /*
* Copyright ConsenSys AG.
*
* 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 | 23,903 | This TODO isn't related to this change. We should remove it. | hyperledger-besu | java |
@@ -27,7 +27,5 @@ import org.apache.iceberg.FieldMetrics;
public interface ValueWriter<D> {
void write(D datum, Encoder encoder) throws IOException;
- default Stream<FieldMetrics> metrics() {
- return Stream.empty(); // TODO will populate in following PRs
- }
+ Stream<FieldMetrics> metrics();
} | 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,760 | `FieldMetrics` is parameterized, but this is a bare reference. Could you update it? I think it should be `FieldMetrics<?>` since the metrics are not necessarily for the written value type, `D`. | apache-iceberg | java |
@@ -58,12 +58,11 @@ namespace Examples.Console
// Application which decides to enable OpenTelemetry metrics
// would setup a MeterProvider and make it default.
// All meters from this factory will be configured with the common processing pipeline.
- MeterProvider.SetDef... | 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://ww... | 1 | 16,583 | @cijothomas do we want this to be `Set` or `Add`? | open-telemetry-opentelemetry-dotnet | .cs |
@@ -42,7 +42,7 @@ namespace Nethermind.JsonRpc
public string? IpcUnixDomainSocketPath { get; set; } = null;
public string[] EnabledModules { get; set; } = ModuleType.DefaultModules.ToArray();
- public long? GasCap { get; set; } = 100000000;
+ public long? GasCap { get; set; } = 5000000... | 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 | 26,382 | Why are we dropping GasCap? | NethermindEth-nethermind | .cs |
@@ -45,11 +45,11 @@ namespace OpenTelemetry.Shims.OpenTracing
public SpanShim(TelemetrySpan span)
{
- this.Span = span ?? throw new ArgumentNullException(nameof(span));
+ this.Span = span ?? throw new ArgumentNullException(nameof(span), "Parameter cannot be null");
... | 1 | // <copyright file="SpanShim.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.org/li... | 1 | 19,329 | should we end the text with a .? | open-telemetry-opentelemetry-dotnet | .cs |
@@ -752,9 +752,10 @@ dispatch_enter_dynamorio(dcontext_t *dcontext)
wherewasi == DR_WHERE_APP ||
/* If the thread was waiting at check_wait_at_safe_point when getting
* suspended, we were in dispatch (ref i#3427). We will be here after the
- * thread's context is being re... | 1 | /* **********************************************************
* Copyright (c) 2011-2020 Google, Inc. All rights reserved.
* Copyright (c) 2000-2010 VMware, Inc. All rights reserved.
* **********************************************************/
/*
* Redistribution and use in source and binary forms, with or witho... | 1 | 22,001 | Could this instead keep the `go_native` and add to it "or the last exit was the special reset exit"? | DynamoRIO-dynamorio | c |
@@ -42,9 +42,9 @@ ConfigPanelDialog::ConfigPanelDialog(LXQtPanel *panel, QWidget *parent):
addPage(mPluginsPage, tr("Widgets"), QLatin1String("preferences-plugin"));
connect(this, &ConfigPanelDialog::reset, mPluginsPage, &ConfigPluginsWidget::reset);
- connect(this, &ConfigPanelDialog::accepted, [panel] ... | 1 | /* BEGIN_COMMON_COPYRIGHT_HEADER
* (c)LGPL2+
*
* LXQt - a lightweight, Qt based, desktop toolset
* https://lxqt.org
*
* Copyright: 2010-2011 Razor team
* Authors:
* Marat "Morion" Talipov <morion.self@gmail.com>
*
* This program or library is free software; you can redistribute it
* and/or modify it under ... | 1 | 6,787 | Oh, I missed this one: The other instances of `this` you've added as lambda contexts aren't really needed, although they're harmless. However, in the above connection, the missing context is `panel`, not `this`. Please correct it! Clazy may show warnings about lambda contexts (I don't use Clazy) but, if so, that's a pr... | lxqt-lxqt-panel | cpp |
@@ -160,14 +160,9 @@ class Service(object):
except AttributeError:
pass
self.process.terminate()
- self.process.kill()
self.process.wait()
+ self.process.kill()
self.process = None
exc... | 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,965 | can we add a try / except around this to make it more stable? I like the idea of any mistakenly un-quit drivers closing down after the process is quit (the java server does this... also i forget to do driver.quit often when i use the command line repl :) ) | SeleniumHQ-selenium | py |
@@ -68,9 +68,12 @@ func (vd *volAPI) cloudMigrateStatus(w http.ResponseWriter, r *http.Request) {
return
}
- if err := json.NewDecoder(r.Body).Decode(statusReq); err != nil {
- vd.sendError(vd.name, method, w, err.Error(), http.StatusBadRequest)
- return
+ // Use empty request if nothing was sent
+ if r.Conten... | 1 | package server
import (
"encoding/json"
"net/http"
"github.com/libopenstorage/openstorage/api"
ost_errors "github.com/libopenstorage/openstorage/api/errors"
)
func (vd *volAPI) cloudMigrateStart(w http.ResponseWriter, r *http.Request) {
startReq := &api.CloudMigrateStartRequest{}
method := "cloudMigrateStart"
... | 1 | 7,714 | when would this happen? backward compatibility? | libopenstorage-openstorage | go |
@@ -0,0 +1,13 @@
+/**
+ * Returns the tagName,
+ * if it is a HTMLElement it gets lowercased
+ * @param {Element} node element
+ * @return {String} normalized tagName
+ */
+axe.utils.getTagName = function(node) {
+ if (node.namespaceURI === 'http://www.w3.org/1999/xhtml') {
+ return node.tagName.toLowerCase();
... | 1 | 1 | 11,790 | I'm not sure what the value of this is. So far we've solved this by always doing `tagName.toUpperCase()` for everything. I think we should stick with this. | dequelabs-axe-core | js | |
@@ -25,6 +25,16 @@ import (
"github.com/spf13/cobra"
)
+var (
+ snapshotListCommandHelpText = `
+Usage: mayactl snapshot list [options]
+
+$ mayactl snapshot list --volname <vol>
+
+This command displays status of available snapshot.
+`
+)
+
// NewCmdSnapshotCreate creates a snapshot of OpenEBS Volume
func NewCm... | 1 | /*
Copyright 2017 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 | 8,197 | This command displays available snapshots on a volume. | openebs-maya | go |
@@ -38,7 +38,7 @@ import (
"golang.org/x/tools/go/types/typeutil"
cpb "kythe.io/kythe/proto/common_go_proto"
- spb "kythe.io/kythe/proto/storage_go_proto"
+ stpb "kythe.io/kythe/proto/storage_go_proto"
)
// EmitOptions control the behaviour of the Emit function. A nil options | 1 | /*
* Copyright 2016 The Kythe 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 | 11,925 | `spb` is the standard package name we use for this proto. | kythe-kythe | go |
@@ -533,13 +533,13 @@ nsCommandProcessor.prototype.execute = function(jsonCommandString,
* Changes the context of the caller to the specified window.
* @param {fxdriver.CommandResponse} response The response object to send the
* command response in.
- * @param {{name: string}} parameters The command parameter... | 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,586 | /javascript/firefox-driver is the Selenium implementation of a WebDriver for Firefox. Since it generally isn't W3C compatible, it shouldn't change. We can just drop this change. | SeleniumHQ-selenium | py |
@@ -369,8 +369,8 @@ func msgToApplication(msg model.Message) (*Application, error) {
return app, nil
}
-// TODO: upgrade to parallel process
// Process translate msg to application , process and send resp to edge
+// TODO: upgrade to parallel process
func (c *Center) Process(msg model.Message) {
app, err := ms... | 1 | package application
import (
"context"
"crypto/md5"
"encoding/json"
"errors"
"fmt"
"sync"
"time"
metainternalversion "k8s.io/apimachinery/pkg/apis/meta/internalversion"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
"k8s.io/apimachinery/pkg/apis/meta/v1/unstructured"
"k8s.io/apimachinery/pkg/fields"
"k8s.i... | 1 | 21,131 | is this pr support parallelly process application? | kubeedge-kubeedge | go |
@@ -48,7 +48,9 @@ func MustEnableIssues(ctx *middleware.Context) {
}
func MustEnablePulls(ctx *middleware.Context) {
- if !ctx.Repo.Repository.EnablePulls {
+ if !ctx.Repo.Repository.CanEnablePulls() {
+ ctx.Handle(404, "Unsupported", nil)
+ } else if !ctx.Repo.Repository.EnablePulls {
ctx.Handle(404, "MustEnab... | 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 (
"errors"
"fmt"
"net/http"
"net/url"
"strings"
"time"
"github.com/Unknwon/com"
"github.com/Unknwon/paginater"
"github.com/gog... | 1 | 10,396 | Based on the assumption that when `EnablePulls` is `true`, `CanEnablePulls` must be `true` as well, then this `if` check is redundant. Actually... we have `AllowsPulls` now... why not use that? | gogs-gogs | go |
@@ -637,7 +637,7 @@ public class ScheduleServlet extends LoginAbstractAzkabanServlet {
if (flow == null) {
ret.put("status", "error");
ret.put("message", "Flow " + flowName + " cannot be found in project "
- + project);
+ + projectName);
return;
}
| 1 | /*
* Copyright 2012 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 | 10,913 | I am not sure why the API requires both project name and project ID as inputs. Wouldn't it introduce more opportunities for clients to make mistakes? | azkaban-azkaban | java |
@@ -15,7 +15,7 @@ module Ncr
def edit
if self.proposal.approved?
- flash[:warning] = "You are about to modify a fully approved request. Changes will be logged and sent to approvers, and this request may require re-approval, depending on the change."
+ flash.now[:warning] = "You are about to ... | 1 | module Ncr
class WorkOrdersController < UseCaseController
# arbitrary number...number of upload fields that "ought to be enough for anybody"
MAX_UPLOADS_ON_NEW = 10
def new
work_order.approving_official_email = self.suggested_approver_email
super
end
def create
Ncr::WorkOrderVa... | 1 | 15,498 | I believe this was happening for several different flash messages - should we add `now` to all flash messages? (there might be a downside to doing that, but I am not sure what it would be) | 18F-C2 | rb |
@@ -46,6 +46,9 @@ class ExceptionListener extends BaseExceptionListener
parent::__construct($controller, $logger);
}
+ /**
+ * {@inheritdoc}
+ */
public function onKernelException(GetResponseForExceptionEvent $event)
{
$exception = $event->getException(); | 1 | <?php
/*
* This file is part of the EasyAdminBundle.
*
* (c) Javier Eguiluz <javier.eguiluz@gmail.com>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace JavierEguiluz\Bundle\EasyAdminBundle\EventListener;
use JavierEguil... | 1 | 9,278 | There is no docblock on the parent method. Also, not related, but I forgot to typehint the `$templating` constructor argument above. | EasyCorp-EasyAdminBundle | php |
@@ -669,6 +669,12 @@ func TestDdevXdebugEnabled(t *testing.T) {
runTime := util.TimeTrack(time.Now(), fmt.Sprintf("%s %s", site.Name, t.Name()))
phpVersions := nodeps.ValidPHPVersions
+
+ // arm64 builds from deb.sury.org do not have xdebug in php5.6
+ if runtime.GOARCH == "arm64" {
+ t.Log("Skipping php5.6 test... | 1 | package ddevapp_test
import (
"bufio"
"fmt"
"io/ioutil"
"net"
"net/url"
"os"
"path"
"path/filepath"
"regexp"
"runtime"
"sort"
"strconv"
"strings"
"testing"
"time"
"github.com/drud/ddev/pkg/nodeps"
"github.com/drud/ddev/pkg/version"
"github.com/drud/ddev/pkg/globalconfig"
"github.com/stretchr/testi... | 1 | 14,742 | Silly me. This shouldn't be done in the tests, but instead in the actual definition of ValidPHPVersions on arm64. Same with Mysql and MariaDB. | drud-ddev | go |
@@ -42,7 +42,8 @@ final class LatLonShapeBoundingBoxQuery extends ShapeQuery {
@Override
protected Relation relateRangeBBoxToQuery(int minXOffset, int minYOffset, byte[] minTriangle,
int maxXOffset, int maxYOffset, byte[] maxTriangle) {
- return rectangle2D.relateRa... | 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 | 30,188 | Shouldn't this work as well for Disjoint? | apache-lucene-solr | java |
@@ -514,11 +514,11 @@ func (c *controller) finalizeOrder(ctx context.Context, cl acmecl.Interface, o *
// if it is already in the 'valid' state, as upon retry we will
// then retrieve the Certificate resource.
_, errUpdate := c.updateOrderStatus(ctx, cl, o)
- if acmeErr, ok := err.(*acmeapi.Error); ok {
+ if acme... | 1 | /*
Copyright 2020 The cert-manager 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 | 30,246 | You've not updated the `o.Status.Reason = fmt.Sprintf("Failed to retrieve Order resource: %v", err)` line below here when you changed this, so here we are checking `errUpdate` but will print the contents of `err` instead. | jetstack-cert-manager | go |
@@ -23,6 +23,9 @@ require 'socket'
module Selenium
module WebDriver
class SocketPoller
+ NOT_CONNECTED_ERRORS = [Errno::ECONNREFUSED, Errno::ENOTCONN, SocketError]
+ NOT_CONNECTED_ERRORS << Errno::EPERM if Platform.cygwin?
+
def initialize(host, port, timeout = 0, interval = 0.25)
@ho... | 1 | # encoding: utf-8
#
# 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
# "Li... | 1 | 13,776 | Doesn't this need to include `Errno::ECONNRESET` to fix the issue? | SeleniumHQ-selenium | java |
@@ -301,6 +301,9 @@ public class Constants {
public static final String PROJECT_CACHE_SIZE_PERCENTAGE = "azkaban"
+ ".project_cache_size_percentage_of_disk";
+ public static final String PROJECT_CACHE_THROTTLE_PERCENTAGE = "azkaban"
+ + ".project_cache_throttle_percentage";
+
// how many ... | 1 | /*
* Copyright 2018 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 | 19,469 | Please consider keeping the config key in one line as it will help in case someone is looking at how this config is used. public static final String PROJECT_CACHE_THROTTLE_PERCENTAGE = "azkaban.project_cache_throttle_percentage"; | azkaban-azkaban | java |
@@ -46,6 +46,7 @@ type DataStore interface {
ListParentIDEntries(request *ListParentIDEntriesRequest) (*ListParentIDEntriesResponse, error)
ListSelectorEntries(request *ListSelectorEntriesRequest) (*ListSelectorEntriesResponse, error)
+ ListPowerSelectorEntries(request *ListSelectorEntriesRequest) (*ListSelectorE... | 1 | package datastore
import (
"net/rpc"
"time"
"github.com/golang/protobuf/ptypes/empty"
"github.com/hashicorp/go-plugin"
"github.com/spiffe/spire/proto/common"
"google.golang.org/grpc"
spi "github.com/spiffe/spire/proto/common/plugin"
)
const TimeFormat = time.RFC1123Z
// Handshake is a common handshake that... | 1 | 8,926 | This is a hard one, naming-wise... `ListPowerSelectorEntries` is logical given `ListSelectorEntries`. Another option could be `ListMatchingEntries` or even `FindMatchingEntries`. :shrug: | spiffe-spire | go |
@@ -0,0 +1,4 @@
+package types
+
+// UVarint represent a 32-bit number encoded as varint.
+type UVarint uint | 1 | 1 | 22,033 | This should be called `Uint` or `Uint32` or simply using our `Uint64` type instead. All of our numbers have varint encoding. It's not inherently a varint. | filecoin-project-venus | go | |
@@ -1513,7 +1513,8 @@ class CommandDispatcher:
)
@cmdutils.register(instance='command-dispatcher', scope='window')
- def view_source(self, edit=False):
+ @cmdutils.argument('pygment')
+ def view_source(self, edit=False, pygment=False):
"""Show the source of the current page in a ne... | 1 | # vim: ft=python fileencoding=utf-8 sts=4 sw=4 et:
# Copyright 2014-2018 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 | 20,848 | No need for this when you don't need to customize anything about the argument. | qutebrowser-qutebrowser | py |
@@ -0,0 +1,14 @@
+<!-- TODO: Move this away from using ID attr -->
+<div class="panel-group section-group"
+ data-modifiable="<%= modifiable %>"
+ id="sections_accordion"
+ role="tablist">
+ <% sections.each do |section| %>
+ <%= render partial: "org_admin/sections/section",
+ object: sect... | 1 | 1 | 17,828 | We're now going to have 3 `#sections_accordion` will need to see how JS behaves. We should probably switch to a class selector instead | DMPRoadmap-roadmap | rb |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.