Problem loading importing contest dump from v1.3.2 into v1.4rc1

22 views
Skip to first unread message

Madhavan Mukund

unread,
Feb 28, 2019, 1:00:30 AM2/28/19
to Stefano Maggiolo, Luca Wehrstedt, contestm...@googlegroups.com
I get this error both from DumpUpdater and DumpImporter:

2019-02-28 11:20:42,531 - CRITICAL [<unknown>] The dump contains an instance of Testcase whose codename field contains an invalid codename: `'.

Is there a simple way to find and fix the problem in the current dump?
Alternatively, what should I do to re-export it from 1.3.2 in a format
that can be updated ?

--Madhavan

P.S. The data model of the dump is 25. The current data model is 39.

2019-02-28 11:20:42,444 - WARNING [<unknown>] The dump you're trying to import has been created by an old version of CMS (it declares data model version 25). It may take a while to adapt it to the current data model (which is version 39). You can use cmsDumpUpdater to update the on-disk dump and speed up future imports.


signature.asc

Stefano Maggiolo

unread,
Feb 28, 2019, 4:12:05 AM2/28/19
to Madhavan Mukund, Luca Wehrstedt, contestm...@googlegroups.com
No, we don't have an automated way of fixing it - it seems surprising that we even allowed empty codenames...

What you need to do is to go over the json in the dump and change all codenames to valid ones. This might be as easy as to use a search and replace, but I'm not sure at this point if you might have more than one testcase on the same dataset with empty codename, in which case you probably want to change to different ones.

I don't think they're referenced anywhere else so you can just replace all occurrences of `"codename": ""`.

Madhavan Mukund

unread,
Feb 28, 2019, 7:52:52 AM2/28/19
to Stefano Maggiolo, Luca Wehrstedt, contestm...@googlegroups.com
Thanks, I'll try that.
signature.asc

Madhavan Mukund

unread,
Feb 28, 2019, 8:49:27 AM2/28/19
to Stefano Maggiolo, Luca Wehrstedt, contestm...@googlegroups.com
There was only one empty "codename". Just setting it to a nonempty
value was not enough. I had to make the corresponding change to the
key under the dataset entry. Now it is importing the dump without a
problem.

--Madhavan
signature.asc
Reply all
Reply to author
Forward
0 new messages