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 |
|---|---|---|---|---|---|---|---|
@@ -616,11 +616,12 @@ def build_sdist(sdist_directory, config_settings=None):
files += glob.glob("src/core/**/*.cc", recursive=True)
files += glob.glob("src/core/**/*.h", recursive=True)
files += glob.glob("ci/xbuild/*.py")
+ files += glob.glob("docs/**/*.rst", recursive=True)
files += [f for f i... | 1 | #!/usr/bin/env python
# -*- coding: utf-8 -*-
#-------------------------------------------------------------------------------
# Copyright 2019-2020 H2O.ai
#
# Permission is hereby granted, free of charge, to any person obtaining a
# copy of this software and associated documentation files (the "Software"),
# to deal i... | 1 | 13,149 | Looks like it is pretty easy to miss it when adding new files under `ci`. Hopefully, this doesn't happen too often. | h2oai-datatable | py |
@@ -244,6 +244,7 @@ func NewBee(addr string, swarmAddress swarm.Address, publicKey ecdsa.PublicKey,
return nil, fmt.Errorf("p2p service: %w", err)
}
b.p2pService = p2ps
+ defer p2ps.Ready()
if !o.Standalone {
if natManager := p2ps.NATManager(); natManager != nil { | 1 | // Copyright 2021 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 node defines the concept of a Bee node
// by bootstrapping and injecting all necessary
// dependencies.
package node
import (
"context"
"crypto... | 1 | 14,212 | do we really need the `Ready` call if startup fails midway? | ethersphere-bee | go |
@@ -17,7 +17,9 @@ namespace storage {
TEST(AddVerticesTest, SimpleTest) {
fs::TempDir rootPath("/tmp/AddVerticesTest.XXXXXX");
- std::unique_ptr<kvstore::KVStore> kv = TestUtils::initKV(rootPath.path());
+ constexpr int32_t partitions = 6;
+ std::unique_ptr<kvstore::KVStore> kv = TestUtils::initKV(root... | 1 | /* Copyright (c) 2018 vesoft inc. All rights reserved.
*
* This source code is licensed under Apache 2.0 License,
* attached with Common Clause Condition 1.0, found in the LICENSES directory.
*/
#include "base/Base.h"
#include "utils/NebulaKeyUtils.h"
#include <gtest/gtest.h>
#include <rocksdb/db.h>
#include "fs/T... | 1 | 28,922 | You can avoid changing the code if there are parameter defaults. right ? | vesoft-inc-nebula | cpp |
@@ -214,7 +214,7 @@ describe('Components', () => {
let good, bad;
let root = render(<GoodContainer ref={c=>good=c} />, scratch);
- expect(scratch.innerText, 'new component with key present').to.equal('A\nB');
+ expect(scratch.textContent, 'new component with key present').to.equal('AB');
expect(Comp.protot... | 1 | import { h, render, rerender, Component } from '../../src/preact';
/** @jsx h */
let spyAll = obj => Object.keys(obj).forEach( key => sinon.spy(obj,key) );
function getAttributes(node) {
let attrs = {};
if (node.attributes) {
for (let i=node.attributes.length; i--; ) {
attrs[node.attributes[i].name] = node.att... | 1 | 10,224 | I wonder why the newline disappeared here? I guess we'll merge and see how SauceLabs fares across the supported browsers. | preactjs-preact | js |
@@ -4252,10 +4252,15 @@ void command_corpsefix(Client *c, const Seperator *sep)
void command_reloadworld(Client *c, const Seperator *sep)
{
- c->Message(Chat::White, "Reloading quest cache and repopping zones worldwide.");
+ int world_repop = atoi(sep->arg[1]);
+ if (world_repop == 0)
+ c->Message(Chat::White, "Re... | 1 | /* EQEMu: Everquest Server Emulator
Copyright (C) 2001-2016 EQEMu Development Team (http://eqemulator.org)
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; version 2 of the License.
This program... | 1 | 9,807 | I know this is legal, but I prefer we put brackets on our calls | EQEmu-Server | cpp |
@@ -1,4 +1,4 @@
-//snippet-sourcedescription:[DeleteServerCertificate.java demonstrates how to delete an AWS Identity and Access Management (IAM) server certificate.]
+//snippet-sourcedescription:[DeleteServerCertificate.java demonstrates how to delete an AWS Identity and Access Management (AWS IAM) server certificate.... | 1 | //snippet-sourcedescription:[DeleteServerCertificate.java demonstrates how to delete an AWS Identity and Access Management (IAM) server certificate.]
//snippet-keyword:[AWS SDK for Java v2]
//snippet-keyword:[Code Sample]
//snippet-service:[AWS IAM]
//snippet-sourcetype:[full-example]
//snippet-sourcedate:[11/02/2... | 1 | 18,237 | AWS Identity and Access Management (IAM) | awsdocs-aws-doc-sdk-examples | rb |
@@ -0,0 +1,18 @@
+package org.openqa.selenium;
+
+/**
+ * Created by James Reed on 11/04/2016.
+ * Thrown to indicate that a click was attempted on an element but was intercepted by another
+ * element on top of it
+ */
+public class InterceptingElementException extends InvalidElementStateException {
+
+ public Interc... | 1 | 1 | 13,182 | We keep who wrote the code anonymous. | SeleniumHQ-selenium | py | |
@@ -135,10 +135,14 @@ export const readableLargeNumber = ( number, currencyCode = false ) => {
if ( false !== currencyCode && '' !== readableNumber ) {
const formatedParts = new Intl.NumberFormat( navigator.language, { style: 'currency', currency: currencyCode } ).formatToParts( number );
- const decimal = for... | 1 | /**
* Utility functions.
*
* Site Kit by Google, Copyright 2019 Google LLC
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* https://www.apache.org/licenses/LICENSE-2.0
*
* U... | 1 | 24,671 | Two things to make the code more error-proof and simplify it: 1. To be safe, this should be: `! isUndefined( decimal ) && ! isUndefined( decimal.value )` 2. The other clause that you changed below can be combined with that since `decimal` isn't used anywhere else, and so there's no point to re-check whether it's not un... | google-site-kit-wp | js |
@@ -26,6 +26,15 @@ import "context"
// Outbound is the common interface for all outbounds
type Outbound interface {
+ // Transports returns the transports that used by this outbound, so they
+ // can be collected for lifecycle management, typically by a Dispatcher.
+ //
+ // Though most outbounds only use a single ... | 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 | 11,565 | Wouldn't composite outbounds compose the transport, such that it would still be represented as a single transport? | yarpc-yarpc-go | go |
@@ -28,6 +28,7 @@ import (
func testAlertmanagerInstanceNamespacesAllNs(t *testing.T) {
ctx := framework.NewTestCtx(t)
+
defer ctx.Cleanup(t)
// create 3 namespaces: | 1 | // Copyright 2019 The prometheus-operator 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 | 16,319 | nit: there is no need for a new line here, usually we tend to put an object creation and its deferred deletion next to each other. It helps not forgetting about the cleanup. | prometheus-operator-prometheus-operator | go |
@@ -7,6 +7,12 @@ use JavierEguiluz\Bundle\EasyAdminBundle\Exception\EntityNotFoundException;
use Symfony\Component\EventDispatcher\GenericEvent;
use Symfony\Component\HttpFoundation\Request;
+/**
+ * Adds some custom attributes to the request object to store information
+ * related to EasyAdmin.
+ *
+ * @author Max... | 1 | <?php
namespace JavierEguiluz\Bundle\EasyAdminBundle\EventListener;
use Doctrine\Bundle\DoctrineBundle\Registry;
use JavierEguiluz\Bundle\EasyAdminBundle\Exception\EntityNotFoundException;
use Symfony\Component\EventDispatcher\GenericEvent;
use Symfony\Component\HttpFoundation\Request;
class RequestPostInitializeLis... | 1 | 9,211 | Feel free to use the full notation with my email address: `Maxime Steinhausser <maxime.steinhausser@gmail.com>` :smile: | EasyCorp-EasyAdminBundle | php |
@@ -44,7 +44,6 @@ const FCGINullRequestID uint8 = 0
// FCGIKeepConn describes keep connection mode.
const FCGIKeepConn uint8 = 1
-const doubleCRLF = "\r\n\r\n"
const (
// BeginRequest is the begin request flag. | 1 | // Forked Jan. 2015 from http://bitbucket.org/PinIdea/fcgi_client
// (which is forked from https://code.google.com/p/go-fastcgi-client/)
// This fork contains several fixes and improvements by Matt Holt and
// other contributors to this project.
// Copyright 2012 Junqing Tan <ivan@mysqlab.net> and The Go Authors
// U... | 1 | 9,353 | This was unused across the codebase | caddyserver-caddy | go |
@@ -2278,7 +2278,8 @@ func (js *jetStream) processConsumerAssignment(ca *consumerAssignment) {
acc, err := s.LookupAccount(ca.Client.serviceAccount())
if err != nil {
- // TODO(dlc) - log error
+ js.mu.Unlock()
+ s.Warnf("Account lookup for consumer create failed: %v", err)
return
}
| 1 | // Copyright 2020-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,895 | Should we put in which account we were trying to look up? | nats-io-nats-server | go |
@@ -55,6 +55,7 @@ class InventoryTypeClass(object):
RESOURCE = 'resource'
IAM_POLICY = 'iam_policy'
GCS_POLICY = 'gcs_policy'
+ Supported_TypeClass = [RESOURCE, IAM_POLICY, GCS_POLICY]
class InventoryIndex(BASE): | 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 | 28,012 | either SUPPORTED_TYPECLASS or supported_typeclass. Camelcase only for class names. | forseti-security-forseti-security | py |
@@ -31,6 +31,7 @@ CREATE TABLE notes (
is_todo INT NOT NULL DEFAULT 0,
todo_due INT NOT NULL DEFAULT 0,
todo_completed INT NOT NULL DEFAULT 0,
+ pinned INT NOT NULL DEFAULT 0,
source TEXT NOT NULL DEFAULT "",
source_application TEXT NOT NULL DEFAULT "",
application_data TEXT NOT NULL DEFAULT "", | 1 | const { promiseChain } = require('lib/promise-utils.js');
const { Database } = require('lib/database.js');
const { sprintf } = require('sprintf-js');
const Resource = require('lib/models/Resource');
const { shim } = require('lib/shim.js');
const structureSql = `
CREATE TABLE folders (
id TEXT PRIMARY KEY,
title TEXT... | 1 | 13,394 | This is not going to work. You need to add a migration to the database. | laurent22-joplin | js |
@@ -308,6 +308,7 @@ class Manager {
* @param {Object} apiClient The ApiClient.
*/
resumeGroupPlayback(apiClient) {
+ // TODO: rename this method, it's not clear what it does.
this.followGroupPlayback(apiClient).then(() => {
this.queueCore.startPlayback(apiClient);
... | 1 | /**
* Module that manages the SyncPlay feature.
* @module components/syncPlay/core/Manager
*/
import { Events } from 'jellyfin-apiclient';
import * as Helper from './Helper';
import TimeSyncCore from './timeSync/TimeSyncCore';
import PlaybackCore from './PlaybackCore';
import QueueCore from './QueueCore';
import Co... | 1 | 18,945 | Should these methods be renamed in this PR? | jellyfin-jellyfin-web | js |
@@ -154,6 +154,18 @@ namespace OpenTelemetry.Metrics
{
var metricStreamConfig = metricStreamConfigs[i];
var metricStreamName = metricStreamConfig?.Name ?? instrument.Name;
+
+ if (!MeterProviderBuilderSdk.IsVal... | 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 | 21,982 | we need to include the `metricStreamName` which is invalid, so users know whats causing the issue. | open-telemetry-opentelemetry-dotnet | .cs |
@@ -93,8 +93,10 @@ namespace Microsoft.VisualStudio.TestPlatform.ObjectModel.Navigation
var pdbFilePath = Path.ChangeExtension(binaryPath, ".pdb");
using (var pdbReader = new PortablePdbReader(new FileHelper().GetStream(pdbFilePath, FileMode.Open, FileAccess.Read)))
{
... | 1 | // Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT license. See LICENSE file in the project root for full license information.
namespace Microsoft.VisualStudio.TestPlatform.ObjectModel.Navigation
{
#if !NET46
using System;
using System.Collections.Generic;
using System.... | 1 | 11,704 | Please run Platform tests `DiaSessionTests`. | microsoft-vstest | .cs |
@@ -741,6 +741,7 @@ read_evex(byte *pc, decode_info_t *di, byte instr_byte,
return pc;
}
*is_evex = true;
+ SYSLOG_INTERNAL_WARNING_ONCE(MSG_AVX_512_SUPPORT_INCOMPLETE_STRING " @" PFX, pc);
info = &evex_prefix_extensions[0][1];
} else {
/* not evex */ | 1 | /* **********************************************************
* Copyright (c) 2011-2019 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 | 16,978 | This is debug-build-only: we want a release-build notice. SYSLOG takes the name w/o the MSG and no _STRING. Args are via events.mc specifiers. | DynamoRIO-dynamorio | c |
@@ -37,6 +37,10 @@ function matchesParentDomain(srvAddress, parentDomain) {
function parseSrvConnectionString(uri, options, callback) {
const result = URL.parse(uri, true);
+ if (options.directConnection || options.directconnection) {
+ return callback(new MongoParseError('directConnection not supported with ... | 1 | 'use strict';
const URL = require('url');
const qs = require('querystring');
const dns = require('dns');
const ReadPreference = require('./read_preference');
const { MongoParseError } = require('./error');
/**
* The following regular expression validates a connection string and breaks the
* provide string into the f... | 1 | 17,596 | is it possible to have both forms here? I was hoping we wouldn't be introducing more cases where we had to check the upper and lowercase version of URI options. | mongodb-node-mongodb-native | js |
@@ -230,11 +230,11 @@ func BenchmarkFloat64LastValueAdd(b *testing.B) {
// Histograms
-func benchmarkInt64HistogramAdd(b *testing.B, name string) {
+func BenchmarkInt64HistogramAdd(b *testing.B) {
ctx := context.Background()
fix := newFixture(b)
labs := makeLabels(1)
- mea := fix.meterMust().NewInt64Histogra... | 1 | // 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/licenses/LICENSE-2.0
//
// Unless required by applicable law or agre... | 1 | 17,198 | Does the name suffix hardcode something? Not clear how changing the name fixes this. | open-telemetry-opentelemetry-go | go |
@@ -39,4 +39,14 @@ public interface JmxExecutorManagerMBean {
@DisplayName("OPERATION: getPrimaryExecutorHostPorts")
public List<String> getPrimaryExecutorHostPorts();
+
+ @DisplayName("OPERATION: isQueueProcessorActive")
+ public boolean isQueueProcessorActive();
+
+ @DisplayName("OPERATION: getUndispatched... | 1 | /*
* Copyright 2014 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,615 | Is undispatched same as queued? getQueuedFlows? | azkaban-azkaban | java |
@@ -1,5 +1,5 @@
/**
- * core/site data store: connection info tests.
+ * Core site data store: connection info tests.
*
* Site Kit by Google, Copyright 2020 Google LLC
* | 1 | /**
* core/site data store: connection info tests.
*
* 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/li... | 1 | 32,207 | See above, same for all similar cases below. | google-site-kit-wp | js |
@@ -80,13 +80,14 @@ func TestSingleImageImportLoggableBuilder(t *testing.T) {
uefiBootable: isUEFIDetectedValue,
biosBootable: biosBootableValue,
},
- traceLogs: traceLogs,
+ traceLogs: append(traceLogs, traceLogs...),
}
assert.Equal(t, expected, NewSingleImageImp... | 1 | // Copyright 2020 Google 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 appl... | 1 | 12,505 | Why is this done twice? | GoogleCloudPlatform-compute-image-tools | go |
@@ -55,6 +55,11 @@ func (it *DeadlineReconciler) Reconcile(request reconcile.Request) (reconcile.Re
return reconcile.Result{}, client.IgnoreNotFound(err)
}
+ if ConditionEqualsTo(node.Status, v1alpha1.ConditionDeadlineExceed, corev1.ConditionTrue) {
+ // if this node deadline is exceed, try propagating to child... | 1 | // Copyright 2021 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 | 23,320 | This sync can ensure that the condition of the child node is consistent with the parent node, but I still don't understand when the child will be overwritten, and this behavior is not what we expected? | chaos-mesh-chaos-mesh | go |
@@ -175,8 +175,8 @@ func TestEnvironment(state *BuildState, target *BuildTarget, testDir string) Bui
if target.HasLabel("cc") {
env = append(env, "GCNO_DIR="+path.Join(RepoRoot, GenDir, target.Label.PackageName))
}
- if state.DebugTests {
- env = append(env, "DEBUG=true")
+ if state.DebugFailingTests {
+ env =... | 1 | package core
import (
"encoding/base64"
"fmt"
"os"
"path"
"runtime"
"strings"
"sync"
"github.com/thought-machine/please/src/fs"
"github.com/thought-machine/please/src/scm"
)
// A BuildEnv is a representation of the build environment that also knows how to log itself.
type BuildEnv []string
// GeneralBuildE... | 1 | 10,277 | This was renamed to avoid any confusion with the more general case of debugging via `plz debug` | thought-machine-please | go |
@@ -88,9 +88,11 @@ public class Converter {
static byte[] convertUtf8ToBytes(Object val, int prefixLength) {
requireNonNull(val, "val is null");
if (val instanceof byte[]) {
- return new String((byte[]) val).substring(0, prefixLength).getBytes(StandardCharsets.UTF_8);
+ return new String((byte[])... | 1 | /*
*
* Copyright 2017 PingCAP, Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agre... | 1 | 9,548 | String valStr = (String)val; valStr.substring(0, Math.min(valStr.length(), prefixLength)) Make it clean. | pingcap-tispark | java |
@@ -2067,9 +2067,13 @@ CheckedError Parser::ParseEnum(const bool is_union, EnumDef **dest) {
const auto strict_ascending = (false == opts.proto_mode);
EnumValBuilder evb(*this, *enum_def, strict_ascending);
EXPECT('{');
- // A lot of code generatos expect that an enum is not-empty.
- if ((is_union || Is('}')... | 1 | /*
* Copyright 2014 Google 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 applica... | 1 | 17,150 | Sorry, this still makes no sense.. the value of any union or enum is simply a name integer constant, it has nothing to do with the `BASE_TYPE_` enum. This value should be `0`. In particular: `Every union has the NONE field, which always has value 0`. | google-flatbuffers | java |
@@ -38,4 +38,6 @@ public interface Alerter {
void alertOnFailedExecutorHealthCheck(Executor executor,
List<ExecutableFlow> executions,
ExecutorManagerException e, List<String> alertEmails);
+
+ String getAzkabanURL();
} | 1 | /*
* Copyright 2014 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 | 22,480 | Looks like getAzkabanURL() is added after concrete Alerter (Emailer)::getAzkabanURL(), so that Override annotation is needed. | azkaban-azkaban | java |
@@ -316,6 +316,8 @@ class BaseDetector(nn.Module, metaclass=ABCMeta):
i = int(i)
color_mask = color_masks[labels[i]]
mask = segms[i]
+ if mask.dtype != np.bool:
+ mask = np.array(mask, dtype=bool)
img[mask] = img[mask]... | 1 | from abc import ABCMeta, abstractmethod
from collections import OrderedDict
import mmcv
import numpy as np
import torch
import torch.distributed as dist
import torch.nn as nn
from mmcv.runner import auto_fp16
from mmcv.utils import print_log
from mmdet.utils import get_root_logger
class BaseDetector(nn.Module, meta... | 1 | 21,536 | The above 3 lines can be written as: `mask = segms[i].astype(bool)` | open-mmlab-mmdetection | py |
@@ -27,6 +27,7 @@ import (
"github.com/iotexproject/iotex-core/pkg/log"
"github.com/iotexproject/iotex-core/pkg/util/byteutil"
"github.com/iotexproject/iotex-core/protogen/iotexapi"
+ "github.com/iotexproject/iotex-address/address"
)
// Flags | 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 | 17,623 | File is not `gofmt`-ed with `-s` (from `gofmt`) | iotexproject-iotex-core | go |
@@ -631,7 +631,10 @@ void nano::node::start ()
{
network.port = bootstrap.port;
}
+
+ logger.always_log (boost::str (boost::format ("Node started with peering port `%1%`.") % network.port));
}
+
if (!flags.disable_backup)
{
backup_wallet (); | 1 | #include <nano/lib/threading.hpp>
#include <nano/lib/tomlconfig.hpp>
#include <nano/lib/utility.hpp>
#include <nano/node/common.hpp>
#include <nano/node/daemonconfig.hpp>
#include <nano/node/node.hpp>
#include <nano/node/rocksdb/rocksdb.hpp>
#include <nano/node/telemetry.hpp>
#include <nano/node/websocket.hpp>
#include... | 1 | 17,075 | Thought it's good to have this logged down so that we can check the used value in the logs. | nanocurrency-nano-node | cpp |
@@ -83,7 +83,8 @@ type AWSMachineSpec struct {
// AWSMachineStatus defines the observed state of AWSMachine
type AWSMachineStatus struct {
// Ready is true when the provider resource is ready.
- Ready *bool `json:"ready,omitempty"`
+ // +optional
+ Ready bool `json:"ready"`
// Addresses contains the AWS instanc... | 1 | /*
Copyright 2019 The Kubernetes Authors.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, ... | 1 | 10,056 | I don't think you can call this optional unless it's a pointer - remove this? | kubernetes-sigs-cluster-api-provider-aws | go |
@@ -116,6 +116,11 @@ public class OfflineEditFragment extends BaseFragment {
@OnClick(R.id.buttonSendAll)
protected void onSendAllProducts() {
+ List<SendProduct> listSaveProduct = SendProduct.listAll(SendProduct.class);
+ if (listSaveProduct.size() == 0) {
+ Toast.makeText(getActiv... | 1 | package openfoodfacts.github.scrachx.openfood.fragments;
import android.content.Context;
import android.content.Intent;
import android.content.SharedPreferences;
import android.graphics.Bitmap;
import android.os.AsyncTask;
import android.os.Bundle;
import android.support.annotation.NonNull;
import android.support.anno... | 1 | 62,326 | @naofum please use `isEmpty`method instead | openfoodfacts-openfoodfacts-androidapp | java |
@@ -280,12 +280,12 @@ bool gen_jit_and_run(compile_t* c, int* exit_code, jit_symbol_t* symbols,
auto resolver = orc::createLambdaResolver(local_lookup, external_lookup);
#if PONY_LLVM >= 500
- auto maybe_handle = compile_layer.addModule(module, resolver);
+ auto nullable_handle = compile_layer.addModule(module,... | 1 | #include "genjit.h"
#include "genexe.h"
#include "genopt.h"
#if PONY_LLVM >= 700
#include "llvm_config_begin.h"
# include <llvm/ExecutionEngine/ExecutionEngine.h>
# include <llvm/ExecutionEngine/JITSymbol.h>
# include <llvm/ExecutionEngine/SectionMemoryManager.h>
# include <llvm/ExecutionEngine/Orc/CompileUtils.h... | 1 | 13,854 | i think this is unrelated and needs to be reverted. need to discuss at sync. | ponylang-ponyc | c |
@@ -19,8 +19,10 @@ import org.hyperledger.besu.datatypes.Hash;
import java.util.Optional;
+import org.apache.tuweni.bytes.Bytes;
+
/** A block header capable of being processed. */
-public class ProcessableBlockHeader {
+public class ProcessableBlockHeader implements org.hyperledger.besu.plugin.data.BlockHeader {... | 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 | 25,984 | Are we eventually moving those type interfaces from plugin project to datatype project? If not, then we'd have a dependency from core onto plugins, which seems a little counter-intuitive to me. | hyperledger-besu | java |
@@ -1372,6 +1372,14 @@ Connection.prototype.setClient = function setClient(client) {
return this;
};
+Connection.prototype.syncIndexes = async function syncIndexes() {
+ const result = [];
+ for (const model in this.models) {
+ result.push(await this.model(model).syncIndexes());
+ }
+ return result;
+};
+
... | 1 | 'use strict';
/*!
* Module dependencies.
*/
const ChangeStream = require('./cursor/ChangeStream');
const EventEmitter = require('events').EventEmitter;
const Schema = require('./schema');
const Collection = require('./driver').get().Collection;
const STATES = require('./connectionstate');
const MongooseError = requ... | 1 | 14,830 | Love how we can finally use async/await in the codebase. | Automattic-mongoose | js |
@@ -3531,6 +3531,7 @@ void nano::rpc_handler::wallet_representative_set ()
{
rpc_control_impl ();
auto wallet (wallet_impl ());
+ bool update_existing_accounts (request.get<bool> ("update_existing_accounts", false));
if (!ec)
{
std::string representative_text (request.get<std::string> ("representative")); | 1 | #include <boost/algorithm/string.hpp>
#include <nano/lib/interface.h>
#include <nano/node/node.hpp>
#include <nano/node/rpc.hpp>
#ifdef NANO_SECURE_RPC
#include <nano/node/rpc_secure.hpp>
#endif
#include <nano/lib/errors.hpp>
nano::rpc_secure_config::rpc_secure_config () :
enable (false),
verbose_logging (false)
{
}... | 1 | 14,801 | Very minor: this line could be moved to a more narrow scope, inside `if (!representative.decode_account (representative_text))` Other than that, LGTM | nanocurrency-nano-node | cpp |
@@ -40,10 +40,8 @@ type Connection struct {
// For invalid and closed connections: StopTime is the time when connection was updated last.
// For established connections: StopTime is latest time when it was polled.
StopTime time.Time
- // IsActive flag helps in cleaning up connections when they are not in conntrac... | 1 | // 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 law or agreed to... | 1 | 30,804 | when is this consumed? I'm probably missing it but I can't find it right now | antrea-io-antrea | go |
@@ -418,6 +418,10 @@ void GroupByAgg::generateCacheKey(CacheWA &cwa) const
groupExpr_.rebuildExprTree(ITM_ITEM_LIST);
if (grpExpr) {
cwa += " gBy:";
+
+ if (isRollup())
+ cwa += " roll:";
+
grpExpr->generateCacheKey(cwa);
}
} | 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 | 14,190 | I think we also need to add the rollupGroupExprList() to the cache key. If we rebuild the list above from a ValueIdSet on line 418 above, it is probably going to be in the same order, regardless whether it was ROLLUP(a,b) or ROLLUP(b,a). | apache-trafodion | cpp |
@@ -14,10 +14,15 @@
*/
package com.google.api.codegen.transformer.nodejs;
+import com.google.api.codegen.config.MethodConfig;
import com.google.api.codegen.transformer.ApiMethodParamTransformer;
import com.google.api.codegen.transformer.MethodTransformerContext;
+import com.google.api.codegen.transformer.Surface... | 1 | /* Copyright 2017 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 | 21,608 | can use `getParamTypeName` instead | googleapis-gapic-generator | java |
@@ -184,14 +184,14 @@ class AdminController extends Controller
{
$this->dispatch(EasyAdminEvents::PRE_EDIT);
- if ($this->request->isXmlHttpRequest()) {
- return $this->ajaxEdit();
- }
-
$id = $this->request->query->get('id');
$easyadmin = $this->request->attri... | 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\Controller;
use Doctrine\DBAL\... | 1 | 9,412 | Why send the parameters? They're accessible directly from `$this->request` so there's no need to inject them in the method | EasyCorp-EasyAdminBundle | php |
@@ -186,6 +186,18 @@ class BrowserPage(QWebPage):
errpage.encoding = 'utf-8'
return True
+ def chooseFile(self, parent_frame: QWebFrame, suggested_file: str):
+ """Override chooseFiles to (optionally) invoke custom file uploader."""
+ handler = config.val.fileselect.handler
... | 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 | 22,807 | Tiny nit: I would prefer `not selected_file` or `len(selected_file) == 0`, as if choose_file starts returning, for example, tuples instead of lists, this won't break. | qutebrowser-qutebrowser | py |
@@ -329,6 +329,15 @@ func (e *ETCD) join(ctx context.Context, clientAccessInfo *clientaccess.Info) er
}
for _, member := range members.Members {
+ memberNodeName := strings.Split(member.Name, "-")[0]
+ if memberNodeName == e.config.ServerNodeName {
+ // make sure to remove the name file if a duplicate node na... | 1 | package etcd
import (
"bytes"
"context"
"crypto/tls"
"encoding/json"
"fmt"
"io/ioutil"
"net/http"
"net/url"
"os"
"path/filepath"
"runtime"
"sort"
"strconv"
"strings"
"time"
"github.com/google/uuid"
"github.com/gorilla/mux"
"github.com/k3s-io/kine/pkg/client"
endpoint2 "github.com/k3s-io/kine/pkg/en... | 1 | 10,154 | How will this code behave with hostnames that contain hyphens? | k3s-io-k3s | go |
@@ -735,6 +735,15 @@ namespace pwiz.Skyline.Model
moleculeIdKeys.Add(MoleculeAccessionNumbers.TagSMILES, smiles);
}
+ var keggCol = ColumnIndex(SmallMoleculeTransitionListColumnHeaders.idKEGG);
+ var kegg = NullForEmpty(row.GetCell(keggCol));
+ if (kegg !... | 1 | /*
* Original author: Brian Pratt <bspratt .at. proteinms.net>,
* MacCoss Lab, Department of Genome Sciences, UW
*
* Copyright 2016 University of Washington - Seattle, WA
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance... | 1 | 12,796 | I think this is redundant since "NullForEmpty" already calls "Trim()". | ProteoWizard-pwiz | .cs |
@@ -317,6 +317,8 @@ type CloudBackupRestoreRequest struct {
}
type CloudBackupGroupCreateResponse struct {
+ // ID for this group of backups
+ GroupCloudBackupID string
// Names of the tasks performing this group backup
Names []string
} | 1 | package api
import (
"context"
"fmt"
"math"
"strconv"
"strings"
"time"
"github.com/golang/protobuf/ptypes"
"github.com/libopenstorage/openstorage/pkg/auth"
"github.com/mohae/deepcopy"
)
// Strings for VolumeSpec
const (
Name = "name"
Token = "token"
SpecNodes ... | 1 | 7,833 | Change this to IDs too? | libopenstorage-openstorage | go |
@@ -221,6 +221,11 @@ public class RaidsPlugin extends Plugin
@Getter
private final List<String> layoutWhitelist = new ArrayList<>();
+ @Getter
+ private final ImmutableSet<String> list_of_DC_SCOUT_RAIDS = ImmutableSet.of(
+ "SCPFCCSPCF", "CSPFCCCSSF", "SCFPCSCPCF", "PCSFCPCSCF", "SCCFCPSCSF", "SCPFCCCSSF",
+ "S... | 1 | /*
* Copyright (c) 2018, Kamiel
* Copyright (c) 2019, ganom <https://github.com/Ganom>
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the... | 1 | 15,511 | private static final, and it should be located in raidsoverlay, as it's not needed in the plugin. also the name could be a bit better, DC_SCOUT_RAIDS or similiar. | open-osrs-runelite | java |
@@ -173,7 +173,7 @@ STATIC fpga_result parse_perf_attributes(struct udev_device *dev,
globfree(&pglob);
return FPGA_EXCEPTION;
}
- if (fscanf(file, "%s", attr_value) != 1) {
+ if (fscanf(file, "%127s", attr_value) != 1) {
OPAE_ERR("Failed to read %s", pglob.gl_pathv[i]);
goto out;
} | 1 | // Copyright(c) 2021, 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 | 21,181 | attr_value is 128 bytes? | OPAE-opae-sdk | c |
@@ -54,7 +54,9 @@ class HTTPRequest(Request):
msg = "Option 'url' is mandatory for request but not found in %s" % config
self.url = self.config.get("url", TaurusConfigError(msg))
self.label = self.config.get("label", self.url)
- self.method = self.config.get("method", "GET").upper()
+ ... | 1 | """
Copyright 2017 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 applicable law or agreed to in writing, software... | 1 | 15,093 | if it's unpredictable - why uppercase it at all? | Blazemeter-taurus | py |
@@ -25,6 +25,7 @@ type KubeCloudInstTool struct {
func (cu *KubeCloudInstTool) InstallTools() error {
cu.SetOSInterface(GetOSInterface())
cu.SetKubeEdgeVersion(cu.ToolVersion)
+ fmt.Println("beforeinstallkubeedge")
err := cu.InstallKubeEdge()
if err != nil { | 1 | package util
import (
"bufio"
"bytes"
"fmt"
"io"
"io/ioutil"
"os"
"os/exec"
"strings"
"time"
"github.com/kubeedge/kubeedge/keadm/app/cmd/common"
)
//KubeCloudInstTool embedes Common struct
//It implements ToolsInstaller interface
type KubeCloudInstTool struct {
Common
}
//InstallTools downloads KubeEdge ... | 1 | 11,935 | Please remove all these debug prints. It doesn't look good. | kubeedge-kubeedge | go |
@@ -74,6 +74,7 @@ type VMContext interface {
BlockHeight() *types.BlockHeight
IsFromAccountActor() bool
Charge(cost types.GasUnits) error
+ SampleChainRandomness(sampleHeight *types.BlockHeight) ([]byte, error)
CreateNewActor(addr address.Address, code cid.Cid, initalizationParams interface{}) error
| 1 | package exec
import (
"context"
"gx/ipfs/QmNf3wujpV2Y7Lnj2hy2UrmuX8bhMDStRHbnSLh7Ypf36h/go-hamt-ipld"
"gx/ipfs/QmR8BauakNcBa3RbE4nbQu76PDiJgoQgz8AJdhJuiU4TAw/go-cid"
"github.com/filecoin-project/go-filecoin/abi"
"github.com/filecoin-project/go-filecoin/address"
"github.com/filecoin-project/go-filecoin/types"
... | 1 | 17,637 | Consumers of this interface should not be required to provide `sampleHeight`. This should be an expected consensus parameter. | filecoin-project-venus | go |
@@ -58,8 +58,14 @@ func GetBackoffForNextSchedule(cronSchedule string, startTime time.Time, closeTi
if err != nil {
return NoBackoff
}
+
+ if closeTime.Before(startTime) {
+ closeTime = startTime
+ }
+
startUTCTime := startTime.In(time.UTC)
closeUTCTime := closeTime.In(time.UTC)
+
nextScheduleTime := sche... | 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 | 9,895 | I don't believe this is the right fix. If startTime comes after closeTime, then it means some other event triggered invocation of this code path like workflow timeout. In this case we should still try to fire the cron on previous value so we should just return start the delta between startTime and closeTime immediately... | temporalio-temporal | go |
@@ -348,6 +348,10 @@ type CloudBackupGenericRequest struct {
CredentialUUID string
// All if set to true, backups for all clusters in the cloud are processed
All bool
+ // StatusFilter indicates backups based on status
+ StatusFilter CloudBackupStatusType
+ // TagFilter indicates backups based on tag
+ TagFilter ... | 1 | package api
import (
"context"
"fmt"
"math"
"strconv"
"strings"
"time"
"github.com/golang/protobuf/ptypes"
"github.com/libopenstorage/openstorage/pkg/auth"
"github.com/mohae/deepcopy"
)
// Strings for VolumeSpec
const (
Name = "name"
Token = "token"
TokenSecret ... | 1 | 8,166 | Not sure if we need tag here, it is an implementation detail in portworx that isn't exposed in openstorage | libopenstorage-openstorage | go |
@@ -50,9 +50,15 @@ class Summon extends SolrDefault
* returned as an array of chunks, increasing from least specific to most
* specific.
*
+ * @param bool $extended Whether to return a keyed array with the following
+ * keys:
+ * - heading: the actual subject heading chunks
+ * - type:... | 1 | <?php
/**
* Model for Summon records.
*
* PHP version 5
*
* Copyright (C) Villanova University 2010.
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License version 2,
* as published by the Free Software Foundation.
*
* This program is d... | 1 | 24,974 | I wonder if it would be cleaner to refactor all of this similar to the SolrMarc driver, so we have a property with Summon field names associated with types, and we iterate through it in a loop... that way we don't have to repeat the loop code four times with different variable names. | vufind-org-vufind | php |
@@ -261,7 +261,7 @@ public class XCJFQuery extends Query {
}
private DocSet getDocSet() throws IOException {
- SolrClientCache solrClientCache = new SolrClientCache();
+ SolrClientCache solrClientCache = searcher.getCore().getCoreContainer().getSolrClientCache();
TupleStream solrStream;
... | 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 | 34,145 | Need the `solrClientCache.close();` further down in the method be removed since a shared cache is now used? | apache-lucene-solr | java |
@@ -38,6 +38,9 @@ type (
ClusterMetadataRow struct {
ImmutableData []byte
ImmutableDataEncoding string
+ Data []byte
+ DataEncoding string
+ Version int64
}
// ClusterMembershipRow represents a row in the cluster_membership table | 1 | // The MIT License
//
// Copyright (c) 2020 Temporal Technologies Inc. All rights reserved.
//
// 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 limit... | 1 | 10,332 | according to the PR (schema changes?) these 2 field should be removed? | temporalio-temporal | go |
@@ -373,16 +373,13 @@ func (s *Service) createStressChaos(exp *core.ExperimentInfo, kubeCli client.Cli
Mode: v1alpha1.PodMode(exp.Scope.Mode),
Value: exp.Scope.Value,
},
+ ContainerNames: exp.Target.StressChaos.ContainerNames,
},
Stressors: stressors,
StressngStressors: ex... | 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 | 24,170 | Panic here if `exp.Target.StressChaos.CintainerName` is nil. | chaos-mesh-chaos-mesh | go |
@@ -93,4 +93,16 @@ public interface LeafCollector {
*/
void collect(int doc) throws IOException;
+ /**
+ * Optionally creates a view of the scorerIterator where only competitive documents
+ * in the scorerIterator are kept and non-competitive are skipped.
+ *
+ * Collectors should delegate this method... | 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 | 33,207 | This allows for some hacks like returning an iterator that matches more docs than the scorer. I liked the previous approach that returned an iterator better. | apache-lucene-solr | java |
@@ -227,6 +227,7 @@ public class IcebergInputFormat<T> extends InputFormat<Void, T> {
private CloseableIterable<T> open(FileScanTask currentTask, Schema readSchema) {
DataFile file = currentTask.file();
+ LOG.debug("Opening [{}] for read", file);
// TODO we should make use of FileIO to create ... | 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 | 23,827 | Aren't there already logs for this from the underlying file system implementation? | apache-iceberg | java |
@@ -75,7 +75,7 @@ class SearchHandlerTest extends TestCase
{
$spec = ['DismaxParams' => [['foo', 'bar'], ['mm', '100%']], 'DismaxFields' => ['field1', 'field2']];
$hndl = new SearchHandler($spec);
- $defaults = ['CustomMunge' => [], 'DismaxHandler' => 'dismax', 'QueryFields' => [], 'Filter... | 1 | <?php
/**
* Unit tests for SOLR search handler.
*
* PHP version 7
*
* Copyright (C) Villanova University 2010.
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License version 2,
* as published by the Free Software Foundation.
*
* This p... | 1 | 28,039 | It would be good to have a test in here that demonstrates the new munge functionality; I can help set that up if you're not sure how. | vufind-org-vufind | php |
@@ -62,6 +62,9 @@ class kubernetes(luigi.Config):
kubernetes_namespace = luigi.OptionalParameter(
default=None,
description="K8s namespace in which the job will run")
+ max_retrials_to_get_pods = luigi.IntParameter(
+ default=0,
+ description="Max retrials to get pods' informatio... | 1 | # -*- coding: utf-8 -*-
#
# Copyright 2015 Outlier Bio, 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
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable la... | 1 | 19,135 | `retrials` isn't the word you intend. I think you mean `retries` and to that end, can the var name just be `max_retries`? | spotify-luigi | py |
@@ -213,6 +213,7 @@ class Shopware6ChannelForm extends AbstractType
AttributeIdType::class,
[
'label' => 'Attribute Product Meta Title',
+ 'help' => 'Value in product it should contain 255 characters or less.',
'choices' => a... | 1 | <?php
/**
* Copyright © Bold Brand Commerce Sp. z o.o. All rights reserved.
* See LICENSE.txt for license details.
*/
declare(strict_types=1);
namespace Ergonode\ExporterShopware6\Application\Form;
use Ergonode\Attribute\Application\Form\Type\AttributeIdType;
use Ergonode\Attribute\Domain\Entity\Attribute\Gallery... | 1 | 9,273 | Value in product should contain 255 characters or less. | ergonode-backend | php |
@@ -169,12 +169,12 @@ func main() {
logger.Error().Msg(fmt.Sprintf("Node %d: Can not get State height", i))
}
bcHeights[i] = chains[i].TipHeight()
- minTimeout = int(configs[i].Consensus.RollDPoS.Delay/time.Second - configs[i].Consensus.RollDPoS.ProposerInterval/time.Second)
+ minTimeout = int(configs[... | 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,366 | line is 133 characters (from `lll`) | iotexproject-iotex-core | go |
@@ -78,7 +78,7 @@ module RSpec
end
def file_options
- custom_options_file ? [custom_options] : [global_options, local_options]
+ custom_options_file ? [custom_options] : [global_options, local_options, personal_options]
end
def env_options | 1 | require 'erb'
require 'shellwords'
module RSpec
module Core
# @private
class ConfigurationOptions
attr_reader :options
def initialize(args)
@args = args
if args.include?("--default_path")
args[args.index("--default_path")] = "--default-path"
end
if args... | 1 | 8,258 | since we're calling the file .rspec-local, I think we should rename local_options to project_options and use local_options for .rspec-local - WDYT? | rspec-rspec-core | rb |
@@ -52,7 +52,7 @@ module Blacklight::Solr
protected
def build_connection
- RSolr.connect(connection_config)
+ RSolr.connect(connection_config.merge(adapter: connection_config[:http_adapter]))
end
end
end | 1 | # frozen_string_literal: true
module Blacklight::Solr
class Repository < Blacklight::AbstractRepository
##
# Find a single solr document result (by id) using the document configuration
# @param [String] id document's unique key value
# @param [Hash] params additional solr query parameters
def find... | 1 | 6,923 | Will we want to refactor this when we drop rsolr 1.x support? | projectblacklight-blacklight | rb |
@@ -63,7 +63,7 @@ func Request(path string, info *clientaccess.Info, requester HTTPRequester) ([]b
return requester(u.String(), clientaccess.GetHTTPClient(info.CACerts), username, password)
}
-func getNodeNamedCrt(nodeName, nodePasswordFile string) HTTPRequester {
+func getNodeNamedCrt(nodeName, nodeIP, nodePasswo... | 1 | package config
import (
"bufio"
"context"
cryptorand "crypto/rand"
"crypto/tls"
"encoding/hex"
"encoding/pem"
"fmt"
"io/ioutil"
sysnet "net"
"net/http"
"net/url"
"os"
"os/exec"
"path/filepath"
"regexp"
"strings"
"time"
"github.com/pkg/errors"
"github.com/rancher/k3s/pkg/agent/proxy"
"github.com/ra... | 1 | 8,523 | should this really be multiple IPs? | k3s-io-k3s | go |
@@ -0,0 +1 @@
+<%= render partial: "proposal", locals: { proposal: @proposal} %> | 1 | 1 | 12,872 | Hmm, is that partial used in multiple places? Maybe we can just move that file in here. | 18F-C2 | rb | |
@@ -0,0 +1,16 @@
+// 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/
... | 1 | 1 | 14,257 | Should be 2014-2016 | aws-amazon-ecs-agent | go | |
@@ -1976,6 +1976,11 @@ namespace pwiz.Skyline.Model
private static Type GetColumnType(string value, IFormatProvider provider)
{
double result;
+ var quote = @"""";
+ if (value.StartsWith(quote) && value.EndsWith(quote))
+ {
+ value = value.S... | 1 | /*
* Original author: Brendan MacLean <brendanx .at. u.washington.edu>,
* MacCoss Lab, Department of Genome Sciences, UW
*
* Copyright 2009 University of Washington - Seattle, WA
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in com... | 1 | 14,348 | Looks like my fault for sure in trying to handle international inputs regardless of locale. I think the correct fix is actually to get rid of TrySplitColumns and use ParseDsvFields instead. It is what gets used in the end, and it already has logic for dealing with quoted fields. | ProteoWizard-pwiz | .cs |
@@ -2733,6 +2733,7 @@ describe('Find', function() {
cursors[0].next(function(err) {
test.equal(null, err);
+ cursors[0].close();
client.close();
done();
}); | 1 | 'use strict';
var test = require('./shared').assert;
var setupDatabase = require('./shared').setupDatabase;
describe('Find', function() {
before(function() {
return setupDatabase(this.configuration);
});
/**
* Test a simple find
* @ignore
*/
it('shouldCorrectlyPerformSimpleFind', {
metadata: ... | 1 | 14,197 | similarly here, are the these cursors not being closed when the client is closed? | mongodb-node-mongodb-native | js |
@@ -22,7 +22,7 @@ import (
)
var (
- supportedPolicies = make(map[string]func() Policy)
+ supportedPolicies = make(map[string]func(string) Policy)
)
type staticUpstream struct { | 1 | package proxy
import (
"bytes"
"fmt"
"io"
"io/ioutil"
"net"
"net/http"
"net/url"
"path"
"strconv"
"strings"
"sync"
"sync/atomic"
"time"
"crypto/tls"
"github.com/mholt/caddy/caddyfile"
"github.com/mholt/caddy/caddyhttp/httpserver"
)
var (
supportedPolicies = make(map[string]func() Policy)
)
type st... | 1 | 11,146 | Or maybe `func(args ...string) Policy` to make it dynamic in case of any future policy that may require more than one args. | caddyserver-caddy | go |
@@ -36,6 +36,7 @@ func serviceLoggedIn(ctx context.Context, config Config, session SessionInfo,
log.CWarningf(ctx,
"Failed to enable existing journals: %v", err)
}
+ jServer.MakeFBOsForExistingJournals(ctx)
}
err := config.MakeDiskBlockCacheIfNotExists()
if err != nil { | 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 (
"github.com/keybase/client/go/libkb"
"golang.org/x/net/context"
)
// EnableAdminFeature returns true if admin features should be enabled
// ... | 1 | 19,793 | Should this happen even if the above failed? | keybase-kbfs | go |
@@ -1,5 +1,5 @@
/*
-Copyright 2017 The OpenEBS Authors.
+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. | 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 | 10,764 | Please dont change this . | openebs-maya | go |
@@ -382,7 +382,7 @@ void nano::active_transactions::cleanup_election (nano::unique_lock<nano::mutex>
node.network.publish_filter.clear (block);
}
}
- node.logger.try_log (boost::str (boost::format ("Election erased for root %1%") % election.qualified_root.to_string ()));
+ node.logger.try_log (boost::str (boos... | 1 | #include <nano/lib/threading.hpp>
#include <nano/node/active_transactions.hpp>
#include <nano/node/confirmation_height_processor.hpp>
#include <nano/node/confirmation_solicitor.hpp>
#include <nano/node/election.hpp>
#include <nano/node/node.hpp>
#include <nano/node/repcrawler.hpp>
#include <nano/secure/store.hpp>
#inc... | 1 | 17,001 | There is a strange $b that looks wrong. | nanocurrency-nano-node | cpp |
@@ -1166,12 +1166,16 @@ def getControlFieldSpeech(attrs,ancestorAttrs,fieldType,formatConfig=None,extraD
# speakStatesFirst: Speak the states before the role.
speakStatesFirst=role==controlTypes.ROLE_LINK
+ containerContainsText="" #: used for item counts for lists
+
# Determine what text to speak.
# Special ... | 1 | # -*- coding: UTF-8 -*-
#speech.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) 2006-2017 NV Access Limited, Peter Vágner, Aleksey Sadovoy, Babbage B.V.
"""High-level functions to speak information.
""... | 1 | 22,841 | Is it still important to have `speakEntry` here? It is checked before this value `containerContainsText` is used in the "General" section. | nvaccess-nvda | py |
@@ -18,6 +18,7 @@ module Travis
CLEANUPS.each do |find_arg|
sh.raw "find #{find_arg[:directory]} -name #{find_arg[:glob]} -delete 2>/dev/null"
end
+ sh.export 'PATH', '$JAVA_HOME:$PATH'
end
def install | 1 | module Travis
module Build
class Script
class Jvm < Script
include Jdk
DEFAULTS = {
jdk: 'default'
}
CLEANUPS = [
{ directory: '$HOME/.ivy2', glob: "ivydata-*.properties"},
{ directory: '$HOME/.sbt', glob: "*.lock"}
]
def setu... | 1 | 15,562 | It is `$JAVA_HOME/bin`, not `$JAVA_HOME`, which should be added. | travis-ci-travis-build | rb |
@@ -9,6 +9,7 @@ bool generate_uuid(char out[static 37]) {
return true;
}
#else
+#include <assert.h>
#include <string.h>
#include <stdlib.h>
| 1 | #include <uuid.h>
#include "util/uuid.h"
#if HAS_LIBUUID
bool generate_uuid(char out[static 37]) {
uuid_t uuid;
uuid_generate_random(uuid);
uuid_unparse(uuid, out);
return true;
}
#else
#include <string.h>
#include <stdlib.h>
bool generate_uuid(char out[static 37]) {
uuid_t uuid;
uint32_t status;
uuid_create(&... | 1 | 16,556 | Should move this to within the `#else` block as it's only used there. | swaywm-wlroots | c |
@@ -41,6 +41,9 @@ class ProductListPage extends AbstractPage
$context = $this->getProductListCompomentContext();
$this->productListComponent->addProductToCartByName($productName, $quantity, $context);
+
+ $this->tester->waitForAjax();
+ $this->tester->wait(1);
}
/** | 1 | <?php
declare(strict_types=1);
namespace Tests\App\Acceptance\acceptance\PageObject\Front;
use Facebook\WebDriver\WebDriverBy;
use PHPUnit\Framework\Assert;
use Tests\App\Acceptance\acceptance\PageObject\AbstractPage;
use Tests\App\Test\Codeception\AcceptanceTester;
use Tests\App\Test\Codeception\Module\StrictWebDri... | 1 | 23,539 | is this a common rule to wait one extra second after ajax? I'm thinking about moving this extra wait into waitForAjax method. | shopsys-shopsys | php |
@@ -94,8 +94,8 @@ abstract class AbstractSolrTask extends AbstractTask {
public function __sleep()
{
$properties = get_object_vars($this);
- // avoid serialization if the site object
- unset($properties['site']);
+ // avoid serialization if the site and logger object
+ uns... | 1 | <?php
namespace ApacheSolrForTypo3\Solr\Task;
/***************************************************************
* Copyright notice
*
* (c) 2017 Timo Hund <timo.hund@dkd.de>
* All rights reserved
*
* This script is part of the TYPO3 project. The TYPO3 project is
* free software; you can redistribute it and/o... | 1 | 6,581 | Maybe you can correct the typo "if" too :) | TYPO3-Solr-ext-solr | php |
@@ -298,6 +298,9 @@ type KeybaseService interface {
// popups spawned.
Identify(ctx context.Context, assertion, reason string) (UserInfo, error)
+ IdentifyForChat(ctx context.Context, assertion, reason string) (
+ UserInfo, *keybase1.IdentifyTrackBreaks, error)
+
// LoadUserPlusKeys returns a UserInfo struct f... | 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 (
"time"
"github.com/keybase/client/go/libkb"
"github.com/keybase/client/go/logger"
"github.com/keybase/client/go/protocol/keybase1"
"githu... | 1 | 13,682 | I'd prefer a name less chat-specific, since later on we could have other app types that want the same behavior. Maybe `IdentifyAndAllowTrackBreaks`? | keybase-kbfs | go |
@@ -51,10 +51,18 @@ public:
*/
bool load(handle src, bool)
{
+ // Import mpi4py if it does not exist.
+ if (!PyMPIComm_Get)
+ {
+ if (import_mpi4py() < 0)
+ {
+ throw std::runtime_error(
+ "ERROR: mpi4py not loaded correctl... | 1 | /*
* Distributed under the OSI-approved Apache License, Version 2.0. See
* accompanying file Copyright.txt for details.
*
* py11glue.cpp
*
* Created on: Mar 16, 2017
* Author: William F Godoy godoywf@ornl.gov
*/
#include <pybind11/pybind11.h>
#include <pybind11/stl.h>
#include <stdexcept>
#include <ad... | 1 | 12,824 | I think I was involved in writing that caster, but I never fully understood the `import_mpi4py` thing. Why is importing mpi4py still necessary at that point? I would think if the user is passing a communicator from python code, they must already have imported mpi4py themselves, or does that not propagate through into t... | ornladios-ADIOS2 | cpp |
@@ -142,13 +142,14 @@ func (cache *httpCache) retrieve(target *core.BuildTarget, key []byte) (bool, er
resp, err := cache.client.Do(req)
if err != nil {
return false, err
- } else if resp.StatusCode == http.StatusNotFound {
+ }
+ defer resp.Body.Close()
+ if resp.StatusCode == http.StatusNotFound {
return fal... | 1 | // Http-based cache.
package cache
import (
"archive/tar"
"compress/gzip"
"encoding/hex"
"fmt"
"io"
"io/ioutil"
"net/http"
"os"
"path"
"time"
"github.com/thought-machine/please/src/core"
"github.com/thought-machine/please/src/fs"
)
type httpCache struct {
url string
writable bool
client *http.... | 1 | 9,192 | This seems like a more interesting change. Maybe we should re-name the PR | thought-machine-please | go |
@@ -20,6 +20,8 @@ namespace Microsoft.AspNetCore.Server.Kestrel.Transport.Abstractions.Internal
IApplicationTransportFeature,
ITransportSchedulerFeature,
IConnectionLifetimeFea... | 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.Buffers;
using System.Collections.Generic;
using System.IO.Pipelines;
using System.Net;
using System.Threading;
using System.Threading.Tas... | 1 | 16,402 | Nit: implement the methods for these interfaces explicitly in this file for consistency. It can be passthrough. | aspnet-KestrelHttpServer | .cs |
@@ -102,6 +102,7 @@ public class CSharpCommonTransformer {
.typeName(typeName)
.setCallName("")
.addCallName("")
+ .getCallName("")
.isMap(false)
.isArray(false)
.isPrimitive(false) | 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 | 22,326 | Not directly related to your PR, but I think here we should create a Type enum (MAP, ARRAY, PRIMITIVE) instead of having 3 flags. | googleapis-gapic-generator | java |
@@ -444,6 +444,7 @@ ExWorkProcRetcode ExHbaseScanSQTaskTcb::work(short &rc)
Lng32 retcode = 0;
rc = 0;
Lng32 remainingInBatch = batchSize_;
+ NABoolean isFirstBatch = false;
while (1)
{ | 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 | 10,970 | Do you want this to be a stack variable? The work method might return at any time (example: when the parent queue fills up) and then get called again, which would cause this variable to become false again. I'm wondering if this variable should be a member instead? | apache-trafodion | cpp |
@@ -116,6 +116,14 @@ nebula::cpp2::HostAddr MetaServiceUtils::parseHostKey(folly::StringPiece key) {
return host;
}
+std::string MetaServiceUtils::schemaEdgesPrefix(GraphSpaceID spaceId) {
+ std::string key;
+ key.reserve(kEdgesTable.size() + sizeof(GraphSpaceID));
+ key.append(kEdgesTable.data(), kEdg... | 1 | /* Copyright (c) 2018 - present, VE Software Inc. All rights reserved
*
* This source code is licensed under Apache 2.0 License
* (found in the LICENSE.Apache file in the root directory)
*/
#include "meta/MetaServiceUtils.h"
#include <thrift/lib/cpp2/protocol/Serializer.h>
#include <thrift/lib/cpp2/protocol/Compa... | 1 | 16,353 | You could reserve a const space to save the extra computation. | vesoft-inc-nebula | cpp |
@@ -15,6 +15,8 @@ namespace System.IO.Tests
private readonly string _testPath200 = PerfUtils.CreateString(200);
private readonly string _testPath500 = PerfUtils.CreateString(500);
private readonly string _testPath1000 = PerfUtils.CreateString(1000);
+ private readonly string _testPathN... | 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 BenchmarkDotNet.Attributes;
using MicroBenchmarks;
namespace System.IO.Tests
{
[BenchmarkCategory(Categor... | 1 | 11,690 | Did you consider adding rooted paths like `C:\ProgramData` and paths with flipped separators? | dotnet-performance | .cs |
@@ -93,10 +93,11 @@ func startDnsServer() {
Port: 53,
}
udpConn, err := net.ListenUDP("udp", laddr)
- defer udpConn.Close()
if err != nil {
klog.Errorf("Dns server Start error : %s", err)
+ return
}
+ defer udpConn.Close()
dnsConn = udpConn
for {
req := make([]byte, bufSize) | 1 | package server
import (
"bufio"
"encoding/binary"
"errors"
"fmt"
"net"
"os"
"strings"
"time"
"unsafe"
"k8s.io/klog"
"github.com/kubeedge/beehive/pkg/core/context"
"github.com/kubeedge/kubeedge/edge/pkg/metamanager/client"
"github.com/kubeedge/kubeedge/edgemesh/pkg/common"
"github.com/kubeedge/kubeedge/... | 1 | 14,321 | does this line cause a panic if it is above the if condition ? | kubeedge-kubeedge | go |
@@ -0,0 +1,5 @@
+package org.phoenicis.javafx.components.library.utils;
+
+public enum LibraryDetailsPanels {
+ ShortcutDetails, ShortcutCreation, ShortcutEditing, Closed;
+} | 1 | 1 | 13,547 | Maybe `LibraryDetailsPanelType` would be clearer. | PhoenicisOrg-phoenicis | java | |
@@ -149,7 +149,6 @@ static void runlevel_cb (runlevel_t *r, int level, int rc, double elapsed,
static void runlevel_io_cb (runlevel_t *r, const char *name,
const char *msg, void *arg);
-static int create_persistdir (attr_t *attrs, uint32_t rank);
static int create_rundir (attr_t *attrs)... | 1 | /************************************************************\
* Copyright 2014 Lawrence Livermore National Security, LLC
* (c.f. AUTHORS, NOTICE.LLNS, COPYING)
*
* This file is part of the Flux resource manager framework.
* For details, see https://github.com/flux-framework.
*
* SPDX-License-Identifier: LGPL-3.... | 1 | 26,364 | minor nit - add "persist-filesystem" and "persist-directory" into commit message, as its something people may search on (maybe applies to a few other commit messages) | flux-framework-flux-core | c |
@@ -7662,8 +7662,6 @@ bool CoreChecks::ValidateEventStageMask(const ValidationStateTracker *state_data
return skip;
}
-static const VkQueueFlagBits kQueueTypeArray[] = {VK_QUEUE_GRAPHICS_BIT, VK_QUEUE_COMPUTE_BIT, VK_QUEUE_TRANSFER_BIT};
-
bool CoreChecks::CheckStageMaskQueueCompatibility(VkCommandBuffer comma... | 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-2021 Advanced Micro Devices, Inc. All rights reserved.
*
* Licensed under the Apache License, Version 2.0 (t... | 1 | 15,070 | I verified offline with @jeremyg-lunarg this should be removed. | KhronosGroup-Vulkan-ValidationLayers | cpp |
@@ -65,6 +65,7 @@ func (i *IncludeWorkflow) populate(ctx context.Context, s *Step) DError {
i.Workflow.Logger = i.Workflow.parent.Logger
i.Workflow.Name = s.name
i.Workflow.DefaultTimeout = s.Timeout
+ fmt.Println("incldued_wf name:", i.Workflow.Name, " timeout:", i.Workflow.DefaultTimeout)
var errs DError
L... | 1 | // Copyright 2017 Google 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 appl... | 1 | 9,645 | This should be removed? If not, typo in incldued_wf | GoogleCloudPlatform-compute-image-tools | go |
@@ -19,6 +19,7 @@ export const variant = ({
export default variant
-export const buttonStyle = variant({ key: 'buttons' })
+export const buttonStyle =
+ variant({ key: 'buttons' }) || variant({ key: 'buttonStyles' })
export const textStyle = variant({ key: 'textStyles', prop: 'textStyle' })
export const colorSt... | 1 | import { get, createParser } from '@styled-system/core'
export const variant = ({
scale,
prop = 'variant',
// shim for v4 API
key,
}) => {
const sx = (value, scale) => {
return get(scale, value, null)
}
sx.scale = scale || key
const config = {
[prop]: sx,
}
const parser = createParser(confi... | 1 | 5,218 | Sorry for the delay on this! It looks like Circle CI isn't running tests on some of the PRs, but this doesn't look like it would work I might be missing something, but are the tests all passing locally? | styled-system-styled-system | js |
@@ -68,6 +68,15 @@ type MatchFile struct {
//
// Default is first_exist.
TryPolicy string `json:"try_policy,omitempty"`
+
+ // A list of delimiters to use to split the path in two
+ // when trying files. If empty, no splitting will
+ // occur, and the path will be tried as-is. For each
+ // split value, the left-... | 1 | // Copyright 2015 Matthew Holt and The Caddy 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 applicab... | 1 | 14,798 | Do you think the godoc should mention that all delimiters will be suffixed with `/`? | caddyserver-caddy | go |
@@ -111,6 +111,8 @@ public class NavigationURLBar extends FrameLayout {
return;
else if (aURL.startsWith("resource:") || SessionStore.get().isHomeUri(aURL))
aURL = "";
+ else if (aURL.startsWith("data:") && SessionStore.get().isCurrentSessionPrivate())
+ ... | 1 | /* -*- Mode: Java; c-basic-offset: 4; tab-width: 4; indent-tabs-mode: nil; -*-
* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
package org.mozilla.vrbrowser.ui;
... | 1 | 6,317 | what if I want to load my own, a different, data URI in Private Browsing mode? I do this often on desktop (e.g., `data:text/html,×`). admittedly, I wouldn't expect this to be done by a non-developer, but this will certainly cause a minor bug. | MozillaReality-FirefoxReality | java |
@@ -312,6 +312,7 @@ class DeleteFileIndex {
static class Builder {
private final FileIO io;
private final Set<ManifestFile> deleteManifests;
+ private long minSequenceNumber = 0L;
private Map<Integer, PartitionSpec> specsById = null;
private Expression dataFilter = Expressions.alwaysTrue();
... | 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 | 39,643 | I remember the sequence number 0 is kept for the data files for iceberg v1, so in theory the sequence number from delete files should start from 1. So setting it to 0 as the default value sounds correct. | apache-iceberg | java |
@@ -68,7 +68,7 @@ public class ImageVersionDaoImpl implements ImageVersionDao {
+ "values (?, ?, ?, ?, ?, ?, ?, ?, ?, ?)";
private static final String SELECT_IMAGE_VERSION_BASE_QUERY =
"select iv.id, iv.path, iv.description, "
- + "iv.version, cast(replace(iv.version, '.', '') as unsigned ... | 1 | /*
* Copyright 2020 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 | 20,974 | For all these MYSQL queries unsigned is required. I have tested again and without unsigned these queries are failing. | azkaban-azkaban | java |
@@ -57,6 +57,8 @@ const defaultState = {
editorNoteStatuses: {},
};
+const MAX_HISTORY = 200;
+
const stateUtils = {};
const derivedStateCache_ = {}; | 1 | const Note = require('lib/models/Note.js');
const Folder = require('lib/models/Folder.js');
const ArrayUtils = require('lib/ArrayUtils.js');
const { ALL_NOTES_FILTER_ID } = require('lib/reserved-ids');
const defaultState = {
notes: [],
notesSource: '',
notesParentType: null,
folders: [],
tags: [],
masterKeys: []... | 1 | 13,322 | Are there tests for this? What happens when you get to limit? | laurent22-joplin | js |
@@ -174,7 +174,7 @@ module Bolt
data['config'] = {}
end
- unless Bolt::Util.windows? || data['config']['transport']
+ unless data['config']['transport']
data['config']['transport'] = 'local' if target.name == 'localhost'
end
| 1 | # frozen_string_literal: true
require 'set'
require 'bolt/config'
require 'bolt/inventory/group'
require 'bolt/target'
require 'bolt/util'
module Bolt
class Inventory
ENVIRONMENT_VAR = 'BOLT_INVENTORY'
class ValidationError < Bolt::Error
attr_accessor :path
def initialize(message, offending_gro... | 1 | 10,168 | Whole thing could be collapsed to `data['config']['transport'] ||= 'local' if target.name == 'localhost'`. | puppetlabs-bolt | rb |
@@ -73,6 +73,15 @@ public class OpenPgpKeyPreference extends Preference {
@Override
protected void onClick() {
+ bindServiceAndGetSignKeyId(new Intent());
+ }
+
+ private void bindServiceAndGetSignKeyId(final Intent data) {
+ if (mServiceConnection != null) {
+ getSignKeyId(da... | 1 | /*
* Copyright (C) 2015 Dominik Schürmann <dominik@dominikschuermann.de>
*
* 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 | 16,710 | maybe throw in `&& mServiceConnection.isBound()`, there are cases where the connection might die | k9mail-k-9 | java |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.