mirror of
https://github.com/hwchase17/langchain.git
synced 2025-06-16 20:09:01 +00:00
Check whether the API key is already in the environment Update: ```python import getpass import os os.environ["DATABRICKS_HOST"] = "https://your-workspace.cloud.databricks.com" os.environ["DATABRICKS_TOKEN"] = getpass.getpass("Enter your Databricks access token: ") ``` To: ```python import getpass import os os.environ["DATABRICKS_HOST"] = "https://your-workspace.cloud.databricks.com" if "DATABRICKS_TOKEN" not in os.environ: os.environ["DATABRICKS_TOKEN"] = getpass.getpass( "Enter your Databricks access token: " ) ``` grit migration: ``` engine marzano(0.1) language python `os.environ[$Q] = getpass.getpass("$X")` as $CHECK where { $CHECK <: ! within if_statement(), $CHECK => `if $Q not in os.environ:\n $CHECK` } ``` |
||
---|---|---|
.. | ||
_templates | ||
additional_resources | ||
changes/changelog | ||
contributing | ||
example_data | ||
how_to | ||
integrations | ||
tutorials | ||
versions | ||
.gitignore | ||
concepts.mdx | ||
introduction.mdx | ||
people.mdx | ||
security.md |