patch stringlengths 18 160k | callgraph stringlengths 4 179k | summary stringlengths 4 947 | msg stringlengths 6 3.42k |
|---|---|---|---|
@@ -122,13 +122,12 @@ public class DbTaskStorage implements TaskStorage
{
return handle.createStatement(
String.format(
- "UPDATE %s SET status_code = :status_code, status_payload = :status_payload WHERE id = :id AND status_code = :old_status_code",
+ ... | [DbTaskStorage->[addAuditLog->[withHandle],getRunningTaskIds->[withHandle],getAuditLogs->[withHandle],removeLock->[withHandle],setStatus->[withHandle],getStatus->[withHandle],addLock->[withHandle],getTask->[withHandle],getLocksWithIds->[withHandle]]] | Updates the status of a task in the task table. | The addition of the "active = 1" check, is that because we actually expect id=:id to potentially return multiple rows or is it just being uber explicit? |
@@ -287,8 +287,8 @@ if (empty($reshook) && $action == 'add')
$object->elementtype = 'task';
}
- $object->datep = $datep;
- $object->datef = $datef;
+ $object->datep = (int) $datep;
+ $object->datef = (int) $datef;
$object->percentage = $percentage;
$object->duree=(((int) GETPOST('dureehour') * 60)... | [fetch,create,select_projects,form_project,formconfirm,fetch_object,lasterror,getNomUrl,selectcontacts,rollback,select_type_actions,createFromClone,select_dolusers,begin,initHooks,form_select_status_action,idate,fetch_contact,load,Create,selectTasks,executeHooks,loadLangs,update,setOptionalsFromPost,setProject,escape,c... | Creates an object from GET parameters Creates an object from the user assigned to the user. | $datep is result of dol_mktime that can return '' that is different than 0. Can you confirm we need this ? |
@@ -72,11 +72,10 @@ class AutomaticRayleighComputationProcess(KM.Process):
"""
import KratosMultiphysics.kratos_utilities as kratos_utils
- if kratos_utils.AreApplicationsAvailable(["ExternalSolversApplication", "EigenSolversApplication"]):
- if kratos_utils.IsApplicationAvailable(... | [AutomaticRayleighComputationProcess->[__init__->[__init__]]] | This method is executed before the solution loop. Compute the next non - zero value for the system damping ratio and the damp Compute the damping coefficients. | @loumalouomega I updated the checks, IMO they make more sense now |
@@ -42,7 +42,14 @@ if (Config::get('enable_bgp')) {
$map_vrf['byId'][$vrf['vrf_id']]['vrf_name'] = $vrf['vrf_name'];
$map_vrf['byName'][$vrf['vrf_name']]['vrf_id'] = $vrf['vrf_id'];
}
- $bgpPeersCache = snmpwalk_cache_oid($device, 'hwBgpPeers', [], 'HUAWEI-BGP-VPN-MIB');
+
+ ... | [compressed] | Provides a list of unique identifiers for the given device. This function is used to find the missing OID reply for a BGP peer. | This is needed cause the parent OID (which was polled before) may include data with different indexing scheme, and it breaks the logic. bgpPeersDesc is one of those. |
@@ -78,14 +78,10 @@ int main(int argc, char *argv[])
trace_point(TRACE_BOOT_START);
- /* setup context */
- sof.argc = argc;
- sof.argv = argv;
-
if (cpu_get_id() == PLATFORM_MASTER_CORE_ID)
- err = master_core_init(&sof);
+ err = master_core_init(argc, argv, &sof);
else
- err = slave_core_init(&sof);
+ e... | [main->[cpu_get_id,master_core_init,panic,trace_point,slave_core_init],master_core_init->[pm_runtime_init,arch_init,init_system_notify,init_heap,platform_init,trace_point,panic,pm_runtime_put,trace_init,task_main_start,platform_init_memmap,interrupt_init]] | main function of the main function. | Why did this need to be moved? |
@@ -79,4 +79,18 @@ class MultipleTranslatedProperties
throw new NoSuchPropertyException($key);
}
}
+
+ public function getLanguagesForNode(NodeInterface $node)
+ {
+ $languages = array();
+ foreach ($node->getProperties() as $property) {
+ preg_match('/^' . $thi... | [MultipleTranslatedProperties->[getName->[getName]]] | Returns the name of the property with the given key. | To determine the available language we search for `template` properties only. (this is kindof an established hack I guess) |
@@ -828,6 +828,7 @@ function $RootScopeProvider() {
lastDirtyWatch = watch;
watch.last = watch.eq ? copy(value, null) : value;
fn = watch.fn;
+ // console.log('call watch fn', watch.exp, fn);
fn(value, ((las... | [No CFG could be retrieved] | loops through the scopes and calls the async functions. Checks if a node is a unique identifier and if so returns it. | I assume these will disappear before merging :-P |
@@ -25,15 +25,15 @@
from spack import *
-
class Sz(AutotoolsPackage):
"""Error-bounded Lossy Compressor for HPC Data."""
homepage = "https://collab.cels.anl.gov/display/ESR/SZ"
- url = "https://github.com/disheng222/SZ/archive/v1.4.11.0.tar.gz"
+ url = "https://github.com/disheng222/SZ... | [Sz->[variant,version]] | Creates a new object with the given parameters. Get the command line options for the n - tuple. | Deleting this line will cause flake8 to fail. |
@@ -14,7 +14,7 @@ public class NewViewLink extends TransientViewActionFactory {
@VisibleForTesting
static final String ICON_FILE_NAME = "folder";
@VisibleForTesting
- public static final String URL_NAME = "newView";
+ static final String URL_NAME_SUFFIX = "newView";
@Override
public Lis... | [NewViewLink->[createFor->[hasPermission->[hasPermission]]]] | This method returns a list of actions that can be performed on a view that has the permission. | formally it is a compat-breaking change. I would recommend not to do so |
@@ -55,5 +55,15 @@ namespace System.Collections.Generic
value = default;
return false;
}
+
+ public static ReadOnlyCollection<T> AsReadOnly<T>(this IList<T> list)
+ {
+ return new ReadOnlyCollection<T>(list);
+ }
+
+ public static ReadOnlyDiction... | [CollectionExtensions->[Remove->[Remove],GetValueOrDefault->[GetValueOrDefault]]] | Remove method for IDictionary. | Add where TKey:not null |
@@ -31,13 +31,8 @@ namespace NServiceBus.Features
var maxRetries = transportConfig?.MaxRetries ?? 5;
var retryPolicy = new FirstLevelRetryPolicy(maxRetries);
context.Container.RegisterSingleton(retryPolicy);
-
- var flrStatusStorage = new FlrStatusStorage();
- ... | [FirstLevelRetries->[GetMaxRetries->[settings,MaxRetries],FlrStatusStorageCleaner->[Task->[CompletedTask],ClearFlrStatusStorage->[ClearAllFailures],statusStorage,FromMinutes],Setup->[RegisterSingleton,b,Register,Settings,RegisterStartupTask],GetMaxRetries,GetRequiredTransactionModeForReceives,None,Prerequisite,EnableBy... | Initialize the components. | Can we pass `FailureInfoStorage` and policy as instance references here? |
@@ -52,6 +52,7 @@ namespace System.Text.Json
public JsonSerializerOptions()
{
Converters = new ConverterList(this);
+ TrackOptionsInstance(this);
}
/// <summary>
| [JsonSerializerOptions->[TypeIsCached->[ContainsKey],JsonClassInfo->[GetOrAddClass,GetOrAdd,TryGetValue],VerifyMutable->[ThrowInvalidOperationException_SerializerOptionsImmutable,Assert],JsonSerializerDoesNotSupportComments,EffectiveMaxDepth,_memberAccessorStrategy,Never,_includeFields,_encoder,SerializationInvalidBuff... | JsonSerializerOptions provides a basic set of options that can be used to serialize a single object Allow trailing commas and readOO. | Since this is only used in development scenarios, not production (my understanding) can we detect this mode and only track in development scenarios? |
@@ -305,9 +305,11 @@ func (o *Operator) getApp(p Descriptor) (Application, error) {
var err error
monitor := o.monitor
+ appName := p.BinaryName()
if app.IsSidecar(p) {
// make watchers unmonitorable
monitor = noop.NewMonitor()
+ appName += "_monitoring"
}
if p.ServicePort() == 0 {
| [State->[State],Close->[Close],runFlow->[State],Shutdown->[Shutdown]] | getApp returns an Application object for the given application descriptor. - - - - - - - - - - - - - - - - - -. | I wonder if this has any effect in other places except the status output? Hopefully a positive impact but we should double check in case we do any comparison on appName. |
@@ -953,6 +953,9 @@ public class Jenkins extends AbstractCIBase implements DirectlyModifiableTopLeve
@Nonnull
@Restricted(NoExternalUse.class)
public InstallState getInstallState() {
+ if (installState == null || installState.name() == null) {
+ return InstallState.UNKNOWN;
+ }
... | [Jenkins->[getAllItems->[getAllItems],getUser->[get],_cleanUpShutdownTcpSlaveAgent->[add],setNumExecutors->[updateComputerList],getPlugin->[getPlugin],_cleanUpCloseDNSMulticast->[add],getViewActions->[getActions],getJDK->[getJDKs],setViews->[addView],getCloud->[getByName],getStaplerFallback->[getPrimaryView],getStoredV... | Get the install state of the node. | This approach is hackish. It won't be extensible if you add new fields to the InstallState |
@@ -17,6 +17,11 @@ class Diffsplice(MakefilePackage):
version('0.1.2beta', 'a1df6e0b50968f2c229d5d7f97327336')
version('0.1.1', 'be90e6c072402d5aae0b4e2cbb8c10ac')
+ def edit(self, spec, prefix):
+ if 'aarch64' in spec.architecture.target.lower():
+ makefile = FileFilter(join_path(s... | [Diffsplice->[install->[install,mkdirp],version]] | Installs the differentials. | maybe even `if not 'amd64' in ...`? |
@@ -200,9 +200,11 @@ def add_parser(subparsers, parent_parser):
default=False,
)
diff_parser.add_argument(
+ "--md",
"--show-md",
help="Show tabulated output in the Markdown format (GFM).",
action="store_true",
+ dest="markdown",
default=False,
)... | [_show_md->[_digest],add_parser->[add_parser],CmdDiff->[_show_diff->[_digest],run->[_show_md,_show_diff]]] | Adds a parser to subparsers to compare a single block of data with a specific block of data. | I always try to use `-md` (single dash) on these abbreviations, so I am not a fan of this, but `--markdown` is too long. And `--md` is what we use in CML as well. |
@@ -76,6 +76,16 @@ function developers_process_settings() {
$handler = [Hooks::class, 'alterMenu'];
elgg_register_plugin_hook_handler('view', 'navigation/menu/default', $handler);
}
+
+ if (!empty($settings['block_email'])) {
+ $handler = [Hooks::class, 'blockOutgoingEmails'];
+ elgg_register_plugin_hook_han... | [_developers_decorate_translations->[getLoadedTranslations],developers_wrap_views->[getExtension],developers_process_settings->[getAllSettings]] | This function processes the settings of the developers plugin This is a hook that will be called when the user logs in and the user is not. | why check? it is also checked in the hooks right? |
@@ -408,7 +408,6 @@ public class ModelFieldEditor extends AnkiActivity implements LocaleSelectionDia
mProgressDialog = null;
}
-
/*
* Renames the current field
*/
| [ModelFieldEditor->[renameField->[renameField],onStop->[onStop],sortByField->[dismissContextMenu],closeActivity->[closeActivity],onCollectionLoaded->[onCollectionLoaded],onSelectedLocale->[addFieldLocaleHint],onBackPressed->[closeActivity],fullRefreshList->[setupLabels,createfieldLabels],onOptionsItemSelected->[onOptio... | Dismisses the progress bar and renames the field. | nit: could you revert irrelevant spacing changes |
@@ -85,7 +85,6 @@ module Engine
'4' => 300,
'5' => 300,
'6' => 300,
- 'D' => 300,
},
num: 20,
},
| [Base->[current_entity->[current_entity],trains->[trains],process_action->[process_action],end_game->[format_currency],inspect->[title],rollback->[clone]]] | A base class for all the attributes of a specific node - level object. Initialize a new instance of the class. | why is this removed? you can trade a D for a D |
@@ -185,7 +185,7 @@ if (isset($_SESSION['cart']->cartID)) {
$quotes = $shipping_modules->quote();
// check that the currently selected shipping method is still valid (in case a zone restriction has disabled it, etc)
- if (isset($_SESSION['shipping'])) {
+ if (isset($_SESSION['shipping']) && isset($_SESSION['s... | [show_weight,bindVars,Execute,quote,notify,in_cart_mixed,get_products,show_total,count_contents,cheapest,add,alterShippingEditButton,set_snapshot] | check if the selected shipping method is still valid The cheapest method. | You can skip the first check in this case. The isset() test will start with the outermost, and work its way in. Plus, this is only checked again in line 199, where only `id` is used. So just `if (isset($_SESSION['shipping']['id']))` would suffice. |
@@ -159,5 +159,18 @@ namespace DynamoUtilities
return false;
}
+
+ /// <summary>
+ /// This is a utility method for generating a default name to the snapshot image.
+ /// </summary>
+ /// <param name="filePath">File path</param>
+ /// <returns>Returns a defaul... | [PathHelper->[IsFileNameInValid->[Any,IndexOfAny,Contains],IsValidPath->[Exists,IsNullOrEmpty],isValidXML->[Load],isValidJson->[EndsWith,ReadAllText,WriteLine,Parse,StartsWith,ToString,Trim],IsReadOnlyPath->[IsValidPath,ToString,HasWritePermissionOnDir,IsReadOnly],HasWritePermissionOnDir->[Write,AccessControlType,GetAc... | IsFileNameInValid - check if fileName is invalid. | How about `GetScreenCaptureNameFromPath`? |
@@ -89,7 +89,6 @@ namespace Content.Server.Body.Metabolism
// Run metabolism code for each reagent
foreach (var effect in metabolism.Effects)
{
- var ent = body != null ? body.Owner : owner;
var conditionsMet = true;
... | [MetabolizerSystem->[Initialize->[Initialize],Update->[Update]]] | Try to metabolize a given component. This method is called when a plant or something effect is detected. | This doesn't strictly have anything to do with getting the add reagent verb to wrok again (I just needed `SolutionContainerSystem.TryRemoveAllReagents` to take an entityUid as an argument), but I'm not sure what's going on in this function and it's a bit of a mess. It's possible the solution refactor may have made it n... |
@@ -23,13 +23,14 @@ from sklearn.svm import SVC
import logging
import numpy as np
-
LOG = logging.getLogger('sklearn_classification')
+
def load_data():
'''Load dataset, use 20newsgroups dataset'''
digits = load_digits()
- X_train, X_test, y_train, y_test = train_test_split(digits.data, digits.targ... | [run->[score,report_final_result,debug,fit],load_data->[fit_transform,train_test_split,load_digits,StandardScaler,transform],get_model->[SVC,get],load_data,debug,exception,getLogger,update,get_model,get_next_parameter,get_default_parameters,run] | Load dataset with 20newsgroups dataset. | please remove empty lines |
@@ -209,6 +209,10 @@ class DiscoursePluginRegistry
self.seedfu_filter << filter
end
+ def self.register_permitted_bulk_action_parameters(filter = nil)
+ self.permitted_bulk_action_parameters << filter
+ end
+
VENDORED_CORE_PRETTY_TEXT_MAP = {
"moment.js" => "vendor/assets/javascripts/moment.js",
... | [DiscoursePluginRegistry->[define_filtered_register->[define_register],define_filtered_register,define_register]] | Register a seedfu filter for this asset. | There shouldn't be any need to define this function. `define_register` will create it automatically |
@@ -568,6 +568,7 @@ class PytestRun(TestRunnerTaskMixin, PythonExecutionTaskBase):
def _pex_run(self, pex, workunit_name, args, env):
with self.context.new_workunit(name=workunit_name,
+ cmd=pex.cmdline(args),
labels=[WorkUnitLabel.TOOL, Wo... | [PytestRun->[_maybe_emit_coverage_data->[_cov_setup,pex_run,ensure_trailing_sep,compute_coverage_sources],_do_run_tests_with_args->[exception,rc],_get_failed_targets_from_junitxml->[_map_relsrc_to_targets],_generate_coverage_config->[_format_string_list,add_realpath],_conftest->[_get_conftest_content],_get_target_from_... | Spawns a subprocess and returns a SubprocessProcessHandler. | Does this mean we'll be computing the args twice? Once for the workunit, and another time to invoke? Almost certainly not an issue for performance, but potentially an issue if they go out of sync for some reason. |
@@ -214,7 +214,7 @@ namespace
const char* USAGE_GET_TX_NOTE("get_tx_note <txid>");
const char* USAGE_GET_DESCRIPTION("get_description");
const char* USAGE_SET_DESCRIPTION("set_description [free text note]");
- const char* USAGE_SIGN("sign <filename>");
+ const char* USAGE_SIGN("sign [<account_index>,<address... | [No CFG could be retrieved] | USAGE - GET_PROOF - GET_RESERVE_PROOF - GET_ USAGE_HW_RECONNECT USAGE_MK_RECONNECT USAGE_. | Why move the filename position? Putting the indexes after would mean existing usage remains unchanged (defaults to primary account). |
@@ -646,6 +646,12 @@ func (a *apiServer) createWorkerSvcAndRc(ctx context.Context, ptr *pps.EtcdPipel
tracing.FinishAnySpan(span)
}()
+ pachClient := a.env.GetPachClient(context.Background())
+
+ if err := a.setupWorkerPachctlAuth(ctx, ptr, pipelineInfo); err != nil {
+ return err
+ }
+
options, err := a.getW... | [createWorkerSvcAndRc->[workerPodSpec,getWorkerOptions]] | createWorkerSvcAndRc creates a worker service and rc for the given pipeline prometheus. io is a file that contains a list of metrics that can be found in Initialize a new service with the given options. | This should use the request context so we propagate cancellation. Also it might make sense to move it closer to where it's used? |
@@ -902,7 +902,7 @@ void FemDem3DElement::CalculateOnIntegrationPoints(
if (rVariable == DAMAGE_ELEMENT) {
rOutput.resize(1);
for (unsigned int PointNumber = 0; PointNumber < 1; PointNumber++) {
- rOutput[PointNumber] = double(this->GetValue(DAMAGE_ELEMENT));
+ rOutput[PointNumber] = mDamage;
}
} else ... | [No CFG could be retrieved] | This function calculates on the integration points of the FemDem3DElement. This function calculates the missing point number in the system. | In this case point_number |
@@ -436,7 +436,9 @@ func printOldNewDiffs(
if diff := olds.Diff(news); diff != nil {
printObjectDiff(b, *diff, planning, indent, summary, debug)
} else {
- printObject(b, news, planning, indent, op, true, debug)
+ // If there's no diff, report the op as Same - there's no diff to render
+ // so it should be re... | [IsObject,IsAssets,ArrayValue,NewArchiveProperty,DiffLinesToChars,Assertf,BoolValue,DiffMain,IsBool,PropertyKey,IsNull,Diff,IsOutput,Strings,Color,Itoa,NewAssetProperty,IgnoreError,New,GetAssets,ParseReference,StableKeys,Assert,Len,NumberValue,Prefix,IsComputed,TypeString,TrimSpace,ID,Failf,TypeOf,Name,IsAsset,IsText,A... | assetOrArchiveToPropertyValue converts an asset or archive element into a property value. print prints the contents of the object. | I'm thinking it's potentially the case that `printObject` doesn't need a `StepOp` parameter anymore, but I didn't want to go too crazy refactoring this whole file for a bug fix. I'm happy to try to get rid of it if anyone wants me to. |
@@ -10,10 +10,12 @@ import (
"github.com/containous/traefik/log"
"github.com/containous/traefik/safe"
"github.com/containous/traefik/types"
+ "github.com/mitchellh/mapstructure"
rancher "github.com/rancher/go-rancher/client"
)
const labelRancheStackServiceName = "io.rancher.stack_service.name"
+const hostNe... | [apiProvide->[createClient,Stop,NewTicker,Background,WithCancel,Go,Duration,Errorf,RetryNotify,NewBackOff,NewExponentialBackOff,loadRancherConfig,Debugf],createClient->[NewRancherClient],Next,Warnf,List,Errorf,Getenv] | rancher import imports a single configuration object from the Rancher API. Reads the configuration of a single . | Can you use a `const` block? |
@@ -428,15 +428,10 @@ class MatrixTransport(Runnable):
client=self._client,
displayname_cache=self._displayname_cache,
address_reachability_changed_callback=self._address_reachability_changed,
- user_presence_changed_callback=self._user_presence_changed,
_l... | [_RetryQueue->[enqueue->[_expiration_generator,_MessageData],_check_and_send->[message_is_in_queue],_run->[_check_and_send],enqueue_unordered->[enqueue]],MatrixTransport->[_handle_web_rtc_messages->[_process_messages],_send_with_retry->[enqueue,_get_retrier],_handle_sdp_callback->[_send_raw],force_check_address_reachab... | Initialize a new instance of the object. Initializes the object variables. | could we also work with a sync filter? |
@@ -1124,10 +1124,16 @@ class RaidenAPI: # pragma: no unittest
logical_and=False,
)
+ chain_state = chain_state = views.state_from_raiden(self.raiden)
events = [
e
for e in events
- if event_filter_for_payments(event=e.wrapped_event, partner_... | [transfer_tasks_view->[flatten_transfer,get_transfer_from_task],RaidenAPI->[get_raiden_events_payment_history_with_timestamps->[event_filter_for_payments],get_pending_transfers->[transfer_tasks_view],start_health_check_for->[start_health_check_for],get_raiden_events_payment_history->[get_raiden_events_payment_history_w... | This function returns a list of Event objects with timestamped events. | One assignment should be enough |
@@ -17,11 +17,12 @@ module Idv
selfie_response = DocAuth::Client.client.post_selfie(
instance_id: instance_id, image: image.read,
)
+
if selfie_response.success?
handle_successful_selfie_match
- else
- handle_selfie_step_failure(selfie_response)
... | [SelfieStep->[handle_successful_selfie_match->[call]]] | This method sends a self - ie request and returns the next node ID. | Rubocop got mad at this so I patched it in 9fe6ce442bbc13b7f4775eecf1761626463cef50 |
@@ -43,12 +43,7 @@ class SVHN(VisionDataset):
download=False):
super(SVHN, self).__init__(root, transform=transform,
target_transform=target_transform)
- self.split = split # training set or test set or extra set
-
- if self.split not in self... | [SVHN->[download->[download_url],_check_integrity->[join,check_integrity],__len__->[len],__getitem__->[fromarray,int,target_transform,transpose,transform],extra_repr->[format],__init__->[place,download,_check_integrity,super,ValueError,transpose,RuntimeError,loadmat,join,loaded_mat]]] | Initialize the object with the data and labels of a specific . | I think being explicit is good. But I wonder if it would make sense to just use `self.split_list`, as it was before? |
@@ -1060,9 +1060,10 @@ public class ErrataHandler extends BaseHandler {
List<Errata> errataToClone = new ArrayList<Errata>();
List<Long> errataIds = new ArrayList<Long>();
+ Optional<Org> originalChannelOrg = ofNullable(original).map(c -> c.getOrg());
//We loop through once, making s... | [ErrataHandler->[publishAsOriginal->[publish,lookupErrata],cloneAsOriginalAsync->[clone],lookupVendorAndUserErrataByAdvisoryAndOrg->[lookupVendorAndUserErrataByAdvisoryAndOrg],create->[getRequiredAttribute],cloneAsOriginal->[clone],delete->[lookupErrata],cloneAsync->[clone],clone->[clone,lookupErrata],publish->[publish... | Clones an errata of the given type. Clones the errata in the channel if it has not yet finished. | Are we sure this is the only place where we should use the new method? |
@@ -545,6 +545,17 @@ RSpec.describe User, type: :model do
end
end
+ context "when callbacks are triggered before save" do
+ describe "#clean_payment_pointer" do
+ let(:user) { build(:user) }
+
+ it "clean leading and trailing space in payment pointer" do
+ user.payment_pointer = " $exampl... | [provider_username,user_from_authorization_service,mock_username] | when validating feed_url with RSSReader it is valid with no feed_url it is on save enqueues job to delete user from elasticsearch. | I'm not _certain_ that this test is necessary, especially if we use `String#strip` over the regex approach. Effectively, it seems like we are testing that the `strip` method and the AR callbacks are working, which probably isn't completely necessary. |
@@ -117,6 +117,9 @@ public class FlinkStreamerConfig extends Configuration {
@Parameter(names = {"--commit-on-errors"}, description = "Commit even when some records failed to be written.")
public Boolean commitOnErrors = false;
+ @Parameter(names = {"--transformer-class"})
+ public List<String> transformerCla... | [FlinkStreamerConfig->[toFlinkConfig->[setDouble,value,parseInt,isNullOrEmpty,setString,fromMap,getProps,setBoolean,toUpperCase,parseLong,setInteger,setLong],getCanonicalName,name,getName]] | Required parameters for the Hoodie - Record class. Returns the default partition name for dynamic partition columns. | please add some description about what it is and how to configure it |
@@ -159,6 +159,8 @@ class FlinkStreamingTransformTranslators {
new CreateViewStreamingTranslator());
TRANSLATORS.put(PTransformTranslation.RESHUFFLE_URN, new ReshuffleTranslatorStreaming());
+ TRANSLATORS.put(
+ PTransformTranslation.RESHUFFLE_PER_KEY_URN, new ReshuffleTranslatorStreaming());
... | [FlinkStreamingTransformTranslators->[BoundedReadSourceTranslator->[translateNode->[getCurrentTransformName]],ToBinaryKeyedWorkItem->[flatMap->[getKey]],SplittableProcessElementsStreamingTranslator->[translateNode->[getCurrentTransformName,translateParDo]],UnboundedReadSourceTranslator->[translateNode->[getCurrentTrans... | Creates a map of all available stream translators. private c t - > c t - > c t - > c t - > c. | Here as well, do we still match this? |
@@ -64,6 +64,9 @@ public final class NativeLibraryLoader {
WORKDIR = tmpdir();
logger.debug("-Dio.netty.native.workdir: " + WORKDIR + " (io.netty.tmpdir)");
}
+
+ DELETE_NATIVE_LIB_AFTER_LOADING = SystemPropertyUtil.getBoolean(
+ "io.netty.native.deleteLibAfterLo... | [NativeLibraryLoader->[load->[isOSX],loadLibrary->[loadLibrary]]] | Returns the temporary directory. | should this be scoped to a particular library? Just wondering if we ever load multiple libraries using this loader if we want to have a global flag or scope it per load. |
@@ -61,10 +61,10 @@ void matrix_scan_kb(void) {
#ifdef DIP_SWITCH_ENABLE
__attribute__((weak))
-void dip_update(uint8_t index, bool active) {}
+bool dip_update(uint8_t index, bool active) { return true; }
__attribute__((weak))
-void dip_switch_update_user(uint8_t index, bool active) {
- dip_update(index, acti... | [matrix_init_kb->[matrix_init_user],suspend_power_down_kb->[suspend_power_down_user,rgb_matrix_set_suspend_state],suspend_wakeup_init_kb->[suspend_wakeup_init_user,rgb_matrix_set_suspend_state],void->[dip_update],matrix_scan_kb->[matrix_scan_user]] | DipSwitchUpdateHandler. dip_switch_update_user is an attribute for the. | And same with the Planck. |
@@ -149,5 +149,7 @@ def price_as_dict(price):
def price_range_as_dict(price_range):
+ if not price_range:
+ return {}
return {'maxPrice': price_as_dict(price_range.max_price),
'minPrice': price_as_dict(price_range.min_price)}
| [price_range_as_dict->[price_as_dict],get_variant_picker_data->[get_availability],products_for_cart->[products_visible_to_user],products_with_details->[products_visible_to_user]] | Returns price_range as a dictionary. | Wouldn't `null` (`None`) be more explicit here? |
@@ -17,7 +17,15 @@
</div>
<div class='sub_block'>
<span class='prop_label'><%= Assignment.human_attribute_name(:due_date) %></span>
- <span class="prop_paragraph"><%= l(@due_date) %></span>
+ <span class="prop_paragraph">
+ <% if !@grouping.extension.nil? %>
+ <%= I18n.l(@grouping.due_date)... | [No CFG could be retrieved] | This is a simple rendering of the calendar component that represents a single node in the system. This is the best penalty for the period of the period. | @grouping might be `nil` here as well |
@@ -20,6 +20,9 @@ def find_outliers(X, threshold=3.0, max_iter=2):
The value above which a feature is classified as outlier.
max_iter : int
The maximum number of iterations.
+ tail : {"two", "positive", "negative"}
+ Whether to search for outliers on both extremes of the z-scores,
+ ... | [find_outliers->[any,max,len,zscore,where,zeros,range,masked_array,abs]] | Find outliers based on iterated Z - scoring. | to match functions like permutation_cluster_test I would use tail = 0, 1 or -1 it's for consistency although it's not the most beautiful API i agree |
@@ -161,7 +161,7 @@ def test_get_formatted_locations_basic_auth():
finder = PackageFinder([], index_urls, session=[])
result = finder.get_formatted_locations()
- assert 'user' not in result and 'pass' not in result
+ assert 'user' in result and 'pass' not in result
@pytest.mark.parametrize(
| [TestLink->[test_splitext->[Link],test_ext_query->[Link],test_filename->[Link],test_is_wheel_false->[Link],test_is_wheel->[Link],test_ext->[Link],test_fragments->[Link],test_ext_fragment->[Link],test_no_ext->[Link],parametrize],test_sort_locations_file_not_find_link->[_sort_locations,PipSession,PackageFinder,index_url]... | Test that get_formatted_locations_basic_auth is not included in formatted output. | How about also checking that "****" is in the result to check / make it more obvious that redaction should be happening? |
@@ -1691,12 +1691,6 @@ func (g *gregorHandler) DismissCategory(ctx context.Context, category gregor1.Ca
Ranges_: []gregor1.MsgRange{
gregor1.MsgRange{
Category_: category,
- // A small non-zero offset that effectively means "now",
- // because an actually-zero offset would be interpreted as "not
- ... | [handleInBandMessage->[Name,Debug,IsAlive,Errorf],UpdateItem->[UpdateItem,templateMessage,pushState,getGregorCli],chatAwareInitialReconnectBackoffWindow->[chatAwareReconnectIsLong],connectTLS->[Errorf,chatAwareInitialReconnectBackoffWindow,chatAwareReconnectBackoff,GetClient,pingLoop,Debug],OnConnectError->[setReachabi... | DismissCategory dismisses a category. | @maxtaco of note this section, I think it is safe to remove this now with the server changes. |
@@ -677,8 +677,9 @@ def main(cli_args=sys.argv[1:]):
displayer = display_util.NoninteractiveDisplay(sys.stdout)
elif config.text_mode:
displayer = display_util.FileDisplay(sys.stdout)
+ elif config.dialog_mode:
+ displayer = display_util.NcursesDisplay()
elif config.verb == "renew"... | [revoke->[revoke,_determine_account],setup_logging->[setup_log_file_handler],_treat_as_renewal->[_handle_identical_cert_request,_handle_subset_cert_request],install->[_init_le_client,_find_domains],run->[_init_le_client,_auth_from_domains,_find_domains,_suggest_donation_if_appropriate],main->[setup_logging],_csr_obtain... | Entry point for the certbot - index script. Provide a function to display a . | This line shouldn't be deleted. |
@@ -333,6 +333,9 @@ export class AmpAdNetworkDoubleclickImpl extends AmpA4A {
dev().warn(TAG, `Frame already exists, sra: ${this.useSra}`);
return '';
}
+
+ const rtcRequestPromise = this.sendRtcRequest_();
+
// TODO(keithwrightbos): SRA blocks currently unnecessarily generate full
// ad... | [AmpAdNetworkDoubleclickImpl->[extractSize->[height,width],getBlockParameters_->[serializeTargeting_,dev,isInManualExperiment,Number,assign,join,googleBlockParameters,getMultiSizeDimensions,map],delayAdRequestEnabled->[experimentFeatureEnabled,DELAYED_REQUEST],constructor->[resolver,experimentFeatureEnabled,extensionsF... | Get google ad url for the current page. | nit: remove extra, empty lines |
@@ -3423,7 +3423,7 @@ function PMA_getSupportedDatatypes($html = false, $selected = '')
$retval .= "<optgroup label='" . htmlspecialchars($key) . "'>";
foreach ($value as $subvalue) {
if ($subvalue == $selected) {
- $retval .= "<option select... | [PMA_showMessage->[getLevel,addMessage,display],PMA_getImage->[getPath],PMA_ajaxResponse->[getDisplay],PMA_selectUploadFile->[display],PMA_showHint->[getLevel,getHash]] | PMA_getSupportedDatatypes - Get the list of supported column types. | Try to avoid long lines here. The PEAR coding standard we use dictates a 85 character limit. Never mind about the descriptions, wrapping them will make it more confusing. |
@@ -91,6 +91,7 @@ func (c *TwoQueue) Put(key uint64, value interface{}) {
c.recent.Put(key, value)
}
+// revive:disable-next-line:flag-parameter
func (c *TwoQueue) ensureSpace(ghost bool) {
recentLen := c.recent.Len()
frequentLen := c.frequent.Len()
| [Get->[Put,Get],ensureSpace->[Put],Peek->[Peek],Elems->[Elems],Put->[Put],Len->[Len]] | Put adds a value to the queue. If the value is not in the queue it will. | Is there a better way to fix this warning? |
@@ -2548,6 +2548,7 @@ class SemanticAnalyzer(NodeVisitor[None]):
for t in types:
if has_any_from_unimported_type(t):
self.msg.unimported_type_becomes_any("Type of a TypedDict key", t, dictexpr)
+ assert total is not None
return items, types, total, ok
... | [SemanticAnalyzer->[analyze_comp_for->[analyze_lvalue],build_newtype_typeinfo->[named_type],name_not_defined->[add_fixture_note,lookup_fully_qualified_or_none],refresh_class_def->[refresh_class_def],check_classvar->[is_self_member_ref],visit_lambda_expr->[analyze_function],build_typeddict_typeinfo->[basic_new_typeinfo,... | Parse the arguments of TypedDict. Parse a boolean expression to determine if the key is a typed dict or not. | This seems redundant, since we return if `total` is `None` above. |
@@ -285,10 +285,11 @@ int CRYPTO_dup_ex_data(int class_index, CRYPTO_EX_DATA *to,
}
for (i = 0; i < mx; i++) {
- ptr = CRYPTO_get_ex_data(from, i);
- if (storage[i] && storage[i]->dup_func)
+ if (storage[i] && storage[i]->dup_func) {
+ ptr = CRYPTO_get_ex_data(from, i);
... | [CRYPTO_free_ex_data->[CRYPTOerr,CRYPTO_THREAD_unlock,OPENSSL_free,CRYPTO_get_ex_data,get_and_lock,sk_EX_CALLBACK_num,sk_EX_CALLBACK_value,OSSL_NELEM,sk_void_free,OPENSSL_malloc],CRYPTO_free_ex_index->[sk_EX_CALLBACK_value,CRYPTO_THREAD_unlock,get_and_lock,sk_EX_CALLBACK_num],CRYPTO_dup_ex_data->[CRYPTOerr,CRYPTO_THREA... | Duplicate an EX_DATA from one CRYPTO_EX_DATA to another. | So if the if () branch is not taken, we just reuse the valueof ptr from the previous iteration of the loop? That changes the semantics, as I see it. |
@@ -35,10 +35,17 @@ class Mbedtls(CMakePackage):
variant('pic', default=False,
description='Compile with position independent code.')
+ variant('shared', default=False,
+ description='Build shared libraries')
depends_on('cmake@3.1.0:', type='build', when='@2.8.0:')
depends_... | [Mbedtls->[flag_handler->[append],variant,depends_on,version]] | Handle flags for C ++ compiler. | If it's only used for tests, shouldn't it be `type='test'`? |
@@ -2,7 +2,6 @@
return [
'default' => [
- 'ckeditor.js' => __DIR__ . '/vendors/ckeditor/ckeditor.js',
'ckeditor/' => __DIR__ . '/vendors/ckeditor/',
'jquery.ckeditor.js' => __DIR__ . '/vendors/ckeditor/adapters/jquery.js',
],
| [No CFG could be retrieved] | <?php return array of all possible ectree. | We can't remove views (BC). |
@@ -1146,12 +1146,17 @@ function createBaseCustomElementClass(win) {
*
* Can only be called on a upgraded and built element.
*
+ * @param {!AbortSignal} signal
* @return {!Promise}
* @package @final
*/
- layoutCallback() {
+ layoutCallback(signal) {
assertNotTemplate... | [No CFG could be retrieved] | Returns the layout of the element. Handle a layout failure. | Can we instead to `Promise.reject(cancellation())`? |
@@ -136,7 +136,7 @@ def execute(args, parser):
if args.features:
features = set(args.package_names)
actions = plan.remove_features_actions(prefix, index, features)
-
+ action_set = actions,
elif args.all:
if plan.is_root_prefix(prefix):
raise CondaEnvironmentErro... | [configure_parser->[add_parser_no_pin,add_argument,add_parser_offline,add_parser_no_use_index_cache,add_parser_pscheck,add_parser_yes,add_parser_json,add_parser_help,add_parser_use_index_cache,set_defaults,add_parser_channels,add_parser_prefix,add_parser_quiet,add_parser,capitalize,add_parser_use_local],execute->[stdou... | Remove a node - level node from the system. Remove packages from environment and index. | Wait, this isn't a python set, is it? If not name it something else. Maybe something like `action_groups` if that's more accurate. In pycharm shift-F6 is your friend for renaming :) |
@@ -30,6 +30,7 @@ import org.apache.nifi.processor.Relationship;
import org.apache.nifi.processor.exception.ProcessException;
import org.apache.nifi.processor.util.StandardValidators;
import org.apache.nifi.processors.standard.db.DatabaseAdapter;
+import org.apache.nifi.processors.standard.db.impl.PhoenixDatabaseAda... | [AbstractDatabaseFetchProcessor->[customValidate->[customValidate],setup->[setup]]] | Imports a single version of a n - node object. Imports all the classes that are used by the Hibernate service. | We may end up moving the abstract class and interface(s) out to its own NAR so other folks can implement DB adapters outside the standard NAR. In that case we'd want to replace this with something like the contains() we did for Oracle. Also if there were a need for 2 separate Phoenix adapters, we'd have to do that anyw... |
@@ -15,7 +15,11 @@
*/
import {AmpViewerIntegration} from '../amp-viewer-integration';
-import {Messaging, WindowPortEmulator, parseMessage} from '../messaging.js';
+import {
+ Messaging,
+ WindowPortEmulator,
+ parseMessage,
+} from '../messaging/messaging.js';
import {ViewerForTesting} from './viewer-for-test... | [No CFG could be retrieved] | Package that contains the logic to show when a specific tag is found. Unload the window. | No ".js" in imports. |
@@ -77,6 +77,12 @@ class Train(Subcommand):
type=str,
help=argparse.SUPPRESS)
+ subparser.add_argument('-c', '--continue',
+ action='store_true',
+ default=False,
+ ... | [datasets_from_params->[info,from_params,read,pop],train_model_from_file->[set_default_mininterval,train_model,from_file],train_model_from_args->[train_model_from_file,import_submodules],train_model->[datasets_from_params,Formatter,join,info,assert_empty,archive_model,ConfigurationError,index_with,FileHandler,from_para... | Add a sub - command parser to train a model on the specified dataset. | Can you use `continue` here instead of `cont`? |
@@ -117,10 +117,15 @@ var (
BrightMagenta = Command("fg 13")
BrightCyan = Command("fg 14")
+ RedBg = Command("bg 1")
+ GreenBg = Command("bg 2")
+ YellowBg = Command("bg 3")
+ BlueBg = Command("bg 4")
+
// We explicitly do not expose blacks/whites. They're problematic given that we don't know what
/... | [ExecuteToString,LastIndex,Contains,Assertf,Compile,String,Replace] | Highlight returns a string with all occurrences of a string with a highlighted version surrounded by those The color of the message that is meant to grab attention. | "Background" instead of Bg. |
@@ -241,6 +241,9 @@ function wpseo_init() {
if ( ! defined( 'DOING_AJAX' ) || ! DOING_AJAX ) {
require_once( WPSEO_PATH . 'inc/wpseo-non-ajax-functions.php' );
}
+
+ // Init it here because the filter must be present on the frontend as well or it won't work in the customizer.
+ new WPSEO_Customizer();
}
/**
| [wpseo_network_activate_deactivate->[get_col]] | This function is called when the module is loaded. It will initialize the WordPress SEO engine. | Shouldn't we wrap this in a `current_user_can` call? |
@@ -20,13 +20,14 @@ namespace System.Text.Json
internal static readonly JsonSerializerOptions s_defaultOptions = new JsonSerializerOptions();
private readonly ConcurrentDictionary<Type, JsonClassInfo> _classes = new ConcurrentDictionary<Type, JsonClassInfo>();
- private static readonly Concur... | [JsonSerializerOptions->[JsonClassInfo->[GetOrAdd,TryGetValue],CreateRangeDelegatesContainsKey->[ContainsKey],TryGetCreateRangeDelegate->[TryGetValue],VerifyMutable->[ThrowInvalidOperationException_SerializerOptionsImmutable,Assert],TryAddCreateRangeDelegate->[TryAdd],GetArgumentOutOfRangeException_MaxDepthMustBePositi... | This class is used to serialize a single object or array of objects. | I don't think we can do this since it ignores user-provided converters. |
@@ -16,7 +16,7 @@
{
var transaction = context.Extensions.GetOrCreate<TransportTransaction>();
var operations = context.Operations as TransportOperation[] ?? context.Operations.ToArray();
- return dispatcher.Dispatch(new TransportOperations(operations), transaction);
+ ... | [ImmediateDispatchTerminator->[Task->[Operations,ToArray,Dispatch,Extensions],dispatcher]] | Override Task Terminate. | Is this something that needs changing later? |
@@ -105,6 +105,14 @@ method_op(
c_function_name='CPyList_Count',
error_kind=ERR_MAGIC)
+# list.insert(index, obj)
+method_op(
+ name='insert',
+ arg_types=[list_rprimitive, int_rprimitive, object_rprimitive],
+ return_type=int_rprimitive,
+ c_function_name='CPyList_Insert',
+ error_kind=ERR_M... | [binary_op,custom_op,load_address_op,function_op,method_op] | Creates a list of objects from a list of objects. | since the function `PyList_Insert` returns an `int` here, it is most reasonable to define the op with `ERR_NEG_INT`. See the append op in list_ops.py for an example |
@@ -48,6 +48,7 @@ namespace System.Net
public static int DefaultConnectionLimit { get { throw null; } set { } }
public static int DnsRefreshTimeout { get { throw null; } set { } }
public static bool EnableDnsRoundRobin { get { throw null; } set { } }
+ [System.Runtime.Versioning.Unsupp... | [No CFG could be retrieved] | This class is used to manage the service point management mechanism. Deprecated. Use HttpClient instead. | What about this property is unsupported? It's just a simple getter. |
@@ -837,6 +837,18 @@ class TrtConvertTest(test_util.TensorFlowTestCase, parameterized.TestCase):
# to fall back to TF function.
self._TestRun(sess, 2)
+ @test_util.run_v2_only
+ def testBackwardCompatibility(self):
+ """Load and execute a model that was saved in TF2.0."""
+ if not is_tensorr... | [TrtConvertTest->[testTrtGraphConverter_DynamicOp->[mkdtemp,_ConvertGraphV1,_TestRun,_GetConfigProto],_CompareSavedModel->[_GetModelPaths->[_CreateConverterV2,mkdtemp],_GetSignatureDef,_GetModelPaths,_CompareSignatureDef,_GetStructuredOutputs],_TestTrtGraphConverter->[_ConvertGraphV1,run,_GetConfigProto],_GetGraphForV1... | Test if the graph_def and the output graph_def are compatible with TF graph_. | This PR also checks in the variables of the test model, is that required even after the conversion? |
@@ -355,6 +355,7 @@ def test_sale_add_catalogues_updates_products_discounted_prices(
product_ids=[product.pk],
category_ids=[category.pk],
collection_ids=[collection.pk],
+ variant_ids=[],
)
| [test_sale_create_updates_products_discounted_prices->[assert_called_once_with,int,from_global_id,post_graphql,get_graphql_content],test_sale_add_catalogues_updates_products_discounted_prices->[assert_called_once_with,post_graphql,to_global_id,get_graphql_content],test_sale_remove_catalogues_updates_products_discounted... | Test sale add catalogues updates products discounted prices of catalogues. | We should update this test to check if this mock receives `variant_id` when passed to mutation. |
@@ -18,5 +18,5 @@ $device_id = '';
$vars['fromdevice'] = false;
require_once 'includes/html/modal/alert_details.php';
require_once 'includes/html/common/alert-log.inc.php';
-echo implode('', $common_output);
+echo htmlspecialchars(implode('', $common_output));
unset($device_id);
| [No CFG could be retrieved] | Show the device alert. | I'm pretty sure $common_output is html. You will need to make any fixes in `includes/html/common/alert-log.inc.php` instead. |
@@ -30,8 +30,12 @@ class ChatChannelsController < ApplicationController
end
def update
- ChatChannelUpdateService.new(@chat_channel, chat_channel_params).update
- flash[:settings_notice] = "Channel Settings Updated."
+ if ChatChannelUpdateService.new(@chat_channel, chat_channel_params).update
+ fl... | [ChatChannelsController->[create->[create],open->[update],update->[update]]] | chat_channel_update_nack where the user has seen a node in the group. | Btw, you can set `flash[:error]` instead of `flash[:settings_notice]` here to be more clear that an error occured. |
@@ -0,0 +1,18 @@
+<?php
+/*
+ * This file is part of the Sulu CMS.
+ *
+ * (c) MASSIVE ART WebServices GmbH
+ *
+ * This source file is subject to the MIT license that is bundled
+ * with this source code in the file LICENSE.
+ */
+
+namespace Sulu\Component\Content\Exception;
+
+use Exception;
+
+class ResourceLocator... | [No CFG could be retrieved] | No Summary Found. | @wachterjohannes ... I would prefer NotFoundException |
@@ -79,6 +79,8 @@ class FeedForward(torch.nn.Module):
output = dropout(activation(layer(output)))
return output
+ # Requires custom logic around the activations (mostly because the Union type is too complex
+ # to handle automatically).
@classmethod
def from_params(cls, params: P... | [FeedForward->[from_params->[pop,pop_int,isinstance,by_name,cls,assert_empty],forward->[zip,activation,dropout,layer],__init__->[append,len,Linear,super,isinstance,ModuleList,Dropout,zip,ConfigurationError]]] | Computes the next non - linear network layer. | Ah, yes, we could handle the `List`, I think, as I mentioned above. But, yeah, that can wait, as it's not very frequent, and not a big deal. You might modify the wording here, though - it's not too complex to handle automatically, it's just complex enough that we haven't bothered to do it yet. |
@@ -1636,12 +1636,6 @@ def submit_version_finish(request, addon_id, addon, version_id):
return _submit_finish(request, addon, version)
-@dev_required
-def submit_file_finish(request, addon_id, addon, version_id):
- version = get_object_or_404(Version, id=version_id)
- return _submit_finish(request, addon... | [submit_version_source->[_submit_source],upload_for_version->[upload],submit_version_details->[_submit_details],upload->[handle_upload],upload_image->[ajax_upload_image],upload_detail->[get_fileupload_by_uuid_or_404,_compat_result,json_upload_detail],submit_version_upload->[_submit_upload],submit_addon_theme_wizard->[_... | Finish the file upload and redirect to the theme if it is disabled. | and remove the `is_file` parameter from `_submit_finish` |
@@ -104,6 +104,14 @@ def train_model_from_args(args: argparse.Namespace):
# Import any additional modules needed (to register custom classes)
for package_name in args.include_package:
import_submodules(package_name)
+
+ if not args.cont and os.path.exists(args.serialization_dir):
+ raise Co... | [datasets_from_params->[info,from_params,read,pop],train_model_from_file->[set_default_mininterval,train_model,from_file],train_model_from_args->[train_model_from_file,import_submodules],train_model->[datasets_from_params,Formatter,join,info,assert_empty,archive_model,ConfigurationError,index_with,FileHandler,from_para... | Train a model from an argparse. Namespace object. | Why not raise an error here, too? |
@@ -79,12 +79,14 @@ class CommunicationTokenCredential(object):
self._lock.acquire()
def _token_expiring(self):
- return self._token.expires_on - self._get_utc_now() <\
+ return self._token.expires_on - self._get_utc_now_as_int() <\
timedelta(minutes=self._ON_DEMAND_REFRESHING... | [CommunicationTokenCredential->[get_token->[_token_expiring,_token_refresher,_is_currenttoken_valid,_wait_till_inprogress_thread_finish_refreshing,notify_all],_token_expiring->[_get_utc_now,timedelta],_is_currenttoken_valid->[_get_utc_now],_wait_till_inprogress_thread_finish_refreshing->[release,acquire],_get_utc_now->... | Check if the token is expired. | This still wont work - you can do a `<` operation between an int and a timedelta. |
@@ -134,7 +134,7 @@ class RunTracker(Subsystem):
help="Option scopes to record in stats on run completion. "
"Options may be selected by joining the scope and the option with a ^ character, "
"i.e. to get option `pantsd` in the GLOBAL scope, you'd pass "
- "`GLOBAL^pant... | [RunTrackerLogger->[warn->[log],error->[log],info->[log],debug->[log]],RunTracker->[get_critical_path_timings->[add_to_timings],end_workunit->[end_workunit,end],write_stats_to_json->[_json_dump_options],_stats->[run_information],post_stats->[do_post->[error,do_post],error,_get_headers,do_post],new_workunit_under_parent... | Register options for the command line. v2 goal rule names. Process a object. | Nit: I'd make this a separate sentence. "`GLOBAL^pantsd`. Add a '*' to the list to capture all known scopes", |
@@ -141,7 +141,7 @@ class CrossRefSettingsForm extends Form {
* @return boolean
*/
function isOptional($settingName) {
- return in_array($settingName, array('username', 'password', 'automaticRegistration'));
+ return in_array($settingName, array('username', 'password', 'automaticRegistration', 'testMode'));
... | [CrossRefSettingsForm->[initData->[_getPlugin,_getContextId],execute->[_getContextId,_getPlugin]]] | Checks if a setting is optional. | Happy to see test mode moving to a setting rather than an obscure URL parameter :) |
@@ -49,12 +49,7 @@ public abstract class FullResponseHolder<T>
}
/**
- * Append a new chunk of data.
- */
- public abstract FullResponseHolder addChunk(T chunk);
-
- /**
- * Get the accumulated data via {@link #addChunk}.
+ * Get the data.
*/
public abstract T getContent();
}
| [No CFG could be retrieved] | Add a chunk to the response. | `addChunk` seems to be implemented by all the subclasses, then why remove this ? |
@@ -24,11 +24,13 @@ import static org.junit.Assert.assertNotNull;
import static org.junit.Assert.assertThat;
import static org.junit.Assert.assertTrue;
+import java.io.ByteArrayOutputStream;
import java.io.File;
import java.io.InputStream;
import java.util.List;
import java.util.regex.Matcher;
+import org.apa... | [SftpTests->[testSftpInboundFlow->[assertNotNull,getName,get,containsString,register,receive,isOneOf,getPayload,destroy,instanceOf,assertThat,getAbsolutePath,QueueChannel],testSftpMgetFlow->[assertNotNull,send,replaceAll,size,containsString,register,receive,getPayload,quoteReplacement,destroy,channel,assertThat,assertE... | Reads a single version of a single object from the System. Reads configuration of remote file template. | ??? Let me guess you were going to use `org.springframework.util.StreamUtils` |
@@ -326,7 +326,10 @@ public class SparkInterpreter extends Interpreter {
}
}
pythonLibUris.trimToSize();
- if (pythonLibs.length == pythonLibUris.size()) {
+
+ // Distribute two libraries(pyspark.zip and py4j-*.zip) to workers
+ // when spark version is less than or equal to 1.4.1
+ if (pyt... | [SparkInterpreter->[getProgress->[getJobGroup],interpretInput->[interpret],getSQLContext->[useHiveContext,getSparkContext],getCompletionTargetString->[toString],getProgressFromStage_1_0x->[getProgressFromStage_1_0x],getProgressFromStage_1_1x->[getProgressFromStage_1_1x],close->[close],cancel->[getJobGroup],open->[getDe... | Create a new SparkContext with the specified configuration. This method is called to add a key and value pair to the configuration. | I think it always discard user provided `spark.yarn.dist.files`. Is it okay to do? |
@@ -242,7 +242,7 @@ public final class DimensionHandlerUtils
public static Float convertObjectToFloat(Object valObj)
{
if (valObj == null) {
- return 0.0f;
+ return ZERO_FLOAT;
}
if (valObj instanceof Float) {
| [DimensionHandlerUtils->[makeStrategy->[getEffectiveCapabilities]]] | Convert object to float. | This method doesn't match `convertObjectToDouble()` in null handling of the result of tryParse(). Also, please locate those methods next to each other. |
@@ -82,7 +82,7 @@ func (c *cmdUPAK) Run() error {
if v != keybase1.UPAKVersion_V2 {
return fmt.Errorf("didn't get UPAK v2")
}
- upk2, _ := res.V2().FindKID(c.kid)
+ upk2, _ := libkb.FindKID(res.V2(), c.kid)
if upk2 == nil {
return fmt.Errorf("key %s wasn't found", c.kid)
}
| [ParseArgv->[Args,New,KIDFromStringChecked,UIDFromString,String,Bool],Run->[GetTerminalUI,V2,Output,GetUPAKLite,Marshal,Background,G,MarshalIndent,IsNil,V,Errorf,FindKID,GetUPAK],NewContextified,ChooseCommand] | Run executes the command. | needed to do this because go doesn't let you implement a "default method" for an interface |
@@ -34,4 +34,16 @@ module ApplicationHelper
@_decorated_session ||= SessionDecorator.new
end
end
+
+ def sp_session
+ session[:sp]
+ end
+
+ def loa1_signup_context?
+ sp_session && current_user && !current_user.recovery_code.present?
+ end
+
+ def loa3_context?
+ sp_session && sp_session[:... | [title->[content_for],tooltip->[image_tag,content_tag,asset_url],decorated_session->[present?,new],card_cls->[content_for]] | Returns a new object that wraps the given node ID in a ServiceProviderSession or a new. | This means that the last chance a user has to cancel is on the phone confirmation page. Once they confirm their phone number, the Cancel link is no longer available in the Recovery Code page. Is that intentional? |
@@ -18,6 +18,7 @@ import java.util.ArrayList;
import java.util.HashSet;
import java.util.Set;
+import com.google.gwt.core.client.*;
import org.rstudio.core.client.Debug;
import org.rstudio.core.client.StringUtil;
import org.rstudio.core.client.command.ApplicationCommandManager;
| [SourceWindow->[handleUnsavedChangesBeforeExit->[handleUnsavedChangesBeforeExit],getCurrentDocId->[getCurrentDocId],saveWithPrompt->[saveWithPrompt],getUnsavedChanges->[getUnsavedChanges],closeSourceWindow->[execute->[onReadyToQuit],getUnsavedChanges,onReadyToQuit,saveWithPrompt],getCurrentDocPath->[getCurrentDocPath],... | Package for the given version of a n - tuple. Package that imports all the attributes of a resource. | Remove wildcard import, put back individual ones |
@@ -189,13 +189,11 @@ public class MoveDelegate extends AbstractMoveDelegate {
removeAirThatCantLand();
}
- // WW2V2/WW2V3, fires at end of combat move
- // WW2V1, fires at end of non combat move
- if (GameStepPropertiesHelper.isFireRockets(data)) {
- if (needToDoRockets && TechTracker.hasRo... | [MoveDelegate->[loadState->[loadState],saveState->[saveState],end->[end],start->[start],removeAirThatCantLand->[removeAirThatCantLand],setDelegateBridgeAndPlayer->[setDelegateBridgeAndPlayer]]] | end of the sequence. | Why are we checking for isNonCombatMove here? |
@@ -81,4 +81,15 @@ class DefaultController extends WebsiteController
$request->query->all()
);
}
+
+ public function structureNotFoundAction(StructureInterface $structure, $preview = false, $partial = false)
+ {
+ $structureFactory = $this->get('sulu_content.structure.factory');
... | [DefaultController->[indexAction->[renderStructure],redirectWebspaceAction->[all,forward],redirectAction->[all,forward]]] | Redirect action. | should at least return 404 google understands no fun for 500 on a page. |
@@ -286,7 +286,7 @@ class Chart(Plot):
ticker (obj): the axis.ticker object
Return:
- grid: Grid instance
+ Grid: A Grid instance
"""
grid = Grid(dimension=dimension, ticker=ticker)
| [Chart->[start_plot->[create_tools,create_axes,create_grids],create_axes->[_get_labels],__init__->[apply]],ChartDefaults] | Create a grid just passing the axis and dimension. | new sphinx versions automatically link to types for args and returns, needed to make it the real type other wise there were problems. |
@@ -194,7 +194,7 @@ namespace System.Linq
protected override Expression VisitConstant(ConstantExpression c)
{
- EnumerableQuery sq = c.Value as EnumerableQuery;
+ EnumerableQuery? sq = c.Value as EnumerableQuery;
if (sq != null)
{
if (... | [EnumerableRewriter->[ArgsMatch->[Type],Expression->[Type,Expression],LabelTarget->[Type]]] | Visit constant expression. | Please use `is` instead of `as` |
@@ -210,10 +210,14 @@ async def infer_python_dependencies_via_imports(
unowned_dependency_behavior = python_infer_subsystem.unowned_dependency_behavior
if unowned_imports and unowned_dependency_behavior is not UnownedDependencyUsage.DoNothing:
+ unowned_imports_with_lines = [
+ f"{modname}... | [rules->[rules,import_rules],infer_python_dependencies_via_imports->[UnownedDependencyError]] | Infer dependencies via imports. Missing dependencies. | Right now I think this will be relative to Pants root. Since Pants commands are generally run from Pants root, I think that's fine. |
@@ -73,6 +73,11 @@ const EXPERIMENTS = [
name: 'Viewability APIs for amp-analytics',
spec: 'https://github.com/ampproject/amphtml/issues/1297#issuecomment-197441289',
},
+ {
+ id: 'amp-sticky-ad',
+ name: 'AMP Sticky Ad',
+ spec: 'https://github.com/ampproject/amphtml/issues/2472',
+ },
];
| [No CFG could be retrieved] | Builds the table with the given . Create a table with a table row with a td and a button to toggle the experiment. | Do I need a include a .md file here? Or the link to the issue is good? |
@@ -221,7 +221,7 @@ namespace System.Runtime.InteropServices
[MethodImpl(MethodImplOptions.InternalCall)]
internal static extern bool IsPinnable(object? obj);
-#if FEATURE_COMINTEROP
+#if TARGET_WINDOWS
/// <summary>
/// Returns the HInstance for this module. Returns -1 if the mod... | [Marshal->[WriteInt32->[WriteInt32],WriteInt64->[WriteInt64],PtrToStructureHelper->[PtrToStructureHelper],WriteByte->[WriteByte],GetTypeFromCLSID->[GetTypeFromCLSID],ReadInt32->[ReadInt32],GetObjectForNativeVariant->[GetObjectForNativeVariant],CreateWrapperOfType->[GetComObjectData,SetComObjectData],TWrapper->[CreateWr... | Returns the HINST of the module or - 1 if there is no HINST in the. | You may want to also: - Ifdef `QCFuncElement("GetHINSTANCE", COMModule::GetHINSTANCE)` in ecalllist.h for Windows - Move the fallback implementation from src\libraries\System.Private.CoreLib\src\System\Runtime\InteropServices\Marshal.NoCom.cs to src\libraries\System.Private.CoreLib\src\System\Runtime\InteropServices\Ma... |
@@ -1580,7 +1580,7 @@ void MarlinSettings::postprocess() {
#if ENABLED(MESH_BED_LEVELING)
if (!validating) mbl.z_offset = dummyf;
- if (mesh_num_x == GRID_MAX_POINTS_X && mesh_num_y == GRID_MAX_POINTS_Y) {
+ if (mesh_num_x == (GRID_MAX_POINTS_X) && mesh_num_y == (GRID_MAX_POINTS_... | [No CFG could be retrieved] | Reads the specified header values from the network and writes them to the eEP file. This function writes the values of the n - th endstop constant in the System. in. | Why the parenthesis? Shouldn't the paren be part of the macro? |
@@ -54,6 +54,11 @@ func (u *Upgrade) Flags() []cli.Flag {
Usage: "Time to wait for upgrade",
Destination: &u.Timeout,
},
+ cli.BoolFlag{
+ Name: "force, f",
+ Usage: "Force the upgrade -- ignore version issue",
+ Destination: &u.Force,
+ },
}
flags = append(
append(
| [Run->[InitDiagnosticLogs,NewDispatcher,CheckImagesFiles,Reference,Error,Args,New,AddDeprecatedFields,NewVCHFromComputePath,Errorf,Infof,processParams,NewVCHFromID,Base,CollectDiagnosticLogs,GetVCHConfig,WithTimeout,Upgrade,Background,NewValidator,String,SetLevel],processParams->[End,HasCredentials,Begin],Flags->[Compu... | Flags returns the flags that are required to run an upgrade. | maybe change this to `Force the upgrade (ignores version checks)` |
@@ -156,3 +156,18 @@ class RemoteConfig(object):
return self.config.get(
Config.SECTION_CORE, Config.SECTION_CORE_REMOTE, level=level
)
+
+ def default_remote_set(self):
+ """
+ Checks if default remote config is present.
+ Args:
+ rconfig: a remote conf... | [RemoteConfig->[add->[resolve_path],get_settings->[get_settings]]] | Get the default configuration for a given level. | Let's not have it here, as no one is using it. Let's keep this helper in dvc/external_repo.py |
@@ -51,9 +51,8 @@ class SubmissionHandler extends PKPSubmissionHandler
}
switch ($request->getUserVar('list')) {
case 'languages':
- $isoCodes = new \Sokil\IsoCodes\IsoCodesFactory(\Sokil\IsoCodes\IsoCodesFactory::OPTIMISATION_IO);
$matches = [];
- ... | [SubmissionHandler->[fetchChoices->[getLocalName,getScope,getLanguages,getType,getUserVar,getAlpha2,getAlpha3],__construct->[addRoleAssignment]]] | Fetches the choices of a node. | This constant should be passed in the `getLanguages()`. Anyway, I've checked locally and basically didn't get no noticeable improvement (sometimes it was faster, sometimes slower). |
@@ -296,8 +296,11 @@ class Stage(params.StageParams):
for out in self.outs:
current = self._read_env(out, checkpoint_func=checkpoint_func)
- if set(env.keys()).intersection(set(current.keys())):
- raise DvcException("Duplicated env variable")
+ if any(
+ ... | [PipelineStage->[changed_stage->[_changed_stage_entry]],create_stage->[loads_from],Stage->[_status->[status,update],relpath->[relpath],remove->[ignore_remove_outs,unprotect_outs,remove_outs],_status_stage->[changed_stage],changed_entries->[changed_stage,_changed_stage_entry,_changed_entries],dump->[dump],get_all_files_... | Return environment variables. | If we have multiple outs of some type that sets an env var (like `checkpoint`, it is expected that `_read_env` will return the same keys for each out. (So it's acceptable for us to set `{DVC_CHECKPOINT: 1}` more than once.) We should be checking that the values of any repeated keys don't conflict with each other, not t... |
@@ -16,13 +16,8 @@ def update_system_path():
are importable without the `apps.` prefix."""
ROOT = os.path.dirname(os.path.abspath(__file__))
-
- prev_sys_path = set(sys.path)
-
- site.addsitedir(os.path.join(ROOT, 'apps'))
-
- # Move the new items to the front of sys.path.
- sys.path.sort(key=pr... | [init_jinja2,init_amo,load_product_details,update_system_path,init_celery,init_newrelic,init_jingo,filter_warnings,configure_logging,init_session_csrf] | Update sys. path with the new items. | I'd be more specific and say something like `# Insert the 'apps' folder to the front of sys.path so it takes precedence.` |
@@ -471,11 +471,15 @@ def ast_to_func(ast_root, dyfunc, delete_on_exit=True):
else:
module = SourceFileLoader(module_name, f.name).load_module()
func_name = dyfunc.__name__
- if not hasattr(module, func_name):
+ if hasattr(module, '__impl__'):
+ callable_func = getattr(module, '__impl__'... | [parse_arg_and_kwargs->[getfullargspec],is_dygraph_api->[is_api_in_module],RenameTransformer->[visit_Attribute->[get_attribute_full_name],rename->[visit]],ast_to_func->[remove_if_exit],NameNodeReplaceTransformer->[__init__->[visit]],ForNodeVisitor->[_get_iter_var_name->[is_for_iter,is_for_enumerate_iter,is_for_range_it... | Transform modified AST of decorated function into python callable object. | if we can't avoid check `__impl__`, I think we can change `__impl__` to a a more complex name such as `__i_m_p_l__`to avoid error handling for user-defined `__impl__` method |
@@ -62,9 +62,17 @@ module RetrieveTitle
else
current = chunk
end
+ if !encoding && content_type = _response['content-type']&.strip&.downcase
+ if content_type =~ /charset="?([a-z0-9_-]+)"?/
+ encoding = $1
+ if !Encoding.list.map(&:name).map(&:downcase).include?(enco... | [fetch_title->[max_chunk_size,extract_title,new,get,throw,length],max_chunk_size->[host],crawl->[fetch_title],extract_title->[inner_text,gsub!,sub,strip!,at,present?]] | Fetch the title of a page from a given URL. | I tend to prefer `Regexp.last_match(1)` because it feels less like a weird Perl variable. |
@@ -321,6 +321,10 @@ def maxwell_filter(raw, origin='auto', int_order=8, ext_order=3,
sss_ctc = _read_ctc(cross_talk)
ctc_chs = sss_ctc['proj_items_chs']
meg_ch_names = [info['ch_names'][p] for p in meg_picks]
+ # checking for extra space ambiguity in channel names
+ # between o... | [_trans_sss_basis->[_sss_basis],_get_grad_point_coilsets->[_prep_mf_coils],_bases_real_to_complex->[_sh_real_to_complex,_sh_negate,_deg_order_idx],_deg_order_idx->[_sq],_regularize_out->[_get_n_moments],_sss_basis_basic->[_get_mag_mask,_concatenate_sph_coils,_sph_harm,_sph_harm_norm],_regularize_in->[_get_degrees_order... | Apply Maxwell filter to data using multipole moments. Additional information about the top - level of a block of memory that is not currently covered by This function is used to perform a tSSS with the median head position during the time This function is used to provide a more detailed description of the type of a sin... | Do we actually need the conditional? My thought is that we should just always run `_clean_names` on both the `meg_ch_names` and `ctc_chs` lists |
@@ -619,9 +619,9 @@ public class SCMPipelineManager implements PipelineManager {
* @throws IOException
*/
protected void destroyPipeline(Pipeline pipeline) throws IOException {
- pipelineFactory.close(pipeline.getType(), pipeline);
// remove the pipeline from the pipeline manager
removePipeline(... | [SCMPipelineManager->[addContainerToPipeline->[addContainerToPipeline],openPipeline->[openPipeline],getPipeline->[getPipeline],activatePipeline->[activatePipeline],minPipelineLimit->[minPipelineLimit],containsPipeline->[getPipeline],close->[close],removeContainerFromPipeline->[removeContainerFromPipeline],waitPipelineR... | Destroy a pipeline. | why need this change ? The sequence of sending SCMCommand and removing state may affect SCM HA. |
@@ -6621,6 +6621,18 @@ namespace Js
return prototype;
}
+ DynamicObject* JavascriptLibrary::CreateClassConstructorPrototypeObject(RecyclableObject * protoParent)
+ {
+ // We can't share types of objects that are prototypes. If we gain the ability to do that, try using a shared type
+ ... | [No CFG could be retrieved] | Magic object creation. | (nit) What would you think about naming this `CreateClassPrototypeObject` (and similarly removing "Constructor"/"Ctor" from other new names)? It's inherently confusing whether we are talking about the class prototype property or the constructor's proto parent, but for me "class prototype" is more natural for describing... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.