Skip to content

Commit 9052ef1

Browse files
authored
Merge pull request #13 from patterninc/feat/add-is-prod-tag
perimeter tag correct and add "is_production" tag
2 parents 5e876ef + 97aeebd commit 9052ef1

3 files changed

Lines changed: 7 additions & 3 deletions

File tree

pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[project]
22
name = "ds-platform-utils"
3-
version = "0.2.2"
3+
version = "0.2.3"
44
description = "Utility library for Pattern Data Science."
55
readme = "README.md"
66
authors = [

src/ds_platform_utils/metaflow/write_audit_publish.py

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
import json
2+
import os
23
import warnings
34
from pathlib import Path
45
from textwrap import dedent
@@ -119,7 +120,10 @@ def extract(prefix: str, default: str = "unknown") -> str:
119120
"user": current.username, # username of user who triggered the run (argo-workflows if its a deployed flow)
120121
"domain": extract("ds.domain"), # business unit (domain) of the flow, same as app
121122
"namespace": current.namespace, # namespace of the flow
122-
"perimeter": "PROD" if current.is_production else "Default", # perimeter of the flow
123+
"perimeter": str(os.environ.get("OB_CURRENT_PERIMETER") or os.environ.get("OBP_PERIMETER")),
124+
"is_production": str(
125+
current.is_production
126+
), # True, if the flow is deployed with the --production flag else false
123127
"team": "data-science", # team name, hardcoded as data-science
124128
}
125129

uv.lock

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)