patch stringlengths 18 160k | callgraph stringlengths 4 179k | summary stringlengths 4 947 | msg stringlengths 6 3.42k |
|---|---|---|---|
@@ -135,6 +135,13 @@ class CI_DB_oci8_driver extends CI_DB {
*/
protected $_count_string = 'SELECT COUNT(1) AS ';
+ /**
+ * OCI8 ROWID
+ *
+ * Used by _execute() to fetch Oracle ROWID
+ */
+ protected $_oci8_rowid = -1;
+
// --------------------------------------------------------------------
/**
| [CI_DB_oci8_driver->[_limit->[version],_list_columns->[escape],field_data->[query,escape,result_object],_delete->[where],_list_tables->[escape_like_str],stored_procedure->[display_error,_bind_params,query],insert_id->[display_error]]] | Constructor for a count object. Checks if the database name and hostname are valid and if so sets it to the original DS. | Why does this default to -1? |
@@ -45,13 +45,9 @@ def supports_firefox(file_obj):
max__version_int__gte=version_int(settings.MIN_NOT_D2C_VERSION))
-def get_endpoint(file_obj):
- """Get the endpoint to sign the file, depending on its review status."""
- server = settings.SIGNING_SERVER
- if (file_obj.status == amo.STATUS_BET... | [sign_file->[get_endpoint,call_signing,supports_firefox],call_signing->[SigningError],sign_multi->[call_signing]] | Get the endpoint to sign the file depending on its review status. | is this the meat of it? I guess I was expecting a `try`/`except` block to catch signing errors? |
@@ -95,7 +95,7 @@ func ReadinessHandler(probes []Probes, urlProbes []HTTPProbe) http.Handler {
}
}
- setProbeResponse(w, http.StatusOK, "Service is ready")
+ setProbeResponse(w, http.StatusOK, constants.HTTPServerHealthReadinessPath)
})
}
| [Probe->[Close,NewRequest,Do],Write,GetID,Warn,Readiness,Sprintf,HandlerFunc,Probe,Msgf,New,Liveness,WriteHeader] | setProbeResponse returns a handler that writes a response with the given code if the probe is Probe returns true if the service is alive. | The 3rd argument is a message, which seems to be shown to the client fetching this endponit. It seems to me that we are switching the message of the response here from `Service is ready` to `/health/ready`. It does not seem like a big deal to make this change. But I'd be surprised to see a path in the body of the respo... |
@@ -12,6 +12,10 @@ import (
"github.com/smartcontractkit/chainlink/store/models"
)
+var (
+ BridgeResultMustBeJSONObjectError = errors.New("Bridge result must be a valid JSON object")
+)
+
// Bridge adapter is responsible for connecting the task pipeline to external
// adapters, allowing for custom computations ... | [postToExternalAdapter->[NewBuffer,Marshal,NewRequest,Do,Close,String,Errorf,ReadAll,Set],Perform->[BridgeResponseURL,handleNewRun,Finished,PendingBridge],handleNewRun->[SetError,Sprintf,postToExternalAdapter,Merge],MarshalJSON->[Marshal,String],Errorf,Unmarshal,Merge] | Perform creates a new Bridge object from the input RunResult and returns it. ToExternalAdapter - post to external adapter. | I believe the convention for errors is to have the prefix `Err` or `Error`. I understand we didn't have that before with the private variable. |
@@ -380,8 +380,8 @@ public class StreamWriteOperatorCoordinator
// The executor thread inherits the classloader of the #handleEventFromOperator
// caller, which is a AppClassLoader.
Thread.currentThread().setContextClassLoader(getClass().getClassLoader());
- // sync Hive if is enabled in batch... | [StreamWriteOperatorCoordinator->[handleWriteMetaEvent->[addEventToBuffer],setExecutor->[close],doCommit->[reset],initInstant->[reset,startInstant],commitInstant->[commitInstant,sendCommitAckEvents,reset],handleBootstrapEvent->[initInstant],TableState->[create->[TableState]],handleEndInputEvent->[addEventToBuffer,syncH... | This method is called when the end of the input event is received. It commits the current. | `synchronously if it is` |
@@ -43,6 +43,10 @@ class Charmpp(Package):
# Patch is no longer needed in versions 6.8.0+
patch("mpi.patch", when="@:6.7.1")
+ # Patch for AOCC
+ patch('charm_6.7.1_aocc.patch', when="@6.7.1 %aocc", level=1)
+ patch('charm_6.8.2_aocc.patch', when="@6.8.2 %aocc", level=3)
+
# support Fujitsu co... | [Charmpp->[install->[join_path,walk,mkdirp,basename,satisfies,append,build,Executable,extend,copy,rename,format,islink,remove,InstallError,stat,rmtree],charmarch->[machine,Version,update,startswith,InstallError],setup_dependent_build_environment->[set],check_build->[join_path,make],depends_on,conflicts,version,patch,on... | Get a list of all version - specific C ABI - related objects. 66726934df34aaeeed59650dd3a0cc. | Are you patching only these two versions because they are the only one tested with `%aocc` or because they are the only one that need fixing? |
@@ -58,6 +58,7 @@ import pandas as pd
import apache_beam as beam
from apache_beam.dataframe import expressions
from apache_beam.dataframe import frames # pylint: disable=unused-import
+from apache_beam.dataframe import pandas_top_level_functions
from apache_beam.dataframe import transforms
from apache_beam.datafr... | [teststring->[TestEnvironment,run,fake_pandas_module,summarize,BeamDataframeDoctestRunner],_DeferrredDataframeOutputChecker->[output_difference->[fix],check_output->[reset,fix],fix->[sort_and_normalize],compute_using_beam->[concat->[concat],_InMemoryResultRecorder,concat,get_recorded,record_fn]],TestEnvironment->[fake_... | A base class for the objects that are created by Beam. Object - > object. | It looks like this file is missing |
@@ -41,6 +41,9 @@ public final class RxtxChannelOption<T> extends ChannelOption<T> {
public static final RxtxChannelOption<Paritybit> PARITY_BIT =
new RxtxChannelOption<Paritybit>("PARITY_BIT");
+
+ public static final RxtxChannelOption<Integer> WAIT_TIME =
+ new RxtxChannelOption<... | [No CFG could be retrieved] | private static final int DATA_BITS = 0 ;. | Please add the explantation of this to RxtxChannelConfig table like the others. |
@@ -231,12 +231,14 @@ class BinaryInstaller
return "@ECHO OFF\r\n".
"setlocal DISABLEDELAYEDEXPANSION\r\n".
"SET BIN_TARGET=%~dp0/".trim(ProcessExecutor::escape(basename($link, '.bat')), '"\'')."\r\n".
+ "SET COMPOSER_BIN_DIR=%~dp0\r\n".
"{$... | [BinaryInstaller->[initializeBinDir->[ensureDirectoryExists],generateWindowsProxyCode->[findShortestPath],installFullBinaries->[installUnixyProxyBinaries,generateWindowsProxyCode,writeError,getName],removeBinaries->[initializeBinDir,isDirEmpty,unlink,getBinaries],installUnixyProxyBinaries->[generateUnixyProxyCode],inst... | Generates code for a windows proxy. | @johnstevenson do you see any problem with this? |
@@ -101,14 +101,16 @@ public class StatusLoggerTest {
@Test
public void TestTrace() {
statusLogger.initialize(getProperties(LogLevel.TRACE), queryableStatusAggregator);
+ statusLogger.setScheduledExecutorService(new RunOnceScheduledExecutorService());
statusLogger.start();
- ... | [StatusLoggerTest->[getProperties->[name,setProperty,Properties],init->[StatusLogger,thenReturn,mock,setAccessible,getDeclaredField,set,setInt,spy,getModifiers],TestDebug->[start,getProperties,debug,initialize],TestError->[start,getProperties,error,initialize],TestErrorException->[thenThrow,getProperties,error,start,IO... | TestTrace and TestDebug. | With the change to ensure that the task is always run, can Mockito.timeout() be removed from all test methods? |
@@ -29,11 +29,14 @@ class PyLlvmlite(PythonPackage):
"""A lightweight LLVM python binding for writing JIT compilers"""
homepage = "http://llvmlite.readthedocs.io/en/latest/index.html"
- url = "https://pypi.io/packages/source/l/llvmlite/llvmlite-0.20.0.tar.gz"
+ url = "https://pypi.io/packages/sou... | [PyLlvmlite->[depends_on,version]] | A lightweight LLVM python binding for writing JIT compilers. | is this a new restriction? or was it missing before? |
@@ -1309,7 +1309,7 @@ def sequence_conv(input,
return helper.append_activation(pre_act)
-def sequence_softmax(input, param_attr=None, bias_attr=None, use_cudnn=False):
+def sequence_softmax(input, use_cudnn=False):
"""
This function computes the softmax activation among all time-steps for each
s... | [ctc_greedy_decoder->[topk],image_resize->[_is_list_or_turple_],sequence_first_step->[sequence_pool],logical_xor->[_logical_op],elementwise_pow->[_elementwise_op],elementwise_min->[_elementwise_op],elementwise_max->[_elementwise_op],logical_not->[_logical_op],conv2d->[_get_default_param_initializer],logical_and->[_logi... | This function computes the softmax activation among all time - steps for each sequence of all time - Returns the softmax_out function if the node is missing. | Add `name` for in the interface. |
@@ -48,7 +48,11 @@ class BlackSetup:
async def setup_black(black: Black) -> BlackSetup:
config_path: Optional[str] = black.options.config
config_snapshot = await Get[Snapshot](
- PathGlobs(include=tuple([config_path] if config_path else []))
+ PathGlobs(
+ include=tuple([config_path] if config_path el... | [lint->[create],fmt->[create],BlackArgs->[create->[BlackArgs]],setup_black->[BlackSetup]] | Setup a Black instance. | Nit (probably overengineering): Here, the only thing that changes from tool to tool is the name. Could we extract something common? |
@@ -27,7 +27,7 @@ import org.springframework.data.redis.core.RedisTemplate;
*/
@Configuration("casAcceptableUsagePolicyRedisConfiguration")
@EnableConfigurationProperties(CasConfigurationProperties.class)
-@ConditionalOnProperty(prefix = "cas.acceptable-usage-policy.core", name = "enabled", havingValue = "true", ma... | [CasAcceptableUsagePolicyRedisConfiguration->[acceptableUsagePolicyRepository->[redisAcceptableUsagePolicyTemplate]]] | Creates a new object that stores AUP decisions in a mongo database. The object. | I am not sure I follow. The second bit here translates to `cas.acceptable-usage-policy.core.redis.enabled`? Perhaps an easier way would be to just declare two annotations each for separate conditions? |
@@ -933,12 +933,12 @@ function contact_block() {
$a = get_app();
$shown = get_pconfig($a->profile['uid'],'system','display_friend_count');
- if($shown === false)
+ if ($shown === false)
$shown = 24;
- if($shown == 0)
+ if ($shown == 0)
return;
- if((! is_array($a->profile)) || ($a->profile['hide-friends']... | [dlogger->[save_timestamp],get_intltext_template->[save_timestamp],get_plink->[remove_baseurl],replace_macros->[save_timestamp,replace_macros,template_engine,getMessage],text_highlight->[setRenderer,highlight],load_view_file->[save_timestamp],logger->[save_timestamp],get_markup_template->[save_timestamp,template_engine... | contact_block - block all contacts contact_block - block. | Here are some more missing brackets. Do you want to rewrote in several passes or is it planned to be perfect with the first one? |
@@ -521,6 +521,7 @@ func (t *InspecJobTask) reportIt(ctx context.Context, job *types.InspecJob, cont
report.SourceRegion = job.TargetConfig.TargetBaseConfig.Region
report.SourceAccountId = job.SourceAccountID
report.AutomateManagerId = job.ManagerID
+ report.AutomateManagerType = job.ManagerType
ipAddress := ne... | [reportIt->[Format,NewReader,Unmarshal,UTC,Now,ProcessComplianceReport,String,Wrap,ParseIP,Debugf],OnTaskComplete->[Err,Continue,Error,Warn,WithFields,Get,WithError,GetParameters,Fail,Wrap,EnqueueTask,GetPayload,Complete,Debugf],OnStart->[Wrapf,Continue,Error,WithError,Now,GetParameters,Fail,Wrap,EnqueueTask],handleCom... | reportIt processes a compliance report from the content and writes it to the ingest service. | this is where we stick the manager type on the report |
@@ -291,6 +291,7 @@ FW_VERSIONS = {
b'\xf1\x00TM ESC \x03 103\x18\x11\x07 58910-S2600\xf1\xa01.03',
b'\xf1\x00TM ESC \x0c 103\x18\x11\x08 58910-S2650',
b'\xf1\x00TM ESC \x0c 103\x18\x11\x08 58910-S2650\xf1\xa01.03',
+ b'\xf1\x00TM ESC \x02 104\031\a\a 58910-S2600\xf1\xa01.04',
],
(Ec... | [dbc_dict,set] | A list of all possible ata - modifiers for the given sequence of tokens. Return a list of all possible conditions for a sequence of sequence sequence values. \ x1b [ 1mNAME \ x1b [ 2mNAME \ x. | Tried `x1f` to replace `031`, however it didn't fix the match until I added it unaltered. |
@@ -387,10 +387,15 @@ var Recording = {
* @param show {true} to show the recording button, {false} to hide it
*/
showRecordingButton (show) {
- if (_isRecordingButtonEnabled() && show) {
- $('#toolbar_button_record').css({display: "inline-block"});
+ let isVisible = show && _is... | [No CFG could be retrieved] | Displays the button that displays the message dialog and displays the button that displays the message dialog. Sets the recording state. | The variable above should probably be renamed because if (isVisible) showElement(); doesn't make sense. The console log above also prints the wrong message. The recording is _not_ visible at this point, it will be made visible after we call showElement. Let's call the variable isShow. |
@@ -388,7 +388,8 @@ func printObject(
// printResourceOutputProperties prints only those properties that either differ from the input properties or, if
// there is an old snapshot of the resource, differ from the prior old snapshot's output properties.
-func getResourceOutputsPropertiesString(step deploy.Step, inde... | [Close->[Close],Chdir->[Wrapf,Chdir,IgnoreError,Getwd],Walk->[Next,IgnoreError,Apply,Start,Close,Assert],IsObject,IsAssets,GetProject,Old,ArrayValue,NewArchiveProperty,Assertf,BoolValue,DiffLinesToChars,DiffMain,IsBool,PropertyKey,NewEvalSource,NewPlan,IsNull,Diff,Walk,IsOutput,Color,Strings,preludeEvent,Itoa,NewAssetP... | Print out the maximum with of the given keys. print if the maxkey is present in the input object. | Nit - was this formatting change needed? |
@@ -263,12 +263,10 @@ namespace System.Windows.Forms
{
get
{
- if (systemIAccessible != null)
- {
- return (AccessibleRole)systemIAccessible.get_accRole(NativeMethods.CHILDID_SELF);
- }
-
- return Accessibl... | [AccessibleObject->[GetItem->[GetItem],ScrollIntoView->[ScrollIntoView],GetPropertyValue->[GetPropertyValue],GetSelected->[GetChild,GetChildCount],accDoDefaultAction->[accDoDefaultAction,DoDefaultAction],get_accRole->[GetAccessibleChild,get_accRole],get_accState->[GetAccessibleChild],get_accDescription->[get_accDescrip... | Gets or sets the parent of an object. Gets the accessible child string?. | I would prefer to move these checks into **`get_accRole`** method. The result will never be null and we can avoid NRE throwing in other classes. Please check it for ComboBox and ListBoxItem AccessibleObjects. Also, please check if it is possible to change without touching many other classes, that use **`get_accRole`**.... |
@@ -213,6 +213,8 @@ class AmpAccordion extends AMP.BaseElement {
/**
* Toggles section between expanded or collapsed.
+ * @param {!Element} section
+ * @param {boolean=} opt_forceExpand
* @private
*/
toggle_(section, opt_forceExpand = undefined) {
| [No CFG could be retrieved] | Get previous state from sessionStorage. onClick - Force expand - single - section to be expanded. | cleanup nit: unspecified arguments are `undefined` by default, so it shouldn't need to be explicitly stated. |
@@ -174,6 +174,12 @@ func ValidateHostSubnet(hs *networkapi.HostSubnet) field.ErrorList {
}
}
+ for i, egressCIDR := range hs.EgressCIDRs {
+ if _, err := validateCIDRv4(egressCIDR); err != nil {
+ allErrs = append(allErrs, field.Invalid(field.NewPath("egressCIDRs").Index(i), egressCIDR, err.Error()))
+ }
+ ... | [Size,Index,DeepEqual,IsDNS1123Subdomain,NewPath,Required,Error,ParseCIDRMask,Child,Errorf,To4,ValidateObjectMeta,ValidVNID,ParseIP,CIDRsOverlap,Invalid,Sprintf,ValidateObjectMetaUpdate,String] | ValidateHostNetworkID validates a Host object and returns a list of all encountered errors. PathSegmentName is used to check if the fields in the path are valid. | Don't we want to block updating EgressIPs when EgressCIDRs field is present in ValidateEgressNetworkPolicyUpdate()? |
@@ -41,6 +41,10 @@ public class ExtensionsConfig
@JsonProperty
private String hadoopContainerDruidClasspath = null;
+ //Only applicable when hadoopContainerDruidClasspath is explicitly specified.
+ @JsonProperty
+ private boolean addExtensionsToHadoopContainer = false;
+
@JsonProperty
private List<Stri... | [No CFG could be retrieved] | Returns true if the current class loader is the same as the passed in . | minor nit: Maybe throw exception in case user has set this to true and hadoopContainerDruidClasspath is still null. |
@@ -164,6 +164,9 @@ public class RedundantTypeCastCheck extends IssuableSubscriptionVisitor {
private static boolean isUnnecessarySubtypeCast(Type childType, TypeCastTree typeCastTree, Type parentType) {
boolean isArgument = skipParentheses(typeCastTree.parent()).is(Tree.Kind.ARGUMENTS);
+ if (isArgument &... | [RedundantTypeCastCheck->[isPrimitiveWrapperInConditional->[isPrimitiveWrapper,isPrimitive,skipParentheses,is,parent],targetType->[symbolType,type,targetTypeFromMethodSymbol,skipParentheses,is,symbol,kind,parent,constructorSymbol],isRawTypeOfParameterizedType->[erasure,isParameterized,equals],targetTypeFromMethodSymbol... | Checks if a type cast tree is necessary to cast a child type to a subtype of a. | Any reason why you used an early return here, instead of including this logic into the returned boolean expression? |
@@ -104,6 +104,7 @@ final class IOUringEventLoop extends SingleThreadEventLoop implements IOUringCom
int fd = ch.socket.intValue();
channels.put(fd, ch);
+ ringBuffer.ioUringSubmissionQueue().incrementHandledFds();
}
void remove(AbstractIOUringChannel ch) {
| [IOUringEventLoop->[newTaskQueue->[newTaskQueue],handle->[remove],remove->[remove],run->[closeAll]]] | Add a Channel to the map. | I think you don't want to increment here in the case that `channels.put` returns non-null, right? |
@@ -590,8 +590,6 @@ void gui_init(struct dt_iop_module_t *self)
g->brightness = dt_bauhaus_slider_from_params(self, N_("brightness"));
g->saturation = dt_bauhaus_slider_from_params(self, N_("saturation"));
- dt_bauhaus_widget_set_label(g->brightness, NULL, NC_("lowpass", "brightness"));
-
gtk_widget_set_too... | [No CFG could be retrieved] | Initialize the data structures for the given module. - - - - - - - - - - - - - - - - - -. | This is certainly a leftover from an earlier refactoring. See abbf0c380b496f6c8f8dd3da1ac82f8b2d0563d7. |
@@ -0,0 +1,15 @@
+# frozen_string_literal: true
+
+module HttpLanguageParser
+ def self.parse(header)
+ # Rails I18n uses underscores between the locale and the region; the request
+ # headers use hyphens.
+ require 'http_accept_language' unless defined? HttpAcceptLanguage
+ available_locales = I18n.availa... | [No CFG could be retrieved] | No Summary Found. | Is there a specific error we're expecting here? I usually try and avoid a blank rescue since things like a typo will go unnoticed. |
@@ -134,11 +134,12 @@ class ModelTestCase(AllenNlpTestCase):
self.model.eval()
single_predictions = []
for i, instance in enumerate(self.dataset.instances):
- dataset = Dataset([instance])
+ dataset = InMemoryDataset([instance])
tensors = dataset.as_tensor_d... | [ModelTestCase->[assert_fields_equal->[assert_fields_equal]]] | Ensures that the batch predictions are consistent. | Minor nitpick, and I'm pretty sure I'm the one who suggested this in the first place, so sorry. But it seems unfortunate to make the typical use case more verbose so that we can handle the lazy case. What do you think of making the base class `AbstractDataset`, or something, and keeping `Dataset` as the name for the in... |
@@ -12,6 +12,11 @@ import numpy as np
import collections.abc
from ...externals.decorator import decorator
+VALID_BROWSER_BACKENDS = (
+ 'matplotlib',
+ 'pyqtgraph'
+)
+
VALID_3D_BACKENDS = (
'pyvistaqt', # default 3d backend
'mayavi',
| [_alpha_blend_background->[copy],_check_color->[,TypeError,type,ValueError,to_rgb,isinstance,format,array],_get_colormap_from_array->[ListedColormap,get_cmap,isinstance,array],run_once->[hasattr,fun],_init_qt_resources->[qInitResources]] | A function to return a color object for a single object. Return a color object that is a color object that is a tuple of colors with alpha bl. | here again I wonder if `BROWSE` is better than `BROWSER` |
@@ -304,7 +304,10 @@ class BuildFileAddress(Address):
"""Convert this BuildFileAddress to an Address."""
# This is weird, since BuildFileAddress is a subtype of Address, but the engine's exact
# type matching requires a new instance.
- # TODO: Possibly BuildFileAddress should wrap an A... | [BuildFileAddress->[to_address->[Address]],Address->[sanitize_path->[InvalidSpecPath],check_target_name->[InvalidTargetName],parse->[parse_spec],__init__->[sanitize_path,check_target_name]],parse_spec->[prefix_subproject,normalize_absolute_refs]] | Convert this BuildFileAddress to an Address. | AFAIK, constructors are generally excluded from a Liskov sense. Still agree with the general gist though. |
@@ -2,15 +2,13 @@
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
-#nullable disable
-
namespace System.Windows.Forms
{
public class DataGridViewRowStateChangedEventArgs : EventArgs
{
public DataGridViewRo... | [No CFG could be retrieved] | EventArgs for the DataGridViewRow and DataGridViewElementStates that are triggered when a. | This looks a pure omission, our API never pass null into here, nor we ever validate this property for null. If anything we should throw a ANE in the .ctor. This is a breaking change, but in line with all the work with been doing. |
@@ -695,10 +695,10 @@ rebuild_one_queue(struct rebuild_iter_obj_arg *iter_arg, daos_unit_oid_t *oid,
rdone->ro_oid = *oid;
uuid_copy(rdone->ro_cont_uuid, iter_arg->cont_uuid);
- D_DEBUG(DB_REBUILD, DF_UOID" %p dkey "DF_KEY" rebuild on idx %d max eph"
- " "DF_U64" iod_num %d\n", DP_UOID(rdone->ro_oid), rdone,
- ... | [No CFG could be retrieved] | - DER - encode - decode - decode - decode - decode - decode - decode - decode find the next in the list of iods Set the key to be read. | (style) code indent should use tabs where possible |
@@ -1285,15 +1285,12 @@ class TypeTranslator(TypeVisitor[Type]):
def visit_type_list(self, t: TypeList) -> Type:
return t
- def visit_error_type(self, t: ErrorType) -> Type:
+ def visit_callable_argument(self, t: CallableArgument) -> Type:
return t
def visit_any(self, t: AnyType) -... | [TypeQuery->[visit_star_type->[accept],visit_overloaded->[items],visit_type_type->[accept],query_types->[accept]],TypeList->[serialize->[serialize],deserialize->[TypeList,deserialize]],TypeStrVisitor->[visit_typeddict_type->[accept,items],visit_star_type->[accept],visit_instance->[name],visit_tuple_type->[accept],visit... | Return a type that can be visited. | Also a recursive call here! |
@@ -67,8 +67,8 @@ func (cs *ContainerService) setKubeletConfig() {
"--image-pull-progress-deadline": "30m",
}
- // AKS overrides
- if cs.Properties.IsHostedMasterProfile() {
+ // Set --non-masquerade-cidr if ip-masq-agent is disabled on AKS
+ if cs.Properties.IsHostedMasterIPMasqAgentDisabled() {
defaultKu... | [setKubeletConfig->[Itoa,IsKubernetesVersionGe,Contains,IsNVIDIADevicePluginEnabled,IsTrueBoolPointer,IsHostedMasterProfile],IsKubernetesVersionGe] | setKubeletConfig sets the kubelet configuration This function is used to configure a static Windows Kubelet. This function is used to set the default kubelet config values. This function is used to set the missing kubelet config values for all agent pools. | let's extend the unit tests to include this case |
@@ -11,6 +11,8 @@ class StoriesController < ApplicationController
]
}.freeze
+ SIGNED_OUT_RECORD_COUNT = (Rails.env.production? ? 60 : 10).freeze
+
before_action :authenticate_user!, except: %i[index search show]
before_action :set_cache_control_headers, only: %i[index search show]
| [StoriesController->[assign_user_and_org->[present?,user,organization],assign_second_and_third_user->[find,third_user_id,blank?,present?,second_user_id],handle_base_index->[headers,decorate,render,decorate_collection,campaign_sidebar_enabled?,set_surrogate_key_header],redirect_if_view_param->[redirect_to,id],assign_use... | Controller for the class The base class for the object that can be used to assign the necessary variables to the object. | Obligatory generalization question: will every community want the same values, or do we need to account for configurability here? |
@@ -688,11 +688,13 @@ def _execute_upload(context, error_report):
import requests
q = 0
url = context.error_upload_url
- response = requests.post(url, headers=headers, timeout=_timeout, data=data)
+ response = requests.post(url, headers=headers, timeout=_timeout, data=data,
+ ... | [handle_exception->[print_conda_exception,print_unexpected_error_message],_print_exception_message_and_prompt->[_calculate_ask_do_upload],print_unexpected_error_message->[_print_exception_message_and_prompt,_execute_upload],maybe_raise->[print_conda_exception],conda_exception_handler->[handle_exception]] | Upload a single node in the network. | `q` ? maybe `retries`, `retry_counter`? |
@@ -499,6 +499,14 @@ public class HostResponse extends BaseResponse {
detailsCopy.remove("username");
detailsCopy.remove("password");
+ if(detailsCopy.containsKey(Host.HOST_UEFI_ENABLE)) {
+ this.setUefiCapabilty(Boolean.parseBoolean((String) detailsCopy.get(Host.HOST_UEFI_ENABLE))... | [HostResponse->[getObjectId->[getId],setDetails->[remove,HashMap],setOutOfBandManagementResponse->[OutOfBandManagementResponse],setHostHAResponse->[HostHAResponse]]] | Sets the details for this CVE. | Can be just set to false |
@@ -97,6 +97,10 @@ func CreateIssue(ctx *context.APIContext, form api.CreateIssueOption) {
if form.Closed {
if err := issue.ChangeStatus(ctx.User, ctx.Repo.Repository, true); err != nil {
+ if models.IsErrDependenciesLeft(err) {
+ ctx.Error(http.StatusPreconditionFailed, "", fmt.Sprintf("cannot close this i... | [Status,GetIssueByIndex,IsPoster,IsWriter,UpdateIssue,Error,IsErrIssueNotExist,ChangeStatus,UpdateIssueUserByAssignee,ChangeMilestoneAssign,JSON,ParamsInt64,StateType,ToLower,IsErrUserNotExist,GetUserByName,Query,APIFormat,Sprintf,SetLinkHeader,NewIssue,GetIssueByID,QueryInt,Issues] | CreateIssue creates a new issue of a repository EditIssueEditForm is a generic action that will update the issue with the given form parameters. | Why fmt.Sprintf when there are no `%` verbs? |
@@ -522,8 +522,6 @@ class Order(ResourceBody):
:ivar .Error error: Any error that occurred during finalization, if applicable.
"""
identifiers = jose.Field('identifiers', omitempty=True)
- status = jose.Field('status', decoder=Status.from_json,
- omitempty=True, default=STATUS_P... | [ChallengeBody->[encode->[_internal_name],to_partial_json->[to_partial_json],fields_from_json->[from_json],__init__->[_internal_name]],Authorization->[challenges->[from_json]],NewRegistration->[Resource],Directory->[from_json->[from_json],__getitem__->[_canon_key]],NewOrder->[Resource],Registration->[phones->[_filter_c... | A class to hold all of the fields related to a single - certificate order. Reads a single from a JSON string. | Although we don't use the returned status, sounds like an `Order` object can come back with a status inside it, which we should retain the ability to parse. So we just want to get the default out I think so that it doesn't fill it in for a `NewOrder`. This is based on my understanding of #5857; if you interpreted that ... |
@@ -155,6 +155,15 @@ func (pkg Package) toMapStr() common.MapStr {
return mapstr
}
+// entityID creates an ID that uniquely identifies this package across machines.
+func (pkg Package) entityID(hostID string) string {
+ h := system.NewEntityHash()
+ binary.Write(h, binary.LittleEndian, []byte(hostID))
+ binary.Wri... | [Close->[Close],reportState->[String],Close,String,toMapStr] | toMapStr converts a Package to a MapStr. | Should we consider the same version being uninstalled and reinstalled as a different entity (installtime)? If we want to be really strict I think we should. But I'm not sure how helpful that would be. May actually help detect package repo poisoning. We can always improve that later, however. Perhaps a follow-up improve... |
@@ -353,14 +353,14 @@ describe PublicBody, " when indexing authorities by tag" do
body.save!
update_xapian_index
- xapian_object = ActsAsXapian::Search.new([PublicBody], "tag:mice", :limit => 100)
+ xapian_object = ActsAsXapian::Search.new([PublicBody], "tag:mice", limit: 100)
expect(xapian_objec... | [all,new,size,describe,public_bodies,match_array,results,tag_string,about_me,where,it,dup,name,map,to,save!,before,info_request_events,with_duplicate_xapian_job_creation,destroy,strip_heredoc,require,user,dirname,short_name,destroy_and_rebuild_xapian_index,title,id,url_name,info_requests,eq,users,info_request,reindex_r... | when indexing authorities by tag when only indexing selected things on a rebuild. | Line is too long. [92/80] |
@@ -531,7 +531,12 @@ func (rm *resmon) SupportsFeature(ctx context.Context,
case "secrets":
hasSupport = true
case "resourceReferences":
- hasSupport = cmdutil.IsTruthy(os.Getenv("PULUMI_EXPERIMENTAL_RESOURCE_REFERENCES"))
+ hasSupport = true
+
+ // If the experimental flag is explicitly set to a falsy value,... | [ReadResource->[getDefaultProviderRef],handleRequest->[newRegisterDefaultProviderEvent],StreamInvoke->[StreamInvoke],Invoke->[Invoke],serve->[handleRequest],RegisterResource->[getDefaultProviderRef],getDefaultProviderRef,serve] | SupportsFeature returns a response with a boolean indicating if the feature is supported by the resource. | I like the idea of keeping a flag to turn off. What do you think of renaming it to `PULUMI_DISABLE_RESOURCE_REFERENCES` to match some of our other env vars for disabling functionality (e.g. `PULUMI_DISABLE_PROVIDER_PREVIEW`), and making it truthy to disable? |
@@ -0,0 +1,12 @@
+from saleor.product.filters import ProductCategoryFilter
+
+
+def test(product_type, categories_tree):
+ product_filter = ProductCategoryFilter(data={}, category=categories_tree)
+ (product_attributes, variant_attributes) = product_filter._get_attributes()
+
+ attribut = product_type.product_... | [No CFG could be retrieved] | No Summary Found. | We could use a more meaningful name that describes what this test is actually testing ;) |
@@ -29,7 +29,7 @@ module Voice
end
def message
- expiration = Devise.direct_otp_valid_for.to_i / 60
+ expiration = TwoFactorAuthenticatable.direct_otp_valid_for_seconds / 60
t('voice.otp.message', code: code_with_pauses, expiration: expiration)
end
| [OtpController->[code_with_pauses->[join],show->[render,blank?],message->[t,to_i],code->[decrypt,blank?],cipher->[new,attribute_encryption_key],encrypted_code->[to_s],repeat_count->[to_i],action_url->[build,voice_otp_url],skip_before_action]] | find message in message list. | ditto for the minutes |
@@ -249,6 +249,10 @@ func (c *readWriteCollection) DeleteAll() {
c.stm.DelAll(c.prefix)
}
+func (c *readWriteCollection) DeleteAllWithPrefix(prefix string) {
+ c.stm.DelAll(path.Join(c.prefix, prefix) + "/")
+}
+
type readWriteIntCollection struct {
*collection
stm STM
| [getIndexPath->[indexPath],WatchByIndex->[indexDir,Path,Get,Watch],Create->[Put,Get,Path],GetByIndex->[indexDir,Get],getMultiIndexPaths->[indexPath],Get->[Path,Get],GetBlock->[Path],List->[Get],Delete->[getIndexPath,Get,getMultiIndexPaths,Path],Count->[Get],WatchOne->[Path],Next->[Get],PutTTL->[getIndexPath,getMultiInd... | DeleteAll deletes all items in the read - write collection. | I'd remove the `With` from this method and `ListWithPrefix` I don't think the `With` is adding a ton of clarity. |
@@ -225,7 +225,7 @@ class DoFnRunner(Receiver):
else:
self.dofn_process = lambda context: fn.process(context, *args)
- class CurriedFn(core.DoFn):
+ class CurriedFn(core.OldDoFn):
start_bundle = staticmethod(fn.start_bundle)
process = staticmethod(self.dofn_pr... | [_LoggingContextAdapter->[enter->[enter],exit->[exit]],DoFnRunner->[_process_outputs->[receive],new_dofn_process->[_new_dofn_window_process],finish->[_invoke_bundle_method],receive->[process],process->[new_dofn_process,exit,old_dofn_process,enter,new_dofn_simple_process],__init__->[process->[process],process,CurriedFn,... | Initializes a DoFnRunner object with the given arguments. This function is used to create a new object from a base object. This function fills in the OtherPlaceholders for context window or timestamp - related parameters. | How many `OldDoFn` s are left after this change? And why can't we upgrade this one? |
@@ -23,6 +23,7 @@
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
##############################################################################
from spack import *
+from spack import architecture
class Sqlite(Package):
| [Sqlite->[install->[make,configure],version]] | Creates a new object and installs it into the database. | Maybe we should just include `architecture` in `__all__` in `lib/spack/spack/__init__.py`. |
@@ -188,6 +188,18 @@ class Order(models.Model):
return last_payment.get_charge_status_display()
return None
+ def get_payment_status(self):
+ status = self.get_last_payment_status()
+ if status is None:
+ return ChargeStatus.NOT_CHARGED
+ return status
+
+ d... | [Order->[can_capture->[can_capture,get_last_payment],get_last_payment_status->[get_last_payment],get_last_payment_status_display->[get_last_payment],can_charge->[can_charge,get_last_payment],can_void->[can_void,get_last_payment],total_authorized->[get_last_payment],total_captured->[get_last_payment],can_refund->[can_re... | Get last payment status display. | Is `get_last_payment_status` and `get_payment_status_display` needed anymore, after introducing these two functions? If no, we could get rid of them to simplify the codebase. Now we would have 4 similar functions while maybe we could have only these 2. |
@@ -1038,10 +1038,10 @@ class Exchange:
)
raise PricingError from e
- logger.info(f"{name} price from orderbook {conf_strategy['price_side'].capitalize()}"
- f"side - top {order_book_top} order book {side} rate {rate:.8f}")
+ #logger.info(... | [available_exchanges->[ccxt_exchanges],validate_exchanges->[available_exchanges,validate_exchange,ccxt_exchanges],Exchange->[fetch_ticker->[fetch_ticker,markets],validate_pairs->[markets,get_pair_quote_currency],sell->[create_order,create_dry_run_order],fetch_order_or_stoploss_order->[fetch_order],_async_get_trade_hist... | Calculates bid rate between current ask price and last price of last bid or last ask. Get the last node in the order. | This will be a side-effect of #5284 - which combined buy and sell rate gathering. While it's ok on buy to echo this "whenever" - the log-level on the sell side should be debug to avoid being verbose. I'd change the log-level to debug instead of removing this - as there is (potentially) information there that can be ena... |
@@ -33,9 +33,9 @@ public class TestJettyWebSocketClient {
final ControllerServiceTestContext context = new ControllerServiceTestContext(service, "service-id");
service.initialize(context.getInitializationContext());
final Collection<ValidationResult> results = service.validate(context.getVali... | [TestJettyWebSocketClient->[testValidationSuccess->[getValidationContext,setCustomValue,getInitializationContext,size,ControllerServiceTestContext,validate,JettyWebSocketClient,assertEquals,initialize],testValidationSuccessWithProxy->[getValidationContext,setCustomValue,getInitializationContext,size,ControllerServiceTe... | Test validation required properties. | These references to `Assertions` should be changed to use static imports. |
@@ -518,7 +518,7 @@ void commit_params(struct dt_iop_module_t *self, dt_iop_params_t *p1, dt_dev_pix
if(fabs(d->contrast) <= 1.0f)
{
// linear curve for contrast up to +/- 1
- for(int k = 0; k < 0x10000; k++) d->ctable[k] = d->contrast * (100.0f * k / 0x10000 - 50.0f) + 50.0f;
+ for(int k = 0; k < 0x10... | [No CFG could be retrieved] | private void commit_params ( void missing - related functions. | This is ok, but below... |
@@ -12,6 +12,7 @@ module IbmNotes
"Central Europe Standard Time",
"Fus horari desconegut (1) Standard Time",
"W. Europe Standard Time",
+ "Unknown1 Standard Time",
].freeze
def initialize(person, response_event)
| [PersonEvent->[set_id->[present?],set_attendees->[present?,compact],set_start_and_end_date->[new,error,include?,hour,parse_date,present?,utc],parse_date->[nil?,parse,min,year,month,hour,sec,day,utc],initialize->[set_id,present?,set_start_and_end_date,set_attendees],freeze,attr_accessor]] | Initialize a new object with the data from a response event. | Avoid comma after the last item of an array. |
@@ -145,13 +145,13 @@ export default class KeyphraseInImagesAssessment extends Assessment {
if ( this.altProperties.withAltNonKeyword > 0 && this.altProperties.withAltKeyword === 0 ) {
return {
score: this._config.scores.withAltNonKeyword,
- resultText: i18n.sprintf(
+ resultText: sprintf(
/* Tr... | [No CFG could be retrieved] | This function calculates the result of the image count operation. Expands to the number of images containing an alt attribute with the keyword expands to the. | This should be a single line string. |
@@ -392,6 +392,11 @@ public class ECKeyOutputStream extends KeyOutputStream {
IOException exception) throws IOException {
Throwable t = HddsClientUtils.checkForException(exception);
Preconditions.checkNotNull(t);
+ boolean containerExclusionException = checkIfContainerToExclude(t);
+ if(container... | [ECKeyOutputStream->[getXceiverClientFactory->[getXceiverClientFactory],writeToOutputStream->[write],Builder->[build->[ECKeyOutputStream]],getStreamEntries->[getStreamEntries],checkAndWriteParityCells->[handleStripeFailure],getExcludeList->[getExcludeList],getLocationInfoList->[getLocationInfoList],closeCurrentStreamEn... | Handles an exception while writing a block to the stream. | Format - missing space before the brackets `if(containerExclusionException)` should be `if (containerExclusionException)` |
@@ -83,14 +83,11 @@ void BuildMatrix(Kratos::unique_ptr<typename SparseSpaceType::MatrixType>& rpMdo
EquationIdVectorType destination_ids;
int ierr;
- for (auto& rp_local_sys : rMapperLocalSystems)
- {
+ for (auto& rp_local_sys : rMapperLocalSystems) {
rp_local_sys->CalculateLocalSystem(lo... | [No CFG could be retrieved] | - - - - - - - - - - - - - - - - - - Construct a mapping matrix from the given unique space. | Could this loop be omp parallel? It would be good for hybrid parallelization, if we ever want that. |
@@ -46,7 +46,13 @@ public class MetricsService {
metrics.put(MetricNames.BYTES_READ, String.valueOf(status.getBytesRead()));
metrics.put(MetricNames.BYTES_WRITTEN, String.valueOf(status.getBytesWritten()));
metrics.put(MetricNames.ACTIVE_THREADS, String.valueOf(status.getActiveThreadCount()))... | [MetricsService->[calculateProcessingNanos->[calculateProcessingNanos]]] | Get metrics for a given process group status. | This uses durationNanos, not durationSeconds |
@@ -270,5 +270,10 @@ public class TextLineDemarcator {
void setStartsWithMatch(int startsWithMatch) {
this.startsWithMatch = startsWithMatch == 1 ? true : false;
}
+
+ @Override
+ public String toString() {
+ return "offset:" + this.startOffset + "; length:" + thi... | [TextLineDemarcator->[nextOffsetInfo->[nextOffsetInfo]]] | Sets the startsWithMatch flag. | Why does this take in an `int` and then assign a `boolean` based on it? Why not just take in an `boolean`? |
@@ -27,7 +27,7 @@ class StorageErrorCode(str, Enum):
condition_headers_not_supported = "ConditionHeadersNotSupported"
condition_not_met = "ConditionNotMet"
empty_metadata_key = "EmptyMetadataKey"
- insufficient_account_permissions = "InsufficientAccountPermissions"
+ insufficient_account_permission... | [AccountPermissions->[__or__->[AccountPermissions],__add__->[AccountPermissions]],Services->[__or__->[Services],__add__->[Services]],DictMixin->[items->[items],__ne__->[__eq__],update->[update]],ResourceTypes->[__or__->[ResourceTypes],__add__->[ResourceTypes]],Services,ResourceTypes,AccountPermissions] | Get the license information for a given resource. Check if a resource already exists in the system. | This is an enum of service values and should not be changed. |
@@ -67,4 +67,5 @@ class TestSoftmaxWithCrossEntropyOp2(OpTest):
if __name__ == "__main__":
+ exit(0) # FIXME: xe has bug
unittest.main()
| [TestSoftmaxWithCrossEntropyOp->[test_check_output->[check_output],test_check_grad->[check_grad],setUp->[apply_along_axis,randint,asmatrix,uniform,log,range]],TestSoftmaxWithCrossEntropyOp2->[test_check_output->[check_output],test_check_grad->[check_grad],setUp->[,uniform,apply_along_axis,sum]],main] | The main function of the unit test. | Can we file an issue on this? |
@@ -224,7 +224,8 @@ function waitForExtensionIfStubbed(win, extension) {
*/
function getElementServicePromiseOrNull(win, id, extension, opt_element) {
return dom.waitForBodyPromise(win.document)
- .then(() => waitForExtensionIfStubbed(win, extension))
+ .then(() => waitForExtensionIfPresent(win, extensi... | [waitForBodyPromise,whenBodyAvailable,getServicePromiseOrNullForDoc,includes,getElementServicePromiseOrNull,getExistingServiceForDocInEmbedScope,document,getServicePromiseForDoc,win,nodeType,user,getService,waitForExtension,getElementServiceIfAvailable,ownerDocument,isElementScheduled,getTopWindow,getServicePromise,res... | Returns a promise that resolves with the service with the given id on the given window if available. | Let's move the `extensionScriptsInNode` call into `waitForExtensionIfPresent`. |
@@ -148,6 +148,12 @@ func BuildKubernetesNodeConfig(options configapi.NodeConfig) (*NodeConfig, error
server.PodInfraContainerImage = imageTemplate.ExpandOrDie("pod")
server.CPUCFSQuota = true // enable cpu cfs quota enforcement by default
+ if dockerClient, _, err := docker.NewHelper().GetClient(); err == nil {
... | [Warningf,Duration,NewKubeletAuth,Atoi,SecureTLSConfig,SplitHostPort,Env,UseTLS,Errorf,GetNamedCertificateMap,CertPoolFromFile,GetKubeClient,AnonymousClientConfig,UnsecuredKubeletConfig,Join,Infof,NewKubeletServer,NewAggregate,V,ParseIP,NewDefaultImageTemplate,ExpandOrDie,Resolve,GetOpenShiftClient,NewPlugin,GetCertifi... | Initialize the server object NewAggregate creates a new Aggregate configuration. | @deads2k how do you feel about making server calls in BuildKubernetesNodeConfig? I'd prefer it not do that, but I also don't want config bits mutating after we build the config here |
@@ -41,11 +41,11 @@ import java.util.SortedSet;
public interface GranularitySpec
{
/**
- * Set of all time groups, broken up on segment boundaries. Should be sorted by interval start and non-overlapping.
+ * Iterable all time groups, broken up on segment boundaries. Should be sorted by interval start and non-o... | [No CFG could be retrieved] | Returns an optional set of bucket intervals. | Suggest `sortedBucketIntervals()` to make it clear the results are sorted. |
@@ -167,6 +167,16 @@ public class HttpResponseBuilder extends HttpMessageBuilder implements Initialis
warnMapPayloadButNoUrlEncodedContentType(httpResponseHeaderBuilder.getContentType());
}
httpEntity = createUrlEncodedEntity(event, (Map) payload);
+
+ ... | [HttpResponseBuilder->[initialise->[initialise],emptyInstance->[HttpResponseBuilder,init],build->[build]]] | Build the response. Private method for handling the case where the response body is not null. Resolve status code and reason phrase. | Could you avoid this cast using an intermediate variable? |
@@ -1507,11 +1507,12 @@ vos_dtx_end(struct daos_tx_handle *dth, int result, bool leader)
D_ASSERT(cont != NULL);
if (leader) {
- if (!UMMID_IS_NULL(dth->dth_ent)) {
+ if (!dtx_is_null(dth->dth_ent)) {
struct vos_dtx_entry_df *dtx;
int rc;
- dtx = umem_id2ptr(&cont->vc_pool->vp_umm, dth->dth_ent);... | [No CFG could be retrieved] | d_list_for_each_entry_safe - list_for_each_ END of function dtx_handle_prepared. | (style) line over 80 characters |
@@ -1790,9 +1790,15 @@ class RoundingTest(tf.test.TestCase):
self.assertShapeEqual(np_ceil, oceil)
def _testDtype(self, dtype):
- data = (np.arange(-3, 3) / 4.).reshape([1, 3, 2]).astype(dtype)
- self._compare(data, use_gpu=True)
- self._compare(data, use_gpu=True)
+ data = (np.arange(-3, 3) / 4.)... | [BinaryOpTest->[testInt16Basic->[_compareBoth],testBCast_5D->[_testBCastD],testBCast_2C->[_testBCastC],testBCast_10A->[_testBCastA],testBCast_12C->[_testBCastC],testBCast_10B->[_testBCastB],_testBCastA->[_testBCastByFunc],testBCast_13B->[_testBCastB],testBCast_13D->[_testBCastD],testComplex64Basic->[_compareBoth],testB... | Test if data is of the specified dtype. | How come we have to modify current test behavior? |
@@ -917,7 +917,7 @@ public class VmwareStorageProcessor implements StorageProcessor {
if (!_fullCloneFlag) {
createVMLinkedClone(vmTemplate, dcMo, vmName, morDatastore, morPool);
} else {
- createVMFullClone(vmTemplate, dcMo, dsMo, vmName, morDatastore, morPool);
+ c... | [VmwareStorageProcessor->[copyTemplateToPrimaryStorage->[getName,copyTemplateFromSecondaryToPrimary],removeVmfsDatastore->[getHostDiscoveryMethod,removeVmfsDatastore,getHostsUsingStaticDiscovery,unmountVmfsDatastore],cloneVMFromTemplate->[createVMFullClone,createVMLinkedClone],createVolumeFromSnapshot->[restoreVolumeFr... | clone VM for vols. | "disk provisioning type" not considered in case of linked clone ? |
@@ -0,0 +1,13 @@
+/*
+ * Copyright The OpenTelemetry Authors
+ * SPDX-License-Identifier: Apache-2.0
+ */
+
+package io.opentelemetry.instrumentation.api.instrumenter;
+
+import io.opentelemetry.api.metrics.Meter;
+
+@FunctionalInterface
+public interface RequestMetricsFactory {
+ RequestMetrics create(Meter meter);
+... | [No CFG could be retrieved] | No Summary Found. | Possibly this class could be called `RequestMetrics` and the other `RequestListener` |
@@ -91,6 +91,9 @@ const DESKTOP_HEIGHT_THRESHOLD = 550;
/** @private @const {number} */
const MIN_SWIPE_FOR_HINT_OVERLAY_PX = 50;
+/** @private @const {string} */
+const ADVERTISEMENT_ATTR_NAME = 'advertisement';
+
/**
* The duration of time (in milliseconds) to wait for a page to be loaded,
* before the story... | [AmpStory->[buildSystemLayer_->[element],assertAmpStoryExperiment_->[user,toggleExperiment,removeElement,textContent,appendChild,classList,addEventListener],constructor->[once,timerFor,for],isSwipeLargeEnoughForHint_->[abs],next_->[dev,SHOW_BOOKEND,next,dispatch],getPageDistanceMapHelper_->[getAdjacentPageIds],initiali... | Package of all the classes that are imported by the system. A simple wrapper for the class. | nit: don't feel that strongly, but... why not just 'ad'? |
@@ -27,6 +27,9 @@
#include <string.h> /* memset */
#include <openssl/sha.h> /* SHA_DIGEST_LENGTH */
#include <openssl/rand.h>
+#include <openssl/err.h>
+#include <openssl/dherr.h>
+#include <openssl/dsaerr.h>
#include "crypto/bn.h"
#include "internal/ffc.h"
| [ffc_params_FIPS186_4_generate->[ffc_params_FIPS186_4_gen_verify],ffc_params_FIPS186_2_generate->[ffc_params_FIPS186_2_gen_verify]] | This function checks the passed in parameters for a specific security strength. Generate Unverifiable Generator g. | Unnecessary empty line |
@@ -231,7 +231,7 @@ Var JavascriptGenerator::EntryNext(RecyclableObject* function, CallInfo callInfo
AUTO_TAG_NATIVE_LIBRARY_ENTRY(function, callInfo, _u("Generator.prototype.next"));
- if (!VarIs<JavascriptGenerator>(args[0]))
+ if (!VarIs<DynamicObject>(args[0]) || JavascriptOperators::GetTypeId(args[0... | [No CFG could be retrieved] | Provides a function which creates a new object if the object is not yet created. Check if the given function has a return tag and if so call it. | `VarIs<JavascriptGenerator>` returns true for AsyncGenerators (which are a subclass of Generators) hence had to change these conditions to use an explicit check for Generators instead. |
@@ -42,10 +42,9 @@ namespace System.ComponentModel.Design
{
if (null != provider)
{
- IWindowsFormsEditorService edSvc = (IWindowsFormsEditorService)provider.GetService(typeof(IWindowsFormsEditorService));
- if (edSvc != null)
+ if (provide... | [ObjectSelectorEditor->[Selector->[OnAfterSelect->[ChooseSelectedNodeIfEqual],Clear->[Clear],SetSelection->[SetSelection],OnKeyDown->[ChooseSelectedNodeIfEqual,OnKeyDown,SetValue],Start->[SetSelection],OnKeyPress->[OnKeyPress],ChooseSelectedNodeIfEqual->[SetValue,EqualsToValue],OnNodeMouseClick->[ChooseSelectedNodeIfEq... | Override to provide a special value for the NavBoxTreeView. | Please invert if to reduce nesting |
@@ -212,8 +212,7 @@ namespace Js
// Note: there also could be plain OutOfMemoryException and StackOverflowException, no special handling for these.
if (!exceptionObject->IsDebuggerSkip() ||
exceptionObject == scriptContext->GetThreadContext()->GetPendingOOMErrorObject() ||
- ex... | [No CFG could be retrieved] | This is a helper method that is called from the script context when a helper method is called A try - catch is used to catch all exceptions that occur within the block. | The assert above won't cover this in release builds. I think it's worth adding `!scriptContext ||` above line 214. |
@@ -937,10 +937,13 @@ end_of_options:
if (j > 0) {
total_done++;
BIO_printf(bio_err, "\n");
- if (!BN_add_word(serial, 1))
+ if (!BN_add_word(serial, 1)) {
+ X509_free(x);
goto end;
+ }
... | [No CFG could be retrieved] | finds the n - tuple of the n - tuple of the two - tuple of the finds the next non - zero number in the stack of newly certified certificates and a. | Shouldn't we also free `x` here too? |
@@ -398,6 +398,14 @@ export default class JitsiMeetExternalAPI extends EventEmitter {
}
break;
}
+ case 'email-change': {
+ const user = this._participants[userID];
+
+ if (user) {
+ user.email = data.email;
+ ... | [No CFG could be retrieved] | Setups listeners that are used internally for JitsiMeetExternalAPI. Adds event listener to Meet Jitsi. | Since we don't have a getter I don't think we need this. But it will be nice to have getEmail method. Could you please implement it. |
@@ -66,7 +66,7 @@ func runCmd(c *cli.Context) error {
}
// Gather up the options for NewContainer which consist of With... funcs
- options = append(options, libpod.WithRootFSFromImage(createConfig.ImageID, createConfig.Image, true))
+ options = append(options, libpod.WithRootFSFromImage(createConfig.ImageID, crea... | [NewContainer,GetContainerCreateOptions,Index,CGroupPath,WithShmSize,WithCgroupParent,WriteFile,Add,Done,Error,Args,Marshal,Init,Start,Errorf,Wait,Debugf,WithLabels,WithSELinuxLabels,Wrapf,ID,Cleanup,ExitCode,RemoveContainer,Shutdown,Attach,AddArtifact,Printf,WithShmDir,String,GetLevel,WithRootFSFromImage,WithUser] | Allocate a unique identifier for the container NewContainerCreated creates a new container and stores it in the system. | We should only set useImageVolumes to true if we are doing bindmount image volumes - should not set if we're doing tmpfs, that happens entirely in podman |
@@ -51,6 +51,7 @@ public final class EchoServer {
// Configure the server.
EventLoopGroup bossGroup = new NioEventLoopGroup(1);
EventLoopGroup workerGroup = new NioEventLoopGroup();
+ final EchoServerHandler server_handler = new EchoServerHandler();
try {
ServerBo... | [EchoServer->[main->[initChannel->[EchoServerHandler,addLast,newHandler,pipeline,alloc],SelfSignedCertificate,ServerBootstrap,build,NioEventLoopGroup,childHandler,shutdownGracefully,sync],getProperty,parseInt]] | Main method of the NioServer. | use camel-case please... `serverHandler` |
@@ -131,7 +131,7 @@ def get_prices_of_discounted_specific_product(lines, voucher):
discounted_lines.extend(list(lines))
for line in discounted_lines:
- line_total = calculate_checkout_line_total(line, []).gross
+ line_total = calculate_checkout_line_total(line, discounts).gross
li... | [clean_checkout->[is_valid_shipping_method,is_fully_paid],update_shipping_address_in_checkout->[get_shipping_address_forms],get_or_create_checkout_from_request->[get_or_create_anonymous_checkout_from_token,get_or_create_user_checkout],update_billing_address_in_checkout->[get_summary_without_shipping_forms],get_voucher_... | Get prices of variants belonging to the discounted specific products. | You should pass empty list here in case of discounts==None |
@@ -2582,6 +2582,11 @@ public class Sched {
}
revYesRate = cur.getDouble(0);
revTime = cur.getDouble(1);
+
+ if (cur != null && !cur.isClosed()) {
+ cur.close();
+ }
+
cur... | [Sched->[_resetRevCount->[_walkingCount],_revConf->[_cardConf],dueForecast->[dueForecast],_fillNew->[_resetNew,_fillNew],suspendCards->[removeLrn,remFromDyn],resetCards->[forgetCards],cardCount->[cardCount,_deckLimit],counts->[counts],_getLrnCard->[_fillLrn,getCard,_getLrnCard],_updateStats->[_updateStats],_fillRev->[_... | Returns the estimated eta for the given counts. - Rate. | I was thinking it would be next to do this splitting the existing try/finally block into two. What do you think? |
@@ -0,0 +1,17 @@
+package org.apache.nifi.processors.standard.http;
+
+public enum FilenameStrategy {
+ RANDOM("FlowFile's filename attribute will be a random value."),
+ URL_PATH("FlowFile's filename attribute will be extracted from the remote URL's path. "
+ + "If the path doesn't exist, the filename... | [No CFG could be retrieved] | No Summary Found. | This file is missing the license header. |
@@ -56,7 +56,7 @@ namespace Dynamo.Wpf.Authentication
return navigateSuccess;
}
- internal void ShowShapewaysLogin(ShapewaysClient client)
+ internal void ShowShapewaysLogin(ShapewaysClient.ShapewaysClient client)
{
context.Send((_) =>
{
| [LoginService->[ShowShapewaysLogin->[CenterOwner,LoginUrl,Browser,Close,Loaded,ShowDialog,Send,AbsolutePath,SetToken,LoadCompleted,PathAndQuery,HideScriptErrors],ShowLogin->[CenterOwner,AutodeskSignIn,LocalPath,Navigated,Close,ShowDialog,Send,ToString,InvalidLoginUrl],HideScriptErrors->[GetField,NonPublic,InvokeMember,... | Show the login window. | I am ok with this. But it looks better if there is an alias created for shapeways namespace. |
@@ -25,13 +25,13 @@ func RegisterSCCExecRestrictions(plugins *admission.Plugins) {
}
var (
- _ = admission.Interface(&sccExecRestrictions{})
_ = initializer.WantsAuthorizer(&sccExecRestrictions{})
_ = oadmission.WantsSecurityInformer(&sccExecRestrictions{})
_ = kadmission.WantsInternalKubeClientSet(&sccExecRe... | [SetSecurityInformers->[SetSecurityInformers],ValidateInitialization->[ValidateInitialization],SetInternalKubeClientSet->[SetInternalKubeClientSet],Admit->[Admit],SetAuthorizer->[SetAuthorizer]] | RegisterSCCExecRestrictions registers an admission plugin which will be used to handle the SCC Check if the pod is an attach or exec. | Double check validating admission gets called on exec requests it's not a normal storage impl |
@@ -838,12 +838,13 @@ namespace System
public static DateTime SpecifyKind(DateTime value, DateTimeKind kind)
{
- return new DateTime(value.InternalTicks, kind);
+ if ((uint)kind > (uint)DateTimeKind.Local) ThrowInvalidKind();
+ return new DateTime(value.UTicks | ((ul... | [DateTime->[TryFormat->[TryFormat],TimeToTicks->[TimeToTicks],TryParse->[TryParse],TypeCode->[DateTime],TryParseExact->[TryParseExact],TryCreate->[IsLeapYear,DateToTicks,TimeToTicks],GetDateTimeFormats->[GetDateTimeFormats],ToOADate->[TicksToOADate],IsDaylightSavingTime->[IsDaylightSavingTime],CompareTo->[Compare],GetD... | Determines the time in which the given value is stored in the time zone. | >return new DateTime(value.UTicks | ((ulong)kind << KindShift)) [](start = 12, length = 62) this also can cause the constructor to throw when checking against the MaxTicks? #Closed |
@@ -128,6 +128,8 @@ EMAIL_BACKEND = email_config["EMAIL_BACKEND"]
EMAIL_USE_TLS = email_config["EMAIL_USE_TLS"]
EMAIL_USE_SSL = email_config["EMAIL_USE_SSL"]
+ENABLE_ACCOUNT_CONFIRMATION_BY_EMAIL = True
+
ENABLE_SSL = get_bool_from_env("ENABLE_SSL", False)
if ENABLE_SSL:
| [get_list->[strip,split],get_bool_from_env->[literal_eval,ValueError,format],get_host->[get_current],get_currency_fraction,int,pgettext_lazy,_,parse,append,get_list,dirname,__import__,get,insert,init,config,DjangoIntegration,join,normpath,warn,get_bool_from_env] | Returns a list of email templates for the given user. This is a hack to get the correct URL for the static files. | It should take the value from env and shouldn't be true by default, otherwise it could be a breaking or unwanted change |
@@ -56,7 +56,8 @@ public abstract class AbstractInfluxDBProcessor extends AbstractProcessor {
.build();
public static final PropertyDescriptor INFLUX_DB_CONNECTION_TIMEOUT = new PropertyDescriptor.Builder()
- .name("InfluxDB Max Connection Time Out (seconds)")
+ .name("influxdb... | [AbstractInfluxDBProcessor->[close->[get,set,isDebugEnabled,close,info],getInfluxDB->[getValue,RuntimeException,error,getLocalizedMessage,get,makeConnection,asTimePeriod,set,info],makeConnection->[isBlank,connect,connectTimeout],build]] | Abstract base class for InfluxDB processors. The password field is only valid if it is not empty. | Unfortunately I think we don't want this change to happen. As soon as a processor is released, changing the ``.name()`` property would be a breaking change for existing flows with this processor. I think we might want to revisit all the processor for a 2.0 release but it'd need to be discussed and we would need to prov... |
@@ -25,6 +25,7 @@ use Doctrine\ORM\QueryBuilder;
* @author Charles Sarrazin <charles@sarraz.in>
* @author Kévin Dunglas <dunglas@gmail.com>
* @author Antoine Bluchet <soyuka@gmail.com>
+ * @author Baptiste Meyer <baptiste.meyer@gmail.com>
*/
final class EagerLoadingExtension implements QueryCollectionExtension... | [EagerLoadingExtension->[applyToItem->[getSerializerGroups],applyToCollection->[getSerializerGroups],joinRelations->[joinRelations]]] | Creates an extension for a single node. Returns the array of the group names for the given resource class and context. | @api-platform/core-team Perhaps we need to have a stricter policy for this. Otherwise there will be unbounded growth. :smile: |
@@ -63,9 +63,9 @@ public @interface Reference {
String cluster() default "";
- int connections() default 0;
+ int connections() default -1;
- int callbacks() default 0;
+ int callbacks() default -1;
String onconnect() default "";
| [lazy,cluster,parameters,loadbalance,timeout,interfaceName,registry,onconnect,filter,stub,check,sticky,module,cache,group,application,init,monitor,listener,retries,interfaceClass,stubevent,Retention,validation,Target,generic,url,ondisconnect,injvm,consumer,proxy,connections,owner,reconnect,client,version,callbacks,laye... | This class is used to reference a class that implements the CDI interface. | I wonder if these default value changes will have side effects , have you checked how dubbo treats the default value of each item? |
@@ -17,7 +17,7 @@ try:
except ImportError:
from urllib.parse import urlparse, quote_plus
-from uamqp import (
+from uamqp import ( # type: ignore
AMQPClient,
Message,
authentication,
| [EventHubSharedKeyCredential->[get_token->[_generate_sas_token]],ConsumerProducerMixin->[_do_retryable_operation->[_handle_exception,_backoff],_close_handler->[close],_handle_exception->[_handle_exception],_close_connection->[_close_handler],_open->[close,_create_auth],close->[_close_handler],__exit__->[close]],ClientB... | Creates a new object from a given connection string. This function is used to extract the hostname and sharedaccesskey from the config. | Why? Being it's just an import, I don't get why you would need to do that. mypy can be started with --ignore-missing-imports if the problem was that that uamqp was not in the path. Or better, you add it in the path :) |
@@ -20,6 +20,8 @@ import (
"fmt"
"time"
+ "github.com/pulumi/pulumi/pkg/diag"
+
"github.com/pkg/errors"
"github.com/pulumi/pulumi/pkg/apitype"
| [GetStackResourceOutputs->[ParseStackReference,NewObjectProperty,PropertyKey,Errorf,Snapshot,NewStringProperty,GetStack],GetStackOutputs->[ParseStackReference,GetRootStackResource,Wrap,Errorf,Snapshot,GetStack],Error->[Sprintf],New] | Package backend encapsulates all external components of a cloud provider. ErrNoPreviousDeployment returns an error if there was no previous deployment. | Group with last group of imports below. |
@@ -153,8 +153,15 @@ func GetBootstrapClusterRoles() []authorizationapi.ClusterRole {
},
Rules: []authorizationapi.PolicyRule{
{
- Verbs: sets.NewString("get"),
- NonResourceURLs: sets.NewString("/healthz", "/healthz/*", "/version", "/api", "/oapi", "/osapi", "/api/", "/oapi/", "/osapi/")... | [NewString] | Returns a specification of the rules that can be applied to the resource in the resource tree. is used to provide a custom object for the image builder and image pruner. | is there ever a case where you would grant `/foo` and not `/foo/`? seems like something we should handle in the evaluation |
@@ -26,6 +26,8 @@ class Group < ActiveRecord::Base
has_many :category_reviews, class_name: 'Category', foreign_key: :reviewable_by_group_id, dependent: :nullify
has_many :reviewables, foreign_key: :reviewable_by_group_id, dependent: :nullify
+ belongs_to :flair_image, class_name: 'Upload'
+
has_and_belongs_... | [Group->[automatic_membership_email_domains_format_validator->[add],ensure_automatic_groups!->[refresh_automatic_group!],mentionable_sql_clause->[visibility_levels],validate_grant_trust_level->[add],user_trust_level_change!->[refresh_automatic_group!,desired_trust_level_groups],refresh_automatic_group!->[visibility_lev... | A class that implements the Model interface. Remove all group_names from the category and all the review groups from the category. | This association seems strange to me. I would think that a `Group` -> `has_one :flair_image` rather than `belongs_to` it |
@@ -660,7 +660,8 @@ public final class CheckList {
PrimitivesMarkedNullableCheck.class,
ForLoopVariableTypeCheck.class,
ReplaceGuavaWithJava8Check.class,
- LoggedRethrownExceptionsCheck.class);
+ LoggedRethrownExceptionsCheck.class,
+ CompareStringsBoxedTypesWithEqualsCheck.class);
... | [CheckList->[getDebugChecks->[asList],getJavaChecks->[asList],getChecks->[build],getXmlChecks->[asList],getJavaTestChecks->[asList]]] | Gets the list of all the JavaChecks that are applicable to this JVM. This is a check to see if a given object is a valid object. This is a list of all the checks that are defined in the current context. | maybe put it next to the other one in the list. |
@@ -44,6 +44,8 @@ public class ContainerController {
private final ContainerSet containerSet;
private final Map<ContainerType, Handler> handlers;
+ private static final Logger LOG =
+ LoggerFactory.getLogger(ContainerController.class);
public ContainerController(final ContainerSet containerSet,
... | [ContainerController->[getContainerLocation->[getContainer],quasiCloseContainer->[quasiCloseContainer,getContainer],getContainer->[getContainer],closeContainer->[closeContainer,getContainer],updateDataScanTimestamp->[updateDataScanTimestamp,getContainer],markContainerForClose->[getContainer,markContainerForClose],expor... | Method to provide a controller for a single container. Mark the container for closing. | The indent of wrapped line is 4 space instead of 8. This is a general code style of ozone. Kindly also check the other part of the code which involes wrapped lines. |
@@ -16,10 +16,10 @@ const (
ADSUpdateStr = "ADS"
)
-// Wrapper to create and send a discovery response to an envoy server
-func (s *Server) sendTypeResponse(tURI envoy.TypeURI,
- proxy *envoy.Proxy, server *xds_discovery.AggregatedDiscoveryService_StreamAggregatedResourcesServer,
- req *xds_discovery.DiscoveryRequ... | [sendSDSResponse->[sendTypeResponse],sendAllResponses->[sendTypeResponse]] | sendTypeResponse sends a response to a typeURI. | Would you be so kind to expand abbreviated variable names? I personally find it tough to read `tURI`. Subjectively I believe `typeURI` makes the code easier to read, lower cognitive load. |
@@ -231,7 +231,7 @@ class KeyClient(AsyncKeyVaultClientBase):
return DeletedKey._from_deleted_key_bundle(bundle)
@distributed_trace_async
- async def get_key(self, name: str, version: Optional[str] = None, **kwargs: "**Any") -> Key:
+ async def get_key(self, name: str, version: "Optional[str]" = N... | [KeyClient->[get_key->[get_key],recover_deleted_key->[recover_deleted_key],create_ec_key->[create_key],delete_key->[delete_key],get_deleted_key->[get_deleted_key],purge_deleted_key->[purge_deleted_key],backup_key->[backup_key],restore_key->[restore_key],create_rsa_key->[create_key],import_key->[import_key],create_key->... | Gets a key s attributes and if it s an asymmetric key its public material. | I like the visibility of positional `version` in `get_*` but now that's inconsistent. Anyone have an opinion? |
@@ -98,6 +98,13 @@ class CoverageSubsystem(PythonToolBase):
advanced=True,
help="Path to write the Pytest Coverage report to. Must be relative to build root.",
)
+ register(
+ "--config",
+ type=file_option,
+ default=None,
+ advanced... | [create_coverage_config->[CoverageConfig],setup_coverage->[CoverageSetup],merge_coverage_data->[MergedCoverageData]] | Register options for coverage report. | > "alternative coverage config file" I'm not sure what this means... does it mean something like "or other file in the `.coveragerc` format"? |
@@ -78,7 +78,7 @@ namespace Microsoft.Extensions.DependencyInjection.ServiceLookup
protected override Type VisitScopeCache(ServiceCallSite scopedCallSite, CallSiteValidatorState state)
{
// We are fine with having ServiceScopeService requested by singletons
- if (scopedCallSite... | [CallSiteValidator->[Type->[Singleton,ToLowerInvariant,Format,VisitCallSiteMain,ScopedInSingletonException,VisitCallSite,ParameterCallSites,ServiceCallSites,ServiceType],ValidateResolution->[ToLowerInvariant,Format,TryGetValue,DirectScopedResolvedFromRootException,ReferenceEquals,ScopedResolvedFromRootException],Valida... | Visit the given scoped call site and check if it is a ServiceScopeService. | Can you replace ServiceScopeFactoryCallSite with a constant call site? |
@@ -199,10 +199,13 @@ namespace System.Reflection
nameof(metadataToken));
}
- fieldHandle = ModuleHandle.ResolveFieldHandleInternal(GetNativeHandle(), tk, typeArgs, methodArgs);
+ fieldHandle = moduleHandle.ResolveFieldHandle(... | [RuntimeModule->[GetMethods->[GetMethods],GetDefinedTypes->[GetTypes],GetFullyQualifiedName->[GetFullyQualifiedName],IsDefined->[IsDefined],Type->[ConvertToTypeHandleArray],ResolveField->[ConvertToTypeHandleArray,ResolveLiteralField],ResolveMethod->[ConvertToTypeHandleArray],GetTypes->[GetTypes],GetFields->[GetFields],... | ResolveField - Resolve a field with a given metadata token. | These two ResolveFieldHandle calls take exactly same arguments. Should we have just common one after the `if { .. }` ? |
@@ -19,6 +19,10 @@ abstract class Jetpack_Tiled_Gallery_Item {
}
$this->orig_file = wp_get_attachment_url( $this->image->ID );
+ // If Photon is active, use it for original
+ if ( class_exists( 'Jetpack_Photon' ) && Jetpack::is_module_active( 'photon' ) ) {
+ $this->orig_file = jetpack_photon_url( $this->or... | [No CFG could be retrieved] | This method is used to initialize the object. | Why are we checking for the class here? We're using a function that isn't part of the class, so we can check for the function instead? The check shouldn't be required since the photon functions are always loaded, but better to play it defensively. |
@@ -62,7 +62,7 @@ bool bitmapNonEmpty(const OpenDDS::RTPS::SequenceNumberSet& snSet)
}
for (int bit = 31; bit >= 0; --bit) {
if ((snSet.bitmap[i] & (1 << bit))
- && snSet.numBits >= i * 32 + (31 - bit)) {
+ && snSet.numBits > i * 32 + (31 - bit)) {
return true;
... | [No CFG could be retrieved] | The number of longs required for the type - specific sequence representation of a sequence number. END OF FUNCTIONS. | This should probably just create a mask and do a single comparison rather than loop over individual bits. |
@@ -102,6 +102,10 @@ class StockError(Error):
code = StockErrorCode(description="The error code.", required=True)
+class BulkStockError(ProductError):
+ id = graphene.ID(description="ID of input element which cause the error.")
+
+
class WarehouseError(Error):
code = WarehouseErrorCode(description="Th... | [WishlistError->[WishlistErrorCode],PermissionDisplay->[PermissionEnum,String],IntRangeInput->[Int],LanguageDisplay->[LanguageCodeEnum,String],ExtensionsError->[ExtensionsErrorCode],StockError->[StockErrorCode],SeoInput->[String],Weight->[String,Float],TaxType->[String],ShippingError->[ShippingErrorCode],Error->[String... | Error class for bulk product errors. Sequence of weight units and values. | In `BulkProductError` we use `index`; I think it would be better to do it here as well. |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.