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

add: Custom arguments with custom cond #68

Merged
merged 3 commits into from
Sep 17, 2022
Merged

Conversation

Miksus
Copy link
Owner

@Miksus Miksus commented Aug 6, 2022

Now one can pass arguments when using a custom condition.

Now this should work:

from pathlib import Path

@app.cond()
def file_exists(file):
    return Path(file).exists()

@app.task(file_exists("myfile.csv"))
def do_things():
    ...

Now one can pass arguments when using a custom condition.
@Miksus Miksus added the built-in Relates to the built-in tasks, conditions etc. label Aug 6, 2022
@codecov-commenter
Copy link

codecov-commenter commented Sep 17, 2022

Codecov Report

Base: 95.50% // Head: 95.50% // No change to project coverage 👍

Coverage data is based on head (aa6dadf) compared to base (9e3539b).
Patch coverage: 100.00% of modified lines in pull request are covered.

Additional details and impacted files
@@           Coverage Diff           @@
##           master      #68   +/-   ##
=======================================
  Coverage   95.50%   95.50%           
=======================================
  Files          88       88           
  Lines        4604     4604           
=======================================
  Hits         4397     4397           
  Misses        207      207           
Impacted Files Coverage Δ
rocketry/conditions/func.py 89.58% <100.00%> (ø)

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

☔ View full report at Codecov.
📢 Do you have feedback about the report comment? Let us know in this issue.

@Miksus Miksus merged commit da8dfe2 into master Sep 17, 2022
@Miksus Miksus deleted the dev/custom_conds_params branch September 17, 2022 19:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
built-in Relates to the built-in tasks, conditions etc.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants