Skip to content
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

step depends_on ignore empty strings #3008

Closed
wants to merge 5 commits into from

Conversation

6543
Copy link
Member

@6543 6543 commented Dec 24, 2023

Just extend the test and ignore empty string dependencies

close #3055
close #3047

Copy link

codecov bot commented Dec 24, 2023

Codecov Report

All modified and coverable lines are covered by tests ✅

Comparison is base (72ae882) 34.81% compared to head (199dd57) 34.83%.
Report is 8 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #3008      +/-   ##
==========================================
+ Coverage   34.81%   34.83%   +0.02%     
==========================================
  Files         228      228              
  Lines       14751    14757       +6     
==========================================
+ Hits         5135     5141       +6     
  Misses       9238     9238              
  Partials      378      378              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@qwerty287 qwerty287 added the tests related to tests or other things CI check before merge label Dec 24, 2023
position: 0,
name: "echo env",
group: "",
dependsOn: []string{""},
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@6543 Why do you want to support such a wrong configuration? Shouldn't we treat it like an error if someone writes: depends_on: [""] instead of depends_on: [] Or is it because of this super weirdish way go-yaml is converting the slice?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I just want to let the server follow our idea: if run and on strange edgecases make sure it still works

the linter of course could point out a warning, but if you do depends_on: [""] as a naive user i expect it to not depend on something ... since the string is empty right 😆

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would just throw an error instead of supporting such configs

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Well I'm for supporting users

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, but not bad habits and wrong configs. Using an empty string is just wrong IMO.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

well we now even have a good use-case, and a user intuitively try to use it that way already

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I still think it supports wrong configs. The mentioned issue was a bug solved by #3097

@6543 6543 changed the title add more dag tests step depends_on ignore empty strings Dec 29, 2023
@6543 6543 mentioned this pull request Dec 29, 2023
5 tasks
@6543 6543 added enhancement improve existing features and removed tests related to tests or other things CI check before merge skip-changelog labels Dec 29, 2023
@6543 6543 added this to the 2.2.0 milestone Dec 29, 2023
@6543
Copy link
Member Author

6543 commented Jan 2, 2024

#3097 got merged

@6543 6543 closed this Jan 2, 2024
@6543 6543 deleted the dag_more_tests branch January 2, 2024 00:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement improve existing features
Projects
None yet
Development

Successfully merging this pull request may close these issues.

depends_on: [] doesn't enable DAG mode
3 participants