Custom Allowance Error

So, I had preliminary results with variable darts yesterday, (ETA: using build May 19,) but when I attempted to reload the file today I got this fascinating error:

File exception.

Exception: Content of attribute lineColor does not match its type definition: String content is not listed in the enumeration facet..

Validation error file /media/pneumarian/Janus/Seamly2D/patterns/X-patterns/DartsExperiment.sm2d in line 53 column 123

Here’s line 53: <path id="30" inUse="true" lineColor="Black" lineType="solidLine" lineWeight="1.00" name="dart cover" type="1">

This is the XML for a Mainline custom seam allowance to smooth over the dart gaps.

Here’s the broken file: DartsExperiment.sm2d (12.6 KB)

The .smms is the GOST file.

After a brief search of the file, I changed the “Black” to “black” like the rest of the linetypes, & moved on to a new error:

File exception.

Exception: Content of attribute lineWeight does not match its type definition: String content is not listed in the enumeration facet..

Validation error file /media/pneumarian/Janus/Seamly2D/patterns/X-patterns/DartsExperiment.sm2d in line 53 column 124

Not able to find any clues for this one, I deleted the whole lineWeight="1.00" attribute.

Of course, I had to have two mainline custom seam allowances because I also wanted a trued dart version, (which involved a lot of re-working the formulae. So line 83 had the same errors.

& now I’ve loaded it a couple times & it’s working fine, so I think it’s probably an error in the code for custom seam allowances.

Party on.

:unicorn:

1 Like

Hello this is bug central… how can I help you? :grin:

I dl’ed the broken file and will take a looksee. :nerd_face:

3 Likes

The party is about to end…

Another dumb mistake… all the line attributes come in pairs for use in comboboxes. There’s the (translatable) text you see, and the variant data the text represents. For ex: There’s the text “Deep Pink” where the actual Qt color name is “deepPink”. In this case I used the text and not the data… so it’s throwing an error for “Black” because the schema calls for “black”, and the line weight should be “1” and not “1.00”.

It doesn’t affect the Internal Paths as the code will “get” the proper attributes. Since I did not update the Custom Seam Allowance (yet) it defaults to the (bad) values provided.

Party is over. :disappointed_relieved:

3 Likes