On 23/11/2010 12:59, Michael McAndrew wrote:
Thanks for the pointers, Mathew.
Matthew :-)
Guess I just needed confirmation that it was a bug and not something
stupid I was doing - hard for me to make that call being unfamiliar
with the data and code
The instructions are meant to be followable, so anything cropping up is
presumably a bug :)
assuming this can be fixed with
ons_code = feat['CODE'].value if not
feat['CODE'].value.startswith('999999') else None
on line 47.
Ah. You're using the most recent Boundary-Line, which has the new ONS
GSS 9-digit codes in it, rather than the old variable-digit ones used
previously. mapit doesn't know anything about them yet, so I'm afraid
there will almost certainly be other issues trying to import this (we
haven't got around to importing it ourselves yet). For example, the code
uses the old ONS codes to decide what country some things are in, which
will no longer work (it's much easier with the new codes, it's just the
first letter IIRC, but still, it currently doesn't handle them).
If you're just loading this one alone it won't really matter, but it
should really import the new ONS codes as type 'gss' rather than 'ons' -
we will have to do that to maintain the old codes and new ones in
parallel, along with a giant lookup table to match the old codes to the
new ones.
That check should just be for '999999' and '999999999', I'm guessing
it'll never be anything else.
ATB,
Matthew
_______________________________________________
Mailing list [email protected]
Archive, settings, or unsubscribe:
https://secure.mysociety.org/admin/lists/mailman/listinfo/developers-public