Expanding Allowed Envs List in DataHub Airflow Plugin

Original Slack Thread

Hi team, I am getting following error while pushing lineage using datahub airflow plugin
datahub.utilities.urns.error.InvalidUrnError: Invalid env:RVW. Allowed envs are {'STG', 'NON_PROD', 'CORP', 'TEST', 'EI', 'QA', 'PRE', 'UAT', 'DEV', 'PROD'}
Any idea on if i can add more values Allowed envs list.

Hey there! :wave: Make sure your message includes the following information if relevant, so we can help more effectively!

  1. Are you using UI or CLI for ingestion?
  2. Which DataHub version are you using? (e.g. 0.12.0)
  3. What data source(s) are you integrating with DataHub? (e.g. BigQuery)

Unfortunately, currently, env is a fixed number of values.
What would you like to achieve? I wonder if there is some other way to achieve this.

<@UV14447EU> we have different env naming convention

let me ask the team what we can do or how we can support this and get back to you

Currently you have the following options:

  1. You can use platform instance to distinguish between environments (https://datahubproject.io/docs/platform-instances/) and environment can be part of the platform_instance_name
  2. If you really want to use environment and change the existing ones then currently you have to fork the project and change/add environment enum