![terratech 0.7 terratech 0.7](https://cdn.cloudflare.steamstatic.com/steam/apps/285920/ss_1cec1cc6c1fceb5b3087e79cf49dafcfd3fa897d.1920x1080.jpg)
The CLI outputs error messages, not strack traces. Head drs object: tnu drs head drs://my-drs-url -bytes 10 Tnu drs copy-batch drs://my-drs-url1 drs://my-drs-url2 -dst gs://my-dst-bucket/prefix Tnu drs copy-batch drs://my-drs-url1 drs://my-drs-url2 -dst local_directory Tnu drs copy drs://my-drs-url local_filepath Head drs object: from terra_notebook_utils import drsĭrs.head("drs://my-drs-url", num_bytes=10)Ĭopy drs object to local or bucket: tnu drs copy drs://my-drs-url gs://my-dst-bucket/my-dstkey Terra-notebook-utils provides several methods and CLI commands useful for working withĬopy drs object to local file system or bucket: from terra_notebook_utils import drsĭrs.copy("drs://my-drs-url", "gs://my-dst-bucket/my-dst-key")ĭrs.copy("drs://my-drs-url", "local_filepath")ĭrs.copy_batch(, "local_directory")ĭrs.copy_batch(, "gs://my-dst-bucket/prefix") These values are used with lowest precedence. tnu table get -help, for usage information.įinally, workspace and workspace namespace can be specified with the environment variables Note that workspace namespace is the same as Google billing project.Īlternatively, workspace and workspace namespace can be passed in to individual commands instead of, or as overrides to, Tnu config set-workspace-google-project my-workspace-namespace Defaults can be configured using theĬommands tnu config set-workspace my-workspace Several CLI commands target a workspace or require a workspace namespace. # Show your available workspace namespaces (also known as Google billing projects) # See the commands available to the vcf group # See the command groups available to the CLI Try the following commands at a bash prompt. Similarly, the CLI may be explored using the typical -h argument. Interpreter or Jupyter notebook will produce help and usage for the drs module. For instance, issuing the follow commands into a Python The PythonĪPI is best explored with Pythons great help function. Terra-notebook-utils exposes a Python API, as well as wrappers to execute some functionality on the CLI. With the command gcloud auth application-default login
![terratech 0.7 terratech 0.7](https://steamcdn-a.akamaihd.net/steamcommunity/public/images/clans/6297347/50098aee3689fe42a89b9e78c9ce0dda28811c07.png)
Much of the terra-notebook-utilities functionality requires credentialed access through a Google Cloud Platform account.Ĭredentials are already available when running in a Terra notebook environment.
Terratech 0.7 install#
Note that all standard notebook runtimes on Terra are based onįor other environments, it is often enough to do pip install -upgrade -no-cache-dir terra-notebook-utils Interface, use /usr/local/bin/pip install -upgrade -no-cache-dir terra-notebook-utils Terra-notebook-utils depends on your host environment.įrom any Jupyter notebook, use the following (and note the leading "%") %pip install -upgrade -no-cache-dir terra-notebook-utilsįrom the CLI on standard Terra notebook runtimes, which are available using the terminal button in the Terra user It is often useful to keep up to date with new features and bug fixes.
![terratech 0.7 terratech 0.7](https://i.imgur.com/Pg1DGxY.png)
In a Jupyter notebook (note the ipython magic " %pip"): %pip install terra-notebook-utils Python API and CLI providing utilities for working with DRSįrom the CLI: pip install terra-notebook-utils