-
Notifications
You must be signed in to change notification settings - Fork 1
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: conditionally run pipelines in debug mode #223
feat: conditionally run pipelines in debug mode #223
Conversation
if priority not in valid_priorities: | ||
raise ValueError(f"priority must be one of {', '.join(valid_priorities)}") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not need to check with the new Typing
openhexa/sdk/pipelines/runtime.py
Outdated
@@ -50,7 +50,7 @@ def download_pipeline(url: str, token: str, run_id: str, target_dir: str): | |||
pipelineRun(id: $id) { | |||
id | |||
version { | |||
number |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Issue also solved in #221 but not yet merged
@@ -67,6 +67,7 @@ include-package-data = true | |||
[tool.ruff] | |||
line-length = 120 | |||
ignore = ["E501"] | |||
per-file-ignores = { "tests/**/test_*.py" = ["D100","D101","D102", "D103"] } # Ignore missing docstrings in tests |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A preference but I am ok spending more time to provide some docstrings if we think it's valuable
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm ok for the tests.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks fine for me. The Priority
word is weird to me and would intuitively call that "LogLevel" but if you are not disturbed by this, I can live with it.
@@ -67,6 +67,7 @@ include-package-data = true | |||
[tool.ruff] | |||
line-length = 120 | |||
ignore = ["E501"] | |||
per-file-ignores = { "tests/**/test_*.py" = ["D100","D101","D102", "D103"] } # Ignore missing docstrings in tests |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm ok for the tests.
I agree it looks odd but that's what we used in the GraphQL layer and it is also stored in the db ( So I decided to avoid complex renames and keep the same name. I can :
Option 3 might be a good one, but let's agree @qgerome |
Let's go for option 3 then :) |
We want to provide a way for users to decide if they want to generate debug messages for the pipeline run. By default they will not be stored and shown.
Changes
log_level
settings from the environment and decide based on that if logs should be storedHow/what to test
Screenshots / screencast
screen-capture.3.webm
Related PRs