agrc / palletjack

A library for updating AGOL data from various external sources
https://agrc.github.io/palletjack/palletjack/
MIT License
12 stars 0 forks source link

check_srs_match fails when sr object doesn't have 'wkid' value #40

Closed jacobdadams closed 1 year ago

jacobdadams commented 1 year ago
Exception has occurred: AttributeError
'SpatialReference' object has no attribute 'wkid'
KeyError: 'wkid'

when trying to get new_srs in utils.FieldChecker.check_srs_match(). The sr object has a dict that is {'wkid': number} when read directly from featureclass/service. If it is projected, or the geometry is created manually, sometimes the key 'wkid' just becomes 0.