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 |
|---|---|---|---|---|---|---|---|
@@ -167,6 +167,19 @@ func TestPullImageGlobalTimeout(t *testing.T) {
wait.Done()
}
+func TestPullImageInactivityTimeout(t *testing.T) {
+ mockDocker, client, testTime, _, _, done := dockerClientSetup(t)
+ defer done()
+
+ testTime.EXPECT().After(gomock.Any()).AnyTimes()
+ mockDocker.EXPECT().PullImage(&pullImageOp... | 1 | // +build !integration
// Copyright 2014-2018 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 | 19,185 | Please use the `assert` instead. Same below. | aws-amazon-ecs-agent | go |
@@ -18,6 +18,7 @@ return array(
'A currency with code "%name" already exists.' => 'A currency with code "%name" already exists.',
'A descriptive title' => 'A descriptive title',
'A message with name "%name" already exists.' => 'A message with name "%name" already exists.',
+ 'A name suche as Europe or... | 1 | <?php
return array(
' content create form' => ' content create form',
' note: only non-visible documents can be associated.' => ' note: only non-visible documents can be associated.',
'"%param" parameter cannot be empty in loop type: %type, name: %name' => '"%param" parameter cannot be empty in loop type: ... | 1 | 10,951 | Owww, I think I found a typo. `suche` | thelia-thelia | php |
@@ -131,8 +131,6 @@ void search(SearchEngineData<Algorithm> &engine_working_data,
source_phantom.GetReverseWeightPlusOffset(),
source_phantom.reverse_segment_id.id);
}
- BOOST_ASSERT(forward_heap.Size() > 0);
- BOOST_ASSERT(rev... | 1 | #include "engine/routing_algorithms/shortest_path.hpp"
#include "engine/routing_algorithms/routing_base_ch.hpp"
#include "engine/routing_algorithms/routing_base_mld.hpp"
#include <boost/assert.hpp>
#include <boost/optional.hpp>
#include <memory>
namespace osrm
{
namespace engine
{
namespace routing_algorithms
{
name... | 1 | 21,672 | This can happen because we could get `PhantomNodes` that are not admissible as source/target right? | Project-OSRM-osrm-backend | cpp |
@@ -19,6 +19,9 @@ func init() {
if !structsEqual(&tls.ClientSessionState{}, &qtls.ClientSessionState{}) {
panic("qtls.ClientSessionState not compatible with tls.ClientSessionState")
}
+ if !structsEqual(&tls.ClientSessionState{}, &clientSessionState{}) {
+ panic("clientSessionState not compatible with tls.Clien... | 1 | package handshake
// This package uses unsafe to convert between:
// * qtls.ConnectionState and tls.ConnectionState
// * qtls.ClientSessionState and tls.ClientSessionState
// We check in init() that this conversion actually is safe.
import (
"crypto/tls"
"reflect"
"github.com/marten-seemann/qtls"
)
func init() {... | 1 | 8,413 | Should we add a note here to file a bug if this ever happens? | lucas-clemente-quic-go | go |
@@ -455,7 +455,14 @@ func (api *BasicMarketAPI) GetDealChangeRequestInfo(ctx context.Context, dealID
}
func (api *BasicMarketAPI) GetNumBenchmarks(ctx context.Context) (int, error) {
- return NumCurrentBenchmarks, nil
+ num, err := api.marketContract.GetBenchmarksQuantity(getCallOptions(ctx))
+ if err != nil {
+ r... | 1 | package blockchain
import (
"context"
"crypto/ecdsa"
"math/big"
"strings"
"time"
"github.com/ethereum/go-ethereum"
"github.com/ethereum/go-ethereum/accounts/abi"
"github.com/ethereum/go-ethereum/common"
"github.com/ethereum/go-ethereum/core/types"
"github.com/ethereum/go-ethereum/ethclient"
"github.com/nox... | 1 | 6,903 | overflow is still possible, isn't it? | sonm-io-core | go |
@@ -37,6 +37,9 @@ RSpec.configure do |config|
config.use_transactional_fixtures = false
config.use_instantiated_fixtures = false
config.fixture_path = "#{::Rails.root}/spec/fixtures"
+ config.infer_base_class_for_anonymous_controllers = false
+ config.order = "random"
+ config.fail_fast = true
config.... | 1 | require 'codeclimate-test-reporter'
CodeClimate::TestReporter.configure do |config|
config.logger.level = Logger::WARN
end
CodeClimate::TestReporter.start
if ENV["COVERAGE"]
require 'simplecov'
SimpleCov.start 'rails'
end
ENV["RAILS_ENV"] ||= 'test'
require File.expand_path("../../config/environment", __FILE__)... | 1 | 9,117 | This seems more like a personal preference, so maybe this should be in your `~/.rspec`? | thoughtbot-upcase | rb |
@@ -31,8 +31,8 @@ else:
THREAD_EXCEPTION = thread.error
if WINDOWS:
- from scapy.arch.pcapdnet import PcapTimeoutElapsed
- recv_error = PcapTimeoutElapsed
+ from scapy.error import Scapy_Exception
+ recv_error = Scapy_Exception
else:
recv_error = ()
| 1 | ## This file is part of Scapy
## See http://www.secdev.org/projects/scapy for more informations
## Copyright (C) Philippe Biondi <phil@secdev.org>
## Copyright (C) Gabriel Potter <gabriel@potter.fr>
## This program is published under a GPLv2 license
"""
Automata with states, transitions and actions.
"""
from __future... | 1 | 11,510 | To avoid a circular import between pcapdnet and automaton | secdev-scapy | py |
@@ -1490,8 +1490,7 @@ class CommandDispatcher:
@cmdutils.register(instance='command-dispatcher', scope='window')
def view_source(self):
"""Show the source of the current page in a new tab."""
- # pylint: disable=no-member
- # WORKAROUND for https://bitbucket.org/logilab/pylint/issue/491... | 1 | # vim: ft=python fileencoding=utf-8 sts=4 sw=4 et:
# Copyright 2014-2017 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 | 19,434 | Please remove this blank line. | qutebrowser-qutebrowser | py |
@@ -70,6 +70,7 @@ func (c *Reconciler) ReconcileKind(ctx context.Context, s *v1alpha1.CloudAuditLo
ctx = logging.WithLogger(ctx, c.Logger.With(zap.Any("auditlogsource", s)))
s.Status.InitializeConditions()
+ s.Status.WorkloadIdentityStatus.InitWorkloadIdentityStatus()
s.Status.ObservedGeneration = s.Generation
... | 1 | /*
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
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
dis... | 1 | 11,346 | it feels that the WorkloadIdentityCondition should be added to this Status... And if you have workload identity enabled, but not working, then you can mark that condition failed, and also Mark the ready false... not entirely sure though | google-knative-gcp | go |
@@ -1681,6 +1681,16 @@ bool CoreChecks::ValidatePipelineUnlocked(const PIPELINE_STATE *pPipeline, uint3
}
}
}
+
+ auto provoking_vertex_state_ci = lvl_find_in_chain<VkPipelineRasterizationProvokingVertexStateCreateInfoEXT>(
+ pPipeline->graphicsPipelineCI.pRaster... | 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 | 16,153 | I think these got refactored to `LvlFindInChain` to better conform with the coding guidelines. I think MarkL left these in for backwards compatibility. | KhronosGroup-Vulkan-ValidationLayers | cpp |
@@ -50,6 +50,7 @@ def _column_op(f):
:param self: Koalas Series
:param args: arguments that the function `f` takes.
"""
+
@wraps(f)
def wrapper(self, *args):
assert all((not isinstance(arg, Series)) or (arg._kdf is self._kdf) for arg in args), \ | 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 | 9,214 | It's fine for this PR, but in the future try to minimize unrelated changes. | databricks-koalas | py |
@@ -202,11 +202,11 @@ class Ansible(base.Base):
::
ANSIBLE_ROLES_PATH:
- $ephemeral_directory/roles/:$project_directory/../
+ $ephemeral_directory/roles/:$project_directory/../:$HOME/.ansible/roles:/usr/share/ansible/roles:/etc/ansible/roles
ANSIBLE_LIBRARY:
- $epheme... | 1 | # Copyright (c) 2015-2018 Cisco Systems, Inc.
# Permission is hereby granted, free of charge, to any person obtaining a copy
# of this software and associated documentation files (the "Software"), to
# deal in the Software without restriction, including without limitation the
# rights to use, copy, modify, merge,... | 1 | 10,032 | The library -> modules and filters -> filter path changes are breaking changes or? | ansible-community-molecule | py |
@@ -1,6 +1,9 @@
import logging
+import os
from typing import TYPE_CHECKING
+import boto3
+import botocore.config
import pytest
from localstack.utils.aws import aws_stack | 1 | import logging
from typing import TYPE_CHECKING
import pytest
from localstack.utils.aws import aws_stack
from localstack.utils.aws.aws_stack import create_dynamodb_table
from localstack.utils.common import short_uid
if TYPE_CHECKING:
from mypy_boto3_dynamodb import DynamoDBClient
from mypy_boto3_s3 import S3... | 1 | 12,884 | Can we encapsulate this check (`os.environ.get("TEST_TARGET") == "AWS_CLOUD"`) into a small config/util function? (and also use it in `integration/conftest.py`) (I'd generally try to avoid accessing `os.environ` directly across the codebase. I'm aware that we're already doing this in a few places, but maybe we can star... | localstack-localstack | py |
@@ -22,7 +22,9 @@ export function h(nodeName, attributes) {
}
while (stack.length) {
if ((child = stack.pop()) && child.pop!==undefined) {
- for (i=child.length; i--; ) stack.push(child[i]);
+ [].concat(child).reverse().forEach((item) => {
+ stack.push(item);
+ });
}
else {
if (child===true ||... | 1 | import { VNode } from './vnode';
import options from './options';
const stack = [];
const EMPTY_CHILDREN = [];
/** JSX/hyperscript reviver
* Benchmarks: https://esbench.com/bench/57ee8f8e330ab09900a1a1a0
* @see http://jasonformat.com/wtf-is-jsx
* @public
*/
export function h(nodeName, attributes) {
let children... | 1 | 10,988 | An `if` statement would be better here. Functions, concat and reverse are all very expensive. | preactjs-preact | js |
@@ -156,3 +156,12 @@ func (c *factory) ERC20Address(ctx context.Context) (common.Address, error) {
}
return erc20Address, nil
}
+
+// DiscoverFactoryAddress returns the canonical factory for this chainID
+func DiscoverFactoryAddress(chainID int64) (common.Address, bool) {
+ if chainID == 5 {
+ // goerli
+ return... | 1 | // Copyright 2020 The Swarm Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
package chequebook
import (
"bytes"
"errors"
"math/big"
"strings"
"github.com/ethereum/go-ethereum/accounts/abi"
"github.com/ethereum/go-ethereum/acc... | 1 | 12,588 | `Log here: connect to default factory for goerli network <address>` | ethersphere-bee | go |
@@ -125,9 +125,11 @@ func (e *Executor) reportRequiringApproval(ctx context.Context) {
var approvers []string
- for _, v := range ds.GenericDeploymentConfig.DeploymentNotification.Mentions {
- if v.Event == "DEPLOYMENT_WAIT_APPROVAL" {
- approvers = v.Slack
+ if ds.GenericDeploymentConfig.DeploymentNotificatio... | 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 | 20,543 | nits, should add `break` to avoid redundant iterations. | pipe-cd-pipe | go |
@@ -56,6 +56,15 @@ namespace Nethermind.Store.Test
provider.Commit(SpuriousDragon.Instance);
Assert.False(provider.AccountExists(_address1));
}
+
+ [Test]
+ public void Eip_158_account_dont_exists_after_zero_value_transfer()
+ {
+ ISnapshotableD... | 1 | /*
* Copyright (c) 2018 Demerzel Solutions Limited
* This file is part of the Nethermind library.
*
* The Nethermind library is free software: you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License as published by
* the Free Software Foundation, either version 3 of th... | 1 | 22,695 | I think we want an exception here, there should never be a transfer to a nonexisting account. | NethermindEth-nethermind | .cs |
@@ -35,7 +35,7 @@ public class Container {
private final ContainerId id;
public Container(Function<HttpRequest, HttpResponse> client, ContainerId id) {
- LOG.info("Created container " + id);
+ LOG.finest("Created container " + id);
this.client = Objects.requireNonNull(client);
this.id = Objects.... | 1 | // Licensed to the Software Freedom Conservancy (SFC) under one
// or more contributor license agreements. See the NOTICE file
// distributed with this work for additional information
// regarding copyright ownership. The SFC licenses this file
// to you under the Apache License, Version 2.0 (the
// "License"); you m... | 1 | 16,458 | This code is new and not tested well. While we may drop the log level before we ship 4.0, right now this is extremely helpful to users. | SeleniumHQ-selenium | java |
@@ -79,11 +79,11 @@ class TestSklearn(unittest.TestCase):
'../../examples/lambdarank/rank.test.query'))
gbm = lgb.LGBMRanker()
gbm.fit(X_train, y_train, group=q_train, eval_set=[(X_test, y_test)],
- eval_group=[q_test], eval_at=[1, 3], early_sto... | 1 | # coding: utf-8
# pylint: skip-file
import itertools
import math
import os
import unittest
import lightgbm as lgb
import numpy as np
from sklearn import __version__ as sk_version
from sklearn.base import clone
from sklearn.datasets import (load_boston, load_breast_cancer, load_digits,
loa... | 1 | 20,943 | Can we make these asserts more strict/precise? I remember this test helped to spot the issue of inconsistent results on different platforms due to using `sort` instead of `stable_sort`. | microsoft-LightGBM | cpp |
@@ -87,6 +87,10 @@ module Bolt
impl
end
+ def select_interpreter(executable, interpreters)
+ interpreters[Pathname(executable).extname] if interpreters
+ end
+
def reject_transport_options(target, options)
if target.options['run-as']
options.reject { |k, _v|... | 1 | # frozen_string_literal: true
require 'logging'
require 'bolt/result'
module Bolt
module Transport
# This class provides the default behavior for Transports. A Transport is
# responsible for uploading files and running commands, scripts, and tasks
# on Targets.
#
# Bolt executes work on the Tran... | 1 | 10,650 | I thought about adjusting for case here as well? For example `.rb,rb,.RB,.rb` would all map to ruby interpreter specified? Is that too much "magic"? Is there a sane workflow that someone would choose to map `.rb` to one interpreter and `.RB` to another? | puppetlabs-bolt | rb |
@@ -1235,12 +1235,15 @@ ostree_sysroot_get_subbootversion (OstreeSysroot *self)
* ostree_sysroot_get_booted_deployment:
* @self: Sysroot
*
+ * This function may only be called if the sysroot is loaded.
+ *
* Returns: (transfer none) (nullable): The currently booted deployment, or %NULL if none
*/
OstreeDep... | 1 | /*
* Copyright (C) 2013 Colin Walters <walters@verbum.org>
*
* SPDX-License-Identifier: LGPL-2.0+
*
* 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 Licen... | 1 | 19,638 | In this and the one below, should we assert `self != NULL` first? | ostreedev-ostree | c |
@@ -147,7 +147,7 @@ class GalleryControllerTest extends \PHPUnit_Framework_TestCase
$view = $galleryController->postGalleryMediaGalleryhasmediaAction(1, 2, new Request());
$this->assertInstanceOf('FOS\RestBundle\View\View', $view);
- $this->assertSame(200, $view->getStatusCode(), 'Should retu... | 1 | <?php
/*
* This file is part of the Sonata Project package.
*
* (c) Thomas Rabaix <thomas.rabaix@sonata-project.org>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace Sonata\MediaBundle\Tests\Controller\Api;
use Doctrine... | 1 | 8,321 | Why this is needed? | sonata-project-SonataMediaBundle | php |
@@ -149,6 +149,12 @@ class PackageEntry:
"""
self._meta['user_meta'] = meta
+ def get_meta(self):
+ """
+ Gets the user_meta for this PackageEntry.
+ """
+ return self.meta or None
+
def _verify_hash(self, read_bytes):
"""
Verifies hash of bytes | 1 | from collections import deque
import gc
import hashlib
import io
import json
import pathlib
import os
import shutil
import time
from multiprocessing import Pool
import uuid
import warnings
import jsonlines
from tqdm import tqdm
from .data_transfer import (
calculate_sha256, copy_file, copy_file_list, get_bytes, g... | 1 | 18,668 | we already have .meta() so I don't think we want get_meta() for PackageEntry | quiltdata-quilt | py |
@@ -83,7 +83,8 @@ public abstract class CoprocessorIterator<T> implements Iterator<T> {
session,
SchemaInfer.create(dagRequest),
dagRequest.getPushDownType(),
- dagRequest.getStoreType()) {
+ dagRequest.getStoreType(),
+ dagRequest.getStartTs().getVersion()) {
@Ove... | 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 agreed ... | 1 | 12,028 | question: can we always get the startts from dagrequest? | pingcap-tispark | java |
@@ -114,9 +114,11 @@ describe( 'AccountSelect', () => {
it( 'should pre-select the property and profile IDs when changed', () => {
const { accounts, properties, profiles } = fixtures.accountsPropertiesProfiles;
const { getByText, container, registry } = render( <AccountSelect />, { setupRegistry } );
+ const p... | 1 | /**
* Account Select component 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/licenses/LICENS... | 1 | 28,513 | Nit-picking, but this can be simplified to reference `properties[ 0 ]` since that is already retrieved 2 lines above. | google-site-kit-wp | js |
@@ -142,6 +142,10 @@ module Bolt
@unresolved_targets[t_name] = target
end
+ def remove_target(target)
+ @resolved_targets.delete(target.name)
+ end
+
def add_target(target)
@resolved_targets[target.name] = { 'name' => target.name }
end | 1 | # frozen_string_literal: true
require 'bolt/inventory/group'
require 'bolt/inventory/inventory2'
require 'bolt/inventory/target'
module Bolt
class Inventory
class Group2
attr_accessor :name, :groups
# Regex used to validate group names and target aliases.
NAME_REGEX = /\A[a-z0-9_][a-z0-9_-]*\... | 1 | 13,373 | This technically works because we call `get_targets` before we remove the target, so it's bound to have been resolved. But I'm not sure I would like to rely on that assumption. Should we also remove it from `@unresolved_targets` to be safe? | puppetlabs-bolt | rb |
@@ -200,7 +200,7 @@ public abstract class AbstractCallOperation extends AbstractOperation {
.sender(sender(frame))
.value(value(frame))
.apparentValue(apparentValue(frame))
- .code(new Code(contract != null ? contract.getCode() : Bytes.EMPTY))
+ .co... | 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,737 | So what happens if I try to get code on a EOA? | hyperledger-besu | java |
@@ -2400,15 +2400,8 @@ class VariablesChecker(BaseChecker):
return
# Attempt to check unpacking is properly balanced
- values: Optional[List] = None
- if isinstance(inferred, (nodes.Tuple, nodes.List)):
- values = inferred.itered()
- elif isinstance(inferred, astr... | 1 | # Copyright (c) 2006-2014 LOGILAB S.A. (Paris, FRANCE) <contact@logilab.fr>
# Copyright (c) 2009 Mads Kiilerich <mads@kiilerich.com>
# Copyright (c) 2010 Daniel Harding <dharding@gmail.com>
# Copyright (c) 2011-2014, 2017 Google, Inc.
# Copyright (c) 2012 FELD Boris <lothiraldan@gmail.com>
# Copyright (c) 2013-2020 Cla... | 1 | 20,475 | Can't we return an empty list and then just compare the lengths? Thereby removing this `if`. | PyCQA-pylint | py |
@@ -151,6 +151,7 @@ class Uppy {
this.addFile = this.addFile.bind(this)
this.removeFile = this.removeFile.bind(this)
this.pauseResume = this.pauseResume.bind(this)
+ this.passesRestrictions = this.passesRestrictions.bind(this)
// ___Why throttle at 500ms?
// - We must throttle at >250ms... | 1 | const Translator = require('@uppy/utils/lib/Translator')
const ee = require('namespace-emitter')
const cuid = require('cuid')
const throttle = require('lodash.throttle')
const prettierBytes = require('@transloadit/prettier-bytes')
const match = require('mime-match')
const DefaultStore = require('@uppy/store-default')
c... | 1 | 13,604 | Mb change it to 'doesPassRestrictions()'? Doesn't sound enough like a boolean-returning method to me. | transloadit-uppy | js |
@@ -17,7 +17,7 @@ import (
// Lookup is the interface for time based feed lookup
type Lookup interface {
- At(ctx context.Context, at, after int64) (swarm.Chunk, error)
+ At(ctx context.Context, at, after int64) (chunk swarm.Chunk, currentIndex, nextIndex Index, err error)
}
// Getter encapsulates a chunk Gette... | 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 feeds
import (
"context"
"encoding/binary"
"fmt"
"time"
"github.com/ethersphere/bee/pkg/soc"
"github.com/ethersphere/bee/pkg/storage"
"githu... | 1 | 13,802 | TODO: in fact At when used with noncurrent time should not return a next index. only latest should.. | ethersphere-bee | go |
@@ -165,7 +165,11 @@ export function diff(
tmp = c.render(c.props, c.state, c.context);
let isTopLevelFragment =
tmp != null && tmp.type == Fragment && tmp.key == null;
- newVNode._children = isTopLevelFragment ? tmp.props.children : tmp;
+ newVNode._children = isTopLevelFragment
+ ? tmp.props.child... | 1 | import { EMPTY_OBJ, EMPTY_ARR } from '../constants';
import { Component } from '../component';
import { Fragment } from '../create-element';
import { diffChildren } from './children';
import { diffProps } from './props';
import { assign, removeNode } from '../util';
import options from '../options';
/**
* Diff two vi... | 1 | 15,303 | There are scenario's where we skip an update with a placeholder, in this case tmp returns null with render, this is not an array so we `[null]` it | preactjs-preact | js |
@@ -33,8 +33,7 @@ import javaslang.match.annotation.Patterns;
// -- javaslang.collection
// List
- @Unapply static <T> Tuple2<T, List<T>> List(List.Cons<T> cons) { return Tuple.of(cons.head(), cons.tail()); }
- @Unapply static <T> Tuple0 List(List.Nil<T> nil) { return Tuple.empty(); }
+ @Unapply st... | 1 | /* / \____ _ _ ____ ______ / \ ____ __ _______
* / / \/ \ / \/ \ / /\__\/ // \/ \ // /\__\ JΛVΛSLΛNG
* _/ / /\ \ \/ / /\ \\__\\ \ // /\ \ /\\/ \ /__\ \ Copyright 2014-2016 Javaslang, http://javaslang.io
* /___/\_/ \_/\____/\_/ \_/\__\/__/\__\_/ \_// \__/\_____/ ... | 1 | 8,181 | @danieldietrich, this wasn't tested so I presumed it wasn't working before either :p | vavr-io-vavr | java |
@@ -22,7 +22,7 @@
* This copyright notice MUST APPEAR in all copies of the script!
***************************************************************/
use TYPO3\CMS\Core\Utility\GeneralUtility;
-
+use ApacheSolrForTypo3\Solr\Facet\Facet;
/**
* Query group facet renderer.
* | 1 | <?php
/***************************************************************
* Copyright notice
*
* (c) 2012-2015 Ingo Renner <ingo@typo3.org>
* All rights reserved
*
* This script is part of the TYPO3 project. The TYPO3 project is
* free software; you can redistribute it and/or modify
* it under the terms of the GNU G... | 1 | 5,531 | Please leave two empty lines after the `use` statement | TYPO3-Solr-ext-solr | php |
@@ -27,6 +27,7 @@ import (
"bytes"
"fmt"
"io/ioutil"
+ "k8s.io/kubernetes/pkg/kubelet/cm"
"os"
"path"
"path/filepath" | 1 | /*
Copyright 2016 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 | 14,565 | Please move this import in the 3rd group which is for external dependencies | kubeedge-kubeedge | go |
@@ -63,7 +63,7 @@ def _path_hash(path, transform, kwargs):
return digest_string(srcinfo)
def _is_internal_node(node):
- is_leaf = not node or node.get(RESERVED['file'])
+ is_leaf = not node or isinstance(node.get(RESERVED['file']), str)
return not is_leaf
def _pythonize_name(name): | 1 | """
parse build file, serialize package
"""
from collections import defaultdict, Iterable
import glob
import importlib
import json
import os
import re
from types import ModuleType
import numpy as np
import pandas as pd
from pandas import DataFrame as df
from six import iteritems, string_types
import yaml
from tqdm im... | 1 | 16,211 | So what exactly is this fixing? The unit test is passing with or without this change. | quiltdata-quilt | py |
@@ -601,8 +601,18 @@ bool FileBasedWal::linkCurrentWAL(const char* newPath) {
LOG(INFO) << idStr_ << "Create link failed, there is no wal files!";
return false;
}
+ if (!fs::FileUtils::makeDir(newPath)) {
+ LOG(INFO) << idStr_ << "Link file parent dir make failed : " << newPath;
+ ... | 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 <utime.h>
#include "kvstore/wal/FileBasedWal.h"
#include "kvstore/wal/FileBasedWalIterat... | 1 | 24,016 | auto targetFile = fs::FileUtils::joinPath(newPath, folly::stringPrintf("%019ld.wal", it->first)); | vesoft-inc-nebula | cpp |
@@ -42,6 +42,16 @@ public class SnapshotUtil {
return ancestorIds(table.currentSnapshot(), table::snapshot);
}
+ /**
+ * @return List of snapshot ids in the range - (fromSnapshotId, toSnapshotId]
+ * This method assumes that fromSnapshotId is an ancestor of toSnapshotId
+ */
+ public static List<Long>... | 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 | 14,714 | I don't see any place that checks whether the from snapshot is an ancestor of the to snapshot. That seems like a requirement for this to work correctly to me. | apache-iceberg | java |
@@ -367,11 +367,10 @@ class Connection implements TranslatorAwareInterface, LoggerAwareInterface
explode(':', $functionConfig['updateFields'])
);
}
- if (isset($functionConfig['helpText'])) {
- $response['helpText'] = $this->getHelpText(
- ... | 1 | <?php
/**
* Catalog Connection Class
*
* This wrapper works with a driver class to pass information from the ILS to
* VuFind.
*
* PHP version 7
*
* Copyright (C) Villanova University 2007.
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public ... | 1 | 32,506 | Other calls to getHelpText() are wrapped in an `isset()` check. Would it make sense to be consistent, and either restore that here or remove it elsewhere? | vufind-org-vufind | php |
@@ -17,7 +17,7 @@ module RSpec
# @param [IO] out
def run(err, out)
@configuration.error_stream = err
- @configuration.output_stream ||= out
+ @configuration.output_stream = out
@options.configure(@configuration)
@configuration.load_spec_files
@world.announ... | 1 | module RSpec
module Core
class CommandLine
def initialize(options, configuration=RSpec::configuration, world=RSpec::world)
if Array === options
options = ConfigurationOptions.new(options)
options.parse_options
end
@options = options
@configuration = ... | 1 | 10,363 | Why the change? If `output_stream` is set to something non-nil, it seems odd (and potentially wrong) to overwrite it.... | rspec-rspec-core | rb |
@@ -4,6 +4,7 @@ class Proposal < ActiveRecord::Base
workflow_column :status
has_one :cart
+ belongs_to :clientdata, polymorphic: true
validates :flow, presence: true, inclusion: {in: ApprovalGroup::FLOWS}
| 1 | class Proposal < ActiveRecord::Base
include ThreeStateWorkflow
workflow_column :status
has_one :cart
validates :flow, presence: true, inclusion: {in: ApprovalGroup::FLOWS}
self.statuses.each do |status|
scope status, -> { where(status: status) }
end
scope :closed, -> { where(status: ['approved', '... | 1 | 12,639 | Thinking this should have an underscore. | 18F-C2 | rb |
@@ -316,14 +316,14 @@ def test_message_state_scope(init_linter: PyLinter) -> None:
linter = init_linter
linter.disable("C0202")
- assert MSG_STATE_SCOPE_CONFIG == linter.get_message_state_scope("C0202")
+ assert MSG_STATE_SCOPE_CONFIG == linter._get_message_state_scope("C0202")
linter.disable("W0... | 1 | # Copyright (c) 2006-2014 LOGILAB S.A. (Paris, FRANCE) <contact@logilab.fr>
# Copyright (c) 2011-2014 Google, Inc.
# Copyright (c) 2012 Kevin Jing Qiu <kevin.jing.qiu@gmail.com>
# Copyright (c) 2012 Anthony VEREZ <anthony.verez.external@cassidian.com>
# Copyright (c) 2012 FELD Boris <lothiraldan@gmail.com>
# Copyright ... | 1 | 16,495 | To accommodate the change to the method being private. | PyCQA-pylint | py |
@@ -90,6 +90,7 @@ namespace AutoRest.Swagger.Model
[CollectionRule(typeof(BodyTopLevelProperties))]
[CollectionRule(typeof(HttpVerbValidation))]
[CollectionRule(typeof(DeleteMustHaveEmptyRequestBody))]
+ [CollectionRule(typeof(PropertiesNamesCamelCase))]
public Dictionary<stri... | 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.Linq;
using System.Collections.Generic;
using System.Globalization;
using Newtonsoft.Json;
using AutoRest.Core.Validation;
using AutoR... | 1 | 23,969 | Shouldn't we traverse all definitions and apply this rule over all model definitions in the doc | Azure-autorest | java |
@@ -0,0 +1,11 @@
+/**
+ * BSD-style license; for more info see http://pmd.sourceforge.net/license.html
+ */
+
+package net.sourceforge.pmd.lang.java.rule.design;
+
+import net.sourceforge.pmd.testframework.PmdRuleTst;
+
+public class MutableStaticState extends PmdRuleTst {
+ // no additional unit tests
+} | 1 | 1 | 18,566 | Please rename this class that it ends with the suffix "Test" - otherwise the tests won't be executed. | pmd-pmd | java | |
@@ -0,0 +1,7 @@
+// This file is here, in part, so that users whose code editors are
+// set to automatically format files with Prettier have a config to detect.
+// Many users only run Prettier when a config is present, so this file makes
+// sure one can be detected, even though we aren't doing anything with it.
+mod... | 1 | 1 | 40,252 | As a JS file, this should also receive our standard file header. | google-site-kit-wp | js | |
@@ -1784,7 +1784,9 @@ short HashJoin::codeGen(Generator * generator) {
UInt16 numBMOsInFrag = (UInt16)generator->getFragmentDir()->getNumBMOs();
double memQuota = 0;
-
+ double memQuotaRatio;
+ Lng32 numStreams;
+ double bmoMemoryUsagePerNode = getEstimatedRunTimeMemoryUsage(TRUE, &numStreams).value(... | 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 | 17,952 | I take it memQuotaRatio is an "out" parameter at line 1810? Also, why use MIN_QUOTA in both the cases of memQuota being too low and too high? Contrast this code with RelRoot::codeGen where we set MIN_QUOTA only in the too low case. | apache-trafodion | cpp |
@@ -49,7 +49,6 @@ func NewPullSubscription(name, namespace string, so ...PullSubscriptionOption) *
for _, opt := range so {
opt(s)
}
- s.SetDefaults(gcpauthtesthelper.ContextWithDefaults())
return s
}
| 1 | /*
Copyright 2019 The Knative 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 | 15,586 | It looks like for newpullsubscription, we have two functions. One for pullsubscription with default, one for pullsubscription without default. If you remove setdefault here, then there is no differences between these two functions. | google-knative-gcp | go |
@@ -186,6 +186,13 @@ type AssetParams struct {
// created.
Total uint64 `codec:"t"`
+ // Decimals specifies the number of digits to display after the decimal
+ // place when displaying this asset. A value of 0 represents an asset
+ // that is not divisible, a value of 1 represents an asset divisible
+ // into ten... | 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,984 | not dramatic, but why 32bits if we allow a range that is smaller than 8? | algorand-go-algorand | go |
@@ -0,0 +1,8 @@
+package dto
+
+type ClientPromise struct {
+ SerialNumber int
+ IssuerId int
+ BenefiterId int
+ Amount int
+} | 1 | 1 | 9,449 | - Use type from `service_discovery/dto/price.go` - Rename `Price` -> `Money` | mysteriumnetwork-node | go | |
@@ -193,6 +193,18 @@ public abstract class Either<L, R> implements io.vavr.Iterable<R>, io.vavr.Value
/**
* Maps either the left or the right side of this disjunction.
*
+ * <pre>{@code
+ *Either<?, AtomicInteger> success = Either.right(new AtomicInteger(42));
+ *
+ * //prints "Right(42... | 1 | /* ____ ______________ ________________________ __________
* \ \/ / \ \/ / __/ / \ \/ / \
* \______/___/\___\______/___/_____/___/\___\______/___/\___\
*
* Copyright 2019 Vavr, http://vavr.io
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use ... | 1 | 13,198 | one space missing at the beginning | vavr-io-vavr | java |
@@ -43,8 +43,9 @@ type RequestDrivenWebServiceProps struct {
// AppRunnerInstanceConfig contains the instance configuration properties for an App Runner service.
type AppRunnerInstanceConfig struct {
- CPU *int `yaml:"cpu"`
- Memory *int `yaml:"memory"`
+ CPU *int `yaml:"cpu"`
+ Memory *int `yaml:"mem... | 1 | // Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
// SPDX-License-Identifier: Apache-2.0
package manifest
import (
"github.com/aws/aws-sdk-go/aws"
"github.com/aws/copilot-cli/internal/pkg/template"
"github.com/imdario/mergo"
)
const (
requestDrivenWebSvcManifestPath string = "workloads/servic... | 1 | 18,471 | I worry that having `Platform` as `string` instead of `*string` would result in it getting overriden with `""` if the environment manifest config doesn't specify `platform` . If it gets overridden as `""`, that could be a problem for users that are not using `linux/amd64` right? If this indeed is a potential impact, ... | aws-copilot-cli | go |
@@ -26,7 +26,10 @@ exports = module.exports = function(grunt, options) {
'http://' + host + ':<%= connect.test.options.port %>/test/commons/',
'http://' +
host +
- ':<%= connect.test.options.port %>/test/integration/rules/'
+ ':<%= connect.test.options.port %>/test/integration/rules/',
+ ... | 1 | exports = module.exports = function(grunt, options) {
var host = 'localhost';
if (process.env.REMOTE_TESTSERVER_HOST) {
host = process.env.REMOTE_TESTSERVER_HOST;
}
function mapToUrl(files, port) {
return grunt.file.expand(files).map(function(file) {
return 'http://' + host + ':' + port + '/' + file;
});... | 1 | 15,000 | I like the new directory `/api`, what is the thinking behind `/external`? | dequelabs-axe-core | js |
@@ -2844,11 +2844,10 @@ func (s *Server) updateAccountClaimsWithRefresh(a *Account, ac *jwt.AccountClaim
// update account signing keys
a.signingKeys = nil
signersChanged := false
- if len(ac.SigningKeys) > 0 {
- // insure copy the new keys and sort
- a.signingKeys = append(a.signingKeys, ac.SigningKeys...)
- ... | 1 | // Copyright 2018-2020 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,217 | staticcheck flags this: replace with `for k := ..` | nats-io-nats-server | go |
@@ -132,8 +132,8 @@ def GMLAN_InitDiagnostics(
p = GMLAN() / GMLAN_PM(subfunction="enableProgrammingMode")
if verbose:
print("Sending %s" % repr(p))
- sock.send(p)
time.sleep(0.05)
+ sock.sr1(p, timeout=0.001, verbose=False)
return True
return False
| 1 | #! /usr/bin/env python
# This file is part of Scapy
# See http://www.secdev.org/projects/scapy for more information
# Copyright (C) Markus Schroetter <project.m.schroetter@gmail.com>
# Copyright (C) Nils Weiss <nils@we155.de>
# This program is published under a GPLv2 license
# scapy.contrib.description = GMLAN Utilit... | 1 | 19,553 | There's already a sleep right above | secdev-scapy | py |
@@ -1249,9 +1249,16 @@ class AssertionFinder
$if_types[$var_id] = [[$assertion->rule[0][0]]];
}
} elseif (\is_string($assertion->var_id)
- && $expr instanceof PhpParser\Node\Expr\MethodCall
+ && (
+ ... | 1 | <?php
namespace Psalm\Internal\Analyzer\Statements\Expression;
use PhpParser;
use Psalm\Codebase;
use Psalm\Internal\Analyzer\ClassLikeAnalyzer;
use Psalm\Internal\Analyzer\StatementsAnalyzer;
use Psalm\Internal\Type\Comparator\UnionTypeComparator;
use Psalm\CodeLocation;
use Psalm\FileSource;
use Psalm\Issue\Docblock... | 1 | 9,648 | This feels hacky, is there a better way? | vimeo-psalm | php |
@@ -22,9 +22,14 @@
# IN THE SOFTWARE.
#
from math import ceil
-from boto.compat import json, map, six
+from boto.compat import json, six
import requests
+try:
+ from collections import OrderedDict
+except ImportError:
+ from ordereddict import OrderedDict
+
class SearchServiceException(Exception):
p... | 1 | # Copyright (c) 2012 Mitch Garnaat http://garnaat.org/
# Copyright (c) 2012 Amazon.com, Inc. or its affiliates.
# 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... | 1 | 11,229 | Can we move this logic into the `boto.compat` module? Then it's just `from boto.compat import OrderedDict` instead. Also, this is introducing a new dependency. What about users on 2.6.x that don't have the OrderedDict module installed? We may need to fall back to an ordinary `dict` so that existing code in the wild doe... | boto-boto | py |
@@ -36,14 +36,14 @@ namespace Fixtures.Azure.AcceptanceTestsAzureBodyDuration
public Uri BaseUri { get; set; }
/// <summary>
- /// Gets or sets json serialization settings.
+ /// Gets JSON serialization settings.
/// </summary>
public JsonSerializerSettings Serializat... | 1 | // Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for
// license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
// Changes may cause incorrect behavior and will be lost if the code is
// regenerated.
namespa... | 1 | 21,868 | "Gets the JSON serialization settings." would be better? | Azure-autorest | java |
@@ -38,6 +38,15 @@ func (s *server) setupRouting() {
handle(router, "/bytes", jsonhttp.MethodHandler{
"POST": http.HandlerFunc(s.bytesUploadHandler),
})
+
+ handle(router, "/file", jsonhttp.MethodHandler{
+ "POST": http.HandlerFunc(s.bzzFileUploadHandler),
+ })
+
+ handle(router, "/file/{addr}", jsonhttp.Method... | 1 | // Copyright 2020 The Swarm Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
package api
import (
"fmt"
"net/http"
"github.com/ethersphere/bee/pkg/jsonhttp"
"github.com/ethersphere/bee/pkg/logging"
"github.com/gorilla/handlers"... | 1 | 10,496 | The endpoint should be in plural `/files`. | ethersphere-bee | go |
@@ -141,6 +141,9 @@ AtomPDBResidueInfo *AtomGetPDBResidueInfo(Atom *atom) {
return (AtomPDBResidueInfo *)res;
}
+struct MDLDummy {};
+struct DaylightDummy {};
+
// FIX: is there any reason at all to not just prevent the construction of
// Atoms?
std::string atomClassDoc = | 1 | // $Id$
//
// Copyright (C) 2003-2013 Greg Landrum and 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_... | 1 | 15,299 | ??? Why do we need to have a different API in Python? Oh, wait, I see what you did. It's to fake the namespaces. Given that I don't think the namespaces are necessary, and that less of these should be exposed anyway, I think these should go. | rdkit-rdkit | cpp |
@@ -40,7 +40,7 @@ func InitContext(contextType string) {
})
}
-func GetContext() gocontext.Context{
+func GetContext() gocontext.Context {
return context.ctx
}
func Done() <-chan struct{} { | 1 | package context
import (
gocontext "context"
"sync"
"time"
"k8s.io/klog"
"github.com/kubeedge/beehive/pkg/core/model"
)
// define channel type
const (
MsgCtxTypeChannel = "channel"
)
var (
// singleton
context *beehiveContext
once sync.Once
)
// InitContext gets global context instance
func InitContex... | 1 | 16,401 | I think this line is gofmt issue? @daixiang0 | kubeedge-kubeedge | go |
@@ -94,6 +94,16 @@ func TestSubrepoLabel(t *testing.T) {
assert.EqualValues(t, BuildLabel{PackageName: "", Name: ""}, label.SubrepoLabel())
}
+func TestParseBuildLabelParts(t *testing.T) {
+ target1 := "@unittest_cpp//:unittest_cpp"
+ targetNewSyntax := "@unittest_cpp"
+ pkg, name, subrepo := parseBuildLabelParts(... | 1 | package core
import (
"os"
"testing"
"github.com/stretchr/testify/assert"
)
func TestIncludes(t *testing.T) {
label1 := BuildLabel{PackageName: "src/core", Name: "..."}
label2 := BuildLabel{PackageName: "src/parse", Name: "parse"}
assert.False(t, label1.Includes(label2))
label2 = BuildLabel{PackageName: "src/... | 1 | 8,305 | probably better to assert the values directly; technically you could pass this test with an implementation that always returned "" for the subrepo for example. | thought-machine-please | go |
@@ -46,7 +46,7 @@ func addTestingTsfBlocks(bc Blockchain) error {
big.NewInt(10),
)
pubk, _ := keypair.DecodePublicKey(Gen.CreatorPubKey)
- sig, _ := hex.DecodeString("3584fe777dd090e1a7a825896f532485ea2cc35d7c300c6c56f0e2e78b51c6ded33f7d0069f4f6f6b6762306466fcff6f261bb30d9e1550f2f8be4f988e740903fd734209cb60101"... | 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,714 | line is 161 characters (from `lll`) | iotexproject-iotex-core | go |
@@ -19,13 +19,14 @@
package org.apache.iceberg.catalog;
+import java.io.Serializable;
import java.util.Arrays;
import org.apache.iceberg.relocated.com.google.common.base.Joiner;
/**
* A namespace in a {@link Catalog}.
*/
-public class Namespace {
+public class Namespace implements Serializable {
privat... | 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,796 | Are these changes needed? | apache-iceberg | java |
@@ -78,12 +78,12 @@ public final class UserUtils {
}
try {
- Path dir = Paths.get(fileName).getParent();
+ final Path dir = Paths.get(fileName).getParent();
if (!dirToFilesMap.containsKey(dir)) {
- // There is not entry for this directory, create a watchkey
+ // ... | 1 | package azkaban.user;
import com.google.common.base.Preconditions;
import com.google.common.collect.HashMultimap;
import com.google.common.collect.Multimap;
import com.sun.nio.file.SensitivityWatchEventModifier;
import java.io.File;
import java.io.IOException;
import java.nio.file.FileSystems;
import java.nio.file.Pat... | 1 | 17,969 | It seems like reducing the sensitivity would make the test failure less likely to occur, but not fix the issue? | azkaban-azkaban | java |
@@ -3,7 +3,9 @@
namespace Thelia\Model;
use Thelia\Model\Base\CategoryDocumentI18n as BaseCategoryDocumentI18n;
+use Thelia\Model\Tools\I18nTimestampableTrait;
class CategoryDocumentI18n extends BaseCategoryDocumentI18n
{
+ use I18nTimestampableTrait;
} | 1 | <?php
namespace Thelia\Model;
use Thelia\Model\Base\CategoryDocumentI18n as BaseCategoryDocumentI18n;
class CategoryDocumentI18n extends BaseCategoryDocumentI18n
{
}
| 1 | 10,697 | missing use statement for importing the full namespace | thelia-thelia | php |
@@ -35,6 +35,9 @@ var ErrInsufficientHosts = &shared.InternalServiceError{Message: "Not enough hos
// ErrListenerAlreadyExist is thrown on a duplicate AddListener call from the same listener
var ErrListenerAlreadyExist = errors.New("Listener already exist for the service")
+// ErrIncorrectAddressFormat is thrown on... | 1 | // Copyright (c) 2017 Uber Technologies, Inc.
//
// Permission is hereby granted, free of charge, to any person obtaining a copy
// of this software and associated documentation files (the "Software"), to deal
// in the Software without restriction, including without limitation the rights
// to use, copy, modify, merge... | 1 | 9,059 | Generally error messages in Go shouldn't start with capital letter. I see this rule is broken in many places here. Why? | temporalio-temporal | go |
@@ -285,7 +285,7 @@ describe('Core_selection', () => {
selectCell(0, 0);
keyDownUp('arrow_left');
- expect(getSelected()).toEqual([[0, 0, 0, 0]]);
+ expect(getSelected()).toEqual([[4, 4, 4, 4]]);
});
it('should fix start range if provided is out of bounds (to the top)', () => { | 1 | describe('Core_selection', () => {
var id = 'testContainer';
beforeEach(function() {
this.$container = $(`<div id="${id}"></div>`).appendTo('body');
});
afterEach(function() {
if (this.$container) {
destroy();
this.$container.remove();
}
});
it('should correctly render the selecti... | 1 | 14,824 | These test checks if selection coordinates don't return negative values in that edge cases. Please revert the changes and set `autoWrapCol` and `autoWrapRow` to `false` to the Handsontable instance. This change applies to the entire Core_selection.spec.js file. | handsontable-handsontable | js |
@@ -60,7 +60,17 @@ namespace Nethermind.Evm.TransactionProcessing
/// <summary>
/// Commit and later restore state, use for CallAndRestore
/// </summary>
- CommitAndRestore = Commit | Restore
+ CommitAndRestore = Commit | Restore,
+
+ /... | 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,074 | I would prefer flag SkipGasPricingValidation | NethermindEth-nethermind | .cs |
@@ -1492,6 +1492,13 @@ void nano::work_watcher::add (std::shared_ptr<nano::block> block_a)
}
}
+bool nano::work_watcher::is_watched (nano::qualified_root const root_a)
+{
+ std::unique_lock<std::mutex> lock (mutex);
+ auto exists (blocks.find (root_a));
+ return exists != blocks.end ();
+}
+
void nano::wallets::d... | 1 | #include <nano/node/wallet.hpp>
#include <nano/crypto_lib/random_pool.hpp>
#include <nano/lib/utility.hpp>
#include <nano/node/node.hpp>
#include <nano/node/wallet.hpp>
#include <nano/node/xorshift.hpp>
#include <argon2.h>
#include <boost/filesystem.hpp>
#include <boost/polymorphic_cast.hpp>
#include <future>
nano... | 1 | 15,593 | could be `const &` ? | nanocurrency-nano-node | cpp |
@@ -75,6 +75,7 @@ module.exports = class Dashboard extends Plugin {
defaultTabIcon: defaultTabIcon,
showProgressDetails: false,
hideUploadButton: false,
+ hideProgressAfterFinish: false,
note: null,
closeModalOnClickOutside: false,
locale: defaultLocale, | 1 | const Plugin = require('../../core/Plugin')
const Translator = require('../../core/Translator')
const dragDrop = require('drag-drop')
const DashboardUI = require('./Dashboard')
const StatusBar = require('../StatusBar')
const Informer = require('../Informer')
const { findAllDOMElements, toArray } = require('../../core/U... | 1 | 10,343 | The docs should also be updated with the new option. | transloadit-uppy | js |
@@ -157,6 +157,15 @@ def send_email(subject, message, sender, recipients, image_png=None):
send_email_smtp(config, sender, subject, message, recipients, image_png)
+def send_notification(subject, message, topic):
+ import boto.sns
+ config = configuration.get_config()
+ con = boto.sns.connect_to_r... | 1 | # -*- coding: utf-8 -*-
#
# Copyright 2012-2015 Spotify AB
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law... | 1 | 12,241 | Name is _way_ to generic for this patch to be accepted I think. Can you rename it to maybe `send_sns_notification` or something else you find suitable? | spotify-luigi | py |
@@ -31,7 +31,7 @@ func run() error {
return fmt.Errorf("failed to load config file: %s", err)
}
- logger := logging.BuildLogger(cfg.Logging.Level)
+ logger := logging.BuildLogger(*cfg.Logging.Level)
ctx := log.WithLogger(context.Background(), logger)
key, err := cfg.Eth.LoadKey() | 1 | package main
import (
"context"
"fmt"
"os"
"os/signal"
"syscall"
log "github.com/noxiouz/zapctx/ctxlog"
"github.com/sonm-io/core/cmd"
"github.com/sonm-io/core/insonmnia/dwh"
"github.com/sonm-io/core/insonmnia/logging"
"github.com/sonm-io/core/util"
"go.uber.org/zap"
)
var (
configFlag string
versionFla... | 1 | 6,845 | Out of the scope. | sonm-io-core | go |
@@ -151,4 +151,12 @@ if (typeof Object.assign != 'function') {
}
return to;
};
-}
+}
+
+
+NodeList.prototype.forEach = function(callback, thisArg) {
+ thisArg = thisArg || window;
+ for (var i = 0; i < this.length; i++) {
+ callback.call(thisArg, this[i], i, this);
+ }
+}; | 1 | if (!String.prototype.endsWith) {
String.prototype.endsWith = function(search, this_len) {
if (this_len === undefined || this_len > this.length) {
this_len = this.length;
}
return this.substring(this_len - search.length, this_len) === search;
};
}
if (!String.prototype.startsWith) {
Object.defineProperty... | 1 | 14,226 | I think we need an if block to check that if this API is really missing. We wouldn't want to override the browser's implementation. | Countly-countly-server | js |
@@ -89,6 +89,11 @@ function _getItem(name) {
* @param {Function} editorClass Editor class.
*/
function _register(name, editorClass) {
+ if (name && typeof name !== 'string') {
+ editorClass = name;
+ name = editorClass.EDITOR_TYPE;
+ }
+
const editorWrapper = new RegisteredEditor(editorClass);
if (... | 1 | /**
* Utility to register editors and common namespace for keeping reference to all editor classes.
*/
import Hooks from '../pluginHooks';
import staticRegister from '../utils/staticRegister';
const registeredEditorClasses = new WeakMap();
const {
register,
getItem,
hasItem,
getNames,
getValues,
} = stati... | 1 | 17,443 | I was wondering, things like EDITOR_TYPE, VALIDATOR_TYPE, RENDERER_TYPE are not obligatory. Therefore if the custom editor will be registered with this method, `name` will be set to `undefined`. Should we handle this scenario? | handsontable-handsontable | js |
@@ -1,7 +1,6 @@
// Copyright 2020 The Swarm Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
-
package p2p
import ( | 1 | // Copyright 2020 The Swarm Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
package p2p
import (
"context"
"fmt"
"io"
ma "github.com/multiformats/go-multiaddr"
)
type Service interface {
AddProtocol(ProtocolSpec) error
Conne... | 1 | 8,697 | This line should not be removed, as it is not the description of the package, but a copyright header. | ethersphere-bee | go |
@@ -37,6 +37,8 @@ type DiskBlockCacheMetadata struct {
TriggeredPrefetch bool `codec:"HasPrefetched"`
// whether the block's triggered prefetches are complete
FinishedPrefetch bool
+ // the last tag with which the block was marked
+ Tag string
}
// lruEntry is an entry for sorting LRU times | 1 | package libkbfs
import (
"time"
"github.com/keybase/kbfs/kbfsblock"
"github.com/keybase/kbfs/kbfscrypto"
"github.com/keybase/kbfs/tlf"
)
// diskBlockCacheEntry packages an encoded block and serverHalf into one data
// structure, allowing us to encode it as one set of bytes.
type diskBlockCacheEntry struct {
Buf... | 1 | 20,893 | Wouldn't it be more space efficient to make this a `byte` enum or bitfield? | keybase-kbfs | go |
@@ -207,13 +207,13 @@ class PostgresTarget(luigi.Target):
connection.autocommit = True
cursor = connection.cursor()
if self.use_db_timestamps:
- sql = """ CREATE TABLE {marker_table} (
+ sql = """ CREATE TABLE IF NOT EXISTS {marker_table} (
update_... | 1 | # -*- coding: utf-8 -*-
#
# Copyright 2012-2015 Spotify AB
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law... | 1 | 16,798 | Flake8 doesn't like the assignment, but non-use of `e` here. I think we can just remove the try/except here for `cursor.execute(sql)`. | spotify-luigi | py |
@@ -0,0 +1,13 @@
+/**
+ * BSD-style license; for more info see http://pmd.sourceforge.net/license.html
+ */
+
+package net.sourceforge.pmd.lang.java.ast;
+
+/**
+ * Marker interface for type body declarations.
+ *
+ * @author Clément Fournier
+ */
+public interface ASTAnyTypeBodyDeclaration extends JavaNode {
+} | 1 | 1 | 12,483 | Maybe add short example list: .... type body declarations, such as AnnotationMembers, Methods, Fields | pmd-pmd | java | |
@@ -47,6 +47,10 @@ public interface CapabilityType {
String HAS_TOUCHSCREEN = "hasTouchScreen";
String OVERLAPPING_CHECK_DISABLED = "overlappingCheckDisabled";
String STRICT_FILE_INTERACTABILITY = "strictFileInteractability";
+ String TIMEOUTS = "timeouts";
+ String IMPLICIT_TIMEOUT = "implicit";
+ String P... | 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 | 19,072 | These are really meant to be the keys in the capabilities, not the keys of values within the capabilities | SeleniumHQ-selenium | rb |
@@ -30,6 +30,15 @@ import org.apache.iceberg.io.LocationProvider;
*/
public interface Table {
+ /**
+ * Return the full name for this table.
+ *
+ * @return this table's name
+ */
+ default String name() {
+ return toString();
+ }
+
/**
* Refresh the current table metadata.
*/ | 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 | 25,822 | It is debatable whether we have to default this. I did this to avoid breaking custom implementations. | apache-iceberg | java |
@@ -54,10 +54,8 @@ class ProxyType:
value = str(value).upper()
for attr in dir(cls):
attr_value = getattr(cls, attr)
- if isinstance(attr_value, dict) and \
- 'string' in attr_value and \
- attr_value['string'] is not None and \
- ... | 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 | 18,411 | # `attr_value['string'] is not None` probably not required as `attr_value['string'] == value` check is already being done | SeleniumHQ-selenium | js |
@@ -8,7 +8,7 @@ import (
"fmt"
"strings"
- "github.com/aws/amazon-ecs-cli-v2/internal/pkg/addons"
+ addon "github.com/aws/amazon-ecs-cli-v2/internal/pkg/addon"
awscloudformation "github.com/aws/amazon-ecs-cli-v2/internal/pkg/aws/cloudformation"
"github.com/aws/amazon-ecs-cli-v2/internal/pkg/aws/ecr"
"github... | 1 | // Copyright Amazon.com Inc. or its affiliates. All Rights Reserved.
// SPDX-License-Identifier: Apache-2.0
package cli
import (
"errors"
"fmt"
"strings"
"github.com/aws/amazon-ecs-cli-v2/internal/pkg/addons"
awscloudformation "github.com/aws/amazon-ecs-cli-v2/internal/pkg/aws/cloudformation"
"github.com/aws/a... | 1 | 13,658 | we shouldn't need the "addon" rename | aws-copilot-cli | go |
@@ -1,4 +1,6 @@
class Admin::DecksController < ApplicationController
+ before_filter :must_be_admin
+
def index
@decks = Deck.all
end | 1 | class Admin::DecksController < ApplicationController
def index
@decks = Deck.all
end
def new
@deck = Deck.new
end
def create
@deck = build_deck
if @deck.save
redirect_to admin_deck_path(@deck)
else
render :new
end
end
def show
@deck = find_deck
end
private
... | 1 | 15,570 | These are covered by routing constraints. | thoughtbot-upcase | rb |
@@ -32,7 +32,7 @@ import (
func (s *Service) InstanceIfExists(instanceID *string) (*v1alpha1.Instance, error) {
glog.V(2).Infof("Looking for instance %q", *instanceID)
input := &ec2.DescribeInstancesInput{
- InstanceIds: []*string{instanceID},
+ InstanceIds: aws.StringSlice([]string{*instanceID}),
}
out, e... | 1 | // Copyright © 2018 The Kubernetes Authors.
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or ag... | 1 | 6,534 | Could we use just a normal string here? | kubernetes-sigs-cluster-api-provider-aws | go |
@@ -1,6 +1,8 @@
import { VNode } from './vnode';
import options from './options';
+import { iterableToArray, isFunction } from './util';
+const hasSymbolSupport = isFunction(Symbol) && Symbol.iterator;
const stack = [];
| 1 | import { VNode } from './vnode';
import options from './options';
const stack = [];
const EMPTY_CHILDREN = [];
/** JSX/hyperscript reviver
* Benchmarks: https://esbench.com/bench/57ee8f8e330ab09900a1a1a0
* @see http://jasonformat.com/wtf-is-jsx
* @public
* @example
* /** @jsx h *\/
* import { render, h } fr... | 1 | 10,327 | `isFunction(Symbol)` triggers a `ReferenceError` if Symbol is undefined. Using `typeof Symbol === 'function'` is OK however. | preactjs-preact | js |
@@ -140,6 +140,10 @@ void nano::election_scheduler::run ()
election->transition_active ();
}
}
+ else
+ {
+ lock.unlock ();
+ }
notify ();
lock.lock ();
} | 1 | #include <nano/node/election_scheduler.hpp>
#include <nano/node/node.hpp>
nano::election_scheduler::election_scheduler (nano::node & node) :
node{ node },
stopped{ false },
thread{ [this] () { run (); } }
{
}
nano::election_scheduler::~election_scheduler ()
{
stop ();
thread.join ();
}
void nano::election_sched... | 1 | 16,988 | Is there an else clause (with a lock.unlock ()) missing here as well? If we think we do not need an else clause then lets add an else clause containing assert zero. | nanocurrency-nano-node | cpp |
@@ -189,7 +189,7 @@ func dispense(w http.ResponseWriter, r *http.Request) {
return
}
- tx, err := c.SendPaymentFromUnencryptedWallet(cfg.Source, target, uint64(cfg.Fee), uint64(cfg.Amount), nil)
+ tx, err := c.SendPaymentFromUnencryptedWallet(cfg.Source, target, uint64(cfg.Fee), uint64(cfg.Amount), [32]byte{}, n... | 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,431 | do we foresee `32` ever changing? (as well as its use in error checking in `clerk.go`) if "no" this is fine, if "yes" it's probably still fine | algorand-go-algorand | go |
@@ -19,13 +19,14 @@ package org.openqa.selenium.remote;
import com.google.common.collect.ImmutableMap;
+import org.openqa.selenium.DeviceRotation;
import org.openqa.selenium.Rotatable;
import org.openqa.selenium.ScreenOrientation;
import java.lang.reflect.Method;
public class AddRotatable implements Augmen... | 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,511 | you don't need to create a enum for this, java allows you to switch on a string ;) (since java 7?) | SeleniumHQ-selenium | py |
@@ -35,6 +35,12 @@ export default AuthenticatedRoute.extend(styleBody, CurrentUserSettings, Paginat
});
}
+ // we need to load the roles into ember cache
+ // invites return role_id only and we do not offer a /role/:id endpoint
+ this.get('store').query('... | 1 | import AuthenticatedRoute from 'ghost-admin/routes/authenticated';
import CurrentUserSettings from 'ghost-admin/mixins/current-user-settings';
import PaginationMixin from 'ghost-admin/mixins/pagination';
import styleBody from 'ghost-admin/mixins/style-body';
import RSVP from 'rsvp';
import {isBlank} from 'ember-utils';... | 1 | 7,647 | This should be `modelPromises.roles = this.get('store').query('role', ...` and the promise body should just `return roles;`. This is because the `model()` hook will pause for the returned promises to be resolved before continuing so when returning `RSVP.hash` you end up with a hash containing the values returned from t... | TryGhost-Admin | js |
@@ -0,0 +1,19 @@
+const landmarks = axe.commons.aria.getRolesByType('landmark');
+const sectioning = ['article', 'aside', 'main', 'navigation', 'section'];
+const nodeIsHeader = node.tagName.toLowerCase() === 'header' && node.getAttribute('role') !== 'banner';
+var parent = axe.commons.dom.getComposedParent(node);
+
+w... | 1 | 1 | 12,001 | This is basically a repeat of `main-is-top-level.js`. I suggest having these 3 checks point to the same evaluate file. You can change what element they test through the rule selector as well as the check.json options property. So you would have `main-is-top-level.json`, `banner-is-top-level.json` and `contentinfo-is-to... | dequelabs-axe-core | js | |
@@ -63,13 +63,13 @@ public class PackageListeners {
}
synchronized void packagesUpdated(List<PackageLoader.Package> pkgs) {
- MDCLoggingContext.setCore(core);
+ if(core != null) MDCLoggingContext.setCore(core);
try {
for (PackageLoader.Package pkgInfo : pkgs) {
invokeListeners(pkgInfo... | 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,752 | Why do we need this check? setCore already handles nulls. | apache-lucene-solr | java |
@@ -121,7 +121,7 @@ def _inject(target_type, inject_type):
# Inject all the methods from the hierarchy:
setattr(target_type, "__getattr__", inject_type.__getattr__)
setattr(target_type, "__getitem__", inject_type.__getitem__)
- for attr in ["__iter__", "__len__", "__invert__", "__setitem__"]:
+ for... | 1 | import pyspark.sql.dataframe as df
import pyspark.sql.column as col
import pyspark.sql.functions as F
import pyspark
from decorator import decorator
import types
import logging
from .structures import *
from . import namespace
logger = logging.getLogger('spark')
_TOUCHED_TEST = "_pandas_updated"
def patch_spark():... | 1 | 8,011 | good catch, thanks. This is going to make the user experience much better. | databricks-koalas | py |
@@ -1,4 +1,4 @@
-import { options } from 'preact';
+import { Component, options } from 'preact';
/** @type {number} */
let currentIndex; | 1 | import { options } from 'preact';
/** @type {number} */
let currentIndex;
/** @type {import('./internal').Component} */
let currentComponent;
/** @type {Array<import('./internal').Component>} */
let afterPaintEffects = [];
let oldBeforeRender = options.render;
options.render = vnode => {
if (oldBeforeRender) oldBe... | 1 | 12,523 | TODO: remove this unused import | preactjs-preact | js |
@@ -591,7 +591,7 @@ func (s *HandlerTestSuite) TestValidateJWTSVID() {
},
workloadUpdate: &cache.WorkloadUpdate{},
code: codes.InvalidArgument,
- msg: "token contains an invalid number of segments",
+ msg: "square/go-jose: compact JWS format must have three parts",
},
... | 1 | package workload
import (
"context"
"crypto/x509"
"encoding/base64"
"testing"
"time"
"github.com/golang/mock/gomock"
structpb "github.com/golang/protobuf/ptypes/struct"
"github.com/sirupsen/logrus/hooks/test"
"github.com/spiffe/go-spiffe/proto/spiffe/workload"
"github.com/spiffe/spire/pkg/agent/client"
"gi... | 1 | 12,020 | Hmm leaking the library name out in the Workload API doesn't seem great. Do we want to catch these errors and return a canned "could not parse token" or something instead? | spiffe-spire | go |
@@ -9,12 +9,14 @@ module Travis
}
def install
- self.if '-f build.gradle', 'gradle assemble', fold: 'install', retry: true
+ self.if '-f ./gradlew', './gradlew assemble', fold: 'install', retry: true
+ self.elif '-f build.gradle', 'gradle assemble', fold: 'install',... | 1 | module Travis
module Build
class Script
class Jvm < Script
include Jdk
DEFAULTS = {
jdk: 'default'
}
def install
self.if '-f build.gradle', 'gradle assemble', fold: 'install', retry: true
self.elif '-f pom.xml', 'mvn install -DskipTests=... | 1 | 10,761 | I think `-f gradlew` is better for code unity | travis-ci-travis-build | rb |
@@ -40,4 +40,10 @@ public class FlinkConfigOptions {
.intType()
.defaultValue(100)
.withDescription("Sets max infer parallelism for source operator.");
+
+ public static final ConfigOption<Integer> SOURCE_READER_FETCH_RECORD_BATCH_SIZE = ConfigOptions
+ .key("source.iceberg.reader... | 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 | 34,691 | Is there precedent for this config key? What other keys are similar? The others in this file start with `table.exec.iceberg`. Is there a reason for not continuing with that convention? | apache-iceberg | java |
@@ -1,4 +1,4 @@
-using System;
+using System;
using System.Collections.Generic;
using System.Globalization;
using System.Linq.Expressions; | 1 | using System;
using System.Collections.Generic;
using System.Globalization;
using System.Linq.Expressions;
using System.Reflection;
using System.Text;
using MvvmCross.Platform.Logging;
namespace MvvmCross.Core.Platform.LogProviders
{
internal sealed class ConsoleLogProvider : MvxBaseLogProvider
{
priv... | 1 | 13,338 | Can we avoid no-change changes being committed - they make it harder to distinguish actual changes from code editor changes | MvvmCross-MvvmCross | .cs |
@@ -1,4 +1,4 @@
-//snippet-sourcedescription:[UpdateServerCertificate.java demonstrates how to update the name of an AWS Identity and Access Management (IAM) server certificate.]
+//snippet-sourcedescription:[UpdateServerCertificate.java demonstrates how to update the name of an AWS Identity and Access Management (AWS ... | 1 | //snippet-sourcedescription:[UpdateServerCertificate.java demonstrates how to update the name of 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-sourced... | 1 | 18,253 | AWS Identity and Access Management (IAM) | awsdocs-aws-doc-sdk-examples | rb |
@@ -83,14 +83,10 @@ func NewCommand(licenseCommandName string) *cli.Command {
cmd.RegisterSignalCallback(func() { errorChannel <- nil })
cmdService := &serviceCommand{
- tequilapi: client.NewClient(nodeOptions.TequilapiAddress, nodeOptions.TequilapiPort),
- errorChannel: errorChannel,
- identityHa... | 1 | /*
* Copyright (C) 2017 The "MysteriumNetwork/node" Authors.
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
... | 1 | 14,436 | You dont use this dependency anymore | mysteriumnetwork-node | go |
@@ -86,6 +86,8 @@ public abstract class AbstractSmartStoreTest extends SmartStoreTestCase {
assertTrue("ENABLE_FTS4 flag not found in compile options", compileOptions.contains("ENABLE_FTS4"));
assertTrue("ENABLE_FTS3_PARENTHESIS flag not found in compile options", compileOptions.contains("ENABLE_FTS3_PARENTHESI... | 1 | /*
* Copyright (c) 2011, salesforce.com, inc.
* All rights reserved.
* Redistribution and use of this software in source and binary forms, with or
* without modification, are permitted provided that the following conditions
* are met:
* - Redistributions of source code must retain the above copyright notice, this... | 1 | 15,211 | Here is the test that checks that the sqlcipher in use was compiled with the right flags | forcedotcom-SalesforceMobileSDK-Android | java |
@@ -199,6 +199,8 @@ public class LoginServerManager {
} catch (Exception e) {
Log.w("LoginServerManager.getLoginServersFromRuntimeConfig",
"Exception thrown while attempting to read array, attempting to read string value instead");
+ }
+ if (mdmLoginServers == null) {
final String loginServer = runti... | 1 | /*
* Copyright (c) 2014, salesforce.com, inc.
* All rights reserved.
* Redistribution and use of this software in source and binary forms, with or
* without modification, are permitted provided that the following conditions
* are met:
* - Redistributions of source code must retain the above copyright notice, this... | 1 | 14,776 | Turns out that if the hosts are not in an `array`, an `Exception` is not thrown anymore :-( It simply returns `null`. So, we need to attempt to parse a `string` outside the `catch` block for it to work. | forcedotcom-SalesforceMobileSDK-Android | java |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.