writing an incident flogfile (via foolscap 0.6.0/1) tries to use characters not valid in a Windows filename (':') #1396

Closed
opened 2011-05-06 16:01:22 +00:00 by davidsarah · 6 comments
davidsarah commented 2011-05-06 16:01:22 +00:00
Owner

While reporting the incident in #1395 on a Windows platform, the following error occurred:

[Failure instance: Traceback: <type 'exceptions.IOError'>:
[Errno 22] invalid mode ('wb') or filename:
u'C:\\tahoeclient\\logs\\incidents\\incident-2011-05-05--18:33:34Z-w2qn32q.flog'

The problem (or at least one problem) is that ':' is not valid in a Windows filename. This MSDN article documents the Windows filename validity rules.

Presumably we don't have any test of writing an incident flogfile. This may mean that incident reporting has always been broken on Windows (unless the flogfile naming changed?) A change to flogfile naming in foolscap 0.6.0 apparently caused this bug.

While reporting the incident in #1395 on a Windows platform, the following error occurred: ``` [Failure instance: Traceback: <type 'exceptions.IOError'>: [Errno 22] invalid mode ('wb') or filename: u'C:\\tahoeclient\\logs\\incidents\\incident-2011-05-05--18:33:34Z-w2qn32q.flog' ``` The problem (or at least one problem) is that '`:`' is not valid in a Windows filename. [This MSDN article](http://msdn.microsoft.com/en-us/library/aa365247%28v=vs.85%29.aspx) documents the Windows filename validity rules. Presumably we don't have any test of writing an incident flogfile. ~~This may mean that incident reporting has always been broken on Windows (unless the flogfile naming changed?)~~ A change to flogfile naming in foolscap 0.6.0 apparently caused this bug.
tahoe-lafs added the
code
major
defect
1.8.2
labels 2011-05-06 16:01:22 +00:00
tahoe-lafs added this to the 1.9.0 milestone 2011-05-06 16:01:22 +00:00
davidsarah commented 2011-05-06 16:02:41 +00:00
Author
Owner

(linewrap description for readability)

(linewrap description for readability)
davidsarah commented 2011-05-06 16:14:40 +00:00
Author
Owner

The problem is actually in foolscap, apparently due to the time format here in foolscap/logging/incident.py:

TIME_FORMAT = "%Y-%m-%d--%H:%M:%S"

which is used indirectly by incident_declared to create the filename. Will file a foolscap ticket.

The problem is actually in foolscap, apparently due to the time format [here](http://foolscap.lothar.com/trac/browser/foolscap/logging/incident.py?rev=77d2c68#L59) in `foolscap/logging/incident.py`: ``` TIME_FORMAT = "%Y-%m-%d--%H:%M:%S" ``` which is used indirectly by `incident_declared` to create the filename. Will file a foolscap ticket.
davidsarah commented 2011-05-06 16:20:25 +00:00
Author
Owner
(http://foolscap.lothar.com/trac/ticket/177)
tahoe-lafs changed title from writing an incident flogfile tries to use characters not valid in a Windows filename (':') to writing an incident flogfile (via foolscap 0.6.0/1) tries to use characters not valid in a Windows filename (':') 2011-05-06 16:47:48 +00:00
davidsarah commented 2011-07-28 21:38:53 +00:00
Author
Owner

This is fixed in foolscap trunk, but has not been released.

This is fixed in foolscap trunk, but has not been released.
tahoe-lafs modified the milestone from 1.9.0 to soon (release n/a) 2011-08-14 00:09:01 +00:00
davidsarah commented 2012-03-29 22:57:53 +00:00
Author
Owner

(http://foolscap.lothar.com/trac/ticket/177) was fixed in foolscap 0.6.2, but Tahoe currently only requires foolscap 0.6.1, so can still be affected. This ticket can be closed when the foolscap dependency is increased.

(http://foolscap.lothar.com/trac/ticket/177) was fixed in foolscap 0.6.2, but Tahoe currently only requires foolscap 0.6.1, so can still be affected. This ticket can be closed when the foolscap dependency is increased.
daira commented 2013-08-28 16:36:18 +00:00
Author
Owner

trunk requires foolscap >= 0.6.3 (since [69bd49fc57bf9e6f851c8f68458d6f518d2c8c2e/trunk], which was before the 1.10 release), so this is fixed.

trunk requires foolscap >= 0.6.3 (since [69bd49fc57bf9e6f851c8f68458d6f518d2c8c2e/trunk], which was before the 1.10 release), so this is fixed.
tahoe-lafs added the
fixed
label 2013-08-28 16:36:18 +00:00
tahoe-lafs modified the milestone from soon (release n/a) to 1.10.0 2013-08-28 16:36:18 +00:00
daira closed this issue 2013-08-28 16:36:18 +00:00
Sign in to join this conversation.
No Milestone
No Assignees
1 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Reference: tahoe-lafs/trac-2024-07-25#1396
No description provided.