| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
1 parent 36c4a63 commit a80f436
3 files changed
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -40,10 +40,11 @@ | |||
| 40 | 40 | ||
| 41 | 41 | try: | |
| 42 | 42 | import shapely # type: ignore | |
| 43 | + from shapely import wkt # type: ignore | ||
| 43 | 44 | except ImportError: | |
| 44 | 45 | shapely = None | |
| 45 | 46 | else: | |
| 46 | - _read_wkt = shapely.wkt.loads | ||
| 47 | + _read_wkt = wkt.loads | ||
| 47 | 48 | ||
| 48 | 49 | import google.api_core.exceptions | |
| 49 | 50 | from google.api_core.page_iterator import HTTPIterator | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -10,7 +10,7 @@ db-dtypes==1.0.4 | |||
| 10 | 10 | Fiona==1.8.22 | |
| 11 | 11 | geojson==2.5.0 | |
| 12 | 12 | geopandas===0.10.2; python_version == '3.7' | |
| 13 | - geopandas==0.11.1; python_version >= '3.8' | ||
| 13 | + geopandas==0.12.1; python_version >= '3.8' | ||
| 14 | 14 | google-api-core==2.10.2 | |
| 15 | 15 | google-auth==2.13.0 | |
| 16 | 16 | google-cloud-bigquery==3.3.5 | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -15,6 +15,7 @@ | |||
| 15 | 15 | import datetime | |
| 16 | 16 | import logging | |
| 17 | 17 | import re | |
| 18 | + from sys import version_info | ||
| 18 | 19 | import time | |
| 19 | 20 | import types | |
| 20 | 21 | import unittest | |
@@ -1969,7 +1970,10 @@ def test_to_geodataframe(self): | |||
| 1969 | 1970 | df = row_iterator.to_geodataframe(create_bqstorage_client=False) | |
| 1970 | 1971 | self.assertIsInstance(df, geopandas.GeoDataFrame) | |
| 1971 | 1972 | self.assertEqual(len(df), 0) # verify the number of rows | |
| 1972 | - self.assertIsNone(df.crs) | ||
| 1973 | + if version_info.major == 3 and version_info.minor > 7: | ||
| 1974 | + assert not hasattr(df, "crs") # used with Python > 3.7 | ||
| 1975 | + else: | ||
| 1976 | + self.assertIsNone(df.crs) # used with Python == 3.7 | ||
| 1973 | 1977 | ||
| 1974 | 1978 | ||
| 1975 | 1979 | class TestRowIterator(unittest.TestCase): | |
| Back | FazBrowse Home | New Git URL |
0 commit comments