text
stringlengths
78
104k
score
float64
0
0.18
async def result_continuation(task): """A preliminary result processor we'll chain on to the original task This will get executed wherever the source task was executed, in this case one of the threads in the ThreadPoolExecutor""" await asyncio.sleep(0.1) num, res = task.result() return num...
0.00304
def get_nts_sorted(self, hdrgo_prt, hdrgos, hdrgo_sort): """Return a flat list of grouped and sorted GO terms.""" nts_flat = [] self.get_sorted_hdrgo2usrgos(hdrgos, nts_flat, hdrgo_prt, hdrgo_sort) return nts_flat
0.008163
def drain_transport(self): ''' "Drain" the transport connection. This command simply returns all waiting messages sent from the remote chrome instance. This can be useful when waiting for a specific asynchronous message from chrome, but higher level calls are better suited for managing wait-for-message typ...
0.029661
def update(self, deltat=1.0): '''straight lines, with short life''' DNFZ.update(self, deltat) self.lifetime -= deltat if self.lifetime <= 0: self.randpos() self.lifetime = random.uniform(300,600)
0.011952
def dispatch(self, tree): "Dispatcher function, dispatching tree type T to method _T." if isinstance(tree, list): for t in tree: self.dispatch(t) return meth = getattr(self, "_" + tree.__class__.__name__) meth(tree)
0.006969
def error_code(self, code): """ :param code: :return: """ context = { 'error_title': "Damn error page %i" % code, 'error_header': "What has happened?", 'error_footer': "WHY!?!?!", 'error_messages': { ('Error %i' % code): self.__message__(code) } } return WWebTemplateResponse(WTemplateT...
0.043478
def extract_HBS_learning_curves(runs): """ function to get the hyperband learning curves This is an example function showing the interface to use the HB_result.get_learning_curves method. Parameters ---------- runs: list of HB_result.run objects the performed runs for an unspecified config Returns ------...
0.031133
def registerMUX(self, stm: Union[HdlStatement, Operator], sig: RtlSignal, inputs_cnt: int): """ mux record is in format (self.MUX, n, m) where n is number of bits of this mux and m is number of possible inputs """ assert inputs_cnt > 1 res = se...
0.006073
def find_tor_binary(globs=('/usr/sbin/', '/usr/bin/', '/Applications/TorBrowser_*.app/Contents/MacOS/'), system_tor=True): """ Tries to find the tor executable using the shell first or in in the paths whose glob-patterns is in the given 'globs'-tuple. :par...
0.000707
def to_epoch(t): """Take a datetime, either as a string or a datetime.datetime object, and return the corresponding epoch""" if isinstance(t, str): if '+' not in t: t = t + '+00:00' t = parser.parse(t) elif t.tzinfo is None or t.tzinfo.utcoffset(t) is None: t = t.repl...
0.00207
def from_Cary(filepath, name=None, parent=None, verbose=True): """Create a collection object from a Cary UV VIS absorbance file. We hope to support as many Cary instruments and datasets as possible. This function has been tested with data collected on a Cary50 UV/VIS spectrometer. If any alternate inst...
0.001459
def get_partitions(self, persistence=None): """ Returns the partitioned data based on a specified persistence level. @ In, persistence, a floating point value specifying the size of the smallest feature we want to track. Default = None means consider all features....
0.000976
def __create_orget_address(conn, name, region): ''' Reuse or create a static IP address. Returns a native GCEAddress construct to use with libcloud. ''' try: addy = conn.ex_get_address(name, region) except ResourceNotFoundError: # pylint: disable=W0703 addr_kwargs = { ...
0.001912
def get_version(self): """Fetches the current version number of the Graph API being used.""" args = {"access_token": self.access_token} try: response = self.session.request( "GET", FACEBOOK_GRAPH_URL + self.version + "/me", params=args,...
0.002545
def put(self, file): """ Create a new file on github :param file: File to create :return: File or self.ProxyError """ input_ = { "message": file.logs, "author": file.author.dict(), "content": file.base64, "branch": file.branch ...
0.002094
def segment(self, text, lower=True, use_stop_words=True, use_speech_tags_filter=False): """对一段文本进行分词,返回list类型的分词结果 Keyword arguments: lower -- 是否将单词小写(针对英文) use_stop_words -- 若为True,则利用停止词集合来过滤(去掉停止词) use_speech_tags_filter -- 是否基于词性进行过滤。若为True,则使用self.d...
0.006459
def _item_to_document_ref(iterator, item): """Convert Document resource to document ref. Args: iterator (google.api_core.page_iterator.GRPCIterator): iterator response item (dict): document resource """ document_id = item.name.split(_helpers.DOCUMENT_PATH_DELIMITER)[-1] ...
0.002717
def _compress(self, value, module_name): """Compress the value passed in using the named compression module. :param bytes value: The uncompressed value :rtype: bytes """ self.logger.debug('Decompressing with %s', module_name) if not isinstance(value, bytes): ...
0.004843
def get_conf(conf, sect, opt): """ Gets a config 'opt' from 'conf' file, under section 'sect'. If no 'opt' exists under 'sect', it looks for option on the default_configs dictionary If there exists an environmental variable named MAMBUPY_{upper_case_opt}, it overrides whatever the conf files or de...
0.001634
def init_log_rate(output_f, N=None, message='', print_rate=None): """Initialze the log_rate function. Returnas a partial function to call for each event. If N is not specified but print_rate is specified, the initial N is set to 100, and after the first message, the N value is adjusted to emit prin...
0.001119
def file_pour(filepath, block_size=10240, *args, **kwargs): """Write physical files from entries.""" def opener(archive_res): _LOGGER.debug("Opening from file (file_pour): %s", filepath) _archive_read_open_filename(archive_res, filepath, block_size) return _pour(opener, *args, flags=0, **k...
0.003067
def generate(env): """Add Builders and construction variables for yacc to an Environment.""" c_file, cxx_file = SCons.Tool.createCFileBuilders(env) # C c_file.add_action('.y', YaccAction) c_file.add_emitter('.y', yEmitter) c_file.add_action('.yacc', YaccAction) c_file.add_emitter('.yacc', ...
0.003755
def do_dd(self, arg): """ [~thread] dd <register> - show memory contents as dwords [~thread] dd <register-register> - show memory contents as dwords [~thread] dd <register> <size> - show memory contents as dwords [~process] dd <address> - show memory contents as dwords [~...
0.003472
def _query(_node_id, value=None, **kw): "Look up value by using Query table" query_result = [] try: query_result = db.execute(text(fetch_query_string('select_query_from_node.sql')), **kw).fetchall() except DatabaseError as err: current_app.logger.error("DatabaseError: %s, %s", err, kw) ...
0.007705
def hincrby(self, key, field, increment=1): """Increment the integer value of a hash field by the given number.""" return self.execute(b'HINCRBY', key, field, increment)
0.010811
def _put_pages(self): """ First, the Document object does the heavy-lifting for the individual page objects and content. Then, the overall "Pages" object is generated. """ self.document._get_orientation_changes() self.document._output_pages() ...
0.00203
def describe_cluster_snapshots(self, cluster_identifier): """ Gets a list of snapshots for a cluster :param cluster_identifier: unique identifier of a cluster :type cluster_identifier: str """ response = self.get_conn().describe_cluster_snapshots( ClusterIden...
0.00321
def suggest_filename(file_path, exists=None): """ Try if exist path and append number to its end. For debug you can set as input if file exists or not. """ import os.path import re if not isinstance(exists, bool): exists = os.path.exists(file_path) if exists: file_path, ...
0.001103
def links(self): """Yields all links in the page""" for anchor in self.parsed.findall(".//a"): if anchor.get("href"): href = anchor.get("href") url = self.clean_link( urllib_parse.urljoin(self.base_url, href) ) ...
0.00213
def _fast_memory_load_pointer(self, addr, size=None): """ Perform a fast memory loading of a pointer. :param int addr: Address to read from. :param int size: Size of the pointer. Default to machine-word size. :return: A pointer or None if the address does not exist. ...
0.004049
def render_full(self, request, lodgeit_url=None): """Render the Full HTML page with the traceback info.""" app = request.app root_path = request.app.ps.debugtoolbar.cfg.prefix exc = escape(self.exception) summary = self.render_summary(include_title=False, request=request) ...
0.003265
def install(self, package, shutit_pexpect_child=None, options=None, timeout=shutit_global.shutit_global_object.default_timeout, force=False, check_exit=True, echo=None, reinstall=False, background=False,...
0.038446
def dump_requestdriver_cookies_into_webdriver(requestdriver, webdriverwrapper, handle_sub_domain=True): """Adds all cookies in the RequestDriver session to Webdriver @type requestdriver: RequestDriver @param requestdriver: RequestDriver with cookies @type webdriverwrapper: WebDriverWrapper @param w...
0.003743
def printContentsOfJobStore(jobStorePath, nameOfJob=None): """ Fetch a list of all files contained in the jobStore directory input if nameOfJob is not declared, otherwise it only prints out the names of files for that specific job for which it can find a match. Also creates a logFile containing thi...
0.004769
def language_create(name, maintenance_db, user=None, host=None, port=None, password=None, runas=None): ''' .. versionadded:: 2016.3.0 Installs a language into a database CLI Example:...
0.000696
def tiles_from_bounds(self, bounds, zoom): """ Return all tiles intersecting with bounds. Bounds values will be cleaned if they cross the antimeridian or are outside of the Northern or Southern tile pyramid bounds. Parameters ---------- bounds : tuple ...
0.003067
def top_sort_recursive(graph): """ Time complexity is the same as DFS, which is O(V + E) Space complexity: O(V) """ order, enter, state = [], set(graph), {} def dfs(node): state[node] = GRAY #print(node) for k in graph.get(node, ()): sk = state.get(k, Non...
0.008237
def is_installed(name): """ Checks whether a package with the name is already installed. :param name: the name of the package :type name: str :return: whether the package is installed :rtype: bool """ pkgs = installed_packages() for pkge in pkgs: if pkge.name == name: ...
0.002825
def value(self): """The current value of the mean.""" return self._sum / tf.cast(self._count, self._dtype)
0.008772
def remove_replica(self, partition_name, osr_broker_ids, count=1): """Removing a replica is done by trying to remove a replica from every broker and choosing the resulting state with the highest fitness score. Out-of-sync replicas will always be removed before in-sync replicas. :param p...
0.001132
def send(self, content): """ Write the content received from the SSH client to the standard input of the forked command. :param str content: string to be sent to the forked command """ try: self.process.stdin.write(content) except IOError as e: ...
0.003021
def close(self): """shut down the pool's workers this method sets the :attr:`closing` attribute, and once all queued work has been completed it will set the :attr:`closed` attribute """ self._closing = True for i in xrange(self.size): self.inq.put(_STOP)
0.006349
def stateenabled(self, window_name, object_name): """ Check whether an object state is enabled or not @param window_name: Window name to look for, either full name, LDTP's name convention, or a Unix glob. @type window_name: string @param object_name: Object name to look ...
0.002736
def find_files(self, word): """Yield matching directory or file names. :param word: :return: iterable """ base_path, last_path, position = parse_path(word) paths = suggest_path(word) for name in sorted(paths): suggestion = complete_path(name, last_path...
0.004963
def std(self, ddof=1, *args, **kwargs): """ Compute standard deviation of groups, excluding missing values. Parameters ---------- ddof : integer, default 1 Degrees of freedom. """ nv.validate_resampler_func('std', args, kwargs) return self._do...
0.00578
def _parse_time_string(time_str): """ Get a datetime.time object from a string time representation. The start and end of acquisition are stored in the optional keyword parameters $BTIM and $ETIM. The following formats are used according to the FCS standard: - FCS 2.0...
0.001817
def add_scan_alarm(self, scan_id, host='', name='', value='', port='', test_id='', severity='', qod=''): """ Adds an alarm result to scan_id scan. """ self.scan_collection.add_result(scan_id, ResultType.ALARM, host, name, value, port, test_i...
0.008902
def _base_placeholder(self): """ Return the notes master placeholder this notes slide placeholder inherits from, or |None| if no placeholder of the matching type is present. """ notes_master = self.part.notes_master ph_type = self.element.ph_type return no...
0.005495
def speed_average(Temperature,element,isotope): r"""This function calculates the average speed (in meters per second) of an atom in a vapour assuming a Maxwell-Boltzmann velocity distribution. This is simply sqrt(8*k_B*T/m/pi) where k_B is Boltzmann's constant, T is the temperature (in Kelvins) an...
0.005085
def session_demo_danger_callback(da_children, session_state=None, **kwargs): 'Update output based just on state' if not session_state: return "Session state not yet available" return "Session state contains: " + str(session_state.get('bootstrap_demo_state', "NOTHING")) + " and the page render count...
0.005376
def parse_cctop_full(infile): """Parse a CCTOP XML results file and return a list of the consensus TM domains in the format:: [(1, inside_outside_or_tm), (2, inside_outside_or_tm), ...] Where the first value of a tuple is the sequence residue number, and the second is the...
0.002865
def batchnorm_to_fp32(module): ''' BatchNorm layers to have parameters in single precision. Find all layers and convert them back to float. This can't be done with built in .apply as that function will apply fn to all modules, parameters, and buffers. Thus we wouldn't be able to guard the float ...
0.001873
def _init_code(self, code: int) -> None: """ Initialize from an int terminal code. """ if -1 < code < 256: self.code = '{:02}'.format(code) self.hexval = term2hex(code) self.rgb = hex2rgb(self.hexval) else: raise ValueError(' '.join(( ...
0.004193
def tagged_projects( self, tag): """*return a list of projects contained within this taskpaper object filtered by a given tag* **Key Arguments:** - ``tag`` -- the tag to filter the projects by. **Return:** - ``projectList`` -- the list of filtere...
0.003897
def updateWCS(self, pixel_scale=None, orient=None,refpos=None,refval=None,size=None): """ Create a new CD Matrix from the absolute pixel scale and reference image orientation. """ # Set up parameters necessary for updating WCS # Check to see if new value is provided, ...
0.002414
def now_micros(absolute=False) -> int: """Return current micros since epoch as integer.""" micros = int(time.time() * 1e6) if absolute: return micros return micros - EPOCH_MICROS
0.026316
def getResourceFileList(self, pid): """ Get a listing of files within a resource. :param pid: The HydroShare ID of the resource whose resource files are to be listed. :raises: HydroShareArgumentException if any parameters are invalid. :raises: HydroShareNotAuthorized if user is not aut...
0.005768
def which(program, paths=None): """ takes a program name or full path, plus an optional collection of search paths, and returns the full path of the requested executable. if paths is specified, it is the entire list of search paths, and the PATH env is not used at all. otherwise, PATH env is used to l...
0.001368
def create_and_write_saml_metadata(proxy_conf, key, cert, dir, valid, split_frontend_metadata=False, split_backend_metadata=False): """ Generates SAML metadata for the given PROXY_CONF, signed with the given KEY and associated CERT. """ satosa_config = SATOSAConfig(pro...
0.00652
def _already_resized_on_fb(self,fn,pid,_megapixels): """Checks if image file (fn) with photo_id (pid) has already been resized on fb. If so, returns True""" logger.debug("%s - resize requested"%(fn)) # Get width/height from fb width_fb,height_fb=self._getphoto_originalsize(pid) ...
0.027251
def minimum(attrs, inputs, proto_obj): """Elementwise minimum of arrays.""" # MXNet minimum compares only two symbols at a time. # ONNX can send more than two to compare. # Breaking into multiple mxnet ops to compare two symbols at a time if len(inputs) > 1: mxnet_op = symbol.minimum(inputs[...
0.00189
def linsolve(self, A, b): """ Solve linear equation set ``Ax = b`` and store the solutions in ``b``. Parameters ---------- A Sparse matrix b RHS of the equation Returns ------- None """ if self.sparselib =...
0.004435
def add_file(dk_api, kitchen, recipe_name, message, api_file_key): """ returns a string. :param dk_api: -- api object :param kitchen: string :param recipe_name: string :param message: string -- commit message, string :param api_file_key: string -- directory wher...
0.003238
def get_tokens_unprocessed(self, text, stack=('root',)): """Reset the content-type state.""" self.content_type = None return RegexLexer.get_tokens_unprocessed(self, text, stack)
0.00995
def check_weight_method(weight_method_spec, use_orig_distr=False, allow_non_symmetric=False): "Check if weight_method is recognized and implemented, or ensure it is callable." if not isinstance(use_orig_distr, bool): raise TypeError('use_original_distribu...
0.0062
def accept_moderator_invite(self, subreddit): """Accept a moderator invite to the given subreddit. Callable upon an instance of Subreddit with no arguments. :returns: The json response from the server. """ data = {'r': six.text_type(subreddit)} # Clear moderated subred...
0.00381
def execute(self, *args, **kwargs): """ Initializes and runs the tool. This is shorhand to parse command line arguments, then calling: self.setup(parsed_arguments) self.process() """ args = self.parser.parse_args(*args, **kwargs) self.process(args...
0.006231
def _make_skel_func(code, cell_count, base_globals=None): """ Creates a skeleton function object that contains just the provided code and the correct number of cells in func_closure. All other func attributes (e.g. func_globals) are empty. """ if base_globals is None: base_globals =...
0.000689
def getDXGIOutputInfo(self): """ [D3D10/11 Only] Returns the adapter index and output index that the user should pass into EnumAdapters and EnumOutputs to create the device and swap chain in DX10 and DX11. If an error occurs both indices will be set to -1. """ fn = self....
0.008753
def get_event_public_discounts(self, id, **data): """ GET /events/:id/public_discounts/ Returns a :ref:`paginated <pagination>` response with a key of ``discounts``, containing a list of public :format:`discounts <discount>` available on this event. Note that public discounts and discoun...
0.008446
def make_zone_file(json_zone_file_input, origin=None, ttl=None, template=None): """ Generate the DNS zonefile, given a json-encoded description of the zone file (@json_zone_file) and the template to fill in (@template) json_zone_file = { "$origin": origin server, "$ttl": default time...
0.001686
def ReliefF_compute_scores(inst, attr, nan_entries, num_attributes, mcmap, NN, headers, class_type, X, y, labels_std, data_type): """ Unique scoring procedure for ReliefF algorithm. Scoring based on k nearest hits and misses of current target instance. """ scores = np.zeros(num_attributes) for feature_nu...
0.008977
def get(self, request, *args, **kwargs): """ Retrieve list of service requests """ if 'service_code' not in request.GET.keys(): return Response({ 'detail': _('A service code must be inserted') }, status=404) service_code = request.GET['service_code'] if service_code not in ...
0.01168
def columns(x, rho, proxop): """Applies a proximal operator to the columns of a matrix""" xnext = np.zeros_like(x) for ix in range(x.shape[1]): xnext[:, ix] = proxop(x[:, ix], rho) return xnext
0.004545
def graph_type(self, graph): """What type of graph is this?""" graph = self.pack(graph) return self.sql('graph_type', graph).fetchone()[0]
0.012346
def handle_cursor(cls, cursor, query, session): """Updates progress information""" from pyhive import hive # pylint: disable=no-name-in-module unfinished_states = ( hive.ttypes.TOperationState.INITIALIZED_STATE, hive.ttypes.TOperationState.RUNNING_STATE, ) ...
0.001296
def get_interface_detail_output_interface_ifHCOutBroadcastPkts(self, **kwargs): """Auto Generated Code """ config = ET.Element("config") get_interface_detail = ET.Element("get_interface_detail") config = get_interface_detail output = ET.SubElement(get_interface_detail, "o...
0.002237
def utf8(s): """ Coerce an object to bytes if it is Unicode. """ if isinstance(s, mitogen.core.UnicodeType): s = s.encode('utf-8') return s
0.005988
def LogAccessWrapper(func): """Decorator that ensures that HTTP access is logged.""" def Wrapper(request, *args, **kwargs): """Wrapping function.""" try: response = func(request, *args, **kwargs) server_logging.LOGGER.LogHttpAdminUIAccess(request, response) except Exception: # pylint: disa...
0.017016
def calcFontScaling(self): '''Calculates the current font size and left position for the current window.''' self.ypx = self.figure.get_size_inches()[1]*self.figure.dpi self.xpx = self.figure.get_size_inches()[0]*self.figure.dpi self.fontSize = self.vertSize*(self.ypx/2.0) self.le...
0.007519
def gen_anytext(*args): """ Convenience function to create bag of words for anytext property """ bag = [] for term in args: if term is not None: if isinstance(term, list): for term2 in term: if term2 is not None: bag.a...
0.002451
def update_remote_ids(self, remote_folder): """ Set remote id based on remote_folder and check children against this folder's children. :param remote_folder: RemoteFolder to compare against """ self.remote_id = remote_folder.id _update_remote_children(remote_folder, self....
0.009119
def assignrepr(self, prefix, style=None, utcoffset=None): """Return a |repr| string with an prefixed assignement. Without option arguments given, printing the returned string looks like: >>> from hydpy import Timegrid >>> timegrid = Timegrid('1996-11-01 00:00:00', ... ...
0.001645
async def forget(request, response): """Forget previously remembered identity. Usually it clears cookie or server-side storage to forget user session. """ identity_policy = request.config_dict.get(IDENTITY_KEY) if identity_policy is None: text = ("Security subsystem is not initialized, ...
0.001497
def __send_command(self, command, command_string=b'', response_size=8): """ send command to the terminal """ if command not in [const.CMD_CONNECT, const.CMD_AUTH] and not self.is_connect: raise ZKErrorConnection("instance are not connected.") buf = self.__create_head...
0.003123
def load_bulk(cls, bulk_data, parent=None, keep_ids=False): """Loads a list/dictionary structure to the tree.""" cls = get_result_class(cls) # tree, iterative preorder added = [] if parent: parent_id = parent.pk else: parent_id = None # s...
0.001472
def run_analysis(self, argv): """Run this analysis""" args = self._parser.parse_args(argv) obs = BinnedAnalysis.BinnedObs(irfs=args.irfs, expCube=args.expcube, srcMaps=args.cmap, ...
0.003752
def list_active_courses_in_account(self, account_id, by_subaccounts=None, by_teachers=None, completed=None, enrollment_term_id=None, enrollment_type=None, hide_enrollmentless_courses=None, include=None, published=None, search_term=None, state=None, with_enrollments=None): """ List active courses in an...
0.004349
def unregister_widget(self, widget_cls): """Unregisters the given widget.""" if widget_cls.__name__ in self.widgets: del self.widgets[widget_cls().get_name()]
0.010753
def load(source, triples=False, cls=PENMANCodec, **kwargs): """ Deserialize a list of PENMAN-encoded graphs from *source*. Args: source: a filename or file-like object to read from triples: if True, read graphs as triples instead of as PENMAN cls: serialization codec class k...
0.001585
def get_notification(self, id): """ :calls: `GET /notifications/threads/:id <http://developer.github.com/v3/activity/notifications>`_ :rtype: :class:`github.Notification.Notification` """ assert isinstance(id, (str, unicode)), id headers, data = self._requester.requestJs...
0.008016
def main(argv=None): """ :param argv: Argument list to parse or None (sys.argv will be set). """ args = _parse_args((argv if argv else sys.argv)[1:]) cnf = os.environ.copy() if args.env else {} extra_opts = dict() if args.extra_opts: extra_opts = anyconfig.parser.parse(args.extra_op...
0.001256
async def blob(self, elem=None, elem_type=None, params=None): """ Loads/dumps blob :return: """ elem_type = elem_type if elem_type else elem.__class__ if hasattr(elem_type, 'blob_serialize'): elem = elem_type() if elem is None else elem return awai...
0.008013
def who_has(self, subid): """Return a list of names who own subid in their id range set.""" answer = [] for name in self.__map: if subid in self.__map[name] and not name in answer: answer.append(name) return answer
0.01087
def deform2curve(script, curve=mp_func.torus_knot('t'), step=0.001): """ Deform a mesh along a parametric curve function Provide a parametric curve function with z as the parameter. This will deform the xy cross section of the mesh along the curve as z increases. Source: http://blackpawn.com/texts/pqt...
0.002655
def auth_required_same_user(*args, **kwargs): """ Decorator for requiring an authenticated user to be the same as the user in the URL parameters. By default the user url parameter name to lookup is ``id``, but this can be customized by passing an argument:: @auth_require_same_user('user_id') ...
0.000644
def surface_energy(self, ucell_entry, ref_entries=None): """ Calculates the surface energy of this SlabEntry. Args: ucell_entry (entry): An entry object for the bulk ref_entries (list: [entry]): A list of entries for each type of element to be used as a re...
0.00484
def _process_noop_timeperiod(self, job_record): """ method is valid for processes having time_grouping != 1. should a job record fall in-between grouped time milestones, its state should be set to STATE_NOOP without any processing """ job_record.state = job.STATE_NOOP sel...
0.008708
def check_model(self, max_paths=1, max_path_length=5): """Check all the statements added to the ModelChecker. Parameters ---------- max_paths : Optional[int] The maximum number of specific paths to return for each Statement to be explained. Default: 1 max...
0.002342
def policy_present(name, rules): ''' Ensure a Vault policy with the given name and rules is present. name The name of the policy rules Rules formatted as in-line HCL .. code-block:: yaml demo-policy: vault.policy_present: - name: foo/bar ...
0.001791