nasa / MCT-Plugins

35 stars 29 forks source link

[Data] Dictionary import sometimes fails #166

Open VWoeltjen opened 10 years ago

VWoeltjen commented 10 years ago

In Data plugin, Import > Dictionary does not behave as expected:

Desired behavior is that Data Taxonomy (re)populates as necessary when dictionary is imported, and that the resulting objects may be placed in collections to support display-building.

VWoeltjen commented 10 years ago

I've taken a quick look at this - at least part of the problem seems to be that persistence is failing due to encountering duplicates (that is, an exception is being hit in the persist(components) call) in component ids, either from prior imports or within the current import.

Commit with some changes to work around this is at: https://github.com/VWoeltjen/MCT-Plugins/commit/15cb6552e444c22a4b450728cd5d64ba1ae5eead

The above appears to fix the second and third bullets from the original issue; not clear to me why Data Taxonomy still appears empty in the tree.

JieD commented 10 years ago

I did very minor changes. But I couldn’t reproduce the problem stated in the first bullet.

VWoeltjen commented 10 years ago

These are the steps I recall reproducing the problem from the first bullet:

It may be the case that the CSV file used must contain duplicates for this issue to occur.

VWoeltjen commented 10 years ago

Note that first bullet seems to need a large data dictionary (e.g. 20000+ lines) to be reproducible