Importing mbox files into hyperkitty since date
![](https://secure.gravatar.com/avatar/d1c9129d47811254fac68d8561c9a50c.jpg?s=120&d=mm&r=g)
What is the syntax for the data in the --since argument to hyperkitty_import>
--since SINCE
SINCE is not very informative. :-)
Guessing, using '1/1/1970' does not seem to achieve anything, and gives no error.
![](https://secure.gravatar.com/avatar/d1c9129d47811254fac68d8561c9a50c.jpg?s=120&d=mm&r=g)
Well, reading the hyperkitty command source code, looks like it uses dateutil.parser, which shoudl read pretty much any date format (?).
This is what happens:
$ django-admin hyperkitty_import -v 2 -l jackrail@list.jackrail.org --since "2010-01-01 00:00Z" /tmp/jackrail@list.jackrail.org-2019-07.mbox
CommandError: No such file: 00:00Z
Regardless of whether Z for UTC is present or not.
![](https://secure.gravatar.com/avatar/d1c9129d47811254fac68d8561c9a50c.jpg?s=120&d=mm&r=g)
Alrighty. It only accepts the YYYY-MM-DD. Not HH:MM or TZ.
I'd submit that as a bit of feedback to the developer.
Andrew
![](https://secure.gravatar.com/avatar/56f108518d7ee2544412cc80978e3182.jpg?s=120&d=mm&r=g)
On 6/20/19 3:08 AM, andrew.bernard@gmail.com wrote:
Well, reading the hyperkitty command source code, looks like it uses dateutil.parser, which shoudl read pretty much any date format (?).
This is what happens:
$ django-admin hyperkitty_import -v 2 -l jackrail@list.jackrail.org --since "2010-01-01 00:00Z" /tmp/jackrail@list.jackrail.org-2019-07.mbox
CommandError: No such file: 00:00Z
This appears to be a bug in Django's BaseCommand class which somehow separates '--since "2010-01-01 00:00Z"' into '--since 2010-01-01' and '00:00Z' despite the quotes.
As a workaround, you can use '--since "2010-01-01/00:00Z"' which doesn't contain the problematic whitespace and which is acceptable to dateutil.parser.parse().
-- Mark Sapiro <mark@msapiro.net> The highway is for gamblers, San Francisco Bay Area, California better use your sense - B. Dylan
participants (2)
-
andrew.bernard@gmail.com
-
Mark Sapiro