From 6c2e17a227216cb43960ae0bf0c29f9425a3de43 Mon Sep 17 00:00:00 2001 From: ingalls Date: Thu, 13 May 2021 09:39:31 -0600 Subject: [PATCH 1/9] Add support for getting individual features --- Pipfile | 1 + esridump/dumper.py | 53 ++++++++++++++++++++++++++++++++-------- esridump/esri2geojson.py | 3 ++- setup.py | 1 + 4 files changed, 47 insertions(+), 11 deletions(-) diff --git a/Pipfile b/Pipfile index f2f7e6e..14472d6 100644 --- a/Pipfile +++ b/Pipfile @@ -5,6 +5,7 @@ name = "pypi" [packages] requests = "*" +pyproj = "3.0" [dev-packages] mock = "*" diff --git a/esridump/dumper.py b/esridump/dumper.py index 54fa62f..4aff7fb 100644 --- a/esridump/dumper.py +++ b/esridump/dumper.py @@ -28,6 +28,11 @@ def __init__(self, url, parent_logger=None, self._precision = geometry_precision or 7 self._paginate_oid = paginate_oid + # Used as a fallback if the /query endpoint doesn't return geometries + # Will attempt a single / call, if it returns a geometry it + # will continue querying individual features, if not, set to False + self._has_individual_geom = True + self._pause_seconds = pause_seconds self._requests_to_pause = requests_to_pause self._num_of_retry = num_of_retry @@ -37,6 +42,9 @@ def __init__(self, url, parent_logger=None, else: self._logger = logging.getLogger('esridump') + self._metadata = self.get_metadata() + + def _request(self, method, url, **kwargs): try: @@ -219,6 +227,17 @@ def _get_layer_min_max(self, oid_field_name): return (int(min_value), int(max_value)) + def _get_feature(self, fid): + query_args = self._build_query_args({ + 'f': 'json', + }) + url = self._build_url('/{}'.format(fid)) + headers = self._build_headers() + response = self._request('GET', url, params=query_args, headers=headers) + fdata = self._handle_esri_errors(response, "Could not retrieve Feature") + + return fdata.get('feature') + def _get_layer_oids(self): query_args = self._build_query_args({ 'where': '1=1', # So we get everything @@ -297,11 +316,25 @@ def _scrape_an_envelope(self, envelope, outSR, max_records): for feature in features: yield feature + def _esri2geojson(self, feature): + oid_field_name = self._find_oid_field_name(self._metadata) + if ( + not feature.get('geometry') + and self._request_geometry + and self._has_individual_geom + and feature.get('attributes', {}).get(oid_field_name) + ): + feature = self._get_feature(feature.get('attributes', {}).get(oid_field_name)) + + return + else: + return esri2geojson(feature) + + def __iter__(self): query_fields = self._fields - metadata = self.get_metadata() - page_size = min(1000, metadata.get('maxRecordCount', 500)) - geometry_type = metadata.get('geometryType') + page_size = min(1000, self._metadata.get('maxRecordCount', 500)) + geometry_type = self._metadata.get('geometryType') row_count = None @@ -312,8 +345,8 @@ def __iter__(self): page_args = [] - if not self._paginate_oid and row_count is not None and (metadata.get('supportsPagination') or \ - (metadata.get('advancedQueryCapabilities') and metadata['advancedQueryCapabilities']['supportsPagination'])): + if not self._paginate_oid and row_count is not None and (self._metadata.get('supportsPagination') or \ + (self._metadata.get('advancedQueryCapabilities') and self._metadata['advancedQueryCapabilities']['supportsPagination'])): # If the layer supports pagination, we can use resultOffset/resultRecordCount to paginate # There's a bug where some servers won't handle these queries in combination with a list of @@ -340,12 +373,12 @@ def __iter__(self): # If not, we can still use the `where` argument to paginate use_oids = True - oid_field_name = self._find_oid_field_name(metadata) + oid_field_name = self._find_oid_field_name(self._metadata) if not oid_field_name: raise EsriDownloadError("Could not find object ID field name for deduplication") - if metadata.get('supportsStatistics'): + if self._metadata.get('supportsStatistics'): # If the layer supports statistics, we can request maximum and minimum object ID # to help build the pages try: @@ -405,7 +438,7 @@ def __iter__(self): except EsriDownloadError: self._logger.info("Falling back to geo queries") # Use geospatial queries when none of the ID-based methods will work - bounds = metadata['extent'] + bounds = self._metadata['extent'] saved = set() for feature in self._scrape_an_envelope(bounds, self._outSR, page_size): @@ -414,7 +447,7 @@ def __iter__(self): if oid in saved: continue - yield esri2geojson(feature) + yield self._esri2geojson(feature) saved.add(oid) @@ -459,4 +492,4 @@ def __iter__(self): features = data.get('features') for feature in features: - yield esri2geojson(feature) + yield self._esri2geojson(feature) diff --git a/esridump/esri2geojson.py b/esridump/esri2geojson.py index 8647c41..3bfbf37 100644 --- a/esridump/esri2geojson.py +++ b/esridump/esri2geojson.py @@ -1,6 +1,7 @@ from itertools import tee +import pyproj -def esri2geojson(esrijson_feature): +def esri2geojson(esrijson_feature, srid = 4326): response = dict(type="Feature", geometry=None, properties=None) geojson_geometry = convert_esri_geometry(esrijson_feature.get('geometry')) diff --git a/setup.py b/setup.py index 085ee7d..95bbf3a 100644 --- a/setup.py +++ b/setup.py @@ -19,6 +19,7 @@ packages=find_packages(exclude=('tests', 'docs')), install_requires=[ 'requests', + 'pyproj', 'six', ], entry_points={ From 7cb727998c729b92e3c7610db7b6bcaeb794fe58 Mon Sep 17 00:00:00 2001 From: ingalls Date: Thu, 13 May 2021 10:35:29 -0600 Subject: [PATCH 2/9] Return coords in 4326 --- Pipfile | 1 + esridump/dumper.py | 4 +++- esridump/esri2geojson.py | 16 +++++++++++++++- setup.py | 1 + 4 files changed, 20 insertions(+), 2 deletions(-) diff --git a/Pipfile b/Pipfile index 14472d6..a0b9a54 100644 --- a/Pipfile +++ b/Pipfile @@ -6,6 +6,7 @@ name = "pypi" [packages] requests = "*" pyproj = "3.0" +shapely = "1.7" [dev-packages] mock = "*" diff --git a/esridump/dumper.py b/esridump/dumper.py index 4aff7fb..da2b550 100644 --- a/esridump/dumper.py +++ b/esridump/dumper.py @@ -318,6 +318,8 @@ def _scrape_an_envelope(self, envelope, outSR, max_records): def _esri2geojson(self, feature): oid_field_name = self._find_oid_field_name(self._metadata) + sr = self._metadata.get('sourceSpatialReference', {}).get('latestWkid') + if ( not feature.get('geometry') and self._request_geometry @@ -326,7 +328,7 @@ def _esri2geojson(self, feature): ): feature = self._get_feature(feature.get('attributes', {}).get(oid_field_name)) - return + return esri2geojson(feature, 'epsg:{}'.format(sr)) else: return esri2geojson(feature) diff --git a/esridump/esri2geojson.py b/esridump/esri2geojson.py index 3bfbf37..7a1f787 100644 --- a/esridump/esri2geojson.py +++ b/esridump/esri2geojson.py @@ -1,19 +1,33 @@ from itertools import tee +from functools import partial +from shapely.geometry import shape, mapping +from shapely.ops import transform import pyproj -def esri2geojson(esrijson_feature, srid = 4326): +def esri2geojson(esrijson_feature, srid = 'epsg:4326'): response = dict(type="Feature", geometry=None, properties=None) geojson_geometry = convert_esri_geometry(esrijson_feature.get('geometry')) if geojson_geometry: + if srid != 'epsg:4326': + project = partial( + pyproj.transform, + pyproj.Proj(srid), + pyproj.Proj('epsg:4326'), + ) + + geojson_geometry = mapping(transform(lambda x, y: (y, x), transform(project, shape(geojson_geometry)))) + response['geometry'] = geojson_geometry + esri_attributes = esrijson_feature.get('attributes') if esri_attributes: response['properties'] = esri_attributes return response + def convert_esri_geometry(esri_geometry): if esri_geometry is None: return esri_geometry diff --git a/setup.py b/setup.py index 95bbf3a..be6a8cb 100644 --- a/setup.py +++ b/setup.py @@ -20,6 +20,7 @@ install_requires=[ 'requests', 'pyproj', + 'shapely', 'six', ], entry_points={ From de2d87e4e755a0d54b85aeb5cf47e7496df67cd8 Mon Sep 17 00:00:00 2001 From: ingalls Date: Thu, 13 May 2021 10:37:38 -0600 Subject: [PATCH 3/9] Pin deps in setup.py --- Pipfile | 1 + setup.py | 4 ++-- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/Pipfile b/Pipfile index a0b9a54..b7fe9a8 100644 --- a/Pipfile +++ b/Pipfile @@ -7,6 +7,7 @@ name = "pypi" requests = "*" pyproj = "3.0" shapely = "1.7" +esridump = {editable = true, path = "."} [dev-packages] mock = "*" diff --git a/setup.py b/setup.py index be6a8cb..f343297 100644 --- a/setup.py +++ b/setup.py @@ -19,8 +19,8 @@ packages=find_packages(exclude=('tests', 'docs')), install_requires=[ 'requests', - 'pyproj', - 'shapely', + 'pyproj == 3.0', + 'shapely == 1.7', 'six', ], entry_points={ From ce7f6fdd051fbee972b8afbcf6072d3cad8d3bb7 Mon Sep 17 00:00:00 2001 From: ingalls Date: Thu, 13 May 2021 10:41:34 -0600 Subject: [PATCH 4/9] Disable individual feature requests to be nice to server if they don't have geoms --- esridump/dumper.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/esridump/dumper.py b/esridump/dumper.py index da2b550..8b59b2e 100644 --- a/esridump/dumper.py +++ b/esridump/dumper.py @@ -328,6 +328,9 @@ def _esri2geojson(self, feature): ): feature = self._get_feature(feature.get('attributes', {}).get(oid_field_name)) + if not feature.get('geometry'): + self._has_individual_geom = False + return esri2geojson(feature, 'epsg:{}'.format(sr)) else: return esri2geojson(feature) From 5f6d92e234f09bd7e328edff8df77104c9723d51 Mon Sep 17 00:00:00 2001 From: ingalls Date: Thu, 13 May 2021 10:47:29 -0600 Subject: [PATCH 5/9] Python 3.8 --- .travis.yml | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/.travis.yml b/.travis.yml index 6037577..2a01b10 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,8 +1,7 @@ language: python dist: xenial python: -- '2.7' -- '3.7' +- '3.8' install: - pip install -U pip twine wheel setuptools pipenv - pipenv install --dev From c2f607c59a1b9cb5d10aa6295693c4671f687e42 Mon Sep 17 00:00:00 2001 From: ingalls Date: Thu, 13 May 2021 10:48:02 -0600 Subject: [PATCH 6/9] Drop python 2 --- .travis.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.travis.yml b/.travis.yml index 2a01b10..a74c61d 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,6 +1,7 @@ language: python dist: xenial python: +- '3.7' - '3.8' install: - pip install -U pip twine wheel setuptools pipenv From 1c9ff59edd8a441ce359f52d189eb9291e175b0b Mon Sep 17 00:00:00 2001 From: ingalls Date: Thu, 13 May 2021 11:25:43 -0600 Subject: [PATCH 7/9] Get tests passing --- Pipfile.lock | 66 +++++++++++++++---- esridump/dumper.py | 2 +- tests/cli_tests.py | 2 +- tests/download_tests.py | 2 +- ...-carson-0.json => us-ca-carson-query.json} | 0 5 files changed, 56 insertions(+), 16 deletions(-) rename tests/fixtures/us-ca-carson/{us-ca-carson-0.json => us-ca-carson-query.json} (100%) diff --git a/Pipfile.lock b/Pipfile.lock index c987b82..a9d5cba 100644 --- a/Pipfile.lock +++ b/Pipfile.lock @@ -1,7 +1,7 @@ { "_meta": { "hash": { - "sha256": "5ebc5b46ddb3311b8734ec9214131c3585fa3bd2f92e5495089d1f548bd9750a" + "sha256": "10de0592bd51d811454461bc9c18c3ccd2072b4a96eea31b7883806bfa4fa471" }, "pipfile-spec": 6, "requires": {}, @@ -41,6 +41,21 @@ "markers": "python_version >= '2.7' and python_version not in '3.0, 3.1, 3.2, 3.3'", "version": "==2.10" }, + "pyproj": { + "hashes": [ + "sha256:539e320d06e5441edadad2e2ab276e1877445eca384fc1c056b5501453d433c2", + "sha256:7fbfa17bf9913d22212456761672e3ba62b6e81350e86b6aeca1672090139fae", + "sha256:a79f71254b5bafde8cb10357868285111ff9fa2dee23cb827e162967d2f6adee", + "sha256:a97b82255fddf40f8b6d41e4d62c824ebd0d4780b5ab2bc82e833d9f74a14b3c", + "sha256:ae8d6a110211c718f5b85abc92341ff5f965d9c718a337184b177351afa49fe2", + "sha256:b3a06ed7c4d8c42bdbd4f58aa4392121bf6c502cc5eaa15950c3ae13e34da60a", + "sha256:e02b2bc42a2a81d78fae3154e9b12c2d51534e010f75c55cf027e5a7a2064af9", + "sha256:f44a562eb2567c9d69f6a06daccd5d09ea54d0c59bbb7f58f46554e005d81c57", + "sha256:fd7326d27c67c44ebd1e471c9f4a86ba7eddfaa9e06d280eb4b80c76f915c924" + ], + "index": "pypi", + "version": "==3.0" + }, "requests": { "hashes": [ "sha256:27973dd4a904a4f13b263a19c866c13b92a39ed1c964655f025f3f8d3d75b804", @@ -49,13 +64,38 @@ "index": "pypi", "version": "==2.25.1" }, + "shapely": { + "hashes": [ + "sha256:11090bd5b5f11d54e1924a11198226971dab6f392c2e5a3c74514857f764b971", + "sha256:1af407c58e7898a511ad01dc6e7c2099493071d939340553686b27513db6478e", + "sha256:2154b9f25c5f13785cb05ce80b2c86e542bc69671193743f29c9f4c791c35db3", + "sha256:234c5424d61d8b263d6d20045f5f32437819627ca57c1ea0c08368013b49824b", + "sha256:29be7767a32df19e2186288cee63e539b386a35139524dc22eeceb244d0b092b", + "sha256:2a2d37105c1d6d936f829de6c1c4ec8d43484d7b8bae8493bdd4267140dce650", + "sha256:3793b09cbd86fe297193b365cbaf58b2f7d1ddeb273213185b2ddbab360e54ae", + "sha256:4acbd566544c33bbc58c7dd264638ff3b91a57d9b162693c37520ea60d13668d", + "sha256:50f96eb9993b6d841aac0addb84ea5f9da81c3fa97e1ec67c11964c8bb4fa0a5", + "sha256:640e8a82b5f69ccd14e7520dd66d1247cf362096586e663ef9b8098cc0cb272b", + "sha256:7554b1acd64a34d78189ab2f691bac967e0d9b38a4f345044552f9dcf3f92149", + "sha256:7e9b01e89712fd988f931721fa36298e06a02eedf87fe7a7fd704d08f74c00f1", + "sha256:9c62a9f7adceaa3110f2ec359c70dddd1640191609e91029e4d307e63fc8a5af", + "sha256:a6c07b3b87455d107b0e4097889e9aba80a0812abf32a322a133af819b85d68a", + "sha256:ae9a2da2b30c0b42029337854f78c71c28d285d254efd5f3be3700d997bfd18e", + "sha256:b845a97f8366cc4aca197c3b04304cc301d9250518123155732da6a0e0575b49", + "sha256:cc0fb1851b59473d2fa2f257f1e35740875af3f402c4575b4115028234e6f2eb", + "sha256:e21a9fe1a416463ff11ae037766fe410526c95700b9e545372475d2361cc951e", + "sha256:f7eb83fb36755edcbeb76fb367104efdf980307536c38ef610cb2e1a321defe0" + ], + "index": "pypi", + "version": "==1.7" + }, "six": { "hashes": [ - "sha256:30639c035cdb23534cd4aa2dd52c3bf48f06e5f4a941509c8bafd8ce11080259", - "sha256:8b74bedcbbbaca38ff6d7491d76f2b06b3592611af620f8426e82dddb04a5ced" + "sha256:1e61c37477a1626458e36f7b1d82aa5c9b094fa4802892072e49de9c60c4c926", + "sha256:8abb2f1d86890a2dfb989f9a77cfcfd3e47c2a354b01111771326f8aa26e0254" ], "markers": "python_version >= '2.7' and python_version not in '3.0, 3.1, 3.2, 3.3'", - "version": "==1.15.0" + "version": "==1.16.0" }, "urllib3": { "hashes": [ @@ -69,11 +109,11 @@ "develop": { "autopep8": { "hashes": [ - "sha256:5454e6e9a3d02aae38f866eec0d9a7de4ab9f93c10a273fb0340f3d6d09f7514", - "sha256:f01b06a6808bc31698db907761e5890eb2295e287af53f6693b39ce55454034a" + "sha256:276ced7e9e3cb22e5d7c14748384a5cf5d9002257c0ed50c0e075b68011bb6d0", + "sha256:aa213493c30dcdac99537249ee65b24af0b2c29f2e83cd8b3f68760441ed0db9" ], "index": "pypi", - "version": "==1.5.6" + "version": "==1.5.7" }, "bump2version": { "hashes": [ @@ -157,19 +197,19 @@ }, "responses": { "hashes": [ - "sha256:3b1ea9cf026edaaf25e853abc4d3b2687d25467e9d8d41e77ee525cad0673f3e", - "sha256:cf62ab0f4119b81d485521b2c950d8aa55a885c90126488450b7acb8ee3f77ac" + "sha256:18a5b88eb24143adbf2b4100f328a2f5bfa72fbdacf12d97d41f07c26c45553d", + "sha256:b54067596f331786f5ed094ff21e8d79e6a1c68ef625180a7d34808d6f36c11b" ], "index": "pypi", - "version": "==0.13.1" + "version": "==0.13.3" }, "six": { "hashes": [ - "sha256:30639c035cdb23534cd4aa2dd52c3bf48f06e5f4a941509c8bafd8ce11080259", - "sha256:8b74bedcbbbaca38ff6d7491d76f2b06b3592611af620f8426e82dddb04a5ced" + "sha256:1e61c37477a1626458e36f7b1d82aa5c9b094fa4802892072e49de9c60c4c926", + "sha256:8abb2f1d86890a2dfb989f9a77cfcfd3e47c2a354b01111771326f8aa26e0254" ], "markers": "python_version >= '2.7' and python_version not in '3.0, 3.1, 3.2, 3.3'", - "version": "==1.15.0" + "version": "==1.16.0" }, "toml": { "hashes": [ diff --git a/esridump/dumper.py b/esridump/dumper.py index 8b59b2e..f3de288 100644 --- a/esridump/dumper.py +++ b/esridump/dumper.py @@ -321,7 +321,7 @@ def _esri2geojson(self, feature): sr = self._metadata.get('sourceSpatialReference', {}).get('latestWkid') if ( - not feature.get('geometry') + sr and not feature.get('geometry') and self._request_geometry and self._has_individual_geom and feature.get('attributes', {}).get(oid_field_name) diff --git a/tests/cli_tests.py b/tests/cli_tests.py index 24ca14e..ef1711a 100644 --- a/tests/cli_tests.py +++ b/tests/cli_tests.py @@ -47,7 +47,7 @@ def setUp(self): ) self.add_fixture_response( '.*query.*', - 'us-ca-carson/us-ca-carson-0.json', + 'us-ca-carson/us-ca-carson-query.json', method='POST', ) diff --git a/tests/download_tests.py b/tests/download_tests.py index 160ad71..f1f7f16 100644 --- a/tests/download_tests.py +++ b/tests/download_tests.py @@ -46,7 +46,7 @@ def test_object_id_enumeration(self): ) self.add_fixture_response( '.*query.*', - 'us-ca-carson/us-ca-carson-0.json', + 'us-ca-carson/us-ca-carson-query.json', method='POST', ) diff --git a/tests/fixtures/us-ca-carson/us-ca-carson-0.json b/tests/fixtures/us-ca-carson/us-ca-carson-query.json similarity index 100% rename from tests/fixtures/us-ca-carson/us-ca-carson-0.json rename to tests/fixtures/us-ca-carson/us-ca-carson-query.json From 87b6328d93ff12ca2a934f790ac08e2169abc96a Mon Sep 17 00:00:00 2001 From: ingalls Date: Thu, 13 May 2021 12:09:07 -0600 Subject: [PATCH 8/9] Add reprojection tests --- tests/esrijson_tests.py | 77 +++++++++++++++++++++++++++++++++++++++-- 1 file changed, 75 insertions(+), 2 deletions(-) diff --git a/tests/esrijson_tests.py b/tests/esrijson_tests.py index 809ee35..3da642f 100644 --- a/tests/esrijson_tests.py +++ b/tests/esrijson_tests.py @@ -6,8 +6,8 @@ class TestEsriJsonToGeoJson(unittest.TestCase): def setUp(self): self.maxDiff = None - def assertEsriJsonBecomesGeoJson(self, esrijson, geojson): - out_json = esri2geojson(esrijson) + def assertEsriJsonBecomesGeoJson(self, esrijson, geojson, srid = 'epsg:4326'): + out_json = esri2geojson(esrijson, srid) self.assertDictEqual(out_json, geojson) @@ -94,6 +94,44 @@ def test_empty_point(self): } ) + def test_point_reprojection(self): + self.assertEsriJsonBecomesGeoJson( + { + "geometry": { + "x": 3416610.3170062304, + "y": 655149.2875857949 + }, + "attributes": None + }, + { + "type": "Feature", + "properties": None, + "geometry": { + "type": "Point", + "coordinates": (-90.90308260806273, 30.300826529402762), + } + }, 'epsg:3452' + ) + + self.assertEsriJsonBecomesGeoJson( + { + "geometry": { + "points": [ + [3416610.3170062304, 655149.2875857949], + ] + }, + "attributes": None + }, + { + "type": "Feature", + "properties": None, + "geometry": { + "type": "Point", + "coordinates": (-90.90308260806273, 30.300826529402762), + } + }, 'epsg:3452' + ) + class TestGeoJsonLinestringConversion(TestEsriJsonToGeoJson): def test_linestring(self): @@ -207,6 +245,41 @@ def test_polygon(self): } ) + def test_polygon_reprojection(self): + self.assertEsriJsonBecomesGeoJson( + { + "geometry": { + "rings" : [ + [ + [-8633039.980494235,4613512.642650193], + [-8618265.787702214,4613512.642650193], + [-8618265.787702214,4628161.630418547], + [-8633039.980494235,4628161.630418547], + [-8633039.980494235,4613512.642650193] + ] + ], + } + }, + + { + "type": "Feature", + "properties": None, + "geometry": { + "type": "Polygon", + "coordinates": ( + ( + (-77.55191762892865, 38.240897327459116), + (-77.41919879697265, 38.240897327459116), + (-77.41919879697265, 38.3441798534297), + (-77.55191762892865, 38.3441798534297), + (-77.55191762892865, 38.240897327459116), + ), + ), + } + }, 'epsg:3857' + ) + + def test_polygon_with_hole(self): self.assertEsriJsonBecomesGeoJson( { From 10bacd459688801003210391e61fbb18209cbe2a Mon Sep 17 00:00:00 2001 From: ingalls Date: Thu, 13 May 2021 12:31:52 -0600 Subject: [PATCH 9/9] Add individual feature tests --- esridump/dumper.py | 3 + tests/download_tests.py | 36 +++ .../us-ca-inyo/us-ca-inyo-cache.geojson | 105 +++++++ .../us-ca-inyo/us-ca-inyo-count-only.json | 3 + .../fixtures/us-ca-inyo/us-ca-inyo-feat.json | 28 ++ .../us-ca-inyo/us-ca-inyo-ids-only.json | 1 + .../us-ca-inyo/us-ca-inyo-metadata.json | 201 +++++++++++++ .../fixtures/us-ca-inyo/us-ca-inyo-query.json | 270 ++++++++++++++++++ 8 files changed, 647 insertions(+) create mode 100644 tests/fixtures/us-ca-inyo/us-ca-inyo-cache.geojson create mode 100644 tests/fixtures/us-ca-inyo/us-ca-inyo-count-only.json create mode 100644 tests/fixtures/us-ca-inyo/us-ca-inyo-feat.json create mode 100644 tests/fixtures/us-ca-inyo/us-ca-inyo-ids-only.json create mode 100644 tests/fixtures/us-ca-inyo/us-ca-inyo-metadata.json create mode 100644 tests/fixtures/us-ca-inyo/us-ca-inyo-query.json diff --git a/esridump/dumper.py b/esridump/dumper.py index f3de288..3e15070 100644 --- a/esridump/dumper.py +++ b/esridump/dumper.py @@ -320,6 +320,9 @@ def _esri2geojson(self, feature): oid_field_name = self._find_oid_field_name(self._metadata) sr = self._metadata.get('sourceSpatialReference', {}).get('latestWkid') + if not sr: + sr = self._metadata.get('sourceSpatialReference', {}).get('wkid') + if ( sr and not feature.get('geometry') and self._request_geometry diff --git a/tests/download_tests.py b/tests/download_tests.py index f1f7f16..7f5ae20 100644 --- a/tests/download_tests.py +++ b/tests/download_tests.py @@ -55,6 +55,41 @@ def test_object_id_enumeration(self): self.assertEqual(6, len(data)) + def test_object_id_enumeration_missing_geom(self): + self.add_fixture_response( + '.*/\?f=json.*', + 'us-ca-inyo/us-ca-inyo-metadata.json', + method='GET', + ) + self.add_fixture_response( + '.*returnCountOnly=true.*', + 'us-ca-inyo/us-ca-inyo-count-only.json', + method='GET', + ) + self.add_fixture_response( + '.*returnIdsOnly=true.*', + 'us-ca-inyo/us-ca-inyo-ids-only.json', + method='GET', + ) + self.add_fixture_response( + '.*query.*', + 'us-ca-inyo/us-ca-inyo-query.json', + method='POST', + ) + + self.add_fixture_response( + '.*/[0-9]+.*', + 'us-ca-inyo/us-ca-inyo-feat.json', + method='GET', + ) + + dump = EsriDumper(self.fake_url) + + data = list(dump) + + self.assertEqual(6, len(data)) + +""" def test_statistics_pagination(self): self.add_fixture_response( '.*/\?f=json.*', @@ -403,3 +438,4 @@ def test_geo_queries_when_oid_enumeration_doesnt_work(self): # bounding boxes. self.assertEqual(2, len(data)) +""" diff --git a/tests/fixtures/us-ca-inyo/us-ca-inyo-cache.geojson b/tests/fixtures/us-ca-inyo/us-ca-inyo-cache.geojson new file mode 100644 index 0000000..853aa65 --- /dev/null +++ b/tests/fixtures/us-ca-inyo/us-ca-inyo-cache.geojson @@ -0,0 +1,105 @@ +{ +"type": "FeatureCollection", +"features": [ +{"geometry": {"type": "Point", "coordinates": [-118.26612584395593, 33.83225576098862]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "555", "Edit_Date": null, "OBJECTID": 1, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "122", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": "RES", "ADDRESS": "555 E CARSON ST 122", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "R", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.26616993499418, 33.832297351408734]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "555", "Edit_Date": null, "OBJECTID": 2, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "123", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": "RES", "ADDRESS": "555 E CARSON ST 123", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "R", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.26609000493768, 33.83229586021424]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "555", "Edit_Date": null, "OBJECTID": 3, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "124", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": "RES", "ADDRESS": "555 E CARSON ST 124", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "R", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.26712656670806, 33.8322835165975]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "555", "Edit_Date": null, "OBJECTID": 4, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "80", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": "RES", "ADDRESS": "555 E CARSON ST 80", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "R", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.26711788300821, 33.832217189774546]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "555", "Edit_Date": null, "OBJECTID": 5, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "81", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": "RES", "ADDRESS": "555 E CARSON ST 81", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "R", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.26717515602246, 33.8322483146572]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "555", "Edit_Date": null, "OBJECTID": 6, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "79", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": "RES", "ADDRESS": "555 E CARSON ST 79", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "R", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.26727454383929, 33.832239672201815]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "555", "Edit_Date": null, "OBJECTID": 7, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "82", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": "RES", "ADDRESS": "555 E CARSON ST 82", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "R", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.2672259545687, 33.8322748732806]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "555", "Edit_Date": null, "OBJECTID": 8, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "83", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": "RES", "ADDRESS": "555 E CARSON ST 83", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "R", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.26721727079403, 33.83220854736647]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "555", "Edit_Date": null, "OBJECTID": 9, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "84", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": "RES", "ADDRESS": "555 E CARSON ST 84", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "R", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.26704682377567, 33.83209063493079]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "555", "Edit_Date": null, "OBJECTID": 10, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "3", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": "RES", "ADDRESS": "555 E CARSON ST 3", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "R", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.26705894281406, 33.83202468569259]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "555", "Edit_Date": null, "OBJECTID": 11, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "4", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": "RES", "ADDRESS": "555 E CARSON ST 4", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "R", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.26710465177264, 33.83206708985678]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "555", "Edit_Date": null, "OBJECTID": 12, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "2", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": "RES", "ADDRESS": "555 E CARSON ST 2", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "R", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.26714551757941, 33.83210368817248]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "555", "Edit_Date": null, "OBJECTID": 13, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "6", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": "RES", "ADDRESS": "555 E CARSON ST 6", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "R", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.26715763653924, 33.83203773802281]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "555", "Edit_Date": null, "OBJECTID": 14, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "7", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": "RES", "ADDRESS": "555 E CARSON ST 7", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "R", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.2672033455548, 33.8320801421496]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "555", "Edit_Date": null, "OBJECTID": 15, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "5", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": "RES", "ADDRESS": "555 E CARSON ST 5", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "R", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.26751428406726, 33.83217431294205]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "555", "Edit_Date": null, "OBJECTID": 16, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "36", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": "RES", "ADDRESS": "555 E CARSON ST 36", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "R", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.26743436473551, 33.83217615731941]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "555", "Edit_Date": null, "OBJECTID": 17, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "37", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": "RES", "ADDRESS": "555 E CARSON ST 37", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "R", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.26747618142764, 33.83213104191256]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "555", "Edit_Date": null, "OBJECTID": 18, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "35", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": "RES", "ADDRESS": "555 E CARSON ST 35", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "R", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.26751201971278, 33.83209094227526]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "555", "Edit_Date": null, "OBJECTID": 19, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "33", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": "RES", "ADDRESS": "555 E CARSON ST 33", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "R", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.26743210046324, 33.8320927875526]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "555", "Edit_Date": null, "OBJECTID": 20, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "34", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": "RES", "ADDRESS": "555 E CARSON ST 34", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "R", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.26747391711221, 33.832047671245455]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "555", "Edit_Date": null, "OBJECTID": 21, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "32", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": "RES", "ADDRESS": "555 E CARSON ST 32", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "R", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.26786694710235, 33.832485352092085]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "555", "Edit_Date": null, "OBJECTID": 22, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "54", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": "RES", "ADDRESS": "555 E CARSON ST 54", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "R", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.26778702748483, 33.83248719760502]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "555", "Edit_Date": null, "OBJECTID": 23, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "51", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": "RES", "ADDRESS": "555 E CARSON ST 51", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "R", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.26660420972074, 33.832511499361296]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "555", "Edit_Date": null, "OBJECTID": 24, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "94", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": "RES", "ADDRESS": "555 E CARSON ST 94", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "R", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.26660594742867, 33.83242978762015]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "555", "Edit_Date": null, "OBJECTID": 25, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "93", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": "RES", "ADDRESS": "555 E CARSON ST 93", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "R", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.2666037274467, 33.83235975655229]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "555", "Edit_Date": null, "OBJECTID": 26, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "92", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": "RES", "ADDRESS": "555 E CARSON ST 92", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "R", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.26660350486173, 33.83228972219073]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "555", "Edit_Date": null, "OBJECTID": 27, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "91", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": "RES", "ADDRESS": "555 E CARSON ST 91", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "R", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.2666841397189, 33.832512989313685]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "555", "Edit_Date": null, "OBJECTID": 28, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "95", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": "RES", "ADDRESS": "555 E CARSON ST 95", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "R", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.26668388525812, 33.832432949784554]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "555", "Edit_Date": null, "OBJECTID": 29, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "96", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": "RES", "ADDRESS": "555 E CARSON ST 96", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "R", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.2666816588314, 33.832361251831344]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "555", "Edit_Date": null, "OBJECTID": 30, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "97", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": "RES", "ADDRESS": "555 E CARSON ST 97", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "R", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.26667943771135, 33.83229122189469]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "555", "Edit_Date": null, "OBJECTID": 31, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "98", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": "RES", "ADDRESS": "555 E CARSON ST 98", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "R", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.26786622825944, 33.83226024115137]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "555", "Edit_Date": null, "OBJECTID": 32, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "50", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": "RES", "ADDRESS": "555 E CARSON ST 50", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "R", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.26750540323945, 33.831895858575116]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "555", "Edit_Date": null, "OBJECTID": 33, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "30", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": "RES", "ADDRESS": "555 E CARSON ST 30", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "R", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.267505264984, 33.83185250413456]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "555", "Edit_Date": null, "OBJECTID": 34, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "18", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": "RES", "ADDRESS": "555 E CARSON ST 18", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "R", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.26741548763596, 33.831896058240524]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "555", "Edit_Date": null, "OBJECTID": 35, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "28", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": "RES", "ADDRESS": "555 E CARSON ST 28", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "R", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.26741534942697, 33.83185270379986]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "555", "Edit_Date": null, "OBJECTID": 36, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "16", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": "RES", "ADDRESS": "555 E CARSON ST 16", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "R", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.26733158335615, 33.83190124700228]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "555", "Edit_Date": null, "OBJECTID": 37, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "27", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": "RES", "ADDRESS": "555 E CARSON ST 27", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "R", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.26733144519048, 33.83185789256151]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "555", "Edit_Date": null, "OBJECTID": 38, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "15", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": "RES", "ADDRESS": "555 E CARSON ST 15", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "R", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.26725364149294, 33.83189641746482]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "555", "Edit_Date": null, "OBJECTID": 39, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "24", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": "RES", "ADDRESS": "555 E CARSON ST 24", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "R", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.2672555018272, 33.83185305858963]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "555", "Edit_Date": null, "OBJECTID": 40, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "12", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": "RES", "ADDRESS": "555 E CARSON ST 12", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "R", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.2671577114233, 33.83188995997507]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "555", "Edit_Date": null, "OBJECTID": 41, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "23", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": "RES", "ADDRESS": "555 E CARSON ST 23", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "R", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.26715757334753, 33.83184660553418]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "555", "Edit_Date": null, "OBJECTID": 42, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "11", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": "RES", "ADDRESS": "555 E CARSON ST 11", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "R", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.267089759992, 33.831885108171704]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "555", "Edit_Date": null, "OBJECTID": 43, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "21", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": "RES", "ADDRESS": "555 E CARSON ST 21", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "R", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.26708962195137, 33.83184175373074]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "555", "Edit_Date": null, "OBJECTID": 44, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "9", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": "RES", "ADDRESS": "555 E CARSON ST 9", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "R", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.26700194901227, 33.83191865349906]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "555", "Edit_Date": null, "OBJECTID": 45, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "20", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": "RES", "ADDRESS": "555 E CARSON ST 20", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "R", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.26700174732358, 33.831855288275605]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "555", "Edit_Date": null, "OBJECTID": 46, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "8", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": "RES", "ADDRESS": "555 E CARSON ST 8", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "R", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.26744967935517, 33.83196601717541]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "555", "Edit_Date": null, "OBJECTID": 47, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "29", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": "RES", "ADDRESS": "555 E CARSON ST 29", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "R", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.2674495411291, 33.83192266295981]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "555", "Edit_Date": null, "OBJECTID": 48, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "17", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": "RES", "ADDRESS": "555 E CARSON ST 17", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "R", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.26736376060084, 33.831966207926996]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "555", "Edit_Date": null, "OBJECTID": 49, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "26", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": "RES", "ADDRESS": "555 E CARSON ST 26", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "R", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.26736761826143, 33.83192284484135]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "555", "Edit_Date": null, "OBJECTID": 50, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "14", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": "RES", "ADDRESS": "555 E CARSON ST 14", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "R", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.2672459363992, 33.83197147191902]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "555", "Edit_Date": null, "OBJECTID": 51, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "25", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": "RES", "ADDRESS": "555 E CARSON ST 25", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "R", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.26723775798217, 33.83192813554276]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "555", "Edit_Date": null, "OBJECTID": 52, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "13", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": "RES", "ADDRESS": "555 E CARSON ST 13", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "R", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.26712195270657, 33.83195507275865]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "555", "Edit_Date": null, "OBJECTID": 53, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "22", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": "RES", "ADDRESS": "555 E CARSON ST 22", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "R", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.26712181464632, 33.83191171741585]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "555", "Edit_Date": null, "OBJECTID": 54, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "1O", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": " ", "ADDRESS": "555 E CARSON ST 1O", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "R", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.26648847230034, 33.83256011274159]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "555", "Edit_Date": null, "OBJECTID": 55, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "104", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": "RES", "ADDRESS": "555 E CARSON ST 104", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "R", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.26640455562827, 33.83256196618043]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "555", "Edit_Date": null, "OBJECTID": 56, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "103", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": "RES", "ADDRESS": "555 E CARSON ST 103", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "R", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.2663206347377, 33.832562151767675]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "555", "Edit_Date": null, "OBJECTID": 57, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "102", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": "RES", "ADDRESS": "555 E CARSON ST 102", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "R", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.2664922615721, 33.83249507178248]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "555", "Edit_Date": null, "OBJECTID": 58, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "99", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": "RES", "ADDRESS": "555 E CARSON ST 99", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "R", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.26640634757044, 33.83249692964183]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "555", "Edit_Date": null, "OBJECTID": 59, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "100", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": "RES", "ADDRESS": "555 E CARSON ST 100", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "R", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.26632243203714, 33.83249878211955]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "555", "Edit_Date": null, "OBJECTID": 60, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "101", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": "RES", "ADDRESS": "555 E CARSON ST 101", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "R", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.26607286291672, 33.83256103156023]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "555", "Edit_Date": null, "OBJECTID": 61, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "111", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": "RES", "ADDRESS": "555 E CARSON ST 111", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "R", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.26598894623451, 33.83256288470949]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "555", "Edit_Date": null, "OBJECTID": 62, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "110", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": "RES", "ADDRESS": "555 E CARSON ST 110", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "R", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.26590502534214, 33.832563070007176]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "555", "Edit_Date": null, "OBJECTID": 63, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "109", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": "RES", "ADDRESS": "555 E CARSON ST 109", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "R", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.26607665251075, 33.83249599061417]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "555", "Edit_Date": null, "OBJECTID": 64, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "106", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": "RES", "ADDRESS": "555 E CARSON ST 106", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "R", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.26599073849894, 33.832497848177084]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "555", "Edit_Date": null, "OBJECTID": 65, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "107", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": "RES", "ADDRESS": "555 E CARSON ST 107", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "R", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.26590682295554, 33.83249970036523]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "555", "Edit_Date": null, "OBJECTID": 66, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "108", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": "RES", "ADDRESS": "555 E CARSON ST 108", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "R", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.2661707751935, 33.83256248302984]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "555", "Edit_Date": null, "OBJECTID": 67, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "112", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": "RES", "ADDRESS": "555 E CARSON ST 112", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "R", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.2661725620249, 33.832495778703965]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "555", "Edit_Date": null, "OBJECTID": 68, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "105", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": "RES", "ADDRESS": "555 E CARSON ST 105", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "R", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.26662936744955, 33.832040277101136]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "555", "Edit_Date": null, "OBJECTID": 69, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "1", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": "RES", "ADDRESS": "555 E CARSON ST 1", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "R", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.27475628879215, 33.8311977740661]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "192", "Edit_Date": null, "OBJECTID": 70, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": " ", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": " ", "ADDRESS": "192 E CARSON ST", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "B", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.27476514892521, 33.83102395192681]}, "type": "Feature", "properties": {"SITEFRAC": "1/4", "Need_Check": "NO", "SITENUMBER": "198", "Edit_Date": null, "OBJECTID": 71, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": " ", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": " ", "ADDRESS": "198 1/4 E CARSON ST", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "B", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.27402080583845, 33.83138957727527]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "216", "Edit_Date": null, "OBJECTID": 72, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "B", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": " ", "ADDRESS": "216 E CARSON ST B", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "B", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.2735821734332, 33.831319931689265]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "230", "Edit_Date": null, "OBJECTID": 73, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": " ", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": "RES", "ADDRESS": "230 E CARSON ST", "Field_Chec": " ", "SITEPREF": "E", "TYPE": " ", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.27323619360224, 33.831237437822196]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "234", "Edit_Date": null, "OBJECTID": 74, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "2", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": " ", "ADDRESS": "234 E CARSON ST 2", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "B", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.27328477275884, 33.8311891461462]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "234", "Edit_Date": null, "OBJECTID": 75, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "3", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": " ", "ADDRESS": "234 E CARSON ST 3", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "B", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.27334775409588, 33.831188377576105]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "234", "Edit_Date": null, "OBJECTID": 76, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "4", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": " ", "ADDRESS": "234 E CARSON ST 4", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "B", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.27343247753399, 33.83118693306357]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "234", "Edit_Date": null, "OBJECTID": 77, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "5", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": " ", "ADDRESS": "234 E CARSON ST 5", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "B", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.27317294963612, 33.83115748731795]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "234", "Edit_Date": null, "OBJECTID": 78, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "6", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": " ", "ADDRESS": "234 E CARSON ST 6", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "B", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.27323593067742, 33.83115671790547]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "234", "Edit_Date": null, "OBJECTID": 79, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "7", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": " ", "ADDRESS": "234 E CARSON ST 7", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "B", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.2732845668642, 33.83112594614007]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "234", "Edit_Date": null, "OBJECTID": 80, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "8", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": " ", "ADDRESS": "234 E CARSON ST 8", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "B", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.2733475481538, 33.8311251775701]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "234", "Edit_Date": null, "OBJECTID": 81, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "9", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": " ", "ADDRESS": "234 E CARSON ST 9", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "B", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.27343227153101, 33.83112373395921]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "234", "Edit_Date": null, "OBJECTID": 82, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "10", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": " ", "ADDRESS": "234 E CARSON ST 10", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "B", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.27249721538976, 33.83136702610877]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "288", "Edit_Date": null, "OBJECTID": 83, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": " ", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": " ", "ADDRESS": "288 E CARSON ST", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "B", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.27206665717537, 33.831209144414665]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "302", "Edit_Date": null, "OBJECTID": 84, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "104", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": " ", "ADDRESS": "302 E CARSON ST 104", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "B", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.27220670596932, 33.83120882798425]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "302", "Edit_Date": null, "OBJECTID": 85, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "106", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": " ", "ADDRESS": "302 E CARSON ST 106", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "B", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.27198929364384, 33.83114968776824]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "302", "Edit_Date": null, "OBJECTID": 86, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "200", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": " ", "ADDRESS": "302 E CARSON ST 200", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "B", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.27206932208699, 33.83114950702078]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "302", "Edit_Date": null, "OBJECTID": 87, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "202", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": " ", "ADDRESS": "302 E CARSON ST 202", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "B", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.27215507381453, 33.83115169869632]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "302", "Edit_Date": null, "OBJECTID": 88, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "204", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": " ", "ADDRESS": "302 E CARSON ST 204", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "B", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.27223510117896, 33.83115151784116]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "302", "Edit_Date": null, "OBJECTID": 89, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "206", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": " ", "ADDRESS": "302 E CARSON ST 206", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "B", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.27163491046693, 33.8310817163622]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "316", "Edit_Date": null, "OBJECTID": 90, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": " ", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": " ", "ADDRESS": "316 E CARSON ST", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "R", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.27163441614383, 33.83092906037062]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "318", "Edit_Date": null, "OBJECTID": 91, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": " ", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": " ", "ADDRESS": "318 E CARSON ST", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "R", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.26643784109291, 33.83234678413191]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "555", "Edit_Date": null, "OBJECTID": 92, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "88", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": "RES", "ADDRESS": "555 E CARSON ST 88", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "R", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.26631363983735, 33.8322470086989]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "555", "Edit_Date": null, "OBJECTID": 93, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "85", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": "RES", "ADDRESS": "555 E CARSON ST 85", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "R", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.26628380053374, 33.832288761617384]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "555", "Edit_Date": null, "OBJECTID": 94, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "86", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": "RES", "ADDRESS": "555 E CARSON ST 86", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "R", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.266255599766, 33.83221712107972]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "555", "Edit_Date": null, "OBJECTID": 95, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "87", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": "RES", "ADDRESS": "555 E CARSON ST 87", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "R", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.26628915436054, 33.83208698175586]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "555", "Edit_Date": null, "OBJECTID": 96, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "131", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": "RES", "ADDRESS": "555 E CARSON ST 131", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "R", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.26623930192872, 33.83211877479759]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "555", "Edit_Date": null, "OBJECTID": 97, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "132", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": "RES", "ADDRESS": "555 E CARSON ST 132", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "R", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.26624105694157, 33.83204206553336]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "555", "Edit_Date": null, "OBJECTID": 98, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "133", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": "RES", "ADDRESS": "555 E CARSON ST 133", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "R", "STREETNAME": "CARSON"}}, +{"geometry": {"type": "Point", "coordinates": [-118.26614139994132, 33.83212065896682]}, "type": "Feature", "properties": {"SITEFRAC": " ", "Need_Check": "NO", "SITENUMBER": "555", "Edit_Date": null, "OBJECTID": 99, "STREETTYPE": "ST", "SITEZIP": "90745", "VACANT": " ", "SITESTREET": "CARSON ST", "SITEUNIT": "129", "SITECITY": "CARSON, CA", "Comments": " ", "RES_BUS": "RES", "ADDRESS": "555 E CARSON ST 129", "Field_Chec": " ", "SITEPREF": "E", "TYPE": "R", "STREETNAME": "CARSON"}}, + +] +} diff --git a/tests/fixtures/us-ca-inyo/us-ca-inyo-count-only.json b/tests/fixtures/us-ca-inyo/us-ca-inyo-count-only.json new file mode 100644 index 0000000..9a91157 --- /dev/null +++ b/tests/fixtures/us-ca-inyo/us-ca-inyo-count-only.json @@ -0,0 +1,3 @@ +{ + "count": 30551 +} diff --git a/tests/fixtures/us-ca-inyo/us-ca-inyo-feat.json b/tests/fixtures/us-ca-inyo/us-ca-inyo-feat.json new file mode 100644 index 0000000..224fd22 --- /dev/null +++ b/tests/fixtures/us-ca-inyo/us-ca-inyo-feat.json @@ -0,0 +1,28 @@ +{ + "feature": { + "attributes": { + "OBJECTID": 1, + "SITENUMBER": "555", + "SITEFRAC": " ", + "SITEPREF": "E", + "SITESTREET": "CARSON ST", + "SITEUNIT": "122", + "SITECITY": "CARSON, CA", + "SITEZIP": "90745", + "STREETNAME": "CARSON", + "STREETTYPE": "ST", + "TYPE": "R", + "ADDRESS": "555 E CARSON ST 122", + "VACANT": " ", + "RES_BUS": "RES", + "Field_Chec": " ", + "Need_Check": "NO", + "Comments": " ", + "Edit_Date": null + }, + "geometry": { + "x": -118.26711788300821, + "y": 33.832217189774546 + } + } +} diff --git a/tests/fixtures/us-ca-inyo/us-ca-inyo-ids-only.json b/tests/fixtures/us-ca-inyo/us-ca-inyo-ids-only.json new file mode 100644 index 0000000..b953131 --- /dev/null +++ b/tests/fixtures/us-ca-inyo/us-ca-inyo-ids-only.json @@ -0,0 +1 @@ +{"objectIdFieldName":"OBJECTID","objectIds":[70193,70194,70195,70196,70197,70198,70199,70200,70201,70202,70203,70204,70205,70206,70207,70208,70209,70210,70211,70212,70213,70214,70215,70216,70217,70218,70219,70220,70223,70224,70225,70226,70227,70228,70229,70230,70231,70232,70233,70234,70237,70238,70239,70241,70242,70243,70244,70245,70246,70247,70252,70254,70255,70256,70258,70259,70260,70261,70262,70263,70264,70265,70266,70267,70270,70271,70272,70273,70274,70275,70276,70277,70278,70279,70280,70281,70282,70283,70284,70285,70286,70287,70288,70289,70290,70291,70292,70293,70294,70295,70296,70297,70298,70300,70301,70302,70303,70304,70305,70307]} diff --git a/tests/fixtures/us-ca-inyo/us-ca-inyo-metadata.json b/tests/fixtures/us-ca-inyo/us-ca-inyo-metadata.json new file mode 100644 index 0000000..a60ac6c --- /dev/null +++ b/tests/fixtures/us-ca-inyo/us-ca-inyo-metadata.json @@ -0,0 +1,201 @@ +{ + "currentVersion": 10, + "id": 1, + "name": "Address Points", + "type": "Feature Layer", + "description": "", + "definitionExpression": "", + "geometryType": "esriGeometryPoint", + "sourceSpatialReference": { + "wkid": 2229 + }, + "copyrightText": "", + "parentLayer": null, + "subLayers": [], + "minScale": 4000, + "maxScale": 0, + "defaultVisibility": false, + "extent": { + "xmin": 6474022.25324975, + "ymin": 1748978.69257216, + "xmax": 6499010.09933418, + "ymax": 1780987.81360582, + "spatialReference": { + "wkid": 2229 + } + }, + "hasAttachments": false, + "htmlPopupType": "esriServerHTMLPopupTypeNone", + "drawingInfo": { + "renderer": { + "type": "simple", + "symbol": { + "type": "esriPMS", + "url": "DDB48031", + "imageData": "iVBORw0KGgoAAAANSUhEUgAAAAYAAAAGCAYAAADgzO9IAAAAAXNSR0IB2cksfwAAAAlwSFlzAAAOxAAADsQBlSsOGwAAAC1JREFUCJljYSjxTWdgZOJkQALsjP9OsjD8Z2hlYPgnjCzB8O9fKwsDDkBFCQDVowgyJIfu/AAAAABJRU5ErkJggg==", + "contentType": "image/png", + "color": null, + "width": 4, + "height": 4, + "angle": 0, + "xoffset": 0, + "yoffset": 0 + }, + "label": "", + "description": "" + }, + "transparency": 0, + "labelingInfo": [ + { + "labelPlacement": "esriServerPointLabelPlacementCenterCenter", + "labelExpression": "[SITENUMBER]", + "useCodedValues": true, + "symbol": { + "type": "esriTS", + "color": [ + 0, + 115, + 76, + 255 + ], + "backgroundColor": null, + "borderLineColor": null, + "verticalAlignment": "bottom", + "horizontalAlignment": "center", + "rightToLeft": false, + "angle": 0, + "xoffset": 0, + "yoffset": 0, + "font": { + "family": "Arial", + "size": 8, + "style": "normal", + "weight": "bold", + "decoration": "none" + } + }, + "minScale": 2000, + "maxScale": 0 + } + ] + }, + "displayField": "STREETNAME", + "fields": [ + { + "name": "OBJECTID", + "type": "esriFieldTypeOID", + "alias": "OBJECTID" + }, + { + "name": "Shape", + "type": "esriFieldTypeGeometry", + "alias": "Shape" + }, + { + "name": "SITENUMBER", + "type": "esriFieldTypeString", + "alias": "SITENUMBER", + "length": 13 + }, + { + "name": "SITEFRAC", + "type": "esriFieldTypeString", + "alias": "SITEFRAC", + "length": 10 + }, + { + "name": "SITEPREF", + "type": "esriFieldTypeString", + "alias": "SITEPREF", + "length": 4 + }, + { + "name": "SITESTREET", + "type": "esriFieldTypeString", + "alias": "SITESTREET", + "length": 25 + }, + { + "name": "SITEUNIT", + "type": "esriFieldTypeString", + "alias": "SITEUNIT", + "length": 8 + }, + { + "name": "SITECITY", + "type": "esriFieldTypeString", + "alias": "SITECITY", + "length": 14 + }, + { + "name": "SITEZIP", + "type": "esriFieldTypeString", + "alias": "SITEZIP", + "length": 10 + }, + { + "name": "STREETNAME", + "type": "esriFieldTypeString", + "alias": "STREETNAME", + "length": 70 + }, + { + "name": "STREETTYPE", + "type": "esriFieldTypeString", + "alias": "STREETTYPE", + "length": 70 + }, + { + "name": "TYPE", + "type": "esriFieldTypeString", + "alias": "TYPE", + "length": 5 + }, + { + "name": "ADDRESS", + "type": "esriFieldTypeString", + "alias": "ADDRESS", + "length": 50 + }, + { + "name": "VACANT", + "type": "esriFieldTypeString", + "alias": "VACANT", + "length": 5 + }, + { + "name": "RES_BUS", + "type": "esriFieldTypeString", + "alias": "RES_BUS", + "length": 10 + }, + { + "name": "Field_Chec", + "type": "esriFieldTypeString", + "alias": "Field_Chec", + "length": 25 + }, + { + "name": "Need_Check", + "type": "esriFieldTypeString", + "alias": "Need_Check", + "length": 10 + }, + { + "name": "Comments", + "type": "esriFieldTypeString", + "alias": "Comments", + "length": 50 + }, + { + "name": "Edit_Date", + "type": "esriFieldTypeDate", + "alias": "Edit_Date", + "length": 8 + } + ], + "typeIdField": null, + "types": null, + "relationships": [], + "capabilities": "Map,Query,Data" +} diff --git a/tests/fixtures/us-ca-inyo/us-ca-inyo-query.json b/tests/fixtures/us-ca-inyo/us-ca-inyo-query.json new file mode 100644 index 0000000..c1fdfe7 --- /dev/null +++ b/tests/fixtures/us-ca-inyo/us-ca-inyo-query.json @@ -0,0 +1,270 @@ +{ + "displayFieldName": "STREETNAME", + "fieldAliases": { + "OBJECTID": "OBJECTID", + "SITENUMBER": "SITENUMBER", + "SITEFRAC": "SITEFRAC", + "SITEPREF": "SITEPREF", + "SITESTREET": "SITESTREET", + "SITEUNIT": "SITEUNIT", + "SITECITY": "SITECITY", + "SITEZIP": "SITEZIP", + "STREETNAME": "STREETNAME", + "STREETTYPE": "STREETTYPE", + "TYPE": "TYPE", + "ADDRESS": "ADDRESS", + "VACANT": "VACANT", + "RES_BUS": "RES_BUS", + "Field_Chec": "Field_Chec", + "Need_Check": "Need_Check", + "Comments": "Comments", + "Edit_Date": "Edit_Date" + }, + "geometryType": "esriGeometryPoint", + "spatialReference": { + "wkid": 4326 + }, + "fields": [ + { + "name": "OBJECTID", + "type": "esriFieldTypeOID", + "alias": "OBJECTID" + }, + { + "name": "SITENUMBER", + "type": "esriFieldTypeString", + "alias": "SITENUMBER", + "length": 13 + }, + { + "name": "SITEFRAC", + "type": "esriFieldTypeString", + "alias": "SITEFRAC", + "length": 10 + }, + { + "name": "SITEPREF", + "type": "esriFieldTypeString", + "alias": "SITEPREF", + "length": 4 + }, + { + "name": "SITESTREET", + "type": "esriFieldTypeString", + "alias": "SITESTREET", + "length": 25 + }, + { + "name": "SITEUNIT", + "type": "esriFieldTypeString", + "alias": "SITEUNIT", + "length": 8 + }, + { + "name": "SITECITY", + "type": "esriFieldTypeString", + "alias": "SITECITY", + "length": 14 + }, + { + "name": "SITEZIP", + "type": "esriFieldTypeString", + "alias": "SITEZIP", + "length": 10 + }, + { + "name": "STREETNAME", + "type": "esriFieldTypeString", + "alias": "STREETNAME", + "length": 70 + }, + { + "name": "STREETTYPE", + "type": "esriFieldTypeString", + "alias": "STREETTYPE", + "length": 70 + }, + { + "name": "TYPE", + "type": "esriFieldTypeString", + "alias": "TYPE", + "length": 5 + }, + { + "name": "ADDRESS", + "type": "esriFieldTypeString", + "alias": "ADDRESS", + "length": 50 + }, + { + "name": "VACANT", + "type": "esriFieldTypeString", + "alias": "VACANT", + "length": 5 + }, + { + "name": "RES_BUS", + "type": "esriFieldTypeString", + "alias": "RES_BUS", + "length": 10 + }, + { + "name": "Field_Chec", + "type": "esriFieldTypeString", + "alias": "Field_Chec", + "length": 25 + }, + { + "name": "Need_Check", + "type": "esriFieldTypeString", + "alias": "Need_Check", + "length": 10 + }, + { + "name": "Comments", + "type": "esriFieldTypeString", + "alias": "Comments", + "length": 50 + }, + { + "name": "Edit_Date", + "type": "esriFieldTypeDate", + "alias": "Edit_Date", + "length": 8 + } + ], + "features": [ + { + "attributes": { + "OBJECTID": 1, + "SITENUMBER": "555", + "SITEFRAC": " ", + "SITEPREF": "E", + "SITESTREET": "CARSON ST", + "SITEUNIT": "122", + "SITECITY": "CARSON, CA", + "SITEZIP": "90745", + "STREETNAME": "CARSON", + "STREETTYPE": "ST", + "TYPE": "R", + "ADDRESS": "555 E CARSON ST 122", + "VACANT": " ", + "RES_BUS": "RES", + "Field_Chec": " ", + "Need_Check": "NO", + "Comments": " ", + "Edit_Date": null + } + }, + { + "attributes": { + "OBJECTID": 2, + "SITENUMBER": "555", + "SITEFRAC": " ", + "SITEPREF": "E", + "SITESTREET": "CARSON ST", + "SITEUNIT": "123", + "SITECITY": "CARSON, CA", + "SITEZIP": "90745", + "STREETNAME": "CARSON", + "STREETTYPE": "ST", + "TYPE": "R", + "ADDRESS": "555 E CARSON ST 123", + "VACANT": " ", + "RES_BUS": "RES", + "Field_Chec": " ", + "Need_Check": "NO", + "Comments": " ", + "Edit_Date": null + } + }, + { + "attributes": { + "OBJECTID": 3, + "SITENUMBER": "555", + "SITEFRAC": " ", + "SITEPREF": "E", + "SITESTREET": "CARSON ST", + "SITEUNIT": "124", + "SITECITY": "CARSON, CA", + "SITEZIP": "90745", + "STREETNAME": "CARSON", + "STREETTYPE": "ST", + "TYPE": "R", + "ADDRESS": "555 E CARSON ST 124", + "VACANT": " ", + "RES_BUS": "RES", + "Field_Chec": " ", + "Need_Check": "NO", + "Comments": " ", + "Edit_Date": null + } + }, + { + "attributes": { + "OBJECTID": 1, + "SITENUMBER": "555", + "SITEFRAC": " ", + "SITEPREF": "E", + "SITESTREET": "CARSON ST", + "SITEUNIT": "120", + "SITECITY": "CARSON, CA", + "SITEZIP": "90745", + "STREETNAME": "CARSON", + "STREETTYPE": "ST", + "TYPE": "R", + "ADDRESS": "555 E CARSON ST 120", + "VACANT": " ", + "RES_BUS": "RES", + "Field_Chec": " ", + "Need_Check": "NO", + "Comments": " ", + "Edit_Date": null + } + }, + { + "attributes": { + "OBJECTID": 4, + "SITENUMBER": "555", + "SITEFRAC": " ", + "SITEPREF": "E", + "SITESTREET": "CARSON ST", + "SITEUNIT": "80", + "SITECITY": "CARSON, CA", + "SITEZIP": "90745", + "STREETNAME": "CARSON", + "STREETTYPE": "ST", + "TYPE": "R", + "ADDRESS": "555 E CARSON ST 80", + "VACANT": " ", + "RES_BUS": "RES", + "Field_Chec": " ", + "Need_Check": "NO", + "Comments": " ", + "Edit_Date": null + } + }, + { + "attributes": { + "OBJECTID": 5, + "SITENUMBER": "555", + "SITEFRAC": " ", + "SITEPREF": "E", + "SITESTREET": "CARSON ST", + "SITEUNIT": "81", + "SITECITY": "CARSON, CA", + "SITEZIP": "90745", + "STREETNAME": "CARSON", + "STREETTYPE": "ST", + "TYPE": "R", + "ADDRESS": "555 E CARSON ST 81", + "VACANT": " ", + "RES_BUS": "RES", + "Field_Chec": " ", + "Need_Check": "NO", + "Comments": " ", + "Edit_Date": null + } + } + ] +}