You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
On Windows, environment variables are case-insensitive and are converted to uppercase, so using lowercase environment variables can lead to subtle bugs.
The current wording is a little vague, and makes it sound like it is Windows that converts the environment variable names to uppercase. In reality, Windows preserves the case of environment variables. Some environment variables that are built into windows use mixed / lower case (for example Path, SystemRoot, windir). The limitation / case conversion seems to be in os.environ (more in python/cpython#73010).
Also, it doesn't explain or give any examples of how using lowercase variable names might lead to the "subtle bugs".
The text was updated successfully, but these errors were encountered:
https://docs.astral.sh/ruff/rules/uncapitalized-environment-variables/
The current wording is a little vague, and makes it sound like it is Windows that converts the environment variable names to uppercase. In reality, Windows preserves the case of environment variables. Some environment variables that are built into windows use mixed / lower case (for example
Path
,SystemRoot
,windir
). The limitation / case conversion seems to be inos.environ
(more in python/cpython#73010).Also, it doesn't explain or give any examples of how using lowercase variable names might lead to the "subtle bugs".
The text was updated successfully, but these errors were encountered: