Ticket #2208 (closed defect: fixed)

Opened 3 years ago

Last modified 2 years ago

time data ... does not match format '%Y-%m-%dT%H:%M:%S'

Reported by: carrott Owned by: alsroot
Priority: Unspecified by Maintainer Milestone: Unspecified by Release Team
Component: journal Version: 0.84.x
Severity: Major Keywords: dextrose
Cc: Distribution/OS:
Bug Status: Unconfirmed

Description

ValueError: time data dbus.ByteArray('1268087339', variant_level=1) does not match format '%Y-%m-%dT%H:%M:%S'
Traceback (most recent call last):
  File "/usr/lib/python2.6/site-packages/jarabe/journal/listmodel.py", line 124, in on_get_value
    return self._cached_row[column]
IndexError: list index out of range

Saw the above in Samoa on os300py on XO-1. I'm not sure what the context was, if a journal backup helps, I can possibly dig one up.

See the attached log file for more context.

Attachments

shell.log2 Download (7.2 KB) - added by carrott 3 years ago.
0001-time-data-.-does-not-match-format-Y-m-dT-H-M-S-2208.patch Download (1.2 KB) - added by alsroot 3 years ago.

Change History

Changed 3 years ago by carrott

  Changed 3 years ago by sascha_silbe

There was a potentially related  thread on sugar-devel recently.

  Changed 3 years ago by carrott

This appears to be related to #2149. I migrated a bunch of laptops from 767 to os300py, and it appears that even with the patch in #2149, migration does not proceed completely successfully.

I think this ticket could be closed as a dupe of #2149.

  Changed 3 years ago by sascha_silbe

  • owner set to tomeu
  • version changed from Unspecified to 0.84.x
  • component changed from untriaged to sugar
  • severity changed from Unspecified to Major

A tarball of the data store (if I don't already have it) and the name or uid of the entry that triggered this bug would be useful as I couldn't reproduce it using the (combined) content of the data stores you sent me. I do get some other errors that we should catch, but not the one about the date format. Maybe I just didn't examine the right entry (by openening the details view).

  Changed 3 years ago by tomeu

  • owner changed from tomeu to alsroot
  • component changed from sugar to sugar-datastore

Guess this got moved to the sugar component by mistake

follow-up: ↓ 6   Changed 3 years ago by sascha_silbe

  • owner changed from alsroot to tomeu
  • component changed from sugar-datastore to sugar

The error message is from sugar and as long as I can't reproduce and diagnose it, that's our best guess as to which component needs to be fixed. Or rather, sugar should be fixed in any case, even if it turns out we're doing something wrong during migration. Invalid metadata should be handled gracefully, not break the Journal.

in reply to: ↑ 5 ; follow-up: ↓ 8   Changed 3 years ago by tomeu

  • owner changed from tomeu to alsroot
  • component changed from sugar to journal

Replying to sascha_silbe:

The error message is from sugar and as long as I can't reproduce and diagnose it, that's our best guess as to which component needs to be fixed. Or rather, sugar should be fixed in any case, even if it turns out we're doing something wrong during migration. Invalid metadata should be handled gracefully, not break the Journal.

In any case, it would be journal, though I don't fully understand why we have only one ticket and not two if the idea is that something is wrong in the DS *and* we want the journal to be more tolerant to bad data coming from the DS.

  Changed 3 years ago by alsroot

  • keywords r? added

I've checked ds and sugar sources, except attached patch there are no other not-try-excepted time.strptime calls.

in reply to: ↑ 6   Changed 3 years ago by sascha_silbe

Replying to tomeu:

In any case, it would be journal,

Good point. I only thought about the git repo it lives in, but you're right there's a separate component in Trac for this part of the code.

though I don't fully understand why we have only one ticket and not two if the idea is that something is wrong in the DS *and* we want the journal to be more tolerant to bad data coming from the DS.

Because we don't know yet if the data store is to blame. It could very well have been an activity that wrote the invalid mtime property, in which case there probably is nothing else to fix (because it most likely was an ancient version and has long been fixed)..

Replying to alsroot:

I've checked ds and sugar sources, except attached patch there are no other not-try-excepted time.strptime calls.

I would replace the %s with %r so any special characters get escaped and the string gets quoted, but other than that the patch looks obviously fine (haven't tested it).

  Changed 2 years ago by sascha_silbe

  • keywords r? removed
  • status changed from new to closed
  • distribution Fedora deleted
  • resolution set to fixed

Fixed in 0.92 by  923a7fc ( 760deeb for 0.90).

Note: See TracTickets for help on using tickets.