From 84be8fb50d259c9f26a7d721560a3700b6577101 Mon Sep 17 00:00:00 2001 From: Dave Armstrong Date: Thu, 30 Sep 2021 13:51:28 +0100 Subject: [PATCH] (GH-313) Update bolt to 3.18.0 --- lib/puppet-languageserver/static_data/bolt-boltlib.json | 2 +- lib/puppet-languageserver/static_data/bolt-log.json | 1 + lib/puppet-languageserver/static_data/bolt-out.json | 2 +- tools/bolt_introspect/README.md | 4 ++-- 4 files changed, 5 insertions(+), 4 deletions(-) create mode 100644 lib/puppet-languageserver/static_data/bolt-log.json diff --git a/lib/puppet-languageserver/static_data/bolt-boltlib.json b/lib/puppet-languageserver/static_data/bolt-boltlib.json index 0e8f9a51..861a3ea8 100644 --- a/lib/puppet-languageserver/static_data/bolt-boltlib.json +++ b/lib/puppet-languageserver/static_data/bolt-boltlib.json @@ -1 +1 @@ -{"datatypes":[{"key":"ResultSet","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"For each target that you execute an action on, Bolt returns a `Result` object\nand adds the `Result` to a `ResultSet` object. In the case of [apply\nactions](applying_manifest_blocks.md), Bolt returns a `ResultSet` with one or\nmore `ApplyResult` objects.","alias_of":null,"attributes":[{"key":"results","default_value":null,"doc":"All results in the set.","types":"Array[Variant[Result, ApplyResult]]"}],"is_type_alias":false},{"key":"ContainerResult","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"The [run_container](plan_functions.md#run_container) plan function returns a\n`ContainerResult` object. A `ContainerResult` is a standalone object (not part\nof a `ResultSet`) that includes either the `stdout` and `stderr` values from\nrunning the container, or an `_error` object if the container exited with a\nnonzero exit code.","alias_of":null,"attributes":[{"key":"value","default_value":null,"doc":"A hash including the `stdout`, `stderr`, and `exit_code` received from the\ncontainer.","types":"Hash[String[1], Data]"}],"is_type_alias":false},{"key":"Target","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"The `Target` object represents a target and its specific connection options.","alias_of":null,"attributes":[{"key":"config","default_value":null,"doc":"The inventory configuration for the target. This function returns the\nconfiguration set directly on the target in `inventory.yaml` or set in\na plan using `Target.new` or `set_config()`. It does not return default\nconfiguration values or configuration set in Bolt configuration files.","types":"Optional[Hash[String[1], Data]]"},{"key":"facts","default_value":null,"doc":"The target's facts. This function does not look up facts for a target and\nonly returns the facts specified in an `inventory.yaml` file or set on a\ntarget during a plan run. To retrieve facts for a target and set them in\ninventory, run the [facts](writing_plans.md#collect-facts-from-targets)\nplan or [puppetdb_fact](writing_plans.md#collect-facts-from-puppetdb)\nplan.","types":"Optional[Hash[String[1], Data]]"},{"key":"features","default_value":null,"doc":"The target's features.","types":"Optional[Array[String[1]]]"},{"key":"name","default_value":null,"doc":"The target's human-readable name, or its URI if a name was not given.","types":"Optional[String[1]]"},{"key":"plugin_hooks","default_value":null,"doc":"The target's `plugin_hooks` [configuration\noptions](bolt_inventory_reference.md#plugin-hooks-1).","types":"Optional[Hash[String[1], Data]]"},{"key":"resources","default_value":null,"doc":"The target's resources. This function does not look up resources for a\ntarget and only returns resources set on a target during a plan run.","types":"Optional[Hash[String[1], ResourceInstance]]"},{"key":"safe_name","default_value":null,"doc":"The target's safe name. Equivalent to `name` if a name was given, or the\ntarget's `uri` with any password omitted.","types":"Optional[String[1]]"},{"key":"target_alias","default_value":null,"doc":"The target's aliases.","types":"Optional[Variant[String[1], Array[String[1]]]]"},{"key":"uri","default_value":null,"doc":"The target's URI.","types":"Optional[String[1]]"},{"key":"vars","default_value":null,"doc":"The target's variables.","types":"Optional[Hash[String[1], Data]]"}],"is_type_alias":false},{"key":"ResourceInstance","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"`ResourceInstance` objects are used to store the observed and desired state of a\ntarget's resource and to track events for the resource. These objects do not\nmodify or interact with a target's resources.\n\n> The `ResourceInstance` data type is experimental and might change in a future\n> release. You can learn more about this data type and how to use it in the\n> [experimental features\n> documentation](experimental_features.md#resourceinstance-data-type).","alias_of":null,"attributes":[{"key":"events","default_value":null,"doc":"Events for the resource.","types":"Optional[Array[Hash[String[1], Data]]]"},{"key":"desired_state","default_value":null,"doc":"[Attributes](https://puppet.com/docs/puppet/latest/lang_resources.html#attributes) describing\nthe desired state of the resource.","types":"Optional[Hash[String[1], Data]]"},{"key":"state","default_value":null,"doc":"[Attributes](https://puppet.com/docs/puppet/latest/lang_resources.html#attributes) describing\nthe observed state of the resource.","types":"Optional[Hash[String[1], Data]]"},{"key":"target","default_value":null,"doc":"The resource's target.","types":"Target"},{"key":"title","default_value":null,"doc":"The [resource title](https://puppet.com/docs/puppet/latest/lang_resources.html#title).","types":"String[1]"},{"key":"type","default_value":null,"doc":"The [resource type](https://puppet.com/docs/puppet/latest/lang_resources.html#resource-types).","types":"Variant[String[1], Type[Resource]]"}],"is_type_alias":false},{"key":"Result","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"For each target that you execute an action on, Bolt returns a `Result` object\nand adds the `Result` to a `ResultSet` object. A `Result` object contains\ninformation about the action you executed on the target.","alias_of":null,"attributes":[{"key":"target","default_value":null,"doc":"The target the result is from.","types":"Target"},{"key":"value","default_value":null,"doc":"The output or return of executing on the target.","types":"Hash[String[1], Data]"}],"is_type_alias":false},{"key":"ApplyResult","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"An [apply action](applying_manifest_blocks.md#return-value-of-apply-action)\nreturns an `ApplyResult`. An `ApplyResult` is part of a `ResultSet` object and\ncontains information about the apply action.","alias_of":null,"attributes":[{"key":"report","default_value":null,"doc":"The Puppet report from the apply action. Equivalent to calling `ApplyResult.value['report']`.\nThe report is a hash representation of the [`Puppet::Transaction::Report`\nobject](https://puppet.com/docs/puppet/latest/format_report.html), where each property\ncorresponds to a key in the report hash. For more information, see [Result\nkeys](applying_manifest_blocks.md#result-keys).","types":"Hash[String[1], Data]"},{"key":"target","default_value":null,"doc":"The target the result is from.","types":"Target"}],"is_type_alias":false},{"key":"Boltlib::PlanResult","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"","alias_of":"Variant[Boolean, Numeric, String, Undef, Error, Result, ApplyResult, ResultSet, Target, ResourceInstance, ContainerResult, Array[Boltlib::PlanResult], Hash[String, Boltlib::PlanResult]]","attributes":[],"is_type_alias":true},{"key":"Boltlib::TargetSpec","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"A TargetSpec represents any String, Target or combination thereof that can be\npassed to get_targets() to return an Array[Target]. Generally, users\nshouldn't need to worry about the distinction between TargetSpec and\nTarget/Array[Target], since the run_* functions will all handle them both\nautomatically. But for use cases that need to deal with the exact list of\nTargets that will be used, get_targets() will return that.","alias_of":"Variant[String[1], Target, Array[Boltlib::TargetSpec]]","attributes":[],"is_type_alias":true}],"functions":[{"key":"resolve_references","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"Evaluates all `_plugin` references in a hash and returns the resolved reference data.","function_version":4,"signatures":[{"key":"resolve_references(Data $references)","doc":"Evaluates all `_plugin` references in a hash and returns the resolved reference data.","return_types":["Data"],"parameters":[{"name":"references","doc":"A hash of reference data to resolve.","types":["Data"],"signature_key_offset":24,"signature_key_length":11}]}]},{"key":"puppetdb_query","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"Makes a query to [puppetdb](https://puppet.com/docs/puppetdb/latest/index.html)\nusing Bolt's PuppetDB client.","function_version":4,"signatures":[{"key":"puppetdb_query(Variant[String, Array[Data]] $query)","doc":"Makes a query to [puppetdb](https://puppet.com/docs/puppetdb/latest/index.html)\nusing Bolt's PuppetDB client.","return_types":["Array[Data]"],"parameters":[{"name":"query","doc":"A PQL query.\nLearn more about [Puppet's query language](https://puppet.com/docs/puppetdb/latest/api/query/tutorial-pql.html), PQL.","types":["Variant[String, Array[Data]]"],"signature_key_offset":44,"signature_key_length":6}]}]},{"key":"upload_file","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"Uploads the given file or directory to the given set of targets and returns the result from each upload.\nThis function does nothing if the list of targets is empty.\n\n> **Note:** Not available in apply block","function_version":4,"signatures":[{"key":"upload_file(String[1] $source, String[1] $destination, Boltlib::TargetSpec $targets, Optional[Hash[String[1], Any]] $options)","doc":"Upload a file or directory.","return_types":["ResultSet"],"parameters":[{"name":"source","doc":"A source path, either an absolute path or a modulename/filename selector for a\nfile or directory in $MODULEROOT/files.","types":["String[1]"],"signature_key_offset":22,"signature_key_length":7},{"name":"destination","doc":"An absolute path on the target(s).","types":["String[1]"],"signature_key_offset":41,"signature_key_length":12},{"name":"targets","doc":"A pattern identifying zero or more targets. See {get_targets} for accepted patterns.","types":["Boltlib::TargetSpec"],"signature_key_offset":75,"signature_key_length":8},{"name":"options","doc":"A hash of additional options.","types":["Optional[Hash[String[1], Any]]"],"signature_key_offset":116,"signature_key_length":8}]},{"key":"upload_file(String[1] $source, String[1] $destination, Boltlib::TargetSpec $targets, String $description, Optional[Hash[String[1], Any]] $options)","doc":"Upload a file or directory, logging the provided description.","return_types":["ResultSet"],"parameters":[{"name":"source","doc":"A source path, either an absolute path or a modulename/filename selector for a\nfile or directory in $MODULEROOT/files.","types":["String[1]"],"signature_key_offset":22,"signature_key_length":7},{"name":"destination","doc":"An absolute path on the target(s).","types":["String[1]"],"signature_key_offset":41,"signature_key_length":12},{"name":"targets","doc":"A pattern identifying zero or more targets. See {get_targets} for accepted patterns.","types":["Boltlib::TargetSpec"],"signature_key_offset":75,"signature_key_length":8},{"name":"description","doc":"A description to be output when calling this function.","types":["String"],"signature_key_offset":92,"signature_key_length":12},{"name":"options","doc":"A hash of additional options.","types":["Optional[Hash[String[1], Any]]"],"signature_key_offset":137,"signature_key_length":8}]}]},{"key":"puppetdb_fact","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"Collects facts based on a list of certnames.\n\nIf a node is not found in PuppetDB, it's included in the returned hash with an empty facts hash.\nOtherwise, the node is included in the hash with a value that is a hash of its facts.","function_version":4,"signatures":[{"key":"puppetdb_fact(Array[String] $certnames)","doc":"Collects facts based on a list of certnames.\n\nIf a node is not found in PuppetDB, it's included in the returned hash with an empty facts hash.\nOtherwise, the node is included in the hash with a value that is a hash of its facts.","return_types":["Hash[String, Data]"],"parameters":[{"name":"certnames","doc":"Array of certnames.","types":["Array[String]"],"signature_key_offset":28,"signature_key_length":10}]}]},{"key":"get_targets","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"Parses common ways of referring to targets and returns an array of Targets.\n\n> **Note:** Not available in apply block","function_version":4,"signatures":[{"key":"get_targets(Boltlib::TargetSpec $names)","doc":"Parses common ways of referring to targets and returns an array of Targets.\n\n> **Note:** Not available in apply block","return_types":["Array[Target]"],"parameters":[{"name":"names","doc":"A pattern or array of patterns identifying a set of targets.","types":["Boltlib::TargetSpec"],"signature_key_offset":32,"signature_key_length":6}]}]},{"key":"run_task","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"Runs a given instance of a `Task` on the given set of targets and returns the result from each.\nThis function does nothing if the list of targets is empty.\n\n> **Note:** Not available in apply block","function_version":4,"signatures":[{"key":"run_task(String[1] $task_name, Boltlib::TargetSpec $targets, Optional[Hash[String[1], Any]] $args)","doc":"Run a task.","return_types":["ResultSet"],"parameters":[{"name":"task_name","doc":"The task to run.","types":["String[1]"],"signature_key_offset":19,"signature_key_length":10},{"name":"targets","doc":"A pattern identifying zero or more targets. See {get_targets} for accepted patterns.","types":["Boltlib::TargetSpec"],"signature_key_offset":51,"signature_key_length":8},{"name":"args","doc":"A hash of arguments to the task. Can also include additional options.","types":["Optional[Hash[String[1], Any]]"],"signature_key_offset":92,"signature_key_length":5}]},{"key":"run_task(String[1] $task_name, Boltlib::TargetSpec $targets, Optional[String] $description, Optional[Hash[String[1], Any]] $args)","doc":"Run a task, logging the provided description.","return_types":["ResultSet"],"parameters":[{"name":"task_name","doc":"The task to run.","types":["String[1]"],"signature_key_offset":19,"signature_key_length":10},{"name":"targets","doc":"A pattern identifying zero or more targets. See {get_targets} for accepted patterns.","types":["Boltlib::TargetSpec"],"signature_key_offset":51,"signature_key_length":8},{"name":"description","doc":"A description to be output when calling this function.","types":["Optional[String]"],"signature_key_offset":78,"signature_key_length":12},{"name":"args","doc":"A hash of arguments to the task. Can also include additional options.","types":["Optional[Hash[String[1], Any]]"],"signature_key_offset":123,"signature_key_length":5}]}]},{"key":"get_target","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"Get a single target from inventory if it exists, otherwise create a new Target.\n\n> **Note:** Calling `get_target('all')` returns an empty array.","function_version":4,"signatures":[{"key":"get_target(Boltlib::TargetSpec $name)","doc":"Get a single target from inventory if it exists, otherwise create a new Target.\n\n> **Note:** Calling `get_target('all')` returns an empty array.","return_types":["Target"],"parameters":[{"name":"name","doc":"A Target name.","types":["Boltlib::TargetSpec"],"signature_key_offset":31,"signature_key_length":5}]}]},{"key":"run_container","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"Run a container and return its output to stdout and stderr.\n\n> **Note:** Not available in apply block","function_version":4,"signatures":[{"key":"run_container(String[1] $image, Optional[Hash[String[1], Any]] $options)","doc":"Run a container and return its output to stdout and stderr.\n\n> **Note:** Not available in apply block","return_types":["ContainerResult"],"parameters":[{"name":"image","doc":"The name of the image to run.","types":["String[1]"],"signature_key_offset":24,"signature_key_length":6},{"name":"options","doc":"A hash of additional options.","types":["Optional[Hash[String[1], Any]]"],"signature_key_offset":63,"signature_key_length":8}]}]},{"key":"run_plan","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"Runs the `plan` referenced by its name. A plan is autoloaded from `$MODULEROOT/plans`.\n\n> **Note:** Not available in apply block","function_version":4,"signatures":[{"key":"run_plan(String $plan_name, Optional[Hash] $args)","doc":"Run a plan","return_types":["Boltlib::PlanResult"],"parameters":[{"name":"plan_name","doc":"The plan to run.","types":["String"],"signature_key_offset":16,"signature_key_length":10},{"name":"args","doc":"A hash of arguments to the plan. Can also include additional options.","types":["Optional[Hash]"],"signature_key_offset":43,"signature_key_length":5}]},{"key":"run_plan(String $plan_name, Boltlib::TargetSpec $targets, Optional[Hash] $args)","doc":"Run a plan, specifying `$nodes` or `$targets` as a positional argument.\n\n> **Note:** When running a plan with both a `$nodes` and `$targets` parameter, and using the second\npositional argument, the plan will fail.","return_types":["Boltlib::PlanResult"],"parameters":[{"name":"plan_name","doc":"The plan to run.","types":["String"],"signature_key_offset":16,"signature_key_length":10},{"name":"targets","doc":"A pattern identifying zero or more targets. See {get_targets} for accepted patterns.","types":["Boltlib::TargetSpec"],"signature_key_offset":48,"signature_key_length":8},{"name":"args","doc":"A hash of arguments to the plan. Can also include additional options.","types":["Optional[Hash]"],"signature_key_offset":73,"signature_key_length":5}]}]},{"key":"without_default_logging","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"Define a block where default logging is suppressed.\n\nMessages for actions within this block will be logged at `info` level instead\nof `notice`, so they will not be seen normally but will still be present\nwhen `verbose` logging is requested.\n\n> **Note:** Not available in apply block","function_version":4,"signatures":[{"key":"without_default_logging(Callable[0, 0] &$block)","doc":"Define a block where default logging is suppressed.\n\nMessages for actions within this block will be logged at `info` level instead\nof `notice`, so they will not be seen normally but will still be present\nwhen `verbose` logging is requested.\n\n> **Note:** Not available in apply block","return_types":["Undef"],"parameters":[{"name":"&block","doc":"The block where action logging is suppressed.","types":["Callable[0, 0]"],"signature_key_offset":39,"signature_key_length":7}]}]},{"key":"facts","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"Returns the facts hash for a target.\n\nUsing the `facts` function does not automatically collect facts for a target,\nand will only return facts that are currently set in the inventory. To collect\nfacts from a target and set them in the inventory, run the\n[facts](writing_plans.md#collect-facts-from-targets) plan or\n[puppetdb_fact](writing_plans.md#collect-facts-from-puppetdb) plan.","function_version":4,"signatures":[{"key":"facts(Target $target)","doc":"Returns the facts hash for a target.\n\nUsing the `facts` function does not automatically collect facts for a target,\nand will only return facts that are currently set in the inventory. To collect\nfacts from a target and set them in the inventory, run the\n[facts](writing_plans.md#collect-facts-from-targets) plan or\n[puppetdb_fact](writing_plans.md#collect-facts-from-puppetdb) plan.","return_types":["Hash[String, Data]"],"parameters":[{"name":"target","doc":"A target.","types":["Target"],"signature_key_offset":13,"signature_key_length":7}]}]},{"key":"run_task_with","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"Runs a given instance of a `Task` with target-specific parameters on the given set of targets and\nreturns the result from each. This function differs from {run_task} by accepting a block that returns\na `Hash` of target-specific parameters that are passed to the task. This can be used to send parameters\nbased on a target's attributes, such as its `facts`, or to use conditional logic to determine the\nparameters a task should receive for a specific target.\n\nThis function does nothing if the list of targets is empty.\n\n> **Note:** Not available in apply block\n\n> **Note:** Not available to targets using the pcp transport","function_version":4,"signatures":[{"key":"run_task_with(String[1] $task_name, Boltlib::TargetSpec $targets, Optional[Hash[String[1], Any]] $options, Callable[Target] &$block)","doc":"Run a task with target-specific parameters.","return_types":["ResultSet"],"parameters":[{"name":"task_name","doc":"The task to run.","types":["String[1]"],"signature_key_offset":24,"signature_key_length":10},{"name":"targets","doc":"A pattern identifying zero or more targets. See {get_targets} for accepted patterns.","types":["Boltlib::TargetSpec"],"signature_key_offset":56,"signature_key_length":8},{"name":"options","doc":"A hash of additional options.","types":["Optional[Hash[String[1], Any]]"],"signature_key_offset":97,"signature_key_length":8},{"name":"&block","doc":"A block that returns a `Hash` of target-specific parameters for the task.","types":["Callable[Target]"],"signature_key_offset":124,"signature_key_length":7}]},{"key":"run_task_with(String[1] $task_name, Boltlib::TargetSpec $targets, Optional[String] $description, Optional[Hash[String[1], Any]] $options, Callable[Target] &$block)","doc":"Run a task with target-specific parameters, logging the provided description.","return_types":["ResultSet"],"parameters":[{"name":"task_name","doc":"The task to run.","types":["String[1]"],"signature_key_offset":24,"signature_key_length":10},{"name":"targets","doc":"A pattern identifying zero or more targets. See {get_targets} for accepted patterns.","types":["Boltlib::TargetSpec"],"signature_key_offset":56,"signature_key_length":8},{"name":"description","doc":"A description to be output when calling this function.","types":["Optional[String]"],"signature_key_offset":83,"signature_key_length":12},{"name":"options","doc":"A hash of additional options.","types":["Optional[Hash[String[1], Any]]"],"signature_key_offset":128,"signature_key_length":8},{"name":"&block","doc":"A block that returns a `Hash` of target-specific parameters for the task.","types":["Callable[Target]"],"signature_key_offset":155,"signature_key_length":7}]}]},{"key":"download_file","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"Downloads the given file or directory from the given set of targets and saves it to a directory\nmatching the target's name under the given destination directory. Returns the result from each\ndownload. This does nothing if the list of targets is empty.\n\n> **Note:** Existing content in the destination directory is deleted before downloading from\n> the targets.\n\n> **Note:** Not available in apply block","function_version":4,"signatures":[{"key":"download_file(String[1] $source, String[1] $destination, Boltlib::TargetSpec $targets, Optional[Hash[String[1], Any]] $options)","doc":"Download a file or directory.","return_types":["ResultSet"],"parameters":[{"name":"source","doc":"The absolute path to the file or directory on the target(s).","types":["String[1]"],"signature_key_offset":24,"signature_key_length":7},{"name":"destination","doc":"The relative path to the destination directory on the local system. Expands\nrelative to `/downloads/`.","types":["String[1]"],"signature_key_offset":43,"signature_key_length":12},{"name":"targets","doc":"A pattern identifying zero or more targets. See {get_targets} for accepted patterns.","types":["Boltlib::TargetSpec"],"signature_key_offset":77,"signature_key_length":8},{"name":"options","doc":"A hash of additional options.","types":["Optional[Hash[String[1], Any]]"],"signature_key_offset":118,"signature_key_length":8}]},{"key":"download_file(String[1] $source, String[1] $destination, Boltlib::TargetSpec $targets, String $description, Optional[Hash[String[1], Any]] $options)","doc":"Download a file or directory, logging the provided description.","return_types":["ResultSet"],"parameters":[{"name":"source","doc":"The absolute path to the file or directory on the target(s).","types":["String[1]"],"signature_key_offset":24,"signature_key_length":7},{"name":"destination","doc":"The relative path to the destination directory on the local system. Expands\nrelative to `/downloads/`.","types":["String[1]"],"signature_key_offset":43,"signature_key_length":12},{"name":"targets","doc":"A pattern identifying zero or more targets. See {get_targets} for accepted patterns.","types":["Boltlib::TargetSpec"],"signature_key_offset":77,"signature_key_length":8},{"name":"description","doc":"A description to be output when calling this function.","types":["String"],"signature_key_offset":94,"signature_key_length":12},{"name":"options","doc":"A hash of additional options.","types":["Optional[Hash[String[1], Any]]"],"signature_key_offset":139,"signature_key_length":8}]}]},{"key":"wait_until_available","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"Wait until all targets accept connections. This function allows a plan execution to wait for a customizable\namount of time via the `wait_time` option until a target connection can be reestablished. The plan proceeds\nto the next step if the connection fails to reconnect in the time specified (default: 120 seconds). A typical\nuse case for this function is if your plan reboots a remote host and the plan needs to wait for the host to reconnect\nbefore it continues to the next step.\n\n> **Note:** Not available in apply block","function_version":4,"signatures":[{"key":"wait_until_available(Boltlib::TargetSpec $targets, Optional[Hash[String[1], Any]] $options)","doc":"Wait until all targets accept connections. This function allows a plan execution to wait for a customizable\namount of time via the `wait_time` option until a target connection can be reestablished. The plan proceeds\nto the next step if the connection fails to reconnect in the time specified (default: 120 seconds). A typical\nuse case for this function is if your plan reboots a remote host and the plan needs to wait for the host to reconnect\nbefore it continues to the next step.\n\n> **Note:** Not available in apply block","return_types":["ResultSet"],"parameters":[{"name":"targets","doc":"A pattern identifying zero or more targets. See {get_targets} for accepted patterns.","types":["Boltlib::TargetSpec"],"signature_key_offset":41,"signature_key_length":8},{"name":"options","doc":"A hash of additional options.","types":["Optional[Hash[String[1], Any]]"],"signature_key_offset":82,"signature_key_length":8}]}]},{"key":"resource","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"Lookup a resource in the target's data.\n\nFor more information about resources see [the\ndocumentation](https://puppet.com/docs/puppet/latest/lang_resources.html).\n\n> **Note:** The `ResourceInstance` data type is under active development and is subject to\n change. You can read more about the data type in the [experimental features\n documentation](experimental_features.md#resourceinstance-data-type).","function_version":4,"signatures":[{"key":"resource(Target $target, Type[Resource] $type, String[1] $title)","doc":"Lookup a resource in the target's data.","return_types":["Optional[ResourceInstance]"],"parameters":[{"name":"target","doc":"The Target object to add resources to. See {get_targets}.","types":["Target"],"signature_key_offset":16,"signature_key_length":7},{"name":"type","doc":"The type of the resource","types":["Type[Resource]"],"signature_key_offset":40,"signature_key_length":5},{"name":"title","doc":"The title of the resource","types":["String[1]"],"signature_key_offset":57,"signature_key_length":6}]},{"key":"resource(Target $target, String[1] $type, String[1] $title)","doc":"Lookup a resource in the target's data, referring to resource as a string","return_types":["Optional[ResourceInstance]"],"parameters":[{"name":"target","doc":"The Target object to add resources to. See {get_targets}.","types":["Target"],"signature_key_offset":16,"signature_key_length":7},{"name":"type","doc":"The type of the resource","types":["String[1]"],"signature_key_offset":35,"signature_key_length":5},{"name":"title","doc":"The title of the resource","types":["String[1]"],"signature_key_offset":52,"signature_key_length":6}]}]},{"key":"set_resources","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"Sets one or more ResourceInstances on a Target. This function does not apply or modify\nresources on a target.\n\nFor more information about resources see [the\ndocumentation](https://puppet.com/docs/puppet/latest/lang_resources.html).\n\n> **Note:** The `ResourceInstance` data type is under active development and is subject to\n change. You can read more about the data type in the [experimental features\n documentation](experimental_features.md#resourceinstance-data-type).\n\n> **Note:** Not available in apply block","function_version":4,"signatures":[{"key":"set_resources(Target $target, Hash $resource)","doc":"Set a single resource from a data hash.","return_types":["Array[ResourceInstance]"],"parameters":[{"name":"target","doc":"The `Target` object to add a resource to. See {get_targets}.","types":["Target"],"signature_key_offset":21,"signature_key_length":7},{"name":"resource","doc":"The resource data hash used to set a resource on the target.","types":["Hash"],"signature_key_offset":35,"signature_key_length":9}]},{"key":"set_resources(Target $target, ResourceInstance $resource)","doc":"Set a single resource from a `ResourceInstance` object","return_types":["Array[ResourceInstance]"],"parameters":[{"name":"target","doc":"The `Target` object to add a resource to. See {get_targets}.","types":["Target"],"signature_key_offset":21,"signature_key_length":7},{"name":"resource","doc":"The `ResourceInstance` object to set on the target.","types":["ResourceInstance"],"signature_key_offset":47,"signature_key_length":9}]},{"key":"set_resources(Target $target, Array[Variant[Hash, ResourceInstance]] $resources)","doc":"Set multiple resources from an array of data hashes and `ResourceInstance` objects.","return_types":["Array[ResourceInstance]"],"parameters":[{"name":"target","doc":"The `Target` object to add resources to. See {get_targets}.","types":["Target"],"signature_key_offset":21,"signature_key_length":7},{"name":"resources","doc":"The resource data hashes and `ResourceInstance` objects to set on the target.","types":["Array[Variant[Hash, ResourceInstance]]"],"signature_key_offset":69,"signature_key_length":10}]}]},{"key":"catch_errors","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"Catches errors in a given block and returns them. This will return the\noutput of the block if no errors are raised. Accepts an optional list of\nerror kinds to catch.\n\n> **Note:** Not available in apply block","function_version":4,"signatures":[{"key":"catch_errors(Optional[Array[String[1]]] $error_types, Callable[0, 0] &$block)","doc":"Catches errors in a given block and returns them. This will return the\noutput of the block if no errors are raised. Accepts an optional list of\nerror kinds to catch.\n\n> **Note:** Not available in apply block","return_types":["Any"],"parameters":[{"name":"error_types","doc":"An array of error types to catch","types":["Optional[Array[String[1]]]"],"signature_key_offset":40,"signature_key_length":12},{"name":"&block","doc":"The block of steps to catch errors on","types":["Callable[0, 0]"],"signature_key_offset":69,"signature_key_length":7}]}]},{"key":"write_file","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"Write contents to a file on the given set of targets.\n\n> **Note:** Not available in apply block","function_version":4,"signatures":[{"key":"write_file(String $content, String[1] $destination, Boltlib::TargetSpec $targets, Optional[Hash[String[1], Any]] $options)","doc":"Write contents to a file on the given set of targets.\n\n> **Note:** Not available in apply block","return_types":["ResultSet"],"parameters":[{"name":"content","doc":"File content to write.","types":["String"],"signature_key_offset":18,"signature_key_length":8},{"name":"destination","doc":"An absolute path on the target(s).","types":["String[1]"],"signature_key_offset":38,"signature_key_length":12},{"name":"targets","doc":"A pattern identifying zero or more targets. See {get_targets} for accepted patterns.","types":["Boltlib::TargetSpec"],"signature_key_offset":72,"signature_key_length":8},{"name":"options","doc":"A hash of additional options.","types":["Optional[Hash[String[1], Any]]"],"signature_key_offset":113,"signature_key_length":8}]}]},{"key":"set_var","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"Sets a variable `{ key => value }` for a target.\n\n> **Note:** Not available in apply block","function_version":4,"signatures":[{"key":"set_var(Target $target, String $key, Data $value)","doc":"Sets a variable `{ key => value }` for a target.\n\n> **Note:** Not available in apply block","return_types":["Target"],"parameters":[{"name":"target","doc":"The Target object to set the variable for. See {get_targets}.","types":["Target"],"signature_key_offset":15,"signature_key_length":7},{"name":"key","doc":"The key for the variable.","types":["String"],"signature_key_offset":31,"signature_key_length":4},{"name":"value","doc":"The value of the variable.","types":["Data"],"signature_key_offset":42,"signature_key_length":6}]}]},{"key":"vars","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"Returns a hash of the 'vars' (variables) assigned to a target.\n\nVars can be assigned through the inventory file or `set_var` function.\nPlan authors can call this function on a target to get the variable hash\nfor that target.","function_version":4,"signatures":[{"key":"vars(Target $target)","doc":"Returns a hash of the 'vars' (variables) assigned to a target.\n\nVars can be assigned through the inventory file or `set_var` function.\nPlan authors can call this function on a target to get the variable hash\nfor that target.","return_types":["Hash[String, Data]"],"parameters":[{"name":"target","doc":"The Target object to get variables from. See {get_targets}.","types":["Target"],"signature_key_offset":12,"signature_key_length":7}]}]},{"key":"set_config","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"Set configuration options on a target.\n\n> **Note:** Not available in apply block\n\n> **Note:** Only compatible with inventory v2","function_version":4,"signatures":[{"key":"set_config(Target $target, Variant[String, Array[String]] $key_or_key_path, Any $value)","doc":"Set configuration options on a target.\n\n> **Note:** Not available in apply block\n\n> **Note:** Only compatible with inventory v2","return_types":["Target"],"parameters":[{"name":"target","doc":"The Target object to configure. See {get_targets}.","types":["Target"],"signature_key_offset":18,"signature_key_length":7},{"name":"key_or_key_path","doc":"The configuration setting to update.","types":["Variant[String, Array[String]]"],"signature_key_offset":58,"signature_key_length":16},{"name":"value","doc":"The configuration value","types":["Any"],"signature_key_offset":80,"signature_key_length":6}]}]},{"key":"add_to_group","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"Adds a target to specified inventory group.\n\n> **Note:** Not available in apply block","function_version":4,"signatures":[{"key":"add_to_group(Boltlib::TargetSpec $targets, String[1] $group)","doc":"Adds a target to specified inventory group.\n\n> **Note:** Not available in apply block","return_types":["Array[Target]"],"parameters":[{"name":"targets","doc":"A pattern or array of patterns identifying a set of targets.","types":["Boltlib::TargetSpec"],"signature_key_offset":33,"signature_key_length":8},{"name":"group","doc":"The name of the group to add targets to.","types":["String[1]"],"signature_key_offset":53,"signature_key_length":6}]}]},{"key":"run_command","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"Runs a command on the given set of targets and returns the result from each command execution.\nThis function does nothing if the list of targets is empty.\n\n> **Note:** Not available in apply block","function_version":4,"signatures":[{"key":"run_command(String[1] $command, Boltlib::TargetSpec $targets, Optional[Hash[String[1], Any]] $options)","doc":"Run a command.","return_types":["ResultSet"],"parameters":[{"name":"command","doc":"A command to run on target.","types":["String[1]"],"signature_key_offset":22,"signature_key_length":8},{"name":"targets","doc":"A pattern identifying zero or more targets. See {get_targets} for accepted patterns.","types":["Boltlib::TargetSpec"],"signature_key_offset":52,"signature_key_length":8},{"name":"options","doc":"A hash of additional options.","types":["Optional[Hash[String[1], Any]]"],"signature_key_offset":93,"signature_key_length":8}]},{"key":"run_command(String[1] $command, Boltlib::TargetSpec $targets, String $description, Optional[Hash[String[1], Any]] $options)","doc":"Run a command, logging the provided description.","return_types":["ResultSet"],"parameters":[{"name":"command","doc":"A command to run on target.","types":["String[1]"],"signature_key_offset":22,"signature_key_length":8},{"name":"targets","doc":"A pattern identifying zero or more targets. See {get_targets} for accepted patterns.","types":["Boltlib::TargetSpec"],"signature_key_offset":52,"signature_key_length":8},{"name":"description","doc":"A description to be output when calling this function.","types":["String"],"signature_key_offset":69,"signature_key_length":12},{"name":"options","doc":"A hash of additional options.","types":["Optional[Hash[String[1], Any]]"],"signature_key_offset":114,"signature_key_length":8}]}]},{"key":"add_facts","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"Deep merges a hash of facts with the existing facts on a target.\n\n> **Note:** Not available in apply block","function_version":4,"signatures":[{"key":"add_facts(Target $target, Hash $facts)","doc":"Deep merges a hash of facts with the existing facts on a target.\n\n> **Note:** Not available in apply block","return_types":["Target"],"parameters":[{"name":"target","doc":"A target.","types":["Target"],"signature_key_offset":17,"signature_key_length":7},{"name":"facts","doc":"A hash of fact names to values that can include structured facts.","types":["Hash"],"signature_key_offset":31,"signature_key_length":6}]}]},{"key":"puppetdb_command","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"Send a command with a payload to PuppetDB.\n\nThe `pdb_command` function only supports version 5 of the `replace_facts`\ncommand. Other commands might also work, but are not tested or supported\nby Bolt.\n\nSee the [commands endpoint](https://puppet.com/docs/puppetdb/latest/api/command/v1/commands.html)\ndocumentation for more information about available commands and payload\nformat.\n\n_This function is experimental and subject to change._\n\n> **Note:** Not available in apply block","function_version":4,"signatures":[{"key":"puppetdb_command(String[1] $command, Integer $version, Hash[Data, Data] $payload)","doc":"Send a command with a payload to PuppetDB.\n\nThe `pdb_command` function only supports version 5 of the `replace_facts`\ncommand. Other commands might also work, but are not tested or supported\nby Bolt.\n\nSee the [commands endpoint](https://puppet.com/docs/puppetdb/latest/api/command/v1/commands.html)\ndocumentation for more information about available commands and payload\nformat.\n\n_This function is experimental and subject to change._\n\n> **Note:** Not available in apply block","return_types":["String"],"parameters":[{"name":"command","doc":"The command to invoke.","types":["String[1]"],"signature_key_offset":27,"signature_key_length":8},{"name":"version","doc":"The version of the command to invoke.","types":["Integer"],"signature_key_offset":45,"signature_key_length":8},{"name":"payload","doc":"The payload to the command.","types":["Hash[Data, Data]"],"signature_key_offset":72,"signature_key_length":8}]}]},{"key":"set_feature","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"Sets a particular feature to present on a target.\n\nFeatures are used to determine what implementation of a task should be run.\nSupported features are:\n- `powershell`\n- `shell`\n- `puppet-agent`\n\n> **Note:** Not available in apply block","function_version":4,"signatures":[{"key":"set_feature(Target $target, String $feature, Optional[Boolean] $value)","doc":"Sets a particular feature to present on a target.\n\nFeatures are used to determine what implementation of a task should be run.\nSupported features are:\n- `powershell`\n- `shell`\n- `puppet-agent`\n\n> **Note:** Not available in apply block","return_types":["Target"],"parameters":[{"name":"target","doc":"The Target object to add features to. See {get_targets}.","types":["Target"],"signature_key_offset":19,"signature_key_length":7},{"name":"feature","doc":"The string identifying the feature.","types":["String"],"signature_key_offset":35,"signature_key_length":8},{"name":"value","doc":"Whether the feature is supported.","types":["Optional[Boolean]"],"signature_key_offset":63,"signature_key_length":6}]}]},{"key":"get_resources","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"Query the state of resources on a list of targets using resource definitions in Bolt's module path.\nThe results are returned as a list of hashes representing each resource.\n\nRequires the Puppet Agent be installed on the target, which can be accomplished with apply_prep\nor by directly running the `puppet_agent::install` task. In order to be able to reference types without\nstring quoting (for example `get_resources($target, Package)` instead of `get_resources($target, 'Package')`),\nrun the command `bolt puppetfile generate-types` to generate type references in `$Boldir/.resource_types`.\n\n> **Note:** Not available in apply block","function_version":4,"signatures":[{"key":"get_resources(Boltlib::TargetSpec $targets, Variant[String, Type[Resource], Array[Variant[String, Type[Resource]]]] $resources)","doc":"Query the state of resources on a list of targets using resource definitions in Bolt's module path.\nThe results are returned as a list of hashes representing each resource.\n\nRequires the Puppet Agent be installed on the target, which can be accomplished with apply_prep\nor by directly running the `puppet_agent::install` task. In order to be able to reference types without\nstring quoting (for example `get_resources($target, Package)` instead of `get_resources($target, 'Package')`),\nrun the command `bolt puppetfile generate-types` to generate type references in `$Boldir/.resource_types`.\n\n> **Note:** Not available in apply block","return_types":["ResultSet"],"parameters":[{"name":"targets","doc":"A pattern or array of patterns identifying a set of targets.","types":["Boltlib::TargetSpec"],"signature_key_offset":34,"signature_key_length":8},{"name":"resources","doc":"A resource type or instance, or an array of such.","types":["Variant[String, Type[Resource], Array[Variant[String, Type[Resource]]]]"],"signature_key_offset":116,"signature_key_length":10}]}]},{"key":"parallelize","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"Map a code block onto an array, where each array element executes in parallel.\nThis function is experimental.\n\n> **Note:** Not available in apply block.","function_version":4,"signatures":[{"key":"parallelize(Array[Any] $data, Callable[Any] &$block)","doc":"Map a code block onto an array, where each array element executes in parallel.\nThis function is experimental.\n\n> **Note:** Not available in apply block.","return_types":["Array[Boltlib::PlanResult]"],"parameters":[{"name":"data","doc":"The array to apply the block to.","types":["Array[Any]"],"signature_key_offset":23,"signature_key_length":5},{"name":"&block","doc":"The code block to execute for each array element.","types":["Callable[Any]"],"signature_key_offset":44,"signature_key_length":7}]}]},{"key":"remove_from_group","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"Removes a target from the specified inventory group.\n\nThe target is removed from all child groups and all parent groups where the target has\nnot been explicitly defined. A target cannot be removed from the `all` group.\n\n> **Note:** Not available in apply block","function_version":4,"signatures":[{"key":"remove_from_group(Boltlib::TargetSpec $target, String[1] $group)","doc":"Removes a target from the specified inventory group.\n\nThe target is removed from all child groups and all parent groups where the target has\nnot been explicitly defined. A target cannot be removed from the `all` group.\n\n> **Note:** Not available in apply block","return_types":["nil"],"parameters":[{"name":"target","doc":"A pattern identifying a single target.","types":["Boltlib::TargetSpec"],"signature_key_offset":38,"signature_key_length":7},{"name":"group","doc":"The name of the group to remove the target from.","types":["String[1]"],"signature_key_offset":57,"signature_key_length":6}]}]},{"key":"fail_plan","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"Raises a `Bolt::PlanFailure` exception to signal to callers that the plan failed.\n\nPlan authors should call this function when their plan is not successful. The\nerror may then be caught by another plans `run_plan` function or in Bolt itself\n\n> **Note:** Not available in apply block","function_version":4,"signatures":[{"key":"fail_plan(String[1] $msg, Optional[String[1]] $kind, Optional[Hash[String[1], Any]] $details, Optional[String[1]] $issue_code)","doc":"Fail a plan, generating an exception from the parameters.","return_types":["Any"],"parameters":[{"name":"msg","doc":"An error message.","types":["String[1]"],"signature_key_offset":20,"signature_key_length":4},{"name":"kind","doc":"An easily matchable error kind.","types":["Optional[String[1]]"],"signature_key_offset":46,"signature_key_length":5},{"name":"details","doc":"Machine-parseable details about the error.","types":["Optional[Hash[String[1], Any]]"],"signature_key_offset":84,"signature_key_length":8},{"name":"issue_code","doc":"Unused.","types":["Optional[String[1]]"],"signature_key_offset":114,"signature_key_length":11}]},{"key":"fail_plan(Error $error)","doc":"Fail a plan, generating an exception from an existing Error object.","return_types":["Any"],"parameters":[{"name":"error","doc":"An error object.","types":["Error"],"signature_key_offset":16,"signature_key_length":6}]}]},{"key":"run_script","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"Uploads the given script to the given set of targets and returns the result of having each target execute the script.\nThis function does nothing if the list of targets is empty.\n\n> **Note:** Not available in apply block","function_version":4,"signatures":[{"key":"run_script(String[1] $script, Boltlib::TargetSpec $targets, Optional[Hash[String[1], Any]] $options)","doc":"Run a script.","return_types":["ResultSet"],"parameters":[{"name":"script","doc":"Path to a script to run on target. Can be an absolute path or a modulename/filename selector for a\nfile in $MODULEROOT/files.","types":["String[1]"],"signature_key_offset":21,"signature_key_length":7},{"name":"targets","doc":"A pattern identifying zero or more targets. See {get_targets} for accepted patterns.","types":["Boltlib::TargetSpec"],"signature_key_offset":50,"signature_key_length":8},{"name":"options","doc":"A hash of additional options.","types":["Optional[Hash[String[1], Any]]"],"signature_key_offset":91,"signature_key_length":8}]},{"key":"run_script(String[1] $script, Boltlib::TargetSpec $targets, String $description, Optional[Hash[String[1], Any]] $options)","doc":"Run a script, logging the provided description.","return_types":["ResultSet"],"parameters":[{"name":"script","doc":"Path to a script to run on target. Can be an absolute path or a modulename/filename selector for a\nfile in $MODULEROOT/files.","types":["String[1]"],"signature_key_offset":21,"signature_key_length":7},{"name":"targets","doc":"A pattern identifying zero or more targets. See {get_targets} for accepted patterns.","types":["Boltlib::TargetSpec"],"signature_key_offset":50,"signature_key_length":8},{"name":"description","doc":"A description to be output when calling this function.","types":["String"],"signature_key_offset":67,"signature_key_length":12},{"name":"options","doc":"A hash of additional options.","types":["Optional[Hash[String[1], Any]]"],"signature_key_offset":112,"signature_key_length":8}]}]},{"key":"apply_prep","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"Installs the `puppet-agent` package on targets if needed, then collects facts,\nincluding any custom facts found in Bolt's module path. The package is\ninstalled using either the configured plugin or the `task` plugin with the\n`puppet_agent::install` task.\n\nAgent installation will be skipped if the target includes the `puppet-agent` feature, either as a\nproperty of its transport (PCP) or by explicitly setting it as a feature in Bolt's inventory.\n\n> **Note:** Not available in apply block","function_version":4,"signatures":[{"key":"apply_prep(Boltlib::TargetSpec $targets, Optional[Hash[String, Data]] $options)","doc":"Installs the `puppet-agent` package on targets if needed, then collects facts,\nincluding any custom facts found in Bolt's module path. The package is\ninstalled using either the configured plugin or the `task` plugin with the\n`puppet_agent::install` task.\n\nAgent installation will be skipped if the target includes the `puppet-agent` feature, either as a\nproperty of its transport (PCP) or by explicitly setting it as a feature in Bolt's inventory.\n\n> **Note:** Not available in apply block","return_types":["nil"],"parameters":[{"name":"targets","doc":"A pattern or array of patterns identifying a set of targets.","types":["Boltlib::TargetSpec"],"signature_key_offset":31,"signature_key_length":8},{"name":"options","doc":"Options hash.","types":["Optional[Hash[String, Data]]"],"signature_key_offset":70,"signature_key_length":8}]}]}]} \ No newline at end of file +{"datatypes":[{"key":"ResultSet","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"For each target that you execute an action on, Bolt returns a `Result` object\nand adds the `Result` to a `ResultSet` object. In the case of [apply\nactions](applying_manifest_blocks.md), Bolt returns a `ResultSet` with one or\nmore `ApplyResult` objects.","alias_of":null,"attributes":[{"key":"results","default_value":null,"doc":"All results in the set.","types":"Array[Variant[Result, ApplyResult]]"}],"is_type_alias":false},{"key":"Future","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"The [`background()` plan function](plan_functions.md#background) returns a\n`Future` object, which can be passed to the [`wait()` plan\nfunction](plan_functions.md#wait) to block on the result of the backgrounded\ncode block.","alias_of":null,"attributes":[],"is_type_alias":false},{"key":"ContainerResult","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"The [run_container](plan_functions.md#run_container) plan function returns a\n`ContainerResult` object. A `ContainerResult` is a standalone object (not part\nof a `ResultSet`) that includes either the `stdout` and `stderr` values from\nrunning the container, or an `_error` object if the container exited with a\nnonzero exit code.","alias_of":null,"attributes":[{"key":"value","default_value":null,"doc":"A hash including the `stdout`, `stderr`, and `exit_code` received from the\ncontainer.","types":"Hash[String[1], Data]"}],"is_type_alias":false},{"key":"Target","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"The `Target` object represents a target and its specific connection options.","alias_of":null,"attributes":[{"key":"config","default_value":null,"doc":"The inventory configuration for the target. This function returns the\nconfiguration set directly on the target in `inventory.yaml` or set in\na plan using `Target.new` or `set_config()`. It does not return default\nconfiguration values or configuration set in Bolt configuration files.","types":"Optional[Hash[String[1], Data]]"},{"key":"facts","default_value":null,"doc":"The target's facts. This function does not look up facts for a target and\nonly returns the facts specified in an `inventory.yaml` file or set on a\ntarget during a plan run. To retrieve facts for a target and set them in\ninventory, run the [facts](writing_plans.md#collect-facts-from-targets)\nplan or [puppetdb_fact](writing_plans.md#collect-facts-from-puppetdb)\nplan.","types":"Optional[Hash[String[1], Data]]"},{"key":"features","default_value":null,"doc":"The target's features.","types":"Optional[Array[String[1]]]"},{"key":"name","default_value":null,"doc":"The target's human-readable name, or its URI if a name was not given.","types":"Optional[String[1]]"},{"key":"plugin_hooks","default_value":null,"doc":"The target's `plugin_hooks` [configuration\noptions](bolt_inventory_reference.md#plugin-hooks-1).","types":"Optional[Hash[String[1], Data]]"},{"key":"resources","default_value":null,"doc":"The target's resources. This function does not look up resources for a\ntarget and only returns resources set on a target during a plan run.","types":"Optional[Hash[String[1], ResourceInstance]]"},{"key":"safe_name","default_value":null,"doc":"The target's safe name. Equivalent to `name` if a name was given, or the\ntarget's `uri` with any password omitted.","types":"Optional[String[1]]"},{"key":"target_alias","default_value":null,"doc":"The target's aliases.","types":"Optional[Variant[String[1], Array[String[1]]]]"},{"key":"uri","default_value":null,"doc":"The target's URI.","types":"Optional[String[1]]"},{"key":"vars","default_value":null,"doc":"The target's variables.","types":"Optional[Hash[String[1], Data]]"}],"is_type_alias":false},{"key":"ResourceInstance","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"`ResourceInstance` objects are used to store the observed and desired state of a\ntarget's resource and to track events for the resource. These objects do not\nmodify or interact with a target's resources.\n\n> The `ResourceInstance` data type is experimental and might change in a future\n> release. You can learn more about this data type and how to use it in the\n> [experimental features\n> documentation](experimental_features.md#resourceinstance-data-type).","alias_of":null,"attributes":[{"key":"events","default_value":null,"doc":"Events for the resource.","types":"Optional[Array[Hash[String[1], Data]]]"},{"key":"desired_state","default_value":null,"doc":"[Attributes](https://puppet.com/docs/puppet/latest/lang_resources.html#attributes) describing\nthe desired state of the resource.","types":"Optional[Hash[String[1], Data]]"},{"key":"state","default_value":null,"doc":"[Attributes](https://puppet.com/docs/puppet/latest/lang_resources.html#attributes) describing\nthe observed state of the resource.","types":"Optional[Hash[String[1], Data]]"},{"key":"target","default_value":null,"doc":"The resource's target.","types":"Target"},{"key":"title","default_value":null,"doc":"The [resource title](https://puppet.com/docs/puppet/latest/lang_resources.html#title).","types":"String[1]"},{"key":"type","default_value":null,"doc":"The [resource type](https://puppet.com/docs/puppet/latest/lang_resources.html#resource-types).","types":"Variant[String[1], Type[Resource]]"}],"is_type_alias":false},{"key":"Result","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"For each target that you execute an action on, Bolt returns a `Result` object\nand adds the `Result` to a `ResultSet` object. A `Result` object contains\ninformation about the action you executed on the target.","alias_of":null,"attributes":[{"key":"target","default_value":null,"doc":"The target the result is from.","types":"Target"},{"key":"value","default_value":null,"doc":"The output or return of executing on the target.","types":"Hash[String[1], Data]"}],"is_type_alias":false},{"key":"ApplyResult","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"An [apply action](applying_manifest_blocks.md#return-value-of-apply-action)\nreturns an `ApplyResult`. An `ApplyResult` is part of a `ResultSet` object and\ncontains information about the apply action.","alias_of":null,"attributes":[{"key":"report","default_value":null,"doc":"The Puppet report from the apply action. Equivalent to calling `ApplyResult.value['report']`.\nThe report is a hash representation of the [`Puppet::Transaction::Report`\nobject](https://puppet.com/docs/puppet/latest/format_report.html), where each property\ncorresponds to a key in the report hash. For more information, see [Result\nkeys](applying_manifest_blocks.md#result-keys).","types":"Hash[String[1], Data]"},{"key":"target","default_value":null,"doc":"The target the result is from.","types":"Target"}],"is_type_alias":false},{"key":"Boltlib::PlanResult","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"","alias_of":"Variant[Boolean, Numeric, String, Undef, Error, Result, ApplyResult, ResultSet, Target, ResourceInstance, ContainerResult, Future, Array[Boltlib::PlanResult], Hash[String, Boltlib::PlanResult]]","attributes":[],"is_type_alias":true},{"key":"Boltlib::TargetSpec","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"A TargetSpec represents any String, Target or combination thereof that can be\npassed to get_targets() to return an Array[Target]. Generally, users\nshouldn't need to worry about the distinction between TargetSpec and\nTarget/Array[Target], since the run_* functions will all handle them both\nautomatically. But for use cases that need to deal with the exact list of\nTargets that will be used, get_targets() will return that.","alias_of":"Variant[String[1], Target, Array[Boltlib::TargetSpec]]","attributes":[],"is_type_alias":true}],"functions":[{"key":"resolve_references","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"Evaluates all `_plugin` references in a hash and returns the resolved reference data.","function_version":4,"signatures":[{"key":"resolve_references(Data $references)","doc":"Evaluates all `_plugin` references in a hash and returns the resolved reference data.","return_types":["Data"],"parameters":[{"name":"references","doc":"A hash of reference data to resolve.","types":["Data"],"signature_key_offset":24,"signature_key_length":11}]}]},{"key":"puppetdb_query","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"Makes a query to [puppetdb](https://puppet.com/docs/puppetdb/latest/index.html)\nusing Bolt's PuppetDB client.","function_version":4,"signatures":[{"key":"puppetdb_query(Variant[String, Array[Data]] $query)","doc":"Makes a query to [puppetdb](https://puppet.com/docs/puppetdb/latest/index.html)\nusing Bolt's PuppetDB client.","return_types":["Array[Data]"],"parameters":[{"name":"query","doc":"A PQL query.\nLearn more about [Puppet's query language](https://puppet.com/docs/puppetdb/latest/api/query/tutorial-pql.html), PQL.","types":["Variant[String, Array[Data]]"],"signature_key_offset":44,"signature_key_length":6}]}]},{"key":"upload_file","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"Uploads the given file or directory to the given set of targets and returns the result from each upload.\nThis function does nothing if the list of targets is empty.\n\n> **Note:** Not available in apply block","function_version":4,"signatures":[{"key":"upload_file(String[1] $source, String[1] $destination, Boltlib::TargetSpec $targets, Optional[Hash[String[1], Any]] $options)","doc":"Upload a file or directory.","return_types":["ResultSet"],"parameters":[{"name":"source","doc":"A source path, either an absolute path or a modulename/filename selector for a\nfile or directory in $MODULEROOT/files.","types":["String[1]"],"signature_key_offset":22,"signature_key_length":7},{"name":"destination","doc":"An absolute path on the target(s).","types":["String[1]"],"signature_key_offset":41,"signature_key_length":12},{"name":"targets","doc":"A pattern identifying zero or more targets. See {get_targets} for accepted patterns.","types":["Boltlib::TargetSpec"],"signature_key_offset":75,"signature_key_length":8},{"name":"options","doc":"A hash of additional options.","types":["Optional[Hash[String[1], Any]]"],"signature_key_offset":116,"signature_key_length":8}]},{"key":"upload_file(String[1] $source, String[1] $destination, Boltlib::TargetSpec $targets, String $description, Optional[Hash[String[1], Any]] $options)","doc":"Upload a file or directory, logging the provided description.","return_types":["ResultSet"],"parameters":[{"name":"source","doc":"A source path, either an absolute path or a modulename/filename selector for a\nfile or directory in $MODULEROOT/files.","types":["String[1]"],"signature_key_offset":22,"signature_key_length":7},{"name":"destination","doc":"An absolute path on the target(s).","types":["String[1]"],"signature_key_offset":41,"signature_key_length":12},{"name":"targets","doc":"A pattern identifying zero or more targets. See {get_targets} for accepted patterns.","types":["Boltlib::TargetSpec"],"signature_key_offset":75,"signature_key_length":8},{"name":"description","doc":"A description to be output when calling this function.","types":["String"],"signature_key_offset":92,"signature_key_length":12},{"name":"options","doc":"A hash of additional options.","types":["Optional[Hash[String[1], Any]]"],"signature_key_offset":137,"signature_key_length":8}]}]},{"key":"puppetdb_fact","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"Collects facts based on a list of certnames.\n\nIf a node is not found in PuppetDB, it's included in the returned hash with an empty facts hash.\nOtherwise, the node is included in the hash with a value that is a hash of its facts.","function_version":4,"signatures":[{"key":"puppetdb_fact(Array[String] $certnames)","doc":"Collects facts based on a list of certnames.\n\nIf a node is not found in PuppetDB, it's included in the returned hash with an empty facts hash.\nOtherwise, the node is included in the hash with a value that is a hash of its facts.","return_types":["Hash[String, Data]"],"parameters":[{"name":"certnames","doc":"Array of certnames.","types":["Array[String]"],"signature_key_offset":28,"signature_key_length":10}]}]},{"key":"get_targets","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"Parses common ways of referring to targets and returns an array of Targets.\n\n> **Note:** Not available in apply block","function_version":4,"signatures":[{"key":"get_targets(Boltlib::TargetSpec $names)","doc":"Parses common ways of referring to targets and returns an array of Targets.\n\n> **Note:** Not available in apply block","return_types":["Array[Target]"],"parameters":[{"name":"names","doc":"A pattern or array of patterns identifying a set of targets.","types":["Boltlib::TargetSpec"],"signature_key_offset":32,"signature_key_length":6}]}]},{"key":"run_task","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"Runs a given instance of a `Task` on the given set of targets and returns the result from each.\nThis function does nothing if the list of targets is empty.\n\n> **Note:** Not available in apply block","function_version":4,"signatures":[{"key":"run_task(String[1] $task_name, Boltlib::TargetSpec $targets, Optional[Hash[String[1], Any]] $args)","doc":"Run a task.","return_types":["ResultSet"],"parameters":[{"name":"task_name","doc":"The task to run.","types":["String[1]"],"signature_key_offset":19,"signature_key_length":10},{"name":"targets","doc":"A pattern identifying zero or more targets. See {get_targets} for accepted patterns.","types":["Boltlib::TargetSpec"],"signature_key_offset":51,"signature_key_length":8},{"name":"args","doc":"A hash of arguments to the task. Can also include additional options.","types":["Optional[Hash[String[1], Any]]"],"signature_key_offset":92,"signature_key_length":5}]},{"key":"run_task(String[1] $task_name, Boltlib::TargetSpec $targets, Optional[String] $description, Optional[Hash[String[1], Any]] $args)","doc":"Run a task, logging the provided description.","return_types":["ResultSet"],"parameters":[{"name":"task_name","doc":"The task to run.","types":["String[1]"],"signature_key_offset":19,"signature_key_length":10},{"name":"targets","doc":"A pattern identifying zero or more targets. See {get_targets} for accepted patterns.","types":["Boltlib::TargetSpec"],"signature_key_offset":51,"signature_key_length":8},{"name":"description","doc":"A description to be output when calling this function.","types":["Optional[String]"],"signature_key_offset":78,"signature_key_length":12},{"name":"args","doc":"A hash of arguments to the task. Can also include additional options.","types":["Optional[Hash[String[1], Any]]"],"signature_key_offset":123,"signature_key_length":5}]}]},{"key":"get_target","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"Get a single target from inventory if it exists, otherwise create a new Target.\n\n> **Note:** Calling `get_target('all')` returns an empty array.","function_version":4,"signatures":[{"key":"get_target(Boltlib::TargetSpec $name)","doc":"Get a single target from inventory if it exists, otherwise create a new Target.\n\n> **Note:** Calling `get_target('all')` returns an empty array.","return_types":["Target"],"parameters":[{"name":"name","doc":"A Target name.","types":["Boltlib::TargetSpec"],"signature_key_offset":31,"signature_key_length":5}]}]},{"key":"run_container","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"Run a container and return its output to stdout and stderr.\n\n> **Note:** Not available in apply block","function_version":4,"signatures":[{"key":"run_container(String[1] $image, Optional[Hash[String[1], Any]] $options)","doc":"Run a container and return its output to stdout and stderr.\n\n> **Note:** Not available in apply block","return_types":["ContainerResult"],"parameters":[{"name":"image","doc":"The name of the image to run.","types":["String[1]"],"signature_key_offset":24,"signature_key_length":6},{"name":"options","doc":"A hash of additional options.","types":["Optional[Hash[String[1], Any]]"],"signature_key_offset":63,"signature_key_length":8}]}]},{"key":"run_plan","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"Runs the `plan` referenced by its name. A plan is autoloaded from `$MODULEROOT/plans`.\n\n> **Note:** Not available in apply block","function_version":4,"signatures":[{"key":"run_plan(String $plan_name, Optional[Hash] $args)","doc":"Run a plan","return_types":["Boltlib::PlanResult"],"parameters":[{"name":"plan_name","doc":"The plan to run.","types":["String"],"signature_key_offset":16,"signature_key_length":10},{"name":"args","doc":"A hash of arguments to the plan. Can also include additional options.","types":["Optional[Hash]"],"signature_key_offset":43,"signature_key_length":5}]},{"key":"run_plan(String $plan_name, Boltlib::TargetSpec $targets, Optional[Hash] $args)","doc":"Run a plan, specifying `$nodes` or `$targets` as a positional argument.\n\n> **Note:** When running a plan with both a `$nodes` and `$targets` parameter, and using the second\npositional argument, the plan will fail.","return_types":["Boltlib::PlanResult"],"parameters":[{"name":"plan_name","doc":"The plan to run.","types":["String"],"signature_key_offset":16,"signature_key_length":10},{"name":"targets","doc":"A pattern identifying zero or more targets. See {get_targets} for accepted patterns.","types":["Boltlib::TargetSpec"],"signature_key_offset":48,"signature_key_length":8},{"name":"args","doc":"A hash of arguments to the plan. Can also include additional options.","types":["Optional[Hash]"],"signature_key_offset":73,"signature_key_length":5}]}]},{"key":"without_default_logging","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"Define a block where default logging is suppressed.\n\nMessages for actions within this block will be logged at `info` level instead\nof `notice`, so they will not be seen normally but will still be present\nwhen `verbose` logging is requested.\n\n> **Note:** Not available in apply block","function_version":4,"signatures":[{"key":"without_default_logging(Callable[0, 0] &$block)","doc":"Define a block where default logging is suppressed.\n\nMessages for actions within this block will be logged at `info` level instead\nof `notice`, so they will not be seen normally but will still be present\nwhen `verbose` logging is requested.\n\n> **Note:** Not available in apply block","return_types":["Undef"],"parameters":[{"name":"&block","doc":"The block where action logging is suppressed.","types":["Callable[0, 0]"],"signature_key_offset":39,"signature_key_length":7}]}]},{"key":"facts","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"Returns the facts hash for a target.\n\nUsing the `facts` function does not automatically collect facts for a target,\nand will only return facts that are currently set in the inventory. To collect\nfacts from a target and set them in the inventory, run the\n[facts](writing_plans.md#collect-facts-from-targets) plan or\n[puppetdb_fact](writing_plans.md#collect-facts-from-puppetdb) plan.","function_version":4,"signatures":[{"key":"facts(Target $target)","doc":"Returns the facts hash for a target.\n\nUsing the `facts` function does not automatically collect facts for a target,\nand will only return facts that are currently set in the inventory. To collect\nfacts from a target and set them in the inventory, run the\n[facts](writing_plans.md#collect-facts-from-targets) plan or\n[puppetdb_fact](writing_plans.md#collect-facts-from-puppetdb) plan.","return_types":["Hash[String, Data]"],"parameters":[{"name":"target","doc":"A target.","types":["Target"],"signature_key_offset":13,"signature_key_length":7}]}]},{"key":"run_task_with","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"Runs a given instance of a `Task` with target-specific parameters on the given set of targets and\nreturns the result from each. This function differs from {run_task} by accepting a block that returns\na `Hash` of target-specific parameters that are passed to the task. This can be used to send parameters\nbased on a target's attributes, such as its `facts`, or to use conditional logic to determine the\nparameters a task should receive for a specific target.\n\nThis function does nothing if the list of targets is empty.\n\n> **Note:** Not available in apply block\n\n> **Note:** Not available to targets using the pcp transport","function_version":4,"signatures":[{"key":"run_task_with(String[1] $task_name, Boltlib::TargetSpec $targets, Optional[Hash[String[1], Any]] $options, Callable[Target] &$block)","doc":"Run a task with target-specific parameters.","return_types":["ResultSet"],"parameters":[{"name":"task_name","doc":"The task to run.","types":["String[1]"],"signature_key_offset":24,"signature_key_length":10},{"name":"targets","doc":"A pattern identifying zero or more targets. See {get_targets} for accepted patterns.","types":["Boltlib::TargetSpec"],"signature_key_offset":56,"signature_key_length":8},{"name":"options","doc":"A hash of additional options.","types":["Optional[Hash[String[1], Any]]"],"signature_key_offset":97,"signature_key_length":8},{"name":"&block","doc":"A block that returns a `Hash` of target-specific parameters for the task.","types":["Callable[Target]"],"signature_key_offset":124,"signature_key_length":7}]},{"key":"run_task_with(String[1] $task_name, Boltlib::TargetSpec $targets, Optional[String] $description, Optional[Hash[String[1], Any]] $options, Callable[Target] &$block)","doc":"Run a task with target-specific parameters, logging the provided description.","return_types":["ResultSet"],"parameters":[{"name":"task_name","doc":"The task to run.","types":["String[1]"],"signature_key_offset":24,"signature_key_length":10},{"name":"targets","doc":"A pattern identifying zero or more targets. See {get_targets} for accepted patterns.","types":["Boltlib::TargetSpec"],"signature_key_offset":56,"signature_key_length":8},{"name":"description","doc":"A description to be output when calling this function.","types":["Optional[String]"],"signature_key_offset":83,"signature_key_length":12},{"name":"options","doc":"A hash of additional options.","types":["Optional[Hash[String[1], Any]]"],"signature_key_offset":128,"signature_key_length":8},{"name":"&block","doc":"A block that returns a `Hash` of target-specific parameters for the task.","types":["Callable[Target]"],"signature_key_offset":155,"signature_key_length":7}]}]},{"key":"download_file","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"Downloads the given file or directory from the given set of targets and saves it to a directory\nmatching the target's name under the given destination directory. Returns the result from each\ndownload. This does nothing if the list of targets is empty.\n\n> **Note:** Existing content in the destination directory is deleted before downloading from\n> the targets.\n\n> **Note:** Not available in apply block","function_version":4,"signatures":[{"key":"download_file(String[1] $source, String[1] $destination, Boltlib::TargetSpec $targets, Optional[Hash[String[1], Any]] $options)","doc":"Download a file or directory.","return_types":["ResultSet"],"parameters":[{"name":"source","doc":"The absolute path to the file or directory on the target(s).","types":["String[1]"],"signature_key_offset":24,"signature_key_length":7},{"name":"destination","doc":"The relative path to the destination directory on the local system. Expands\nrelative to `/downloads/`.","types":["String[1]"],"signature_key_offset":43,"signature_key_length":12},{"name":"targets","doc":"A pattern identifying zero or more targets. See {get_targets} for accepted patterns.","types":["Boltlib::TargetSpec"],"signature_key_offset":77,"signature_key_length":8},{"name":"options","doc":"A hash of additional options.","types":["Optional[Hash[String[1], Any]]"],"signature_key_offset":118,"signature_key_length":8}]},{"key":"download_file(String[1] $source, String[1] $destination, Boltlib::TargetSpec $targets, String $description, Optional[Hash[String[1], Any]] $options)","doc":"Download a file or directory, logging the provided description.","return_types":["ResultSet"],"parameters":[{"name":"source","doc":"The absolute path to the file or directory on the target(s).","types":["String[1]"],"signature_key_offset":24,"signature_key_length":7},{"name":"destination","doc":"The relative path to the destination directory on the local system. Expands\nrelative to `/downloads/`.","types":["String[1]"],"signature_key_offset":43,"signature_key_length":12},{"name":"targets","doc":"A pattern identifying zero or more targets. See {get_targets} for accepted patterns.","types":["Boltlib::TargetSpec"],"signature_key_offset":77,"signature_key_length":8},{"name":"description","doc":"A description to be output when calling this function.","types":["String"],"signature_key_offset":94,"signature_key_length":12},{"name":"options","doc":"A hash of additional options.","types":["Optional[Hash[String[1], Any]]"],"signature_key_offset":139,"signature_key_length":8}]}]},{"key":"wait_until_available","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"Wait until all targets accept connections. This function allows a plan execution to wait for a customizable\namount of time via the `wait_time` option until a target connection can be reestablished. The plan proceeds\nto the next step if the connection fails to reconnect in the time specified (default: 120 seconds). A typical\nuse case for this function is if your plan reboots a remote host and the plan needs to wait for the host to reconnect\nbefore it continues to the next step.\n\n> **Note:** Not available in apply block","function_version":4,"signatures":[{"key":"wait_until_available(Boltlib::TargetSpec $targets, Optional[Hash[String[1], Any]] $options)","doc":"Wait until all targets accept connections. This function allows a plan execution to wait for a customizable\namount of time via the `wait_time` option until a target connection can be reestablished. The plan proceeds\nto the next step if the connection fails to reconnect in the time specified (default: 120 seconds). A typical\nuse case for this function is if your plan reboots a remote host and the plan needs to wait for the host to reconnect\nbefore it continues to the next step.\n\n> **Note:** Not available in apply block","return_types":["ResultSet"],"parameters":[{"name":"targets","doc":"A pattern identifying zero or more targets. See {get_targets} for accepted patterns.","types":["Boltlib::TargetSpec"],"signature_key_offset":41,"signature_key_length":8},{"name":"options","doc":"A hash of additional options.","types":["Optional[Hash[String[1], Any]]"],"signature_key_offset":82,"signature_key_length":8}]}]},{"key":"resource","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"Lookup a resource in the target's data.\n\nFor more information about resources see [the\ndocumentation](https://puppet.com/docs/puppet/latest/lang_resources.html).\n\n> **Note:** The `ResourceInstance` data type is under active development and is subject to\n change. You can read more about the data type in the [experimental features\n documentation](experimental_features.md#resourceinstance-data-type).","function_version":4,"signatures":[{"key":"resource(Target $target, Type[Resource] $type, String[1] $title)","doc":"Lookup a resource in the target's data.","return_types":["Optional[ResourceInstance]"],"parameters":[{"name":"target","doc":"The Target object to add resources to. See {get_targets}.","types":["Target"],"signature_key_offset":16,"signature_key_length":7},{"name":"type","doc":"The type of the resource","types":["Type[Resource]"],"signature_key_offset":40,"signature_key_length":5},{"name":"title","doc":"The title of the resource","types":["String[1]"],"signature_key_offset":57,"signature_key_length":6}]},{"key":"resource(Target $target, String[1] $type, String[1] $title)","doc":"Lookup a resource in the target's data, referring to resource as a string","return_types":["Optional[ResourceInstance]"],"parameters":[{"name":"target","doc":"The Target object to add resources to. See {get_targets}.","types":["Target"],"signature_key_offset":16,"signature_key_length":7},{"name":"type","doc":"The type of the resource","types":["String[1]"],"signature_key_offset":35,"signature_key_length":5},{"name":"title","doc":"The title of the resource","types":["String[1]"],"signature_key_offset":52,"signature_key_length":6}]}]},{"key":"set_resources","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"Sets one or more ResourceInstances on a Target. This function does not apply or modify\nresources on a target.\n\nFor more information about resources see [the\ndocumentation](https://puppet.com/docs/puppet/latest/lang_resources.html).\n\n> **Note:** The `ResourceInstance` data type is under active development and is subject to\n change. You can read more about the data type in the [experimental features\n documentation](experimental_features.md#resourceinstance-data-type).\n\n> **Note:** Not available in apply block","function_version":4,"signatures":[{"key":"set_resources(Target $target, Hash $resource)","doc":"Set a single resource from a data hash.","return_types":["Array[ResourceInstance]"],"parameters":[{"name":"target","doc":"The `Target` object to add a resource to. See {get_targets}.","types":["Target"],"signature_key_offset":21,"signature_key_length":7},{"name":"resource","doc":"The resource data hash used to set a resource on the target.","types":["Hash"],"signature_key_offset":35,"signature_key_length":9}]},{"key":"set_resources(Target $target, ResourceInstance $resource)","doc":"Set a single resource from a `ResourceInstance` object","return_types":["Array[ResourceInstance]"],"parameters":[{"name":"target","doc":"The `Target` object to add a resource to. See {get_targets}.","types":["Target"],"signature_key_offset":21,"signature_key_length":7},{"name":"resource","doc":"The `ResourceInstance` object to set on the target.","types":["ResourceInstance"],"signature_key_offset":47,"signature_key_length":9}]},{"key":"set_resources(Target $target, Array[Variant[Hash, ResourceInstance]] $resources)","doc":"Set multiple resources from an array of data hashes and `ResourceInstance` objects.","return_types":["Array[ResourceInstance]"],"parameters":[{"name":"target","doc":"The `Target` object to add resources to. See {get_targets}.","types":["Target"],"signature_key_offset":21,"signature_key_length":7},{"name":"resources","doc":"The resource data hashes and `ResourceInstance` objects to set on the target.","types":["Array[Variant[Hash, ResourceInstance]]"],"signature_key_offset":69,"signature_key_length":10}]}]},{"key":"catch_errors","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"Catches errors in a given block and returns them. This will return the\noutput of the block if no errors are raised. Accepts an optional list of\nerror kinds to catch.\n\n> **Note:** Not available in apply block","function_version":4,"signatures":[{"key":"catch_errors(Optional[Array[String[1]]] $error_types, Callable[0, 0] &$block)","doc":"Catches errors in a given block and returns them. This will return the\noutput of the block if no errors are raised. Accepts an optional list of\nerror kinds to catch.\n\n> **Note:** Not available in apply block","return_types":["Any"],"parameters":[{"name":"error_types","doc":"An array of error types to catch","types":["Optional[Array[String[1]]]"],"signature_key_offset":40,"signature_key_length":12},{"name":"&block","doc":"The block of steps to catch errors on","types":["Callable[0, 0]"],"signature_key_offset":69,"signature_key_length":7}]}]},{"key":"write_file","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"Write contents to a file on the given set of targets.\n\n> **Note:** Not available in apply block","function_version":4,"signatures":[{"key":"write_file(String $content, String[1] $destination, Boltlib::TargetSpec $targets, Optional[Hash[String[1], Any]] $options)","doc":"Write contents to a file on the given set of targets.\n\n> **Note:** Not available in apply block","return_types":["ResultSet"],"parameters":[{"name":"content","doc":"File content to write.","types":["String"],"signature_key_offset":18,"signature_key_length":8},{"name":"destination","doc":"An absolute path on the target(s).","types":["String[1]"],"signature_key_offset":38,"signature_key_length":12},{"name":"targets","doc":"A pattern identifying zero or more targets. See {get_targets} for accepted patterns.","types":["Boltlib::TargetSpec"],"signature_key_offset":72,"signature_key_length":8},{"name":"options","doc":"A hash of additional options.","types":["Optional[Hash[String[1], Any]]"],"signature_key_offset":113,"signature_key_length":8}]}]},{"key":"set_var","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"Sets a variable `{ key => value }` for a target.\n\n> **Note:** Not available in apply block","function_version":4,"signatures":[{"key":"set_var(Target $target, String $key, Data $value)","doc":"Sets a variable `{ key => value }` for a target.\n\n> **Note:** Not available in apply block","return_types":["Target"],"parameters":[{"name":"target","doc":"The Target object to set the variable for. See {get_targets}.","types":["Target"],"signature_key_offset":15,"signature_key_length":7},{"name":"key","doc":"The key for the variable.","types":["String"],"signature_key_offset":31,"signature_key_length":4},{"name":"value","doc":"The value of the variable.","types":["Data"],"signature_key_offset":42,"signature_key_length":6}]}]},{"key":"background","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"Starts a block of code in parallel with the main plan without blocking.\nReturns a Future object.\n\n> **Note:** Not available in apply block","function_version":4,"signatures":[{"key":"background(Optional[String[1]] $name, Callable[0, 0] &$block)","doc":"Starts a block of code in parallel with the main plan without blocking.\nReturns a Future object.\n\n> **Note:** Not available in apply block","return_types":["Future"],"parameters":[{"name":"name","doc":"An optional name for legible logs.","types":["Optional[String[1]]"],"signature_key_offset":31,"signature_key_length":5},{"name":"&block","doc":"The code block to run in the background.","types":["Callable[0, 0]"],"signature_key_offset":53,"signature_key_length":7}]}]},{"key":"vars","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"Returns a hash of the 'vars' (variables) assigned to a target.\n\nVars can be assigned through the inventory file or `set_var` function.\nPlan authors can call this function on a target to get the variable hash\nfor that target.","function_version":4,"signatures":[{"key":"vars(Target $target)","doc":"Returns a hash of the 'vars' (variables) assigned to a target.\n\nVars can be assigned through the inventory file or `set_var` function.\nPlan authors can call this function on a target to get the variable hash\nfor that target.","return_types":["Hash[String, Data]"],"parameters":[{"name":"target","doc":"The Target object to get variables from. See {get_targets}.","types":["Target"],"signature_key_offset":12,"signature_key_length":7}]}]},{"key":"set_config","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"Set configuration options on a target.\n\n> **Note:** Not available in apply block\n\n> **Note:** Only compatible with inventory v2","function_version":4,"signatures":[{"key":"set_config(Target $target, Variant[String, Array[String]] $key_or_key_path, Any $value)","doc":"Set configuration options on a target.\n\n> **Note:** Not available in apply block\n\n> **Note:** Only compatible with inventory v2","return_types":["Target"],"parameters":[{"name":"target","doc":"The Target object to configure. See {get_targets}.","types":["Target"],"signature_key_offset":18,"signature_key_length":7},{"name":"key_or_key_path","doc":"The configuration setting to update.","types":["Variant[String, Array[String]]"],"signature_key_offset":58,"signature_key_length":16},{"name":"value","doc":"The configuration value","types":["Any"],"signature_key_offset":80,"signature_key_length":6}]}]},{"key":"add_to_group","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"Adds a target to specified inventory group.\n\n> **Note:** Not available in apply block","function_version":4,"signatures":[{"key":"add_to_group(Boltlib::TargetSpec $targets, String[1] $group)","doc":"Adds a target to specified inventory group.\n\n> **Note:** Not available in apply block","return_types":["Array[Target]"],"parameters":[{"name":"targets","doc":"A pattern or array of patterns identifying a set of targets.","types":["Boltlib::TargetSpec"],"signature_key_offset":33,"signature_key_length":8},{"name":"group","doc":"The name of the group to add targets to.","types":["String[1]"],"signature_key_offset":53,"signature_key_length":6}]}]},{"key":"wait","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"Wait for a Future or array of Futures to finish and return results,\noptionally with a timeout.\n\n> **Note:** Not available in apply block","function_version":4,"signatures":[{"key":"wait(Variant[Future, Array[Future]] $futures, Optional[Hash[String[1], Any]] $options)","doc":"Wait for Futures to finish.","return_types":["Array[Boltlib::PlanResult]"],"parameters":[{"name":"futures","doc":"A Bolt Future object or array of Bolt Futures to wait on.","types":["Variant[Future, Array[Future]]"],"signature_key_offset":36,"signature_key_length":8},{"name":"options","doc":"A hash of additional options.","types":["Optional[Hash[String[1], Any]]"],"signature_key_offset":77,"signature_key_length":8}]},{"key":"wait(Optional[Hash[String[1], Any]] $options)","doc":"Wait for all Futures in the current plan to finish.","return_types":["Array[Boltlib::PlanResult]"],"parameters":[{"name":"options","doc":"A hash of additional options.","types":["Optional[Hash[String[1], Any]]"],"signature_key_offset":36,"signature_key_length":8}]},{"key":"wait(Variant[Integer[0], Float[0.0]] $timeout, Optional[Hash[String[1], Any]] $options)","doc":"Wait for all Futures in the current plan to finish with a timeout.","return_types":["Array[Boltlib::PlanResult]"],"parameters":[{"name":"timeout","doc":"How long to wait for Futures to finish before raising a Timeout error.","types":["Variant[Integer[0], Float[0.0]]"],"signature_key_offset":37,"signature_key_length":8},{"name":"options","doc":"A hash of additional options.","types":["Optional[Hash[String[1], Any]]"],"signature_key_offset":78,"signature_key_length":8}]},{"key":"wait(Variant[Future, Array[Future]] $futures, Variant[Integer[0], Float[0.0]] $timeout, Optional[Hash[String[1], Any]] $options)","doc":"Wait for Futures to finish with timeout.","return_types":["Array[Boltlib::PlanResult]"],"parameters":[{"name":"futures","doc":"A Bolt Future object or array of Bolt Futures to wait on.","types":["Variant[Future, Array[Future]]"],"signature_key_offset":36,"signature_key_length":8},{"name":"timeout","doc":"How long to wait for Futures to finish before raising a Timeout error.","types":["Variant[Integer[0], Float[0.0]]"],"signature_key_offset":78,"signature_key_length":8},{"name":"options","doc":"A hash of additional options.","types":["Optional[Hash[String[1], Any]]"],"signature_key_offset":119,"signature_key_length":8}]}]},{"key":"run_command","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"Runs a command on the given set of targets and returns the result from each command execution.\nThis function does nothing if the list of targets is empty.\n\n> **Note:** Not available in apply block","function_version":4,"signatures":[{"key":"run_command(String[1] $command, Boltlib::TargetSpec $targets, Optional[Hash[String[1], Any]] $options)","doc":"Run a command.","return_types":["ResultSet"],"parameters":[{"name":"command","doc":"A command to run on target.","types":["String[1]"],"signature_key_offset":22,"signature_key_length":8},{"name":"targets","doc":"A pattern identifying zero or more targets. See {get_targets} for accepted patterns.","types":["Boltlib::TargetSpec"],"signature_key_offset":52,"signature_key_length":8},{"name":"options","doc":"A hash of additional options.","types":["Optional[Hash[String[1], Any]]"],"signature_key_offset":93,"signature_key_length":8}]},{"key":"run_command(String[1] $command, Boltlib::TargetSpec $targets, String $description, Optional[Hash[String[1], Any]] $options)","doc":"Run a command, logging the provided description.","return_types":["ResultSet"],"parameters":[{"name":"command","doc":"A command to run on target.","types":["String[1]"],"signature_key_offset":22,"signature_key_length":8},{"name":"targets","doc":"A pattern identifying zero or more targets. See {get_targets} for accepted patterns.","types":["Boltlib::TargetSpec"],"signature_key_offset":52,"signature_key_length":8},{"name":"description","doc":"A description to be output when calling this function.","types":["String"],"signature_key_offset":69,"signature_key_length":12},{"name":"options","doc":"A hash of additional options.","types":["Optional[Hash[String[1], Any]]"],"signature_key_offset":114,"signature_key_length":8}]}]},{"key":"add_facts","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"Deep merges a hash of facts with the existing facts on a target.\n\n> **Note:** Not available in apply block","function_version":4,"signatures":[{"key":"add_facts(Target $target, Hash $facts)","doc":"Deep merges a hash of facts with the existing facts on a target.\n\n> **Note:** Not available in apply block","return_types":["Target"],"parameters":[{"name":"target","doc":"A target.","types":["Target"],"signature_key_offset":17,"signature_key_length":7},{"name":"facts","doc":"A hash of fact names to values that can include structured facts.","types":["Hash"],"signature_key_offset":31,"signature_key_length":6}]}]},{"key":"puppetdb_command","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"Send a command with a payload to PuppetDB.\n\nThe `pdb_command` function only supports version 5 of the `replace_facts`\ncommand. Other commands might also work, but are not tested or supported\nby Bolt.\n\nSee the [commands endpoint](https://puppet.com/docs/puppetdb/latest/api/command/v1/commands.html)\ndocumentation for more information about available commands and payload\nformat.\n\n_This function is experimental and subject to change._\n\n> **Note:** Not available in apply block","function_version":4,"signatures":[{"key":"puppetdb_command(String[1] $command, Integer $version, Hash[Data, Data] $payload)","doc":"Send a command with a payload to PuppetDB.\n\nThe `pdb_command` function only supports version 5 of the `replace_facts`\ncommand. Other commands might also work, but are not tested or supported\nby Bolt.\n\nSee the [commands endpoint](https://puppet.com/docs/puppetdb/latest/api/command/v1/commands.html)\ndocumentation for more information about available commands and payload\nformat.\n\n_This function is experimental and subject to change._\n\n> **Note:** Not available in apply block","return_types":["String"],"parameters":[{"name":"command","doc":"The command to invoke.","types":["String[1]"],"signature_key_offset":27,"signature_key_length":8},{"name":"version","doc":"The version of the command to invoke.","types":["Integer"],"signature_key_offset":45,"signature_key_length":8},{"name":"payload","doc":"The payload to the command.","types":["Hash[Data, Data]"],"signature_key_offset":72,"signature_key_length":8}]}]},{"key":"set_feature","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"Sets a particular feature to present on a target.\n\nFeatures are used to determine what implementation of a task should be run.\nSupported features are:\n- `powershell`\n- `shell`\n- `puppet-agent`\n\n> **Note:** Not available in apply block","function_version":4,"signatures":[{"key":"set_feature(Target $target, String $feature, Optional[Boolean] $value)","doc":"Sets a particular feature to present on a target.\n\nFeatures are used to determine what implementation of a task should be run.\nSupported features are:\n- `powershell`\n- `shell`\n- `puppet-agent`\n\n> **Note:** Not available in apply block","return_types":["Target"],"parameters":[{"name":"target","doc":"The Target object to add features to. See {get_targets}.","types":["Target"],"signature_key_offset":19,"signature_key_length":7},{"name":"feature","doc":"The string identifying the feature.","types":["String"],"signature_key_offset":35,"signature_key_length":8},{"name":"value","doc":"Whether the feature is supported.","types":["Optional[Boolean]"],"signature_key_offset":63,"signature_key_length":6}]}]},{"key":"get_resources","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"Query the state of resources on a list of targets using resource definitions in Bolt's module path.\nThe results are returned as a list of hashes representing each resource.\n\nRequires the Puppet Agent be installed on the target, which can be accomplished with apply_prep\nor by directly running the `puppet_agent::install` task. In order to be able to reference types without\nstring quoting (for example `get_resources($target, Package)` instead of `get_resources($target, 'Package')`),\nrun the command `bolt puppetfile generate-types` to generate type references in `$Boldir/.resource_types`.\n\n> **Note:** Not available in apply block","function_version":4,"signatures":[{"key":"get_resources(Boltlib::TargetSpec $targets, Variant[String, Type[Resource], Array[Variant[String, Type[Resource]]]] $resources)","doc":"Query the state of resources on a list of targets using resource definitions in Bolt's module path.\nThe results are returned as a list of hashes representing each resource.\n\nRequires the Puppet Agent be installed on the target, which can be accomplished with apply_prep\nor by directly running the `puppet_agent::install` task. In order to be able to reference types without\nstring quoting (for example `get_resources($target, Package)` instead of `get_resources($target, 'Package')`),\nrun the command `bolt puppetfile generate-types` to generate type references in `$Boldir/.resource_types`.\n\n> **Note:** Not available in apply block","return_types":["ResultSet"],"parameters":[{"name":"targets","doc":"A pattern or array of patterns identifying a set of targets.","types":["Boltlib::TargetSpec"],"signature_key_offset":34,"signature_key_length":8},{"name":"resources","doc":"A resource type or instance, or an array of such.","types":["Variant[String, Type[Resource], Array[Variant[String, Type[Resource]]]]"],"signature_key_offset":116,"signature_key_length":10}]}]},{"key":"parallelize","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"Map a code block onto an array, where each array element executes in parallel.\nThis function is experimental.\n\n> **Note:** Not available in apply block.","function_version":4,"signatures":[{"key":"parallelize(Array[Any] $data, Callable[Any] &$block)","doc":"Map a code block onto an array, where each array element executes in parallel.\nThis function is experimental.\n\n> **Note:** Not available in apply block.","return_types":["Array[Boltlib::PlanResult]"],"parameters":[{"name":"data","doc":"The array to apply the block to.","types":["Array[Any]"],"signature_key_offset":23,"signature_key_length":5},{"name":"&block","doc":"The code block to execute for each array element.","types":["Callable[Any]"],"signature_key_offset":44,"signature_key_length":7}]}]},{"key":"remove_from_group","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"Removes a target from the specified inventory group.\n\nThe target is removed from all child groups and all parent groups where the target has\nnot been explicitly defined. A target cannot be removed from the `all` group.\n\n> **Note:** Not available in apply block","function_version":4,"signatures":[{"key":"remove_from_group(Boltlib::TargetSpec $target, String[1] $group)","doc":"Removes a target from the specified inventory group.\n\nThe target is removed from all child groups and all parent groups where the target has\nnot been explicitly defined. A target cannot be removed from the `all` group.\n\n> **Note:** Not available in apply block","return_types":["nil"],"parameters":[{"name":"target","doc":"A pattern identifying a single target.","types":["Boltlib::TargetSpec"],"signature_key_offset":38,"signature_key_length":7},{"name":"group","doc":"The name of the group to remove the target from.","types":["String[1]"],"signature_key_offset":57,"signature_key_length":6}]}]},{"key":"fail_plan","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"Raises a `Bolt::PlanFailure` exception to signal to callers that the plan failed.\n\nPlan authors should call this function when their plan is not successful. The\nerror may then be caught by another plans `run_plan` function or in Bolt itself\n\n> **Note:** Not available in apply block","function_version":4,"signatures":[{"key":"fail_plan(String[1] $msg, Optional[String[1]] $kind, Optional[Hash[String[1], Any]] $details, Optional[String[1]] $issue_code)","doc":"Fail a plan, generating an exception from the parameters.","return_types":["Any"],"parameters":[{"name":"msg","doc":"An error message.","types":["String[1]"],"signature_key_offset":20,"signature_key_length":4},{"name":"kind","doc":"An easily matchable error kind.","types":["Optional[String[1]]"],"signature_key_offset":46,"signature_key_length":5},{"name":"details","doc":"Machine-parseable details about the error.","types":["Optional[Hash[String[1], Any]]"],"signature_key_offset":84,"signature_key_length":8},{"name":"issue_code","doc":"Unused.","types":["Optional[String[1]]"],"signature_key_offset":114,"signature_key_length":11}]},{"key":"fail_plan(Error $error)","doc":"Fail a plan, generating an exception from an existing Error object.","return_types":["Any"],"parameters":[{"name":"error","doc":"An error object.","types":["Error"],"signature_key_offset":16,"signature_key_length":6}]}]},{"key":"run_script","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"Uploads the given script to the given set of targets and returns the result of having each target execute the script.\nThis function does nothing if the list of targets is empty.\n\n> **Note:** Not available in apply block","function_version":4,"signatures":[{"key":"run_script(String[1] $script, Boltlib::TargetSpec $targets, Optional[Hash[String[1], Any]] $options)","doc":"Run a script.","return_types":["ResultSet"],"parameters":[{"name":"script","doc":"Path to a script to run on target. Can be an absolute path or a modulename/filename selector for a\nfile in $MODULEROOT/files.","types":["String[1]"],"signature_key_offset":21,"signature_key_length":7},{"name":"targets","doc":"A pattern identifying zero or more targets. See {get_targets} for accepted patterns.","types":["Boltlib::TargetSpec"],"signature_key_offset":50,"signature_key_length":8},{"name":"options","doc":"A hash of additional options.","types":["Optional[Hash[String[1], Any]]"],"signature_key_offset":91,"signature_key_length":8}]},{"key":"run_script(String[1] $script, Boltlib::TargetSpec $targets, String $description, Optional[Hash[String[1], Any]] $options)","doc":"Run a script, logging the provided description.","return_types":["ResultSet"],"parameters":[{"name":"script","doc":"Path to a script to run on target. Can be an absolute path or a modulename/filename selector for a\nfile in $MODULEROOT/files.","types":["String[1]"],"signature_key_offset":21,"signature_key_length":7},{"name":"targets","doc":"A pattern identifying zero or more targets. See {get_targets} for accepted patterns.","types":["Boltlib::TargetSpec"],"signature_key_offset":50,"signature_key_length":8},{"name":"description","doc":"A description to be output when calling this function.","types":["String"],"signature_key_offset":67,"signature_key_length":12},{"name":"options","doc":"A hash of additional options.","types":["Optional[Hash[String[1], Any]]"],"signature_key_offset":112,"signature_key_length":8}]}]},{"key":"apply_prep","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"Installs the `puppet-agent` package on targets if needed, then collects facts,\nincluding any custom facts found in Bolt's module path. The package is\ninstalled using either the configured plugin or the `task` plugin with the\n`puppet_agent::install` task.\n\nAgent installation will be skipped if the target includes the `puppet-agent`\nfeature, either as a property of its transport (PCP) or by explicitly setting\nit as a feature in Bolt's inventory.\n\n> **Note:** Not available in apply block","function_version":4,"signatures":[{"key":"apply_prep(Boltlib::TargetSpec $targets, Optional[Hash[String, Data]] $options)","doc":"Installs the `puppet-agent` package on targets if needed, then collects facts,\nincluding any custom facts found in Bolt's module path. The package is\ninstalled using either the configured plugin or the `task` plugin with the\n`puppet_agent::install` task.\n\nAgent installation will be skipped if the target includes the `puppet-agent`\nfeature, either as a property of its transport (PCP) or by explicitly setting\nit as a feature in Bolt's inventory.\n\n> **Note:** Not available in apply block","return_types":["Bolt::ResultSet"],"parameters":[{"name":"targets","doc":"A pattern or array of patterns identifying a set of targets.","types":["Boltlib::TargetSpec"],"signature_key_offset":31,"signature_key_length":8},{"name":"options","doc":"Options hash.","types":["Optional[Hash[String, Data]]"],"signature_key_offset":70,"signature_key_length":8}]}]}]} \ No newline at end of file diff --git a/lib/puppet-languageserver/static_data/bolt-log.json b/lib/puppet-languageserver/static_data/bolt-log.json new file mode 100644 index 00000000..5ca41ecc --- /dev/null +++ b/lib/puppet-languageserver/static_data/bolt-log.json @@ -0,0 +1 @@ +{"functions":[{"key":"log::error","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"Log an error message.\n\nMessages logged at this level typically indicate that the plan encountered an\nerror that can be recovered from. For example, you might log a message at the\n`error` level if you want to inform the user an action running on a target\nfailed but that the plan will continue running.\n\nSee [Logs](logs.md) for more information about Bolt's log levels.\n\n> **Note:** Not available in apply block","function_version":4,"signatures":[{"key":"log::error(Any $message)","doc":"Log an error message.\n\nMessages logged at this level typically indicate that the plan encountered an\nerror that can be recovered from. For example, you might log a message at the\n`error` level if you want to inform the user an action running on a target\nfailed but that the plan will continue running.\n\nSee [Logs](logs.md) for more information about Bolt's log levels.\n\n> **Note:** Not available in apply block","return_types":["Undef"],"parameters":[{"name":"message","doc":"The message to log.","types":["Any"],"signature_key_offset":15,"signature_key_length":8}]}]},{"key":"log::warn","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"Log a warning message.\n\nMessages logged at this level typically include messages about deprecated\nbehavior or potentially harmful situations that might affect the plan run.\nFor example, you might log a message at the `warn` level if you are\nplanning to make a breaking change to your plan in a future release and\nwant to notify users.\n\nSee [Logs](logs.md) for more information about Bolt's log levels.\n\n> **Note:** Not available in apply block","function_version":4,"signatures":[{"key":"log::warn(Any $message)","doc":"Log a warning message.\n\nMessages logged at this level typically include messages about deprecated\nbehavior or potentially harmful situations that might affect the plan run.\nFor example, you might log a message at the `warn` level if you are\nplanning to make a breaking change to your plan in a future release and\nwant to notify users.\n\nSee [Logs](logs.md) for more information about Bolt's log levels.\n\n> **Note:** Not available in apply block","return_types":["Undef"],"parameters":[{"name":"message","doc":"The message to log.","types":["Any"],"signature_key_offset":14,"signature_key_length":8}]}]},{"key":"log::info","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"Log an info message.\n\nMessages logged at this level typically include high-level information about\nwhat a plan is doing. For example, you might log a message at the `info` level\nthat informs users that the plan is reading a file on disk.\n\nSee [Logs](logs.md) for more information about Bolt's log levels.\n\n> **Note:** Not available in apply block","function_version":4,"signatures":[{"key":"log::info(Any $message)","doc":"Log an info message.\n\nMessages logged at this level typically include high-level information about\nwhat a plan is doing. For example, you might log a message at the `info` level\nthat informs users that the plan is reading a file on disk.\n\nSee [Logs](logs.md) for more information about Bolt's log levels.\n\n> **Note:** Not available in apply block","return_types":["Undef"],"parameters":[{"name":"message","doc":"The message to log.","types":["Any"],"signature_key_offset":14,"signature_key_length":8}]}]},{"key":"log::debug","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"Log a debugging message.\n\nMessages logged at this level typically include detailed information about\nwhat a plan is doing. For example, you might log a message at the `debug`\nlevel that shows what value is returned from a function invocation.\n\nSee [Logs](logs.md) for more information about Bolt's log levels.\n\n> **Note:** Not available in apply block","function_version":4,"signatures":[{"key":"log::debug(Any $message)","doc":"Log a debugging message.\n\nMessages logged at this level typically include detailed information about\nwhat a plan is doing. For example, you might log a message at the `debug`\nlevel that shows what value is returned from a function invocation.\n\nSee [Logs](logs.md) for more information about Bolt's log levels.\n\n> **Note:** Not available in apply block","return_types":["Undef"],"parameters":[{"name":"message","doc":"The message to log.","types":["Any"],"signature_key_offset":15,"signature_key_length":8}]}]},{"key":"log::trace","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"Log a trace message.\n\nMessages logged at this level typically include the most detailed information\nabout what a plan is doing. For example, you might log a message at the `trace`\nlevel that describes how a plan is manipulating data.\n\nSee [Logs](logs.md) for more information about Bolt's log levels.\n\n> **Note:** Not available in apply block","function_version":4,"signatures":[{"key":"log::trace(Any $message)","doc":"Log a trace message.\n\nMessages logged at this level typically include the most detailed information\nabout what a plan is doing. For example, you might log a message at the `trace`\nlevel that describes how a plan is manipulating data.\n\nSee [Logs](logs.md) for more information about Bolt's log levels.\n\n> **Note:** Not available in apply block","return_types":["Undef"],"parameters":[{"name":"message","doc":"The message to log.","types":["Any"],"signature_key_offset":15,"signature_key_length":8}]}]},{"key":"log::fatal","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"Log a fatal message.\n\nMessages logged at this level indicate that the plan encountered an error that\ncould not be recovered from. For example, you might log a message at the\n`fatal` level if a service is unavailable and the plan cannot continue running\nwithout it.\n\nSee [Logs](logs.md) for more information about Bolt's log levels.\n\n> **Note:** Not available in apply block","function_version":4,"signatures":[{"key":"log::fatal(Any $message)","doc":"Log a fatal message.\n\nMessages logged at this level indicate that the plan encountered an error that\ncould not be recovered from. For example, you might log a message at the\n`fatal` level if a service is unavailable and the plan cannot continue running\nwithout it.\n\nSee [Logs](logs.md) for more information about Bolt's log levels.\n\n> **Note:** Not available in apply block","return_types":["Undef"],"parameters":[{"name":"message","doc":"The message to log.","types":["Any"],"signature_key_offset":15,"signature_key_length":8}]}]}]} \ No newline at end of file diff --git a/lib/puppet-languageserver/static_data/bolt-out.json b/lib/puppet-languageserver/static_data/bolt-out.json index 6b4d1276..baf010ab 100644 --- a/lib/puppet-languageserver/static_data/bolt-out.json +++ b/lib/puppet-languageserver/static_data/bolt-out.json @@ -1 +1 @@ -{"functions":[{"key":"out::message","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"Output a message for the user.\n\nThis will print a message to stdout when using the human output format,\nand print to stderr when using the json output format\n\n> **Note:** Not available in apply block","function_version":4,"signatures":[{"key":"out::message(Any $message)","doc":"Output a message for the user.\n\nThis will print a message to stdout when using the human output format,\nand print to stderr when using the json output format\n\n> **Note:** Not available in apply block","return_types":["Undef"],"parameters":[{"name":"message","doc":"The message to output.","types":["Any"],"signature_key_offset":17,"signature_key_length":8}]}]}]} \ No newline at end of file +{"functions":[{"key":"out::verbose","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"Output a message for the user when running in verbose mode.\n\nThis will print a message to stdout when using the human output format,\nand print to stderr when using the json output format. Messages are\nalso logged at the `debug` level. For more information about logs, see\n[Logs](logs.md).\n\n> **Note:** Not available in apply block","function_version":4,"signatures":[{"key":"out::verbose(Any $message)","doc":"Output a message for the user when running in verbose mode.\n\nThis will print a message to stdout when using the human output format,\nand print to stderr when using the json output format. Messages are\nalso logged at the `debug` level. For more information about logs, see\n[Logs](logs.md).\n\n> **Note:** Not available in apply block","return_types":["Undef"],"parameters":[{"name":"message","doc":"The message to output.","types":["Any"],"signature_key_offset":17,"signature_key_length":8}]}]},{"key":"out::message","calling_source":null,"source":null,"line":null,"char":null,"length":null,"doc":"Output a message for the user.\n\nThis will print a message to stdout when using the human output format,\nand print to stderr when using the json output format. Messages are\nalso logged at the `info` level. For more information about logs, see\n[Logs](logs.md).\n\n> **Note:** Not available in apply block","function_version":4,"signatures":[{"key":"out::message(Any $message)","doc":"Output a message for the user.\n\nThis will print a message to stdout when using the human output format,\nand print to stderr when using the json output format. Messages are\nalso logged at the `info` level. For more information about logs, see\n[Logs](logs.md).\n\n> **Note:** Not available in apply block","return_types":["Undef"],"parameters":[{"name":"message","doc":"The message to output.","types":["Any"],"signature_key_offset":17,"signature_key_length":8}]}]}]} \ No newline at end of file diff --git a/tools/bolt_introspect/README.md b/tools/bolt_introspect/README.md index 04626e74..3e2ac477 100644 --- a/tools/bolt_introspect/README.md +++ b/tools/bolt_introspect/README.md @@ -22,5 +22,5 @@ This should regenerate all of the bolt files in `/lib/puppet-languageserver/stat | Component | Version | | --------------- | ------- | -| Bolt | 3.8.1 | -| Editor Services | 1.2.0 | +| Bolt | 3.18.0 | +| Editor Services | 1.3.0 |