python check existence of os.environ vairable code example Example: python check environment variable exists from os import environ if environ.get('Foo') is not None: