"""Config for the Peloton Monthly Ingestion Workflow. Peloton delivers monthly usage files to the SME partner S3 bucket, one file per country. The files are copied (``grab_drop_files``) from ``s3://sme-ca-prod-partners/peloton/in/monthly/`` into the orchard archive (``cucumbers``) bucket. """ import os environment = os.environ.get('Environment', 'dev') feed_name = 'peloton' secrets_path = 'swf-peloton' # Countries delivered by Peloton each month. countries = ['AT', 'AU', 'CA', 'DE', 'GB', 'US'] sme_secrets_path = os.environ.get('SME_DROP_BUCKET_SECRETS_PATH', 'swf-sme-ca-prod-partners-s3-access') # SME partner bucket where Peloton drops the raw files. drop_bucket = os.environ.get( 'SME_FEED_INGESTION_DROP_BUCKET', 'sme-ca-prod-partners') # Bucket for archived data. data_bucket = os.environ.get('FEED_INGESTION_DATA_BUCKET', 'dev-cucumbers') if environment in ['production', 'prod']: data_bucket = 'cucumbers' # Path in the SME bucket where the monthly files are dropped. drop_path = 'peloton/in/monthly/' # Monthly file name, e.g. PMY5_M_US_20260501_20260531.txt drop_filename = 'PMY5_M_{country}_{first_day:%Y%m%d}_{last_day:%Y%m%d}.txt' # Path in the orchard archive (data) bucket. archive_path = 'Peloton/archives/{date:%Y-%m}/' staging_raw_table = 'staging_raw_peloton_monthly'