environment variables for jupyter notebook #9739
-
In vscode "terminal.integrated.env.osx" : {
"MY_ENV": "test"
"MY_ENVTYPE": "qa"
} Now whenever, I start a new shell in the workspace, the shell loads with the above environment variables, and I can access them typically with But with the same Currently the workaround I have found is to add the following code snippet in a top code cell. import os
os.environ["MY_ENV"] = "test"
os.environ["MY_ENVTYPE"] = "qa" I am hoping there is a better way to do the same. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
Beta Was this translation helpful? Give feedback.
We actually have a setting that can run some arbitrary code at the start up of a any notebook or interactive window. Give this a try, should be what you need. If you just put that code snippet into the setting.