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

Added format_timedelta and support function english_list. #57

Closed
wants to merge 1 commit into from
Closed

Added format_timedelta and support function english_list. #57

wants to merge 1 commit into from

Conversation

chrisnorman7
Copy link

@chrisnorman7 chrisnorman7 commented Jun 4, 2017

As per issue #48.

@hugovk hugovk added needs localisation Translations need updating needs tests labels Feb 13, 2020
@hugovk hugovk removed the needs localisation Translations need updating label Mar 9, 2020
@eldipa
Copy link
Contributor

eldipa commented Jun 14, 2020

@hugovk do you think that this feature has value for humanize? IMHO I think that it has.
I could do the rebase (or reimplementation) needed if there is interest on this and if @chrisnorman7 is not available (I would give him credit of course)

@chrisnorman7
Copy link
Author

chrisnorman7 commented Jun 15, 2020 via email

@hugovk
Copy link
Collaborator

hugovk commented Jun 25, 2020

Hello, this doesn't need localisation (as the others in time.py also aren't localised), but it does need tests. Thanks!

@@ -166,3 +166,66 @@ def naturaldate(value):
return naturalday(value)


def english_list(
Copy link
Collaborator

Choose a reason for hiding this comment

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

I think this should be an internal function:

Suggested change
def english_list(
def _english_list(

)
if seconds and show_seconds:
fmt.append('%.2f seconds' % seconds)
return english_list(fmt)
Copy link
Collaborator

Choose a reason for hiding this comment

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

Suggested change
return english_list(fmt)
return _english_list(fmt)

@hugovk
Copy link
Collaborator

hugovk commented Jul 28, 2020

This has been superseded by #137. Thanks both!

@hugovk hugovk closed this Jul 28, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants