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

Remove all usages of days_ago from test suite #21683

Closed
1 task done
eladkal opened this issue Feb 19, 2022 · 13 comments
Closed
1 task done

Remove all usages of days_ago from test suite #21683

eladkal opened this issue Feb 19, 2022 · 13 comments
Assignees
Labels
good first issue kind:task A task that needs to be completed as part of a larger issue

Comments

@eladkal
Copy link
Contributor

eladkal commented Feb 19, 2022

Body

days_ago is deprecated #21653

We have several references to the function in test suite / example dags.

Task:
there should be no imports of airflow.utils.dates import days_ago in the code.
In most cases we can simple replace with datetime(2022, 1, 1)

Committer

  • I acknowledge that I am a maintainer/committer of the Apache Airflow project.
@eladkal eladkal added good first issue kind:task A task that needs to be completed as part of a larger issue labels Feb 19, 2022
@hubert-pietron
Copy link
Contributor

Hi, can i take it?

@eladkal
Copy link
Contributor Author

eladkal commented Feb 20, 2022

@hubert-pietron sure, assigned to you.

@Dev232001
Copy link
Contributor

Hi, can you assign this to me?

@potiuk
Copy link
Member

potiuk commented Feb 23, 2022

Just check with @hubert-pietron - if it's not something already started.

@hubert-pietron
Copy link
Contributor

Let me know @Dev232001 how you want to split, or you can take whole and i will look for another issue to work on :)

@Dev232001
Copy link
Contributor

Hi @hubert-pietron , thanks for letting me join this issue here. I am relatively new to open source contributions and was looking for a beginner level task. This looked like an easy problem so I asked for this. If you can just give me an update on what you have done till now that will be the best. I think I will be able to work on the rest of the issue from thereon :)

@Dev232001
Copy link
Contributor

https://github.com/apache/airflow/tree/main/airflow/example_dags
@potiuk is this the correct folder in which the task is to be done?

@eladkal
Copy link
Contributor Author

eladkal commented Feb 23, 2022

it can be in example dags or in tests.
You can find all relevant files by searching from airflow.utils.dates import days_ago in the code base.

@Dev232001
Copy link
Contributor

Dev232001 commented Feb 23, 2022 via email

@hubert-pietron
Copy link
Contributor

I just looked how many occurrences there is in code, so You can take it all :)

@Dev232001
Copy link
Contributor

I have completed the given task and created a pull request for the same. Kindly review it.
Besides this, there are quite a few syntax related errors in tests folder like in
from fake_datetime import FakeDatetime - test_impersonation_custom.py - dags_corrupted - tests

tests - decorators - test_python_virtualenv.py - errors found

tests - operators - test_python.py - import funcsigs - error

@Dev232001
Copy link
Contributor

This is my first contribution and its asking for a approval review
#21796

kaxil added a commit to astronomer/astronomer-providers that referenced this issue Mar 1, 2022
kaxil added a commit to astronomer/astronomer-providers that referenced this issue Mar 1, 2022
@eladkal
Copy link
Contributor Author

eladkal commented May 29, 2022

fixed in #23237
and duplicated of #23233
I don't know why I opened two issues for this :/

@eladkal eladkal closed this as completed May 29, 2022
OlympuJupiter added a commit to OlympuJupiter/astronomer-providers that referenced this issue Nov 14, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue kind:task A task that needs to be completed as part of a larger issue
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants