patch
stringlengths
18
160k
callgraph
stringlengths
4
179k
summary
stringlengths
4
947
msg
stringlengths
6
3.42k
@@ -692,11 +692,13 @@ static int xBestIndex(sqlite3_vtab* tab, sqlite3_index_info* pIdxInfo) { // Expect this index to correspond with argv within xFilter. size_t expr_index = 0; // If any constraints are unusable increment the cost of the index. - double cost = 1; + double cost = 1000000; // Tables may have requirements or use indexes. - bool required_satisfied = false; - bool index_used = false; + int numIndexedColumns = 0; + int numRequiredColumns = 0; + int numIndexedConstraints = 0; + int numRequiredConstraints = 0; // Expressions operating on the same virtual table are loosely identified by // the consecutive sets of terms each of the constraint sets are applied onto.
[No CFG could be retrieved]
Returns the value of the column in the current row. Lookup the column name given an index into the table column set.
How would this be `< 0`?
@@ -141,7 +141,8 @@ public class PersistentObjectStorePartition<T extends Serializable> { if (!realKeyToUUIDIndex.containsKey(key)) { - throw new ObjectDoesNotExistException(); + String message = "Key does not exist: " + key; + throw new ObjectDoesNotExistException(CoreMessages.createStaticMessage(message)); } String filename = (String) realKeyToUUIDIndex.get(key); File file = getValueFile(filename);
[PersistentObjectStorePartition->[clear->[clear],trimToMaxSize->[deleteStoreFile],serialize->[serialize,close],remove->[retrieve],deserialize->[close,deserialize],createOrRetrievePartitionDescriptorFile->[close,readPartitionFileName]]]
Retrieve the object with the given key.
Change constructors so that you are required to provide a key, and the message get's formatted in the exception's constructor.
@@ -100,6 +100,14 @@ public class CuratorZookeeperClient extends AbstractZookeeperClient<CuratorZooke try { client.create().withMode(CreateMode.EPHEMERAL).forPath(path); } catch (NodeExistsException e) { + try { + if (!checkEphemeralBelongToCurrentSession(path)) { + deletePath(path); + createEphemeral(path); + } + }catch (Exception e1) { + throw new IllegalStateException(e.getMessage(), e1); + } } catch (Exception e) { throw new IllegalStateException(e.getMessage(), e); }
[CuratorZookeeperClient->[addTargetDataListener->[addTargetDataListener],stateChanged->[stateChanged],isConnected->[isConnected]]]
Creates an ephemeral node with the specified path.
I find this method will get triggered whenever ConnectionState.RECONNECT happens, which can be caused on the root by either connection recover or new session creation. I think it would be better if we can recognize this different condition by checking session id at the entry point of the callback.
@@ -69,6 +69,18 @@ class SelfOriginalTeacher(FbDialogTeacher): super().__init__(opt, shared) +class LimitedSelfOriginalTeacher(SelfOriginalTeacher): + """ SelfOriginal teacher limited to the 20 first dialogs ( 100 examples) + Can be used for debug or testing. + """ + + def num_episodes(self): + return 20 + + def num_examples(self): + return 100 + + class SelfTeacher(SelfOriginalTeacher): pass
[BothTeacher->[__init__->[_path]],NoneTeacher->[__init__->[_path]],SelfOriginalTeacher->[__init__->[_path]],SelfRevisedTeacher->[__init__->[_path]]]
Constructor for the n - tuple teacher class.
can we just do --num-epochs .001 instead of making a new teacher?
@@ -40,10 +40,6 @@ public final class SchemaConstants { public static final QName MULE_ABSTRACT_POOLING_PROFILE_TYPE = new QName(MULE_NAMESPACE, "abstractPoolingProfileType", MULE_PREFIX); public static final QName MULE_POOLING_PROFILE_TYPE = new QName(MULE_NAMESPACE, "pooling-profile", MULE_PREFIX); - public static final QName MULE_ABSTRACT_THREADING_PROFILE_TYPE = - new QName(MULE_NAMESPACE, "abstractServiceThreadingProfileType", MULE_PREFIX); - public static final QName MULE_ABSTRACT_THREADING_PROFILE = - new QName(MULE_NAMESPACE, "abstract-service-threading-profile", MULE_PREFIX); public static final QName MULE_EXTENSION_CONNECTION_PROVIDER_ELEMENT = new QName(MULE_EXTENSION_NAMESPACE, "abstractConnectionProvider", MULE_EXTENSION_PREFIX); public static final QName MULE_EXTENSION_CONNECTION_PROVIDER_TYPE =
[SchemaConstants->[format,QName]]
Creates a new group of MULE elements. MULE_ABSTRACT_OPERATOR and MULE_ABST_OPERATOR are not used.
Check with MG if there is anything else to be cleaned up in modules aside of mule-core related to threading profile.
@@ -66,6 +66,7 @@ namespace System.IO.Tests } [Fact] + [SkipOnTargetFramework(TargetFrameworkMonikers.NetFramework, "Async method")] public async Task ThrowWhenHandlePositionIsChanged_async() { await ThrowWhenHandlePositionIsChanged(useAsync: true);
[FileStream_SafeFileHandle->[Task->[IsInvalid,Seek,WriteByte,Flush,IsOSPlatform,ThrowWhenHandlePositionIsChanged,ReadAsync,End,Assert,SetLength,Windows,GetTestFilePath,Create,Equal,ReadByte,Position,Dispose,Read,Write,ReadWrite,SafeFileHandle,CompletesSynchronously,Length],AccessFlushesFileClosesHandle->[GetTestFilePath,Write,ReadWrite,Create,Equal,Delete,SafeFileHandle,Open,Read,Length],HandleNotNull->[GetTestFilePath,Create,SafeFileHandle,NotNull],DisposeClosesHandle->[GetTestFilePath,IsInvalid,Create,Dispose,SafeFileHandle,IsClosed,True]]]
Throw when handle position is changed.
What does "Async method" mean as to why this is being skipped?
@@ -154,6 +154,7 @@ class DBA /** * Return the database object. * @return PDO|mysqli + * @TODO Maybe not expose this "internal" field? */ public static function getConnection() {
[DBA->[lastInsertId->[lastInsertId],close->[close],fetch->[fetch],rollback->[rollback],columnCount->[columnCount]]]
Get the connection object.
This function is used in the tests.
@@ -328,6 +328,9 @@ int dma_trace_enable(struct dma_trace_data *d) goto out; #endif + /* flush fw description message */ + trace_flush(); + /* validate DMA context */ if (!d->dc.dmac || !d->dc.chan) { tr_err_atomic(&dt_tr, "dma_trace_enable(): not valid");
[No CFG could be retrieved]
finds the host tag and returns the size of the tag region Private functions.
@ktrzcinx Why, with this change, tr_info and trace_flush() are no longer close one to each other?
@@ -11,12 +11,14 @@ from dvc.hash_info import HashInfo from dvc.path_info import CloudURLInfo from dvc.progress import Tqdm from dvc.scheme import Schemes -from dvc.utils import error_link +from dvc.utils import conversions, error_link from .base import BaseTree logger = logging.getLogger(__name__) +_AWS_CONFIG_PATH = os.path.expanduser("~/.aws/config") + class S3Tree(BaseTree): scheme = Schemes.S3
[S3Tree->[_get_bucket->[_get_s3],copy->[_get_s3],_upload->[getsize,_get_obj],get_file_hash->[_get_obj],_get_obj->[_get_bucket],_copy->[copy,_copy_multipart],walk_files->[_list_paths],_download->[_get_obj],getsize->[_get_obj],remove->[_get_obj],_list_paths->[_get_bucket],makedirs->[_get_obj],_upload_fobj->[_get_obj],_generate_download_url->[_get_s3]]]
Creates a new object that represents a single object in the system. Creates a new object for the given key.
Does it work on windows? Or this is how awscli does it too?
@@ -703,13 +703,7 @@ public class ImapMailReceiverTests { when(store.getFolder(Mockito.any(URLName.class))).thenReturn(folder); storeField.set(receiver, store); - doAnswer(new Answer<Object>() { - - @Override - public Object answer(InvocationOnMock invocation) throws Throwable { - return folder; - } - }).when(receiver).getFolder(); + doAnswer(invocation -> folder).when(receiver).getFolder(); MimeMessage mailMessage = mock(MimeMessage.class); Flags flags = mock(Flags.class);
[ImapMailReceiverTests->[receiveAndMarkAsReadDontDeletePassingFilter->[receiveAndMarkAsReadDontDeleteGuts],testIdleWithServerGuts->[testIdleWithServerGuts],testNullMessages->[receive,TestReceiver],receiveAndMarkAsReadDontDeleteFiltered->[receiveAndMarkAsReadDontDeleteGuts]]]
This test creates a queue channel and a mailbox that will be used to receive messages when the This method is called by the mock to answer a message. It will return the message from.
Can we get rid of this long sleep somehow? I understand that this is a `LongRunningIntegrationTest`, but still... Sometime I run `testAll` locally and our CI plan for IO performs `testAll`, too. Twice.
@@ -58,7 +58,7 @@ public class GlobalProjectNamingStrategyConfiguration extends GlobalConfiguratio } } if (j.getProjectNamingStrategy() == null) { - j.setProjectNamingStrategy(DefaultProjectNamingStrategy.DEFAULT_NAMING_STRATEGY); + j.setProjectNamingStrategy(ProjectNamingStrategy.DEFAULT_NAMING_STRATEGY); } return true; }
[GlobalProjectNamingStrategyConfiguration->[configure->[getPluginManager,optJSONObject,getJSONObject,forName,get,getString,bindJSON,FormException,getProjectNamingStrategy,setProjectNamingStrategy]]]
Configures the configuration of the lease.
Also weird and should be cleaned up
@@ -200,6 +200,9 @@ def main(): return os.EX_DATAERR except models.MigrationRemovedError: return os.EX_SOFTWARE + except ServerSelectionTimeoutError: + _logger.info(_('Cannot connect to database, please validate that the database is up.')) + return os.EX_SOFTWARE except Exception, e: _logger.critical(str(e)) _logger.critical(''.join(traceback.format_exception(*sys.exc_info())))
[main->[parse_args],migrate_database->[DataError],_auto_manage_db->[migrate_database],parse_args->[parse_args]]
This is the main entry point for the nagios_magic command.
Does this actually get raised in practice? The call to `connection.initialize()` contains a wait-until-ready behavior which I think will try to reconnect on a timeout error. It's also possible that we don't suppress and continue that exception type and that it would be raised here.
@@ -347,7 +347,7 @@ type LeaderElectionConfiguration struct { // SeedConfig contains configuration for the seed cluster. type SeedConfig struct { - gardencorev1beta1.Seed `json:",inline"` + gardencorev1beta1.SeedTemplate `json:",inline"` } // FluentBit contains configuration for Fluent Bit.
[No CFG could be retrieved]
ResourcesConfiguration defines the configuration for the resources. HTTP servers.
WDYT about removing the `SeedConfig` type in favor of the new `SeedTemplate`? We might even consider renaming the `seedConfig` field to `seedTemplate` to make it consistent with the `ManagedSeed`. Yes, I know, this is a breaking change. But the gardenlet config API is only in an `alpha` version, which means we are able to introduce breaking changes by API conventions. Though, this is probably too much effort for such a cosmetic change and is not worth it. WDYT?
@@ -732,6 +732,9 @@ type RequestHeaderIdentityProvider struct { // ClientCA is a file with the trusted signer certs. If empty, no request verification is done, and any direct request to the OAuth server can impersonate any identity from this provider, merely by setting a request header. ClientCA string `json:"clientCA"` + // ClientCommonNames is an optional list of common names to require a match from. If empty, any client certificate validated against the clientCA bundle is considered authoritative. + ClientCommonNames []string `json:"clientCommonNames"` + // Headers is the set of headers to check for identity information Headers []string `json:"headers"` // PreferredUsernameHeaders is the set of headers to check for the preferred username
[No CFG could be retrieved]
The loginURL and challengeURL parameters are the URLs to redirect unauthenticated requests to.
I can't think of anything better. .
@@ -133,4 +133,17 @@ class User < ActiveRecord::Base def strip_whitespace # no-op end + + # Override Devise because we want to include the SAML request id in the + # confirmation instructions email + def send_confirmation_instructions + # no-op + end + + def send_custom_confirmation_instructions(id = nil) + generate_confirmation_token! unless @raw_confirmation_token + + opts = pending_reconfirmation? ? { to: unconfirmed_email, request_id: id } : { request_id: id } + send_devise_notification(:confirmation_instructions, @raw_confirmation_token, opts) + end end
[User->[decorate->[new],multiple_identities?->[size],set_default_role->[role],send_devise_notification->[deliver_later],need_two_factor_authentication?->[two_factor_enabled?],active_profile->[find],active_identities->[order],confirmation_period_expired?->[ago,utc],password_reset_profile->[first,password_reset?],two_factor_enabled?->[present?],last_identity->[new],after_validation,include,enum,encrypted_attribute,encrypted_attribute_without_setter,has_many,attr_accessor,devise]]
Remove whitespace from a node if it exists.
Where does `@ raw_confirmation_token` get set? Where does `generate_confirmation_token!` come from? Devise?
@@ -108,9 +108,11 @@ public class BlockManagerImpl implements BlockManager { // transaction is reapplied in the ContainerStateMachine on restart. // It also implies that the given block must already exist in the db. // just log and return - LOG.warn("blockCommitSequenceId {} in the Container Db is greater than" - + " the supplied value {}. Ignoring it", - containerBCSId, bcsId); + if (LOG.isDebugEnabled()) { + LOG.debug("blockCommitSequenceId {} in the Container Db is greater" + + " than the supplied value {}. Ignoring it", + containerBCSId, bcsId); + } return data.getSize(); } // update the blockData as well as BlockCommitSequenceId here
[BlockManagerImpl->[getCommittedBlockLength->[parseFrom,getContainerData,getDB,checkNotNull,getBlockByID,getSize],getBlockByID->[get,StorageContainerException,toByteArray,getLocalID],deleteBlock->[getKeyCount,checkState,getContainerData,getLocalID,getDB,toByteArray,writeBatch,checkNotNull,decrKeyCount,getContainerID,BatchOperation,getBlockByID,put,delete],listBlock->[readLock,getValue,checkState,BlockData,getSequentialRangeKVs,getNormalKeyFilter,getContainerData,checkArgument,readUnlock,getDB,toByteArray,add,checkNotNull,getBlockID,getBlockData],shutdown->[shutdownCache,getInstance],getBlock->[parseFrom,StorageContainerException,getContainerData,getBlockCommitSequenceId,getDB,getFromProtoBuf,checkNotNull,getContainerID,getBlockByID],putBlock->[getKeyCount,size,getContainerData,getBlockCommitSequenceId,getLocalID,checkNotNull,warn,isDebugEnabled,BatchOperation,updateBlockCommitSequenceId,put,getSize,incrKeyCount,getContainerID,getBytesUsed,getBlockID,checkState,debug,getDB,toByteArray,writeBatch],checkNotNull,getLogger]]
Put a block into the database. This method is called when the disk space of the block is used by the container. It.
Is it necessary to wrap a debug log entry in the `if (LOG.isDebugEnabled())` statement? It is my understanding, that so long as you are not doing string interpolation in the log message and are passing simple variables as any parameters to the log message (ie not doing any computation to calculate the values being passed), then LOG4J does the correct thing and there is no performance penalty to removing the IF wrapper.
@@ -18,7 +18,12 @@ const limiter = new Bottleneck({ maxConcurrent: 25 }) const getPastEvents = memoize( async function(instance, fromBlock, toBlock, batchSize = 10000) { - if (!instance.loadedCache && instance.ipfsEventCache) { + if ( + instance.ipfsEventCache && + !instance.loadedCache && + (!instance.cacheMaxBlock || + instance.latestIndexedBlock < instance.cacheMaxBlock) + ) { try { debug('Loading event cache from IPFS', instance.ipfsEventCache) const cachedEvents = flattenDeep(
[No CFG could be retrieved]
Get events from IPFS Handle a sequence of new events that have been received from the backend.
Nit: to make it a bit easier to reason about, I would not add +1 here and then remove -1 on line #38 and add +1 on line 41
@@ -847,6 +847,7 @@ class ControlFlowAnalysis(object): def _iter_inst(self): for inst in self.bytecode: if self._use_new_block(inst): + self._guard_with_as(inst) self._start_new_block(inst) self._curblock.body.append(inst.offset) yield inst
[ControlFlowAnalysis->[_op_ABSOLUTE_JUMP_IF->[jump],op_SETUP_LOOP->[jump],_op_ABSOLUTE_JUMP_OR_POP->[jump],_start_new_block->[CFBlock],run->[set_entry_point,process,in_loops,backbone,CFGraph,add_node,add_edge,nodes],op_JUMP_ABSOLUTE->[jump],op_BREAK_LOOP->[jump],op_FOR_ITER->[jump],op_SETUP_WITH->[jump],op_JUMP_FORWARD->[jump],dump->[dump]],CFGraph->[_find_topo_order->[_dfs_rec->[_dfs_rec],_dfs_rec],_find_dominator_tree->[_DictOfContainers],_find_immediate_dominators->[_find_postorder],_find_back_edges->[push_state,entry_point],__ne__->[__eq__],__init__->[_DictOfContainers],_eliminate_dead_blocks->[_remove_node_edges,_dfs],_find_loops->[Loop],_find_in_loops->[in_loops],_find_dominators->[_find_dominators_internal],_find_postorder->[_dfs_rec->[_dfs_rec],_dfs_rec],_find_post_dominators->[_add_edge,_find_dominators_internal,_remove_node_edges],dump->[backbone]],_DictOfContainers->[__ne__->[__eq__]]]
Iterate over the bytecode object.
The included test still passes if this line and the implementation of `_guard_with_as` are removed - is this catching a different, untested case? (I note the code here is also exactly the same as in byteflow.py).
@@ -48,6 +48,10 @@ public class BucketInfo implements Serializable { return partitionPath; } + public void setBucketType(BucketType bucketType) { + this.bucketType = bucketType; + } + @Override public String toString() { final StringBuilder sb = new StringBuilder("BucketInfo {");
[BucketInfo->[toString->[toString],equals->[equals]]]
Returns partition path.
Does the original design make the `BucketInfo` immutable? But now, it has a setter. Can we inject this field from the constructor?
@@ -36,6 +36,6 @@ class DisplayAd < ApplicationRecord # attributes: %w[href target src height width style] stripped_html = initial_html.html_safe # rubocop:disable Rails/OutputSafety html = stripped_html.delete("\n") - self.processed_html = MarkdownParser.new(html).prefix_all_images(html, 350) + self.processed_html = HtmlParser.new(html).prefix_all_images(350).html end end
[DisplayAd->[process_markdown->[render,new,processed_html,prefix_all_images,html_safe,delete],for_display->[rand,order,sample],belongs_to,scope,before_save,validates,where,has_many]]
Processes the given block of markdown and replaces any tags with the correct HTML.
Nice, I like how this reads :-) In the interest of keeping our services folder clean, should it maybe be `Html::Parser`?
@@ -1165,6 +1165,12 @@ namespace Internal.JitInterface private bool shouldEnforceCallvirtRestriction(CORINFO_MODULE_STRUCT_* scope) { throw new NotImplementedException("shouldEnforceCallvirtRestriction"); } + private string getStringLiteral(CORINFO_MODULE_STRUCT_* module, uint metaTOK, ref int length) + { + length = -1; + return null; + } + private CorInfoType asCorInfoType(CORINFO_CLASS_STRUCT_* cls) { var type = HandleToObject(cls);
[No CFG could be retrieved]
private static final int CORINFO_VERIFICATION_CAN_SKIP = 0 ; Get the pin of the .
Does returning a `string` here mean that there's an expectation that RyuJIT will CoTaskMemFree the memory? (I.e once we implement this, there will be a memory leak.) Maybe we should just treat this the same as the JitInterface methods that return `const char*` (i.e. have it return an actual pointer that we can clean up when we're done compiling).
@@ -66,7 +66,9 @@ public class RewindableRotatingFileOutputStream extends RewindableFileOutputStre */ public void deleteAll() { for (int i=0; i<=size; i++) { - getNumberedFileName(i).delete(); + File f= getNumberedFileName(i); + if (!f.delete()) + LOGGER.log(WARNING, String.format("Could not delete %s", f.getAbsolutePath())); } } }
[RewindableRotatingFileOutputStream->[rewind->[getNumberedFileName,rewind]]]
Delete all the files in the list.
Better to replace it by the new `Files` API
@@ -6733,7 +6733,8 @@ var _examplesQuickstartsCakephpMysqlPersistentJson = []byte(`{ }, "message": "The following service(s) have been created in your project: ${NAME}, ${DATABASE_SERVICE_NAME}.\n\nFor more information about using this template, including OpenShift considerations, see https://github.com/openshift/cake-ex/blob/master/README.md.", "labels": { - "template": "cakephp-mysql-persistent" + "template": "cakephp-mysql-persistent", + "app": "cakephp-mysql-persistent" }, "objects": [ {
[FileMode,ModTime,Dir,Unix,Error,WriteFile,Join,Chtimes,Replace,Errorf,Split,MkdirAll,Mode]
A list of all of the configuration options for a single node - tag. Examples of the jenkins pipeline.
The app label should be parameterized so that when templates are used in conjunction to form a single application we can make the `app` labels match.
@@ -310,6 +310,10 @@ const strings = { 'Label for the sidebar button that pulls up a menu ' + 'of options for interacting with the story', }, + [LocalizedStringId.AMP_STORY_SKIP_NEXT_BUTTON_LABEL]: { + string: 'Skip next', + description: 'Label for a button that advances the story to the next page', + }, [LocalizedStringId.AMP_STORY_TOOLTIP_EXPAND_TWEET]: { string: 'Expand Tweet', description:
[No CFG could be retrieved]
Possible share targets are buttons that can be used to share a link via the operating system s A list of AMP - story warning messages that are only supported in wider windows.
Nit: worth adding context saying that it'll skip the current content to advance to the next element of a carousel. The story / page vocabulary is super confusing to people unfamiliar with AMP Stories
@@ -0,0 +1,17 @@ +/** + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with this + * work for additional information regarding copyright ownership. The ASF + * licenses this file to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * <p> + * http://www.apache.org/licenses/LICENSE-2.0 + * <p> + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS,WITHOUT + * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the + * License for the specific language governing permissions and limitations under + * the License. + */ +package org.apache.hadoop.ozone.common.ha.utils; \ No newline at end of file
[No CFG could be retrieved]
No Summary Found.
An empty dir, better remove it.
@@ -1395,8 +1395,15 @@ do_userquota_cacheflush(objset_t *os, userquota_cache_t *cache, dmu_tx_t *tx) cookie = NULL; while ((uqn = avl_destroy_nodes(&cache->uqc_user_deltas, &cookie)) != NULL) { + /* + * os_userused_lock protects against concurrent calls to + * zap_increment_int(). It's needed because zap_increment_int() + * is not thread-safe (i.e. not atomic). + */ + mutex_enter(&os->os_userused_lock); VERIFY0(zap_increment(os, DMU_USERUSED_OBJECT, uqn->uqn_id, uqn->uqn_delta, tx)); + mutex_exit(&os->os_userused_lock); kmem_free(uqn, sizeof (*uqn)); } avl_destroy(&cache->uqc_user_deltas);
[No CFG could be retrieved]
typedef struct userquota_node region UserQuotaUpdateCache methods.
It's good thing these trees are expected to be small. It might be worth breaking these in to cacheline aligned `os_userused_lock` and `os_groupused_lock` locks if there's significant contention.
@@ -171,7 +171,11 @@ class BaseContext(object): return self.tm.check_compatible(fromty, toty) def unify_types(self, *typelist): - return functools.reduce(self.unify_pairs, typelist) + # Sort the type list according to bit width before doing + # pairwise unification (with thanks to aterrel). + def keyfunc(obj): return getattr(obj, 'bitwidth', hash(obj)) + return functools.reduce( + self.unify_pairs, sorted(typelist, key=keyfunc)) def unify_pairs(self, first, second): """
[Context->[init->[install]],BaseContext->[extend_user_function->[insert_user_function],resolve_function_type->[resolve_function_type],type_compatibility->[type_compatibility],insert_class->[insert_attributes],resolve_setitem->[resolve_function_type],unify_pairs->[type_compatibility]]]
Unify PyObject type from a list of tuples.
Hmm, why fall back on hash(obj)? Is it just to get an arbitrary order? (who is "aterrel" by the way?)
@@ -384,6 +384,7 @@ class ADMMPruner(IterativePruner): for i, wrapper in enumerate(self.get_modules_wrapper()): z = wrapper.module.weight.data + self.U[i] self.Z[i] = self._projection(z, wrapper.config['sparsity'], wrapper) + torch.cuda.empty_cache() self.U[i] = self.U[i] + wrapper.module.weight.data - self.Z[i] # apply prune
[IterativePruner->[compress->[_fresh_calculated]],ADMMPruner->[compress->[_projection],_projection->[calc_mask]],AGPPruner->[calc_mask->[calc_mask],compress->[update_epoch]]]
Compress the model with Adam. Returns the model with specified modules compressed.
could you briefly explain the reason of adding this line?
@@ -195,6 +195,17 @@ export class Indexation extends Component { } } + /** + * If the current state of the indexing process is the given state. + * + * @param {STATE.IDLE|STATE.ERRORED|STATE.IN_PROGRESS|STATE.COMPLETED} state The state value to check against. + * + * @returns {boolean} If the current state of the indexing process is the given state. + */ + isState( state ) { + return this.state.state === state; + } + /** * Renders a notice if it is the first time the indexation is performed.
[No CFG could be retrieved]
The endpoint of the component that is rendered when the indexing process is complete. XML for the last n - node SEO data optimization.
I am not sure if this is a tool. It is located on the tools page, but it is an indexing thing...
@@ -52,11 +52,11 @@ class TestMKLDNNMulOpS8S8(OpTest): # limit random range inside |-127, 127| to avoid overflow on SKL if self.srctype == np.int8: - A_data = np.random.randint(-127, 127, (2, 5)).astype(np.int8) - else: - A_data = np.random.randint(0, 127, (2, 5)).astype(np.uint8) + A_data = np.random.randint(-127, 127, (20, 5)).astype(np.int8) + elif self.srctype == np.uint8: + A_data = np.random.randint(0, 127, (20, 5)).astype(np.uint8) - B_data = np.random.uniform(-127, 127, (5, 3)).astype(np.float32) + B_data = np.random.uniform(-127, 127, (5, 20)).astype(np.float32) quant_B = np.round(B_data * self.scale_y[0]).astype(np.int) output = np.dot(A_data, quant_B)
[TestMKLDNNMulOpS8S8WithFlatten->[setUp->[init_data_type,init_data,init_kernel_type]]]
Initialize the data for the .
Is there an option other than `np.int8` and `np.uint8`? If yes, please add `else`. If not, please keep `else` here.
@@ -211,7 +211,12 @@ namespace System.Net.Http { } protected override Stream GetDecompressedStream(Stream originalStream) => - new DeflateStream(originalStream, CompressionMode.Decompress); + // As described in RFC 2616, the deflate content-coding is actually + // the "zlib" format (RFC 1950) in combination with the "deflate" + // compression algrithm (RFC 1951). So while potentially + // counterintuitive based on naming, this needs to use ZLibStream + // rather than DeflateStream. + new ZLibStream(originalStream, CompressionMode.Decompress); } private sealed class BrotliDecompressedContent : DecompressedContent
[No CFG could be retrieved]
Package private class DecompressedContent.
Do you think there is any compatibility issue here? Anyone who might desire the old behavior?
@@ -24,7 +24,7 @@ class TeeLogger: # correctly, so we'll just make sure that each batch shows up on its one line. if '\x08' in message: message = message.replace('\x08', '') - if len(message) == 0 or message[-1] != '\n': + if message or message[-1] != '\n': message += '\n' self.log.write(message)
[TeeLogger->[flush->[flush],__init__->[open,makedirs,dirname],write->[replace,write,len]]]
Writes a message to the terminal and the log file.
I think this one should be `if not message or message[-1] != '\n':`.
@@ -46,11 +46,13 @@ final class DeserializeListener public function onKernelRequest(GetResponseEvent $event) { $request = $event->getRequest(); + $requestContent = null; if ( $request->isMethodSafe(false) || $request->isMethod(Request::METHOD_DELETE) || !($attributes = RequestAttributesExtractor::extractAttributes($request)) || !$attributes['receive'] + || ($request->isMethod(Request::METHOD_PUT) && '' === ($requestContent = $request->getContent())) ) { return; }
[DeserializeListener->[getFormat->[getFormat,get],onKernelRequest->[getContent,getFormat,get,isMethodSafe,createFromRequest,set,deserialize,getRequest,isMethod]]]
Adds a block node to the request if it is a block node.
If you invert the conditions (`('' === $requestContent = $request->getContent()) && $request->isMethod(Request::METHOD_PUT)`), you don't need the trick with `??` anymore because the variable will always be defined. WDYT?
@@ -679,6 +679,10 @@ func (t *tether) launch(session *SessionConfig) error { case <-session.ClearToLaunch: log.Infof("Received the clear signal to launch %s", session.ID) } + // reset RunBlock to unblock process start next time + session.RunBlock = false + prefix := extraconfig.CalculateKeys(t.config, fmt.Sprintf("%s.%s", session.extraconfigKey, session.ID), "")[0] + extraconfig.EncodeWithPrefix(t.sink, session, prefix) } pid := 0
[Start->[processSessions,initializeSessions,cleanup,setup,setHostname,setLogLevel,setNetworks,reloadExtensions,setMounts],handleSessionExit->[cleanupSession],launch->[cleanupSession]]
launch launches a session This function blocks until the container process has been started. This function is called when a process is launched. It will write the pid file to disk.
do we need to call this? We are already calling EncodeWithPrefix in a defer statement above
@@ -571,6 +571,16 @@ def query_paths( offered_fee = pfs_config.info.price scrap_existing_iou = False + current_info = get_pfs_info(pfs_config.info.url) + while current_info.confirmed_block_number < pfs_wait_for_block: + log.info( + "Waiting for PFS to reach target confirmed block number", + pfs_wait_for_block=pfs_wait_for_block, + pfs_confirmed_block_number=current_info.confirmed_block_number, + ) + gevent.sleep(0.5) + current_info = get_pfs_info(pfs_config.info.url) + for retries in reversed(range(MAX_PATHS_QUERY_ATTEMPTS)): # Since the IOU amount is monotonically increasing, only a single # greenlet can be in charge of increasing it at the same time. Using a
[post_pfs_paths->[is_iou_rejected],update_iou->[sign],make_iou->[sign,IOU],get_valid_pfs_url->[get_pfs_info],create_current_iou->[make_iou,get_last_iou,update_iou],get_pfs_info->[PFSInfo],configure_pfs_or_exit->[get_random_pfs,get_pfs_info],get_last_iou->[IOU],get_random_pfs->[get_valid_pfs_url],query_paths->[create_current_iou,get_pfs_info,as_json,post_pfs_paths]]
Query paths from the Pathfinding Service. Get a single node from Pathfinding Service.
I think this sleep might be too short to re-query the PFS for the block number
@@ -130,12 +130,13 @@ public class IntegrationHandler extends BaseHandler @Override public ListResult<Integration> list(UriInfo uriInfo) { Class<Integration> clazz = resourceKind().getModelClass(); - return getDataManager().fetchAll( - Integration.class, + List<Integration> integrations = getDataManager().fetchAll(Integration.class, new DeletedFilter(), new ReflectiveSorter<>(clazz, new SortOptionsFromQueryParams(uriInfo)), new PaginationFilter<>(new PaginationOptionsFromQueryParams(uriInfo)) - ); + ).getItems().stream().map(updateCurrentState).collect(Collectors.toList()); + + return new ListResult.Builder<Integration>().addAllItems(integrations).totalCount(integrations.size()).build(); } @Override
[IntegrationHandler->[delete->[get,determineCurrentState,update],get->[get],create->[create],update->[get,create,update]]]
Returns a list of integration objects that are not yet in the system.
`ListResult.of(integrations)` would be simpler
@@ -35,6 +35,7 @@ type Operations interface { SetupFirewall() error Apply(endpoint *NetworkEndpoint) error MountLabel(ctx context.Context, label, target string) error + MountTarget(ctx context.Context, source url.URL, target string, mountOptions string) error Fork() error // Returns two DynamicMultiWriters for stdout and stderr SessionLog(session *SessionConfig) (dio.DynamicMultiWriter, dio.DynamicMultiWriter, error)
[No CFG could be retrieved]
Type defines the set of operations that the user can use to run a single n -.
Maybe we pass a struct here instead of this, which contains values we wanna pass to this function and that struct happens to have some methods on it to convert those values to the format that consumer consumes? (eg; MountOptions struct and String(), Source(), Target() methods))
@@ -86,7 +86,8 @@ fig.tight_layout() # Compute the degree and plot it # ------------------------------ -degree = mne.connectivity.degree(corr, 0.15) +threshold_percent = 0.15 # percentage of strongest edges to keep in the graph +degree = mne.connectivity.degree(corr, threshold_percent=threshold_percent) stc = mne.labels_to_stc(labels, degree) stc = stc.in_label(mne.Label(inv['src'][0]['vertno'], hemi='lh') + mne.Label(inv['src'][1]['vertno'], hemi='rh'))
[apply_proj,degree,tight_layout,filter,join,apply_inverse_epochs,make_forward_solution,make_inverse_operator,percentile,imshow,dict,crop,envelope_correlation,read_labels_from_annot,apply_gradient_compensation,compute_raw_covariance,compute_proj_ecg,plot,read_raw_ctf,data_path,read_source_spaces,Label,extract_label_time_course,in_label,labels_to_stc,subplots,Epochs,make_fixed_length_events,compute_proj_eog]
Plots the cortical correlation matrix of the given object. The band of the NeuroImage.
This is not a percentage but a proportion
@@ -53,6 +53,8 @@ def compute_raw_psd(raw, tmin=0, tmax=np.inf, picks=None, freqs: array of float The frequencies """ + if NFFT is not None: + warnings.warn("`NFFT` is deprecated, use `n_fft` instead") start, stop = raw.time_as_index([tmin, tmax]) if picks is not None: data, times = raw[picks, start:(stop + 1)]
[compute_raw_psd->[int,make_projector_info,parallel_func,info,array,my_psd,close,time_as_index,float,figure,dot,parallel],_compute_psd->[psd,array],compute_epochs_psd->[int,parallel_func,array,my_psd,close,info,float,pick_types,figure,parallel]]
Compute power spectral density with multi - taper filter. Calculate the PSD of the last nanoseconds in the data.
when will it be deprecated?
@@ -523,6 +523,13 @@ class HTMLPage(object): real_url = geturl(resp) headers = resp.info() + content_type = headers.get('Content-Type', None) + if not content_type.lower().startswith('text/html'): + logger.debug('Skipping page %s because of Content-Type: %s' % (link, content_type)) + if cache is not None: + cache.set_is_archive(url) + return None + contents = resp.read() encoding = headers.get('Content-Encoding', None) #XXX need to handle exceptions and add testing for this
[PackageFinder->[find_requirement->[_sort_locations,mkurl_pypi_url],_sort_locations->[sort_path],_link_package_versions->[_known_extensions],_package_versions->[_sort_links]],get_requirement_from_url->[Link,splitext],HTMLPage->[get_page->[is_archive,add_page_failure,get_page,set_is_archive,add_page,too_many_failures]],Link->[splitext->[splitext]],Link]
Get a page from the cache. Get a object from the cache.
It is not a good idea to choose `None` as default and in the next line do `content_type.lower()`
@@ -906,8 +906,11 @@ def enhance(config, plugins): if not config.chain_path: lineage = cert_manager.lineage_for_certname(config, config.certname) config.chain_path = lineage.chain_path - le_client = _init_le_client(config, authenticator=None, installer=installer) - le_client.enhance_config(domains, config.chain_path, ask_redirect=False) + if oldstyle_enh: + le_client = _init_le_client(config, authenticator=None, installer=installer) + le_client.enhance_config(domains, config.chain_path, ask_redirect=False) + if enhancements.is_supported(config): + enhancements.enable(lineage, domains, installer, config) def rollback(config, plugins):
[enhance->[_init_le_client],revoke->[revoke,_delete_if_appropriate,_determine_account],renew_cert->[_init_le_client,_get_and_save_cert],_ask_user_to_confirm_new_names->[_format_list,_get_added_removed],install->[_init_le_client,_install_cert,_find_domains_or_certname],unregister->[_determine_account],certificates->[certificates],run->[_suggest_donation_if_appropriate,_find_domains_or_certname,_get_and_save_cert,_report_new_cert,_install_cert,_init_le_client,_find_cert],_report_new_cert->[_report_successful_dry_run],certonly->[_suggest_donation_if_appropriate,_find_domains_or_certname,_get_and_save_cert,_report_new_cert,_csr_get_and_save_cert,_init_le_client,_find_cert],rollback->[rollback],main->[set_displayer,make_or_verify_needed_dirs],_find_lineage_for_domains->[_handle_identical_cert_request,_handle_subset_cert_request],_find_lineage_for_domains_and_certname->[_handle_identical_cert_request,_find_lineage_for_domains],delete->[delete],_init_le_client->[_determine_account],register->[_determine_account],main]
Add security enhancements to existing configuration object. Rollback server configuration changes made during install.
nit: I think we technically can remove this check and always call `enhancements.enable`, but feel free to leave this as is if you prefer.
@@ -126,10 +126,13 @@ namespace Js } // The Encode algorithm described in sec. 15.1.3 of the spec. The input string is - // 'input' and the Unescaped set is described by the flags 'unescapedFlags'. The + // 'strURI' and the Unescaped set is described by the flags 'unescapedFlags'. The // output is a string var. - Var UriHelper::Encode(__in_ecount(len) const char16* input, uint32 len, unsigned char unescapedFlags, ScriptContext* scriptContext ) + Var UriHelper::Encode(JavascriptString* strURI, unsigned char unescapedFlags, ScriptContext* scriptContext ) { + uint32 len = strURI->GetLength(); + __in_ecount(len) const char16* input = strURI->GetString(); + bool needsChanges = false; BYTE bUTF8[MaxUTF8Len]; // pass 1 calculate output length and error check
[No CFG could be retrieved]
This routine returns the Unicode code - point value of the UTF - 8 encoding passed in as The Encode algorithm described in sec. 15. 1. 3 of the spec.
I realise that this is how it was previously, but should this be a `charcount_t`? #Resolved
@@ -224,6 +224,7 @@ class CI_Form_validation { 'field' => $field, 'label' => $label, 'rules' => $rules, + 'errors' => $errors, 'is_array' => $is_array, 'keys' => $indexes, 'postdata' => NULL,
[CI_Form_validation->[set_rules->[set_rules],_execute->[_execute],strip_image_tags->[strip_image_tags],xss_clean->[xss_clean],valid_emails->[valid_email],run->[set_rules],set_checkbox->[set_radio],valid_ip->[valid_ip],prep_for_form->[prep_for_form],_reduce_array->[_reduce_array]]]
Set the rules for a field Build the master array of the field_data.
Use a tab to align this.
@@ -41,7 +41,9 @@ module PublicBodyDerivedFields def update_url_name if changed.include?('name') || changed.include?('short_name') - self.url_name = MySociety::Format.simplify_url_part(self.short_or_long_name, 'body') + write_attribute("url_name", + MySociety::Format. + simplify_url_part(self.short_or_long_name, 'body')) end end
[update_url_name->[short_or_long_name,include?,simplify_url_part,url_name],short_or_long_name->[short_name,nil?,name,empty?],set_first_letter->[first_letter,upcase,scan,blank?],included,before_save,extend]
Update url_name if changed.
can probably remove the `self` here
@@ -44,6 +44,10 @@ class _ExecutionContext(object): self._step_context = DirectStepContext(self.keyed_states) return self._step_context + def reset(self): + if self._step_context: + self._step_context = None + class _SideInputView(object):
[DirectStepContext->[get_keyed_state->[DirectUnmergedState]],_SideInputsContainer->[__init__->[_SideInputView]],EvaluationContext->[handle_result->[add_values,finalize_value_and_get_tasks],create_bundle->[create_bundle],get_execution_context->[_ExecutionContext],__init__->[_SideInputsContainer],create_empty_committed_bundle->[create_empty_committed_bundle],get_value_or_schedule_after_output->[get_value_or_schedule_after_output],extract_fired_timers->[extract_fired_timers],get_aggregator_values->[get_aggregator_values]]]
Get the direct step context for the current iteration.
<!--new_thread; commit:2bc3b2426c278088706b430164375d35dc5cd148; resolved:0--> You don't need the if here.
@@ -62,7 +62,7 @@ void GcodeSuite::M355() { else { #if CASELIGHT_USES_BRIGHTNESS if (PWM_PIN(CASE_LIGHT_PIN)) { - SERIAL_ECHOLN(int(caselight.brightness)); + if (TERN0(CASELIGHT_USES_BRIGHTNESS, TERN(CASE_LIGHT_USE_NEOPIXEL, true, PWM_PIN(CASE_LIGHT_PIN)))) { return; } #endif
[M355->[value_bool,seenval,SERIAL_ECHOLNPGM,SERIAL_ECHOPGM,update,PWM_PIN,SERIAL_ECHOLN,SERIAL_ECHO_START,value_byte],ENABLED]
M355 - Check if a node has a missing configuration or if it has a light.
This doesn't look good, did you forgot to remove the if above?
@@ -154,6 +154,16 @@ public class MongoClientTracer extends DatabaseClientTracer<CommandStartedEvent, } } catch (IllegalAccessException | InvocationTargetException | NoSuchMethodException ignored) { } + if (settings == null) { + try { + settings = JsonWriterSettings.class.getConstructor(Boolean.TYPE).newInstance(false); + } catch (InstantiationException + | IllegalAccessException + | InvocationTargetException + | NoSuchMethodException ignored) { + } + } + return settings; }
[MongoClientTracer->[writeScrubbed->[writeScrubbed],onConnection->[onConnection],MongoClientTracer]]
Creates a JsonWriterSettings object that can be used to write a query to the JSON stream.
What happens if this is null, is it ok?
@@ -32,6 +32,18 @@ abstract class CommonDocGenerator { var $error=''; + public $db; + + + /** + * Constructor + * + * @param DoliDB $db Database handler + */ + public function __construct($db) { + $this->db = $db; + return 1; + } /**
[CommonDocGenerator->[printRect->[line],get_substitutionarray_shipment->[list_delivery_methods,getTotalDiscount],get_substitutionarray_contact->[getFullName,fetch_optionals,transnoentitiesnoconv,fetch_name_optionals_label],get_substitutionarray_mysoc->[transnoentitiesnoconv],get_substitutionarray_thirdparty->[fetch_optionals,transnoentitiesnoconv,fetch_name_optionals_label],get_substitutionarray_object->[fetch,fetch_optionals,transnoentitiesnoconv,fetch_name_optionals_label,getTotalDiscount,getSommePaiement,fill_substitutionarray_with_extrafields],get_substitutionarray_user->[getFullName]]]
Provides a function to generate array of substitution key - value pairs for a given user. Define array with couple subtitution key.
Since this is an abstract class, I'd have made the constructor protected.
@@ -178,6 +178,8 @@ func (sg *stepGenerator) GenerateSteps( new := resource.NewState(goal.Type, urn, goal.Custom, false, "", inputs, nil, goal.Parent, goal.Protect, false, goal.Dependencies, goal.InitErrors, goal.Provider, goal.PropertyDependencies, false, goal.AdditionalSecretOutputs, goal.Aliases, &goal.CustomTimeouts) + // Mark the URN/resource as having been seen. + sg.urns[urn] = new // Is this thing a provider resource? If so, stash it - we might need it later when calculating replacement // of resources that use this provider.
[diff->[providerChanged],calculateDependentReplacements->[loadResourceProvider]]
GenerateSteps generates all the steps that need to be performed on the given resource. Process ignore changes and return a new state object This is the main entry point for all the plugin - host operations.
I don't think it's safe to do this so late: this function can terminate before we reach this point if the processing of `ignoreChanges` fails. I think we should keep a second map from URN -> resource state instead, and leave the write to `sg.urns` where it originally was.
@@ -811,5 +811,15 @@ bool Rename(const std::string &from, const std::string &to) return rename(from.c_str(), to.c_str()) == 0; } +std::string CreateTempFile() +{ + std::string path = TempPath() + DIR_DELIM "MT_XXXXXX"; + int fd = mkstemp(&path[0]); // modifies path + if (fd == -1) + return ""; + close(fd); + return path; +} + } // namespace fs
[No CFG could be retrieved]
rename a ncat.
Doesn't `close()` free the temporary file? This seems to be unreliable behaviour.
@@ -254,7 +254,7 @@ export class HDSegwitP2SHWallet extends AbstractHDWallet { } tx.value = value; // new BigNumber(value).div(100000000).toString() * 1; - + tx.confirmations = (response.body.info.latest_block.height - tx.block_height) || 0 this.transactions.push(tx); }
[No CFG could be retrieved]
Get the transactions that are currently in the chain. Fetches the utxos for a given .
Nice! Havent noticed that blockchain info response actually has block height and we can calculate confirmation num
@@ -3037,8 +3037,15 @@ zfs_do_userspace(int argc, char **argv) } while (delim != NULL); } - if ((zhp = zfs_open(g_zfs, argv[0], ZFS_TYPE_DATASET)) == NULL) + if ((zhp = zfs_open(g_zfs, argv[0], ZFS_TYPE_FILESYSTEM | + ZFS_TYPE_SNAPSHOT)) == NULL) return (1); + if (zhp->zfs_head_type != ZFS_TYPE_FILESYSTEM) { + (void) fprintf(stderr, gettext("operation is only applicable " + "to filesystems and their snapshots\n")); + zfs_close(zhp); + return (1); + } if ((avl_pool = uu_avl_pool_create("us_avl_pool", sizeof (us_node_t), offsetof(us_node_t, usn_avlnode), us_compare, UU_DEFAULT)) == NULL)
[No CFG could be retrieved]
ZFS filesystems zfs_for_each - This function is called by zfs_upgrade_list.
Need a `zfs_close()` before the return. In fact it looks like this whole function always leaks the zhp. We should fix that.
@@ -42,7 +42,10 @@ public final class ConnectExecutor { final ConnectResponse<ConnectorInfo> response = client.create( createConnector.getName(), - Maps.transformValues(createConnector.getConfig(), l -> l.getValue().toString())); + ConnectTemplate.resolve( + Maps.transformValues( + createConnector.getConfig(), + l -> l != null ? l.getValue().toString() : null))); if (response.datum().isPresent()) { return Optional.of(
[ConnectExecutor->[execute->[create,of,transformValues,getName,ErrorEntity,isPresent,getStatementText,getStatement,CreateConnectorEntity,get,getConnectClient,getConfig,toString,map]]]
Execute a Ksql statement.
Why would this ever be null?
@@ -31,8 +31,8 @@ export class AmpRiddleQuiz extends AMP.BaseElement { /** @private {?number} */ this.itemHeight_ = 400; //default - /** @private {?number} */ - this.riddleId_ = null; + /** @private {string} */ + this.riddleId_ = ''; /** @private {?Function} */ this.unlistenMessage_ = null;
[No CFG could be retrieved]
Creates an object that represents a single element in the AMP Riddle. Checks if the riddle id is defined and if so sets it to the correct value.
Intentional? Will data['riddleId'] return a string or a number?
@@ -3683,6 +3683,16 @@ func (s TeamSigChainState) GetAllUVs() (res []UserVersion) { return res } +func (s TeamSigChainState) ActiveInvites() (ret []TeamInvite) { + for _, md := range s.InviteMetadatas { + if code, err := md.Status.Code(); err == nil && + code == TeamInviteMetadataStatusCode_ACTIVE { + ret = append(ret, md.Invite) + } + } + return ret +} + func (h *HiddenTeamChain) IsStale() bool { if h == nil { return false
[FindDeviceKey->[Equal],IsPublic->[IsPublic],ListSubteams->[IsNil,String],RootID->[ToTeamID,RootAncestorName],KeySummary->[KeySummary],MaxReaderPerTeamKeyGeneration->[MaxReaderPerTeamKey],AddUVWithRole->[IsRestrictedBot],SwapLastPart->[Parent,Append],Append->[String],AssertionValue->[String],GoError->[Error],PrefixMatch->[IsNil],IsTeamOrSubteam->[IsTeam,IsSubteam],Hash->[ToBytes,Less],ToShortID->[ToBytes],IsZero->[Equal],IsIn->[Equal],GetAllUVs->[UserRole],Match->[IsNil,String],Exists->[IsNil],ToMapKey->[StripSuffix,String],FormatDisplayLabel->[ValueString],ToMediumID->[ToBytes],Clashes->[Eq],GetUserLastJoinTime->[UserRole],GetPerUserKeyAtSeqno->[AllIncarnations],GetShard->[IsValidID],ExportToSimpleUser->[GetUID,GetName],IsRootTeam->[IsSubTeam],FindSigningDeviceKID->[FindSigningDeviceKey],IsAncestorOf->[Eq,Depth],HumanString->[IsRestrictedBot,String],MarshalJSON->[String],Parent->[IsRootTeam],HasKID->[FindKID],Export->[GetUID,GetName],Equal->[Equal],SecureEqual->[Equal,Bytes],Eq->[Owner,Eq,ToBytes,Equal,String],ToShortIDString->[ToBytes],GetUID->[GetUID],Add->[init],IsOrAbove->[teamRoleForOrderingOnly],FindKID->[Equal],GetKeyType->[ToBytes],IsValidID->[IsUser,IsTeamOrSubteam],FindDevice->[Eq],Duration->[Duration],LastFullPopulateIfUnset->[PopulateLastFull],Less->[String],FindEncryptionDeviceKeyFromSigningKID->[Equal],PercentForm->[String],NotEqual->[Equal],UnixSeconds->[Time],IsImplicit->[String],FindSigningDeviceKey->[Eq],ToJsonw->[IsNil],GetDeviceID->[Equal],IsStale->[Max],ToTeamID->[String],FindEncryptionKIDFromSigningKID->[FindEncryptionDeviceKeyFromSigningKID],Compare->[Compare],AsUserOrBust->[AsUser],TeamInviteName->[PercentForm],GetAllAdds->[RestrictedBotUVs],GetStatus->[GetStatus],EqSigID->[StripSuffix,String],MaxTriple->[MaxTriple,TailTriple],FindEncryptionKIDFromDeviceID->[IsNil,FindSigningDeviceKID,FindEncryptionKIDFromSigningKID],AssertEqString->[Eq,String],UnmarshalJSON->[StripSuffix],ToUserVersion->[ToUserVersion],AsTeamOrBust->[AsTeam],ToSigIDLegacy->[ToSigID],GetName->[GetName],IsUsedUp->[IsValid],Merge->[Eq,init,Merge],IsNil->[IsNil],String->[List,NumTotalUsers,IsInfiniteUses,ToString,String],LinkAndKeySummary->[KeySummary],Bytes->[String],List->[String],ToSigID->[String],IsActive,IsZero,Error,check,AsUserOrTeam]
GetAllUVs returns a slice of all UVs in the user log.
this seems similar to `func (t *TeamSigChainState) ActiveInvites()` and seems to only be used in tests. but it's probably fine to keep both
@@ -979,7 +979,7 @@ public class MessagingMethodInvokerHelper<T> extends AbstractExpressionEvaluator } } - private static class ParametersWrapper { + public static class ParametersWrapper { private final Object payload;
[MessagingMethodInvokerHelper->[setConversionService->[setConversionService],findClosestMatch->[findClosestMatch],setBeanFactory->[setBeanFactory],isRunning->[isRunning],HandlerMethod->[toString->[toString],invoke->[invoke],generateExpression->[toString]],stop->[stop],getTargetClass->[getTargetClass],start->[start],processInternal->[prepareEvaluationContext,setBeanFactory],setDisplayString->[toString]]]
Creates a header retrieval expression. Replies the .
Thank you for such a good catch, @garyrussell ! Really appreciate. Previously this class wasn't `static`. But there is really nothing to make it tied with an outer class and the `static` is better for instance. So, right now making it as a `public` (because we need it any way) makes me think that we should poll this class to the package level and bring it better public name. Just in case some one some where will be interested in similar abstraction. WDYT? Otherwise yes, LGTM.
@@ -82,6 +82,10 @@ obj_ec_rw_req_split(daos_unit_oid_t oid, struct obj_iod_array *iod_array, D_ASSERT((oiods[0].oiod_flags & OBJ_SIOD_SINGV) || oiods[0].oiod_nr >= 2); + if (oca == NULL) + oca = daos_oclass_attr_find(oid.id_pub, NULL); + D_ASSERT(oca != NULL); + if (tgt_map != NULL) tgt_max_idx = 0; else
[obj_ec_rw_req_split->[obj_ec_tgt_nr,D_GOTO,D_ALLOC,D_FREE,obj_ec_tgt_oiod_fini,obj_ec_is_valid_tgt,obj_ec_tgt_oiod_init,roundup,D_ASSERT,obj_ec_tgt_oiod_get,setbit],obj_ec_split_req_fini->[D_FREE,obj_ec_tgt_oiod_fini]]
- - - - - - - - - - - - - - - - - - read - write access to the object - store and read - write access to the object - This function is called by the server when a target is not available. obj_ec_tgt_oiod_get - get the next next next next next - - - - - - - - - - - - - - - - - -.
I would rather get oca in ds_obj_dtx_leader_prep_handle() and pass it into this function
@@ -120,7 +120,7 @@ def get_iter(state, unused_arg): def symmetric_binary_op(state, unused_arg): # TODO(robertwb): This may not be entirely correct... - b, a = state.stack.pop(), state.stack.pop() + b, a = Const.unwrap(state.stack.pop()), Const.unwrap(state.stack.pop()) if a == b: state.stack.append(a) elif type(a) == type(b) and isinstance(a, typehints.SequenceTypeConstraint):
[rot_four->[rot_n],rot_three->[rot_n],build_list_unpack->[_unpack_lists],build_tuple_unpack->[_unpack_lists],rot_two->[rot_n],build_tuple_unpack_with_call->[build_tuple_unpack],push_value]
A binary operation that checks if the stack is empty and if so adds a to the.
It looks like this is an unrelated change that got pulled in?
@@ -448,7 +448,11 @@ module.exports = class coinbasepro extends Exchange { } const status = this.parseOrderStatus (this.safeString (order, 'status')); const price = this.safeFloat (order, 'price'); - const amount = this.safeFloat (order, 'size'); + let amount = this.safeFloat (order, 'size'); + if (amount === undefined) { + // old market orders don't have an amount value + amount = this.safeFloat (order, 'funds'); + } const filled = this.safeFloat (order, 'filled_size'); let remaining = undefined; if (amount !== undefined) {
[No CFG could be retrieved]
fetchTime retrieves the last order time for a given order. Get order fee data for a specific order id type side.
I think `funds` means _"cost"_ here, no?
@@ -91,9 +91,9 @@ class PulpBindings(Bindings): """ def __init__(self): - host = cfg.rest.host - port = int(cfg.rest.port) - cert = cfg.rest.clientcert + host = cfg.server.host + port = int(cfg.server.port) + cert = os.path.join(cfg.filesystem.id_cert_dir, cfg.filesystem.id_cert_filename) connection = PulpConnection(host, port, cert_filename=cert) Bindings.__init__(self, connection)
[Profile->[send->[Conduit,PulpBindings,cn,ConsumerX509Bundle,profile,send]],Conduit->[consumer_id->[cn,ConsumerX509Bundle],cancelled->[cancelled]],Synchronization->[profile->[send],registered->[cn,ConsumerX509Bundle]],Consumer->[unbind->[unbind,Conduit],bind->[bind,Conduit],unregistered->[ConsumerX509Bundle,Conduit]],PulpBindings->[__init__->[__init__]],ConsumerX509Bundle->[cn->[cn],__init__->[__init__]],Heartbeat->[send->[cn,ConsumerX509Bundle,producer,send]],RegistrationMonitor->[changed->[cn,ConsumerX509Bundle]],Content->[install->[install,Conduit],uninstall->[uninstall,Conduit],update->[Conduit,update]]]
Initialize the connection to the Pulp server.
This particular join statement seems to happen multiple times in this module. Would it make sense to make it a module-level constant?
@@ -2112,11 +2112,13 @@ public class ResourceManagerImpl extends ManagerBase implements ResourceManager, /* TODO: move to listener */ _haMgr.cancelScheduledMigrations(host); + + boolean vms_migrating = false; final List<VMInstanceVO> vms = _haMgr.findTakenMigrationWork(); for (final VMInstanceVO vm : vms) { - if (vm != null && vm.getHostId() != null && vm.getHostId() == hostId) { - s_logger.info("Unable to cancel migration because the vm is being migrated: " + vm); - return false; + if (vm.getHostId() != null && vm.getHostId() == hostId) { + s_logger.warn("Unable to cancel migration because the vm is being migrated: " + vm + ", hostId = " + hostId); + vms_migrating = true; } }
[ResourceManagerImpl->[updateClusterPassword->[doUpdateHostPassword],createHostAndAgentDeferred->[markHostAsDisconnected,isFirstHostInCluster,createHostVO],propagateResourceEvent->[getPeerName],createHostVOForConnectedAgent->[createHostVO],dispatchToStateAdapters->[deleteHost],umanageHost->[doUmanageHost],getAvailableHypervisor->[getSupportedHypervisorTypes,getDefaultHypervisor],doMaintain->[resourceStateTransitTo],checkAndMaintain->[resourceStateTransitTo],updateHost->[resourceStateTransitTo],deleteHost->[doDeleteHost],addHost->[createHostAndAgent],start->[start],updateHostPassword->[doUpdateHostPassword],maintenanceFailed->[resourceStateTransitTo],doCancelMaintenance->[resourceStateTransitTo],listAllUpAndEnabledNonHAHosts->[listAllUpAndEnabledNonHAHosts],executeUserRequest->[doCancelMaintenance,doDeleteHost,doMaintain],fillRoutingHostVO->[checkIPConflicts],createHostAndAgent->[markHostAsDisconnected,createHostAndAgent,createHostVO],discoverHostsFull->[processResourceEvent],createHostVO->[resourceStateTransitTo,dispatchToStateAdapters,checkCIDR,getCluster],maintain->[processResourceEvent,maintain,doMaintain],registerResourceEvent->[insertListener],cancelMaintenance->[doCancelMaintenance,cancelMaintenance,processResourceEvent]]]
Cancel a maintenance. Checks if a user is authorized to connect to the host and if yes sends a restart to.
Is this conditional right? `vm.getHostId() != null && vm.getHostId() == hostId` It is looking a little weird to me.
@@ -394,6 +394,10 @@ namespace Microsoft.Xna.Framework.Graphics _texCoordTL, _texCoordBR); + unchecked + { + ++_drawCount; + } if (autoFlush) { FlushIfNeeded();
[SpriteBatch->[Draw->[Draw,CheckValid],Dispose->[Dispose],DrawString->[CheckValid]]]
Draws a single color - based sprite. A non - transparent object that can be used to display a color object.
The whitespace used here is a bit of a mess. Maybe `_drawCount++` instead? (There shouldn't be any difference between the two and it is nicer to read). Sorry just nitpicking really :)
@@ -86,11 +86,15 @@ public abstract class TracingRequestStreamHandler implements RequestStreamHandle private final OutputStream delegate; private final io.opentelemetry.context.Context otelContext; + private final OpenTelemetrySdk openTelemetrySdk; private OutputStreamWrapper( - OutputStream delegate, io.opentelemetry.context.Context otelContext) { + OutputStream delegate, + io.opentelemetry.context.Context otelContext, + OpenTelemetrySdk openTelemetrySdk) { this.delegate = delegate; this.otelContext = otelContext; + this.openTelemetrySdk = openTelemetrySdk; } @Override
[TracingRequestStreamHandler->[OutputStreamWrapper->[close->[close],write->[write],flush->[flush]]]]
Write a byte array to the underlying stream.
Are you sure that it is a good thing that library instrumentation depends on SDK? Shouldn't it use only API?
@@ -67,7 +67,7 @@ public class ConnectException extends LocatedMuleException { } } - public void handleReconnection() { + public void handleReconnection(Executor retryExecutor) { // TODO See MULE-9307 - read reconnection behaviour for configs and sources } }
[ConnectException->[writeObject->[writeObject],readObject->[readObject]]]
readObject - read object from a stream.
Why Executor and not ExecutorService?
@@ -558,7 +558,6 @@ WbField *WbNode::field(int index, bool internal) const { WbField *WbNode::findField(const QString &fieldName, bool internal) const { const QVector<WbField *> &l = internal ? mFields : fieldsOrParameters(); - foreach (WbField *const field, l) if (fieldName == field->name()) return field;
[No CFG could be retrieved]
Find the next node in the tree. Retrieves the field in which this node sits and returns the index of the node within this.
Please revert this change.
@@ -785,7 +785,7 @@ def repack_themes_for_69(addon_ids, **kw): else: log.info('[SKIP] No need for theme repack [%s]' % addon.id) timer.log_interval('') - except (IOError, ValidationError) as exc: + except (IOError, ValidationError, SigningError) as exc: log.debug('[FAIL] Theme repack for [%r]:', addon, exc_info=exc) finally: resume_all_tasks()
[theme_checksum->[make_checksum],calc_checksum->[make_checksum],rereviewqueuetheme_checksum->[make_checksum],add_static_theme_from_lwt->[_get_lwt_default_author],save_theme_reupload->[save_persona_image],save_theme->[create_persona_preview_images,theme_checksum,save_persona_image],migrate_lwts_to_static_themes->[add_static_theme_from_lwt],delete_preview_files->[delete_preview_files]]
Repack themes to use 69 + properties.
A test would be nice but since we're in the middle of it not necessarily a requirement to land the code.
@@ -455,8 +455,10 @@ describes.realWin('amp-video', { return listenOncePromise(v, VideoEvents.PAUSE); }) .then(() => { - impl.unmute(); - return listenOncePromise(v, VideoEvents.UNMUTED); + // Can NOT test unmute because browsers no longer allow unmutting + // without user-interaction :( + // impl.unmute(); + // return listenOncePromise(v, VideoEvents.UNMUTED); }) .then(() => { // Should not send the unmute event twice if already sent once.
[No CFG could be retrieved]
This function should not be called directly from the amp element. It is called by the UI The video is only visible when the video ends.
Will the `.then()` block after this fail as a result of not calling `impl.unmute()`?
@@ -419,7 +419,7 @@ func (s *TeamEKBoxStorage) MaxGeneration(ctx context.Context, teamID keybase1.Te // -------------------------------------------------- -const MemCacheLRUSize = 200 +const MemCacheLRUSize = 1000 // Store some TeamEKBoxes's in memory. Threadsafe. type teamEKCache struct {
[Get->[Error,HasError],unbox->[Get],MaxGeneration->[getCacheForTeamID,HasError],GetMap->[Get],DeleteExpired->[getCacheForTeamID,deleteMany,HasError],getCacheForTeamID->[dbKey],PurgeCacheForTeamID->[dbKey],Error->[HasError],put->[dbKey,getCacheForTeamID],fetchAndStore->[Get],deleteMany->[dbKey,getCacheForTeamID],GetAll->[unbox,getCacheForTeamID,HasError]]
MaxGeneration returns a teamEKCache for the given generation. GetMap returns a teamEKBoxCache for the given teamID. If the cache does.
seemed unnecessarily low
@@ -5,9 +5,9 @@ .module('<%=angularAppName%>') .controller('SettingsController', SettingsController); - SettingsController.$inject = ['Principal', 'Auth'<% if (enableTranslation){ %>, 'Language', '$translate'<% } %>]; + SettingsController.$inject = ['Principal', 'Auth'<% if (enableTranslation){ %>, '<%=jhiPrefix%>LanguageService', '$translate'<% } %>]; - function SettingsController (Principal, Auth<% if (enableTranslation){ %>, Language, $translate<% } %>) { + function SettingsController (Principal, Auth<% if (enableTranslation){ %>, <%=jhiPrefix%>LanguageService, $translate<% } %>) { var vm = this; vm.error = null;
[No CFG could be retrieved]
The settings controller.
all this should be `jhiPrefixCapitalized`
@@ -994,11 +994,16 @@ class Optimizer(object): return no_grad_set @framework.dygraph_only - def clear_grad(self): + def clear_grad(self, set_to_zero=True): """ Clear the gradients of all optimized parameters for model. If not, new gradient will accumulat on previous gradient. + + There are two method to clear grad: set_to_zero or delete grad. + + Args: + set_to_zero (bool): If set grads to zero or not, default is True. Returns: None
[Optimizer->[apply_gradients->[_create_optimization_pass],step->[_apply_optimize],append_regularization_ops->[_create_regularization_of_grad],state_dict->[state_dict],set_state_dict->[set_state_dict],_create_param_lr->[_global_learning_rate],_apply_optimize->[apply_gradients,_create_optimization_pass],_create_optimization_pass->[_update_param_device_map,_append_optimize_op,_finish_update,_create_accumulators,_create_global_learning_rate,_get_device_for_param],minimize->[_apply_optimize,backward],backward->[_append_dgc_ops]]]
Clear the gradients of all optimized parameters for model.
bool -> bool, optional
@@ -62,7 +62,8 @@ int WPACKET_reserve_bytes(WPACKET *pkt, size_t len, unsigned char **allocbytes) if (BUF_MEM_grow(pkt->buf, newlen) == 0) return 0; } - *allocbytes = GETBUF(pkt) + pkt->curr; + if (allocbytes != NULL) + *allocbytes = GETBUF(pkt) + pkt->curr; return 1; }
[WPACKET_start_sub_packet_len__->[WPACKET_allocate_bytes],WPACKET_memcpy->[WPACKET_allocate_bytes],WPACKET_init->[WPACKET_init_len],WPACKET_sub_allocate_bytes__->[WPACKET_allocate_bytes],WPACKET_start_sub_packet->[WPACKET_start_sub_packet_len__],WPACKET_sub_memcpy__->[WPACKET_close,WPACKET_memcpy,WPACKET_start_sub_packet_len__],int->[WPACKET_allocate_bytes],WPACKET_sub_reserve_bytes__->[WPACKET_reserve_bytes],WPACKET_put_bytes__->[WPACKET_allocate_bytes]]
This function is called by the WPACKET code to reserve some bytes of data. It.
shouldn't this call the new get_curr routine you just added?
@@ -220,11 +220,6 @@ void ChatBuffer::scrollBottom() m_scroll = getBottomScrollPos(); } -void ChatBuffer::scrollTop() -{ - m_scroll = getTopScrollPos(); -} - u32 ChatBuffer::formatChatLine(const ChatLine& line, u32 cols, std::vector<ChatFormattedLine>& destination) const {
[historyPrev->[replace],step->[deleteByAge,step],formatChatLine->[clear],historyNext->[replace],scrollPageDown->[getRows,scroll],getRecentChat->[getLineCount],resize->[deleteOldest],deleteByAge->[deleteOldest],nickCompletion->[replace],applySettings->[resize],scrollPageUp->[getRows,scroll],clear->[clear],addMessage->[addLine],ChatLine->[getLineCount],addUnparsedMessage->[addMessage],clearRecentChat->[clear],reformat->[reformat,clear],scroll->[scroll]]
This is the main method that is called when a line is entered. Layouts the fragments into lines and places them into the output buffer. This function is called to parse the line and add the fragments to the destination list.
Although very short and trivial I'd prefer keeping this for consistency with `scrollBottom`
@@ -49,7 +49,6 @@ async function checkTypes() { // Prepare build environment process.env.NODE_ENV = 'production'; - cleanupBuildDir(); typecheckNewServer(); await Promise.all([compileCss(), compileJison()]);
[No CFG could be retrieved]
Executes tsc type - checking on the given target.
AFAICT the `debug` flag no longer has meaning in this file
@@ -32,6 +32,8 @@ import ( "testing" "time" + "github.com/elastic/beats/v7/heartbeat/monitors/stdfields" + "github.com/stretchr/testify/require" "github.com/elastic/beats/v7/heartbeat/hbtest"
[CertToTempFile,Compose,HelloWorldHandler,AvailableTCP4Port,NewConfigFrom,Test,RespondingTCPChecks,NewUnstartedServer,DeepEqual,Duration,Close,JoinHostPort,ExpiredCertChecks,LoadX509KeyPair,StartTLS,URLFields,WrapCommon,ReadOpen,GetValue,SummaryChecks,ParseCertificate,NotNil,MustCompile,NewTLSServer,BuildNameToCertificate,Nil,ToConfig,TLSChecks,Join,Equal,BaseChecks,Name,Strict,IsIntGt,Remove,Optional,ErrorChecks,NoError,SizedResponseHandler,StartHTTPSServer,URLChecks,RedirectHandler,NewCertPool,NewServer,Sprintf,String,Parse,AppendCertsFromPEM,Getwd,ReadAll,Sleep,Run,True]
License agreements. sendSimpleTLSRequest tests the given request and sends a TLS request to the given URL.
Import seems out of order, should be with the other `github.com/elastic/beats/v7/...`
@@ -677,6 +677,13 @@ static int ipc_pm_gate(uint32_t header) else pm_runtime_enable(PM_RUNTIME_DSP, PLATFORM_MASTER_CORE_ID); +#if !CONFIG_CAVS_LPRO + if (pm_runtime_is_active(PM_RUNTIME_DSP, PLATFORM_MASTER_CORE_ID)) + platform_set_active_clock(CPU_HPRO_FREQ_IDX); + else + platform_set_active_clock(CPU_LPRO_FREQ_IDX); +#endif + /* resume dma trace if needed */ if (!(pm_gate.flags & SOF_PM_NO_TRACE)) trace_on();
[No CFG could be retrieved]
region Public API Methods function to handle the SOF_IPC_PM_CTX_SAVE SOF.
@mmaka1 @slawblauciak we also send the PM_GATE IPC when the DSP enters D0i3 in S0. The only way for the FW to know if it is sent during S0 or S0ix is by checking whether the DMA_TRACE is requested to be turned off or not. Do you think it makes a difference whether the switching to LPRO is happening during S0 as well?
@@ -76,7 +76,8 @@ export default createStyleSheet({ flex: 1, flexDirection: 'column', margin: 0, - padding: 2 * BoxModel.padding + padding: CONTAINER_PADDING, + paddingTop: 0 }, /**
[No CFG could be retrieved]
A list of all the properties of the top level header.
how about extracting this into a constant?
@@ -141,10 +141,12 @@ func (o ProjectsOptions) RunProjects() error { if err == nil { switch len(projects) { case 0: - msg += "You are not a member of any projects. You can request a project to be created with the 'new-project' command." + if !o.DisplayShort { + msg += "You are not a member of any projects. You can request a project to be created with the 'new-project' command." + } case 1: if o.DisplayShort { - msg += fmt.Sprintf("%s", api.DisplayNameAndNameForProject(&projects[0])) + msg += fmt.Sprintf("%s", projects[0].Name) } else { msg += fmt.Sprintf("You have one project on this server: %q.", api.DisplayNameAndNameForProject(&projects[0])) }
[Complete->[ClientConfig,RawConfig,Errorf,Clients],RunProjects->[Printf,Fprintf,Println,Sprintf,Sort,IsForbidden,GetContextNickname,DisplayNameAndNameForProject],Flags,Error,RunProjects,BoolVarP,LongDesc,UsageError,CheckErr,NewPathOptions,Complete]
RunProjects executes the command shows information about a specific context on a server.
nit, but `&` is not needed here, it can just be `projects[0].name`
@@ -354,7 +354,7 @@ aggregate_basic(struct io_test_args *arg, struct agg_tst_dataset *ds, assert_non_null(buf_u); for (epoch = epr_u->epr_lo; epoch <= epr_u->epr_hi; epoch++) { - if (punch_nr > 0 && punch_epoch[punch_idx] == epoch) { + if (punch_idx < punch_nr && punch_epoch[punch_idx] == epoch) { arg->ta_flags |= TF_PUNCH; assert_true(punch_idx < punch_nr); punch_idx++;
[run_discard_tests->[cmocka_run_group_tests_name],run_aggregate_tests->[cmocka_run_group_tests_name],int->[daos_iov_set,vos_hdl2cont,vos_iterate,strlen,assert_true,test_args_reset,vos_oi_find,assert_int_equal],daos_size_t->[assert_true],void->[daos_iov_set,daos_fail_loc_set,io_test_obj_update,assert_non_null,rand,dts_buf_render,vos_aggregate,io_test_obj_fetch,phy_recs_nr,aggregate_multi,VERBOSE_MSG,strlen,dts_key_gen,assert_int_equal,generate_view,D_ALLOC,D_FREE,daos_sgl_init,generate_or_verify,daos_fail_value_set,generate_recx,get_ds_index,D_ALLOC_ARRAY,dts_unit_oid_gen,assert_memory_equal,fetch_value,verify_view,daos_sgl_fini,memset,aggregate_basic,get_view_len,assert_true,vos_discard,lookup_object,multi_view,update_value]]
- - - - - - - - - - - - - - - - - - Random generation of an object.
I thought I made this change in a recent patch.
@@ -5790,7 +5790,7 @@ def sum_cost(input, name=None, layer_attr=None): :param input: The first input layer. :type input: LayerOutput. - :param name: The name of this layers. It is not necessary. + :param name: The name of this layer. It is not necessary. :type name: None|basestring. :param layer_attr: Extra Layer Attribute. :type layer_attr: ExtraLayerAttribute
[seq_concat_layer->[LayerOutput],out_prod_layer->[LayerOutput],img_pool_layer->[LayerOutput],multiplex_layer->[LayerOutput],cross_entropy->[LayerOutput,__cost_input__],multibox_loss_layer->[LayerOutput],gated_unit_layer->[fc_layer,dotmul_operator,mixed_layer],lstm_step_layer->[LayerOutput],clip_layer->[LayerOutput],MixedLayerType->[AddToSealedMixedLayerException->[__init__->[__init__]],__iadd__->[AddToSealedMixedLayerException],__init__->[__init__]],maxout_layer->[LayerOutput],cross_entropy_with_selfnorm->[LayerOutput],gru_step_layer->[LayerOutput],warp_ctc_layer->[LayerOutput],row_l2_norm_layer->[LayerOutput],cos_sim->[LayerOutput],hsigmoid->[LayerOutput],crf_decoding_layer->[LayerOutput],nce_layer->[LayerOutput],huber_classification_cost->[LayerOutput],spp_layer->[LayerOutput],eos_layer->[LayerOutput],img_pool3d_layer->[LayerOutput],img_conv_layer->[LayerOutput],cross_channel_norm_layer->[LayerOutput],memory->[LayerOutput],priorbox_layer->[LayerOutput],fc_layer->[LayerOutput],recurrent_group->[set_input,memory],kmax_seq_score_layer->[LayerOutput],dropout_layer->[addto_layer],img_cmrnorm_layer->[__img_norm_layer__],smooth_l1_cost->[LayerOutput],interpolation_layer->[LayerOutput],linear_comb_layer->[LayerOutput],get_output_layer->[LayerOutput],beam_search->[__real_step__->[after_real_step,before_real_step,eos_layer],recurrent_group],grumemory->[LayerOutput],repeat_layer->[LayerOutput],prelu_layer->[LayerOutput],cross_entropy_over_beam->[LayerOutput],seq_slice_layer->[LayerOutput],sum_cost->[LayerOutput],img_conv3d_layer->[LayerOutput],sampling_id_layer->[LayerOutput],gru_step_naive_layer->[__gate__->[full_matrix_projection,identity_projection,mixed_layer],dotmul_operator,__gate__,mixed_layer,full_matrix_projection,identity_projection],scaling_layer->[LayerOutput],conv_shift_layer->[LayerOutput],slope_intercept_layer->[LayerOutput],rank_cost->[LayerOutput],sub_nested_seq_layer->[LayerOutput],batch_norm_layer->[LayerOutput],addto_layer->[LayerOutput],power_layer->[LayerOutput],data_layer->[LayerOutput],mixed_layer->[MixedLayerType,mixed_layer],classification_cost->[LayerOutput,__add_evaluator__,__cost_input__],embedding_layer->[table_projection,mixed_layer],ctc_layer->[LayerOutput],selective_fc_layer->[LayerOutput],pooling_layer->[LayerOutput],GeneratedInput->[before_real_step->[embedding_layer,memory]],recurrent_layer->[LayerOutput],row_conv_layer->[LayerOutput],detection_output_layer->[LayerOutput],pad_layer->[LayerOutput],seq_reshape_layer->[LayerOutput],scale_shift_layer->[LayerOutput],expand_layer->[LayerOutput],crf_layer->[LayerOutput],lstmemory->[LayerOutput],__img_norm_layer__->[LayerOutput],bilinear_interp_layer->[LayerOutput],last_seq->[LayerOutput],tensor_layer->[LayerOutput],concat_layer->[__is_type__->[__is_type__],__reduce_concat_type__->[__is_type__],__is_type__,LayerOutput],sum_to_one_norm_layer->[LayerOutput],block_expand_layer->[LayerOutput],crop_layer->[LayerOutput],maxid_layer->[LayerOutput],multi_binary_label_cross_entropy->[LayerOutput],rotate_layer->[LayerOutput],switch_order_layer->[LayerOutput],first_seq->[LayerOutput],square_error_cost->[LayerOutput,__cost_input__],LayerOutput->[__init__->[is_layer_type]],lambda_cost->[LayerOutput],trans_layer->[LayerOutput],huber_regression_cost->[LayerOutput],layer_support]
Sum cost of the last n - layer in a network.
please delete the sentence "It is not necessary."
@@ -127,6 +127,7 @@ namespace System.Net.Quic.Tests stream.Shutdown(); await stream.ShutdownWriteCompleted(); + await stream.ShutdownCompleted(); }, async serverConnection => {
[MsQuicTests->[CreateReadOnlySequenceFromBytes->[CreateSegments,ToArray,Add,Array],WriteData->[Enum,ToArray],Task->[ServerAuthenticationOptions,CreateReadOnlySequenceFromBytes,False,AsTask,ConnectAsync,GatheredBuffers,CloseAsync,GetSslClientAuthenticationOptions,Append,ReadAsync,Sum,CompletedTask,Start,Assert,Skip,OpenBidirectionalStream,GetBytes,AcceptStreamAsync,MsQuic,Equal,nameof,CreateQuicListener,FromSeconds,Shutdown,GetSslServerAuthenticationOptions,GetRemoteAvailableBidirectionalStreamCount,IdleTimeout,SingleBuffer,ShutdownWriteCompleted,CreateQuicConnection,ToArray,GetRemoteAvailableUnidirectionalStreamCount,ListenEndPoint,WriteAsync,Loopback,AcceptConnectionAsync,RunClientServer,GatheredSequence,IsSingleSegment,WaitAsync,Fail,Length,OpenUnidirectionalStream],BufferSegment->[],CreateSegments->[Append,Length,Slice],GetBytes,IsSupported,nameof]]
Write tests for a sequence of bytes.
is awaiting shutdown write completed even necessary?
@@ -88,6 +88,10 @@ .css({ 'background-color': '#DDD' }) .slice(0, c.idx) .css({ 'background-color': c.col }); + }else { + if (!iElement.hasClass('ng-hide')){ + iElement.addClass('ng-hide'); + } } }); }
[No CFG could be retrieved]
ng - hide.
formatting is not good, a space misses
@@ -75,4 +75,4 @@ </footer><!-- #entry-meta --> </article><!-- #post-<?php the_ID(); ?> --> -<?php comments_template( '', true ); ?> \ No newline at end of file +<?php comments_template( '', true ); ?>
[No CFG could be retrieved]
The footer of the page.
I don't think we have a strong preference to newlines, so let's keep those as they were to remove unnecessary changes from the diff.
@@ -249,7 +249,7 @@ func parseSecurityOpt(config *createConfig, securityOpts []string) error { for _, opt := range securityOpts { if opt == "no-new-privileges" { - config.NoNewPrivileges = true + config.NoNewPrivs = true } else { con := strings.SplitN(opt, "=", 2) if len(con) != 2 {
[NewContainer,InitLabels,GetContainerCreateOptions,Pull,IsContainer,GetLocalImageName,Port,StringSlice,GetImage,Close,DisableSecOpt,SplitProtoPort,StringInSlice,GetImageInspectInfo,RAMInBytes,GetFQName,WithShmSize,IsSet,WriteFile,Atoi,IsNotExist,ShmDir,Itoa,ParsePortRange,Error,Stat,ParsePortSpecs,Args,Marshal,IsHost,SplitHostPort,Int,NewImage,PidMode,UTSMode,Errorf,Container,IpcMode,Bool,SplitN,Debug,WithLabels,WithSELinuxLabels,Wrapf,ID,Fprintln,Valid,Uint64,Shutdown,Int64,AddArtifact,Split,ParseUint,NetworkMode,Printf,Listen,WithShmDir,Sprintf,LookupContainer,Addr,Uint,String,ProcessLabel,NewPort,DupSecOpt,FromHumanSize,WithRootFSFromImage,ParseSignal,Float64,WithUser]
parseSecurityOpt parses the security - opt option and sets the appropriate fields in the config. if - creates a new object.
Does this need to be added to the createConfig at ~line 542 in parseCreateOpts?
@@ -0,0 +1,11 @@ +import React from 'react'; +import {StatefulPhoneInput, countries} from 'baseui/phone-input'; + +export default () => ( + <StatefulPhoneInput + initialState={{ + inputValue: `+${countries.find(c => c.id === 'RO').dialCode} `, + countryValue: countries.find(c => c.id === 'RO'), + }} + /> +);
[No CFG could be retrieved]
No Summary Found.
Can it set the input value prefix automatically based on the initially selected country value?
@@ -135,7 +135,7 @@ func installCmd(streams *cli.IOStreams, cmd *cobra.Command, args []string) error } } if token == "" { - token, err = c.ReadInput("Fleet enrollment token:") + token, err = c.ReadInput("Fleet Server enrollment token:") if err != nil { return fmt.Errorf("problem reading prompt response") }
[PrintNotGA,Status,Unlock,GetBool,NewAppLocker,ConfigFile,Confirm,Exit,HasRoot,StartService,Uninstall,TryLock,Start,Errorf,BoolP,ReadInput,Wait,Data,ExitCode,Fprint,ExecutablePath,StopService,Command,Fprintf,Sprintf,Install,GetString,Flags]
Check if the user has provided an enrollment token. If it is not present ask the user check - checks if the elastic agent has already been installed and if so runs it.
@blakerouse That is another one. This is actually the token copied from Fleet?
@@ -128,9 +128,9 @@ func (l *listener) Start() error { return l.StartOnce("DirectRequestListener", func() error { unsubscribeLogs := l.logBroadcaster.Register(l, log.ListenerOpts{ Contract: l.oracle, - Logs: []generated.AbigenLog{ - oracle_wrapper.OracleOracleRequest{}, - oracle_wrapper.OracleCancelOracleRequest{}, + LogsWithTopics: map[common.Hash][][]log.Topic{ + oracle_wrapper.OracleOracleRequest{}.Topic(): {{log.Topic(l.onChainJobSpecID)}}, + oracle_wrapper.OracleCancelOracleRequest{}.Topic(): {{log.Topic(l.onChainJobSpecID)}}, }, NumConfirmations: 1, })
[ServicesForSpec->[NewOracle,Errorf,MinRequiredOutgoingConfirmations,Address,Bytes,NewMailbox],handleCancelOracleRequest->[LoadAndDelete],handleOracleRequest->[Add,CreateLogger,Errorw,Background,CombinedContext,LoadOrStore,With,Err,Done,ExecuteAndInsertFinishedRun],Start->[StartOnce,Done,Add,run,Register,Subscribe],Close->[StopOnce,Range,Wait],HandleLog->[Deliver,Error],run->[Done,handleReceivedLogs],handleReceivedLogs->[handleCancelOracleRequest,Error,DecodedLog,Errorw,handleOracleRequest,ValueOf,Debugw,Warnf,IsNil,Errorf,MarkConsumed,RetrieveIf,WasAlreadyConsumed,RawLog],Sprintf,Errorf,RawLog,Hex]
Start starts the listener.
IIRC, `indexed` topics are hashed. Should definitely test this out on a testnet
@@ -38,10 +38,10 @@ func init() { // Instead, you should fork the logger.Default instance to create a new logger // for your module. // Eg: logger.Default.Named("<my-package-name>") -func SetLogger(newLogger *Logger) { +func SetLogger(newLogger Logger) { if Default != nil { - defer func() { - if err := Default.Sync(); err != nil { + defer func(l Logger) { + if err := l.Sync(); err != nil { if errors.Unwrap(err).Error() != os.ErrInvalid.Error() && errors.Unwrap(err).Error() != "inappropriate ioctl for device" && errors.Unwrap(err).Error() != "bad file descriptor" {
[Warn,PanicIf,Fatalw,Info,ErrorIf,Error,Errorw,RegisterSink,Infow,New,NewProduction,Debug,Sugar,Fatalf,Warnw,Unwrap,ErrorIfCalling,Panic,Sprintf,Sync,Debugw,Fatal,WarnIf]
Initialize a logger. Debugw logs a debug message and any additional given information and includes the ethernet stack trace.
Previously the value of the `Default` variable was not captured, so the deferred func would call `newLogger.Sync()`.
@@ -129,6 +129,8 @@ def get_cuda_home(*subdirs): path. """ cuda_home = os.environ.get('CUDA_HOME') + if cuda_home is None: + cuda_home = os.environ.get('CUDA_PATH') # Try Windows CUDA installation without Anaconda if cuda_home is not None: return os.path.join(cuda_home, *subdirs)
[_get_cudalib_dir->[_get_cudalib_dir_path_decision],_get_cudalib_dir_path_decision->[_cudalib_path,_find_valid_path],_get_libdevice_paths->[_get_libdevice_path_decision],_get_libdevice_path_decision->[_find_valid_path],_get_nvvm_path->[_get_nvvm_path_decision],_get_nvvm_path_decision->[_find_valid_path,_nvvm_lib_dir],get_cuda_paths->[_get_cudalib_dir,_get_nvvm_path,_get_libdevice_paths]]
Get paths of CUDA_HOME. cuda_home is the path to the CUDA.
@seibert Expect this line needs wrapping to 80 chars for flake8 to pass?
@@ -1,7 +1,9 @@ class RemoveRepositoryRowsAndColumnsWithoutRepository < ActiveRecord::Migration[5.1] def up - repository_ids = Repository.select(:id) - RepositoryRow.where.not(repository_id: repository_ids).delete_all - RepositoryColumn.where.not(repository_id: repository_ids).delete_all + if column_exists?(:repositories, :discarded_at) + repository_ids = Repository.select(:id) + RepositoryRow.where.not(repository_id: repository_ids).delete_all + RepositoryColumn.where.not(repository_id: repository_ids).delete_all + end end end
[RemoveRepositoryRowsAndColumnsWithoutRepository->[up->[select,delete_all]]]
Delete all records with no records with no records with no records with no records with no records.
Probably we can get rid of it
@@ -6,14 +6,10 @@ self.onmessage = ( { data } ) => { return; } - for ( const dependency in data.dependencies ) { - if ( ! Object.prototype.hasOwnProperty.call( data.dependencies, dependency ) ) { - continue; - } - - self.importScripts( data.dependencies[ dependency ] ); + for ( const dependency of data.dependencies ) { + self.importScripts( dependency ); - if ( dependency === "lodash" ) { + if ( dependency.includes( "lodash" ) ) { // eslint-disable-next-line no-undef self.lodash = _.noConflict(); }
[No CFG could be retrieved]
Ensure the global window is set and our dependencies use it.
Why is this no longer a precise match? Is it now `vendor/lodash`? If so, maybe a little more precise `endsWith` instead? Or is that a `lodash-es` thing?
@@ -45,6 +45,7 @@ type plugin struct { Bin string Args []string + Env []string Conn *grpc.ClientConn Proc *os.Process Stdin io.WriteCloser
[Close->[Kill,IgnoreClose,KillChildren,Append],Close,WithInsecure,RegisterProcessGroup,StdinPipe,StderrPipe,Code,Atoi,Itoa,Dial,IgnoreError,New,Start,WaitForStateChange,Errorf,Assert,AddInt32,TrimSpace,Wrapf,Invoke,Infof,ReadString,Contains,Kill,V,StdoutPipe,Read,GetState,Command,WithUnaryInterceptor,NewReader,Infoerrf,OpenTracingClientInterceptor,WithTimeout,Background,WithDefaultCallOptions,MaxCallRecvMsgSize,FromError,StreamMessage,Sleep]
Provides a plugin object that can be used to run a plugin on a server. newPlugin creates a plugin from the specified binary.
If the expectation that `Env` contains key value pairs of the form "X=Y", then that definitely should be called out. e.g. what happens when encountering newlines in the config value? Will that work? Or does "Y" need to be enclosed in quotation marks? etc.
@@ -90,7 +90,7 @@ public class SingleKeyNonTxInvocationContext extends AbstractInvocationContext { @Override public CacheEntry lookupEntry(Object key) { - if (key != null && key.equals(this.key)) return cacheEntry; + if (key != null && this.key !=null && key.equals(this.key)) return cacheEntry; return null; }
[SingleKeyNonTxInvocationContext->[removeLookedUpEntry->[clearLockedKeys],clearLookedUpEntries->[clearLockedKeys],putLookedUpEntries->[illegalStateException]]]
Lookup the cache entry for the given key.
This is to protect from broken .equals() implementations which don't check for a null param ?
@@ -332,9 +332,7 @@ namespace System.Xml.Serialization [RequiresUnreferencedCode(TrimSerializationWarning)] public void Serialize(Stream stream, object? o, XmlSerializerNamespaces? namespaces) { - XmlTextWriter xmlWriter = new XmlTextWriter(stream, null); - xmlWriter.Formatting = Formatting.Indented; - xmlWriter.Indentation = 2; + XmlWriter xmlWriter = XmlWriter.Create(stream, new XmlWriterSettings() { CheckCharacters = true, IndentChars = " ", Indent = true }); Serialize(xmlWriter, o, namespaces); }
[XmlSerializer->[FromMappings->[FromMappings],Serialize->[Serialize],Deserialize->[Deserialize],XmlSerializerMappingKey->[GetHashCode->[GetHashCode]],GetXmlSerializerAssemblyName->[GetXmlSerializerAssemblyName],GenerateTempAssembly->[GenerateTempAssembly],FromTypes->[FromMappings]]]
Serialize a managed object to the specified stream.
Same for this, skip setting values to the defaults.
@@ -24,7 +24,7 @@ namespace Microsoft.Extensions.DependencyInjection.ServiceLookup public CallSiteFactory(IEnumerable<ServiceDescriptor> descriptors) { _stackGuard = new StackGuard(); - _descriptors = descriptors.ToList(); + _descriptors = descriptors.ToArray(); Populate(); }
[CallSiteFactory->[ServiceDescriptorCacheItem->[]]]
Populates the cache with the service descriptors.
What was the benefit of this change? Is _descriptors accessed a lot such that the overhead of going through _descriptors as a list vs an array mattered?
@@ -389,13 +389,16 @@ func (jm *runManager) updateWithError(run *models.JobRun, msg string, args ...in logger.Errorw("Error saving run", run.ForLogger("error", err)...) return err } + jm.statsPusher.PushNow() return nil } func (jm *runManager) updateAndTrigger(run *models.JobRun) error { + defer jm.statsPusher.PushNow() if err := jm.orm.SaveJobRun(run); err != nil { return err } + jm.statsPusher.PushNow() if run.Status == models.RunStatusInProgress { numberRunsResumed.Inc() jm.runQueue.Run(run)
[Create->[Ended,Started,Sprintf,Runnable,Archived,Debugw,Now,String,Errorf,Run,CreateJobRun,Wrap,FindJob,ForLogger,Inc,Unscoped],ResumeAllInProgress->[UnscopedJobRunsWithStatus],ResumePending->[NextTaskRun,FindJobRun,PendingBridge,Debugw,updateWithError,ApplyBridgeRunResult,Errorf,Merge,updateAndTrigger,ForLogger,Unscoped],ResumeAllConfirming->[NewBig,NextTaskRun,Errorw,Sprintf,Debugw,updateWithError,UnscopedJobRunsWithStatus,ForLogger,updateAndTrigger],updateWithError->[Error,Errorw,Sprintf,Errorf,ForLogger,SaveJobRun,SetError],Cancel->[FindJobRun,Debugw,Finished,Errorf,Cancel,Inc,ForLogger,SaveJobRun],updateAndTrigger->[Inc,Run,SaveJobRun],CreateErrored->[Now,NewID,CreateJobRun,Wrap,FindJob,SetError,Unscoped],ResumeAllConnecting->[NextTaskRun,Errorw,Debugw,updateWithError,UnscopedJobRunsWithStatus,ForLogger,updateAndTrigger],Uint32From,Add,MinimumContractPayment,NewBig,Cmp,NewLink,Errorf,SetError,Text,MinConfs,MaxUint32,NewCounter,MinPayment,ForLogger,For,MinIncomingConfirmations,Debugw,NewID,String]
updateWithError updates a run with error message and triggers the run.
Not related to this PR but, what's the difference between a `JobManager` (jm) and a `RunManager` (the type itself)?
@@ -23,6 +23,7 @@ import numpy as np from tensorflow.python.framework import dtypes from tensorflow.python.framework import errors from tensorflow.python.framework import ops +from tensorflow.python.framework import test_util from tensorflow.python.ops import array_ops from tensorflow.python.ops import sparse_ops from tensorflow.python.platform import test
[SparseToDenseTest->[testFloat->[assertAllClose,sparse_to_dense,array],testShapeInferenceUnknownShape->[placeholder,assertIsNone,get_shape,Graph,sparse_to_dense],testBadNumValues->[assertRaisesRegex,sparse_to_dense,evaluate],testBadDefault->[assertRaisesRegex,sparse_to_dense,evaluate],test2d->[assertAllClose,sparse_to_dense,array],testRepeatingIndicesWithWithoutValidation->[assertRaisesRegex,sparse_to_dense,evaluate],testInt->[assertAllClose,sparse_to_dense,array],testSetSingleValue->[assertAllClose,sparse_to_dense,array],testSetValue->[assertAllClose,sparse_to_dense,array],testShapeInferenceKnownShape->[placeholder,assertEqual,get_shape,Graph,sparse_to_dense],testUnsortedIndicesWithWithoutValidation->[assertRaisesRegex,sparse_to_dense,evaluate],testString->[assertAllEqual,sparse_to_dense,array],test3d->[assertAllClose,ones,sparse_to_dense],testOutOfBoundsIndicesWithWithoutValidation->[assertRaisesRegex,sparse_to_dense,evaluate],testZeroDefault->[assertAllEqual,sparse_to_dense],testBadShape->[assertRaisesRegex,sparse_to_dense],testBadValue->[assertRaisesRegex,sparse_to_dense,evaluate]],main]
Tests for tensorflow. kernels. sparse_op. Test for the number of unique values in the system.
Please change the corresponding `tf_py_test` to `cuda_py_test`.
@@ -394,7 +394,7 @@ module Repository #if @repos_admin # Are we admin? # Adds a user with given permissions to the repository - ga_repo = Gitolite::GitoliteAdmin.new(Repository.conf[:REPOSITORY_PERMISSION_FILE]) + ga_repo = Gitolite::GitoliteAdmin.new(Repository.conf[:REPOSITORY_STORAGE]) repo = ga_repo.config.get_repo(self.get_repos.workdir.split('/').last) # Gets permissions of a particular user
[GitRevision->[initialize->[get_repos]],GitRepository->[delete_bulk_permissions->[add_user],expand_path->[expand_path],remove_user->[add_user],add_file->[path_exists_for_latest_revision?],latest_revision_number->[get_revision_number],remove_file->[commit_options,create],create->[commit_options,create],access->[open],make_directory->[make_directory,expand_path],close->[close],get_revision_by_timestamp->[get_revision,get_revision_number,get_repos],add_user->[close],make_file->[commit_options,create,open]]]
Get permissions for a given user.
Line is too long. [81/80]
@@ -146,7 +146,9 @@ func resourceAwsCognitoResourceServerRead(d *schema.ResourceData, meta interface scopeIdentifier := fmt.Sprintf("%s/%s", aws.StringValue(resp.ResourceServer.Identifier), elem["scope_name"].(string)) scopeIdentifiers = append(scopeIdentifiers, scopeIdentifier) } - d.Set("scope_identifiers", scopeIdentifiers) + if err := d.Set("scope_identifiers", scopeIdentifiers); err != nil { + return fmt.Errorf("error setting scope_identifiers: %s", err) + } return nil }
[StringLenBetween,Printf,UpdateResourceServer,StringValue,GetOk,Sprintf,List,Id,String,Errorf,DescribeResourceServer,DeleteResourceServer,SetId,Get,CreateResourceServer,Split,Set]
resourceAwsCognitoResourceServerUpdate updates a cognito resource server based on the provided data UpdateResourceServer updates a Cognito Resource Server.
Sorry this change was unrelated to the syntax fixes to try and see if the new Terraform 0.12 error could be teased out with `d.Set()`, but it didn't help. The error check is a recommended practice, but let me know if you want this removed since its unrelated.
@@ -1957,8 +1957,14 @@ func (dctx *docGenContext) generatePackage(tool string, pkg *schema.Package) (ma glog.V(3).Infoln("generating package docs now...") files := fs{} - for _, mod := range dctx.modules() { - if err := mod.gen(files); err != nil { + modules := []string{} + modMap := dctx.modules() + for k := range modMap { + modules = append(modules, k) + } + sort.Strings(modules) + for _, mod := range modules { + if err := modMap[mod].gen(files); err != nil { return nil, err } }
[getPythonLookupParams->[getLanguageDocHelper],getTSLookupParams->[getLanguageDocHelper],genLookupParams->[getTSLookupParams,getCSLookupParams,getPythonLookupParams,getGoLookupParams],genConstructorGo->[getLanguageDocHelper],getConstructorResourceInfo->[getLanguageModuleName],getPropertiesWithIDPrefixAndExclude->[typeString,getLanguageDocHelper],genNestedTypes->[getLanguageDocHelper],getGoLookupParams->[getLanguageDocHelper],genConstructorCS->[getLanguageDocHelper],genConstructors->[genConstructorTS,genConstructorPython,genConstructorGo,genConstructorCS],genConstructorTS->[getLanguageDocHelper],cleanTypeString->[cleanTypeString,getLanguageModuleName],generatePackageTree->[modules],getCSLookupParams->[getLanguageDocHelper],typeString->[cleanTypeString,getLanguageModuleName,typeString,getLanguageDocHelper],getMod->[getMod],genResource->[genNestedTypes,genLookupParams,genConstructors,getProperties,getConstructorResourceInfo,genResourceHeader],gen->[getModuleFileName,genResource,add],generatePackage->[gen,modules],genConstructorPython->[getLanguageDocHelper],genIndex->[getModuleFileName],initialize->[generateModulesFromSchemaPackage,setModules],generateModulesFromSchemaPackage->[details,getMod,getLanguageDocHelper],getNestedTypes->[contains,getNestedTypes,add],getTypes->[getNestedTypes,getTypes],withDocGenContext->[withDocGenContext],generatePackage,generatePackageTree,initialize]
generatePackage generates the package docs.
Oof nice find. Anything else using dctx.modules() like this?
@@ -66,6 +66,13 @@ public class HttpTunnelServerChannel extends AbstractServerChannel implements HttpTunnelServerChannelSink sink = (HttpTunnelServerChannelSink) getPipeline().getSink(); sink.setRealChannel(realChannel); + ChannelFutureListener CLOSE_FUTURE_PROXY = new ChannelFutureListener() { + @Override + public void operationComplete(ChannelFuture future) + throws Exception { + HttpTunnelServerChannel.this.setClosed(); + } + }; sink.setCloseListener(CLOSE_FUTURE_PROXY); config = new HttpTunnelServerChannelConfig(realChannel); }
[HttpTunnelServerChannel->[getLocalAddress->[getLocalAddress],TunnelCreator->[newChannel->[create]],create->[HttpTunnelServerChannel],isBound->[isBound],setClosed->[setClosed]]]
Returns the server socket configuration.
Isn't this just a matter of style ? I can not see any improvement whic his archived by this ...