-
Notifications
You must be signed in to change notification settings - Fork 14.8k
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
adding new dateformatter #44108
adding new dateformatter #44108
Conversation
Congratulations on your first Pull Request and welcome to the Apache Airflow community! If you have any issues or are unsure about any anything please check our Contributors' Guide (https://github.com/apache/airflow/blob/main/contributing-docs/README.rst)
|
@amoghrajesh I see this https://github.com/kunaljubce/airflow/blob/c269be90c9a840d159fd38c03459bc6aeaf5708d/tests/api_fastapi/core_api/routes/public/test_import_error.py#L118 |
def format_datetime_zulu(dt): | ||
return dt.strftime(ZULU_STR_FORMAT).replace('+0000', 'Z') | ||
|
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.
This is not the only file we need to edit. Can you probably place this utility somewhere under airflow/tests_common/test_utils
and reuse it across other files?
For instance, also check for test_assets.py
ZULU_STR_FORMAT = '%Y-%m-%dT%H:%M:%S%z' | ||
|
||
|
||
def format_datetime_zulu(dt): |
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.
def format_datetime_zulu(dt): | |
def format_datetime_zulu(dt: datetime) -> str: |
@iprithv I also see static checks failing. We have a pre-commit to maintain quality standards. You can install pre-commit using this: https://github.com/apache/airflow/blob/d43052e53bcf9bd8772484b8be4590f869932330/contributing-docs/03_contributors_quick_start.rst#configuring-pre-commit |
This pull request has been automatically marked as stale because it has not had recent activity. It will be closed in 5 days if no further activity occurs. Thank you for your contributions. |
Fixes #44033