Skip to content

Commit

Permalink
Fix invalid Python syntax for Spaces Overview page (#1303)
Browse files Browse the repository at this point in the history
`print(os.getenv['MODEL_REPO_ID'])` is invalid Python syntax this has been replaced with `print(os.getenv('MODEL_REPO_ID'))`
  • Loading branch information
alexandercarruthers authored Jun 3, 2024
1 parent 3e4c6ef commit d49f678
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion docs/hub/spaces-overview.md
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ Accessing secrets and variables is different depending on your Space SDK:
For other Spaces, both are exposed to your app as environment variables. Here is a very simple example of accessing the previously declared `MODEL_REPO_ID` variable in Python (it would be the same for secrets):
```py
import os
print(os.getenv['MODEL_REPO_ID'])
print(os.getenv('MODEL_REPO_ID'))
```

Spaces owners are warned when our `Spaces Secrets Scanner` [finds hard-coded secrets](./security-secrets).
Expand Down

0 comments on commit d49f678

Please sign in to comment.