-
-
Notifications
You must be signed in to change notification settings - Fork 7k
Add ability to specify output format for DurationField
#8532
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
Conversation
|
Thanks - good to talk this through from a docs-first perspective. |
|
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. |
|
Can we reopen this? |
|
I think it's not possible to contribute to the pr to solve the conflicts, @sevdog would you be able to do it? |
|
Just rebased the PR, the "conflict" was a very silly issue in the doc file 🤷♂️ CI is failing due to a change in django-main branch, it should be addressed in an other PR. |
295a462 to
70751a5
Compare
auvipy
left a comment
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 saw FAILED tests/test_fields.py::TestISOOutputFormatDurationField::test_outputs
=========== 1 failed,
|
Ok, fixed the test. It was a long lasting double typo (wrong class and wrong format). |
|
we should merge this only in a major release |
|
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. |
|
The fix seems still relevant. |
auvipy
left a comment
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 not sure if this will be accepted or not, but if it is accepted, fixing the merge conflict should be enough
|
Conflict revolved. |
peterthomassen
left a comment
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.
Thanks for resolving the conflict; some more comments here!
Co-authored-by: Bruno Alla <[email protected]>
Co-authored-by: Bruno Alla <[email protected]>
|
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. |
|
Can we have stale flag removed? We still need this @auvipy |
|
I am still waiting to get a response in this thread. I was also thinking of re-creating the branch and the PR to have less noise and a cleaner git history. |
…prove related docs
|
I have updated the code and docs according to latest comments. The validation check for |
peterthomassen
left a comment
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.
sorry, overlooked something.
peterthomassen
left a comment
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.
almost! 🙃
peterthomassen
left a comment
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.
lgtm!
browniebroke
left a comment
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.
Let's keep it as is
|
thanks for the patience! |
DurationField
Description
As explained in #8527 this PR will provide the ability to choose the output format for
DurationFields.Since Python builtim
timedeltaobject does not have any format function we are going to allow only formats which are already defined in Django codebase in the packagedjango.utils.duration:duration_stringduration_iso_string