Skip to main content

meteostat.config.get_env_name

Get the full name of an environment variable (including prefix) that can be used to set a configuration option.

Parameters

ParameterDescriptionType
keyConfiguration option keystr

Returns

str

The full environment variable name with the prefix included.

Example

import meteostat as ms

# Get environment variable name for cache directory
env_var = ms.config.get_env_name('cache_directory')
print(env_var) # Output: MS_CACHE_DIRECTORY