Strf time formatting doesn't work on MS windows

Bug #1096489 reported by ijk
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
GTimeLog
Fix Released
Undecided
Unassigned

Bug Description

Lines like
> week = self.window.min_timestamp.strftime('%V')

fail on windows because %V isn't supported.
Replacing %V with %U everywhere in main.py fixes it.

Related branches

Revision history for this message
ijk (ijk) wrote :

Actually it doesn't fix it.
week = self.window.min_timestamp.isocalendar()[1] works but returns an integer (no leading 0)

Revision history for this message
Marius Gedminas (mgedmin) wrote :

This is curious: I thought strftime was implemented in directly in Python, in recent versions, and so should work the same on all platforms?

What Python version do you have?

Revision history for this message
Marius Gedminas (mgedmin) wrote :

Never mind, I misremembered something I'd read about strptime.

Changed in gtimelog:
status: New → Fix Committed
Changed in gtimelog:
milestone: none → 0.8.1
Changed in gtimelog:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.