From 7c6472d317a480ed17643a2ece1a09244730955c Mon Sep 17 00:00:00 2001 From: Marc-Philipp Esser Date: Mon, 16 Oct 2023 11:03:53 +0200 Subject: [PATCH] remove as handled trough bash script instead --- src/blocks/create_env_string.py | 22 ---------------------- 1 file changed, 22 deletions(-) delete mode 100644 src/blocks/create_env_string.py diff --git a/src/blocks/create_env_string.py b/src/blocks/create_env_string.py deleted file mode 100644 index 5700abb..0000000 --- a/src/blocks/create_env_string.py +++ /dev/null @@ -1,22 +0,0 @@ -"""Programmatically Store ENV variable in form of a String as Prefect Block """ - -from prefect.blocks.system import String -from src.utils import load_env_variables - - -def create_env_string_block(): - """Store ENV environment variable as String in Prefect Block""" - env_variables = load_env_variables() - - ENV = env_variables["ENV"] # dev, test or prod - PREFECT_BLOCK_NAME_ENV_STRING = f"{env_variables['GCP_PROJECT_ID']}-{ENV}" - - env_string_block = String(value=ENV).save( - name=PREFECT_BLOCK_NAME_ENV_STRING, overwrite=True - ) - - return String.load(PREFECT_BLOCK_NAME_ENV_STRING).value - - -if __name__ == "__main__": - env = create_env_string_block()