Skip to content

Commit

Permalink
feat: Update to required key checking
Browse files Browse the repository at this point in the history
  • Loading branch information
StephenGoodall committed Oct 28, 2024
1 parent bba5a31 commit df2ae0e
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions src/custom_parser/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,10 +31,9 @@ def check_env_vars():
pass

# Check endpoint specific keys
if ("DYNATRACE_TENANT_ID" not in os.environ and "OTEL_EXPORTER_OTEL_ENDPOINT" not in os.environ):
if "DYNATRACE_TENANT_ID" not in os.environ and "OTEL_EXPORTER_OTEL_ENDPOINT" not in os.environ:
print(f"One of DYNATRACE_TENANT_ID or OTEL_EXPORTER_OTEL_ENDPOINT must be set")
keys_not_set.append("DYNATRACE_TENANT_ID")
keys_not_set.append("OTEL_EXPORTER_OTEL_ENDPOINT")
keys_not_set.append("DYNATRACE_TENANT_ID or OTEL_EXPORTER_OTEL_ENDPOINT")

if len(keys_not_set) > 0:
for key in keys_not_set:
Expand Down

0 comments on commit df2ae0e

Please sign in to comment.