earthengine-api 1.6.13rc0__py3-none-any.whl → 1.6.14rc0__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of earthengine-api might be problematic. Click here for more details.
- {earthengine_api-1.6.13rc0.dist-info → earthengine_api-1.6.14rc0.dist-info}/METADATA +1 -1
- {earthengine_api-1.6.13rc0.dist-info → earthengine_api-1.6.14rc0.dist-info}/RECORD +13 -13
- ee/__init__.py +1 -1
- ee/deprecation.py +5 -0
- ee/terrain.py +1 -1
- ee/tests/batch_test.py +8 -0
- ee/tests/deprecation_test.py +4 -2
- ee/tests/serializer_test.py +26 -0
- ee/tests/terrain_test.py +8 -0
- {earthengine_api-1.6.13rc0.dist-info → earthengine_api-1.6.14rc0.dist-info}/WHEEL +0 -0
- {earthengine_api-1.6.13rc0.dist-info → earthengine_api-1.6.14rc0.dist-info}/entry_points.txt +0 -0
- {earthengine_api-1.6.13rc0.dist-info → earthengine_api-1.6.14rc0.dist-info}/licenses/LICENSE +0 -0
- {earthengine_api-1.6.13rc0.dist-info → earthengine_api-1.6.14rc0.dist-info}/top_level.txt +0 -0
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
earthengine_api-1.6.
|
|
2
|
-
ee/__init__.py,sha256=
|
|
1
|
+
earthengine_api-1.6.14rc0.dist-info/licenses/LICENSE,sha256=xx0jnfkXJvxRnG63LTGOxlggYnIysveWIZ6H3PNdCrQ,11357
|
|
2
|
+
ee/__init__.py,sha256=xl4k0DxOUmXvTXfyuFDO05uOvgmELmvTKHFIfj-YSE8,16807
|
|
3
3
|
ee/_arg_types.py,sha256=nrJrnPFnAS8fzMxAGmG3TbUOi_yFVrnSGW5IP8ATzDQ,2662
|
|
4
4
|
ee/_cloud_api_utils.py,sha256=06xr56VvGeQHl6DTeoC9_YE0hKVtE11tMnDCv98TKSA,32998
|
|
5
5
|
ee/_helpers.py,sha256=71xYDbCO_1usY3SnedoA9zi7j6dnPBijru1eUh4o25g,4859
|
|
@@ -17,7 +17,7 @@ ee/confusionmatrix.py,sha256=e6vz-FcT6acWxk5pDEK0vLIN1pUjYMh5Gyn1QSGJT3I,4233
|
|
|
17
17
|
ee/customfunction.py,sha256=ONDKyd5dldQLMX7diYZJK5wc8ty_-cI8K421Jumo9SM,7381
|
|
18
18
|
ee/data.py,sha256=eI6-JLKqw4RNsa_zOWAb2j8NgXCrVSKm9SjniGiZRPQ,85497
|
|
19
19
|
ee/daterange.py,sha256=nrRYkR2M2aVU0ZJyG7yiZStFt-W2TvYVuazoZK_WZqM,4948
|
|
20
|
-
ee/deprecation.py,sha256=
|
|
20
|
+
ee/deprecation.py,sha256=J6eTNrKE3pQodyE8Pig8ixPRT3C4pTxFqrraE8R_cOo,6226
|
|
21
21
|
ee/deserializer.py,sha256=Xz9Dis85JgZeLvpF-4yw3ZRv39rjvCTBYHjio8DE1kM,8424
|
|
22
22
|
ee/dictionary.py,sha256=b0t46vaeVMsFGI2icdGNspmedRtVVxfiIcFLWcmL2v8,10508
|
|
23
23
|
ee/ee_array.py,sha256=EJmQ-zku1x0e6z44SlVD-F7mafmvRS0DoByKFyeDCuc,36368
|
|
@@ -49,7 +49,7 @@ ee/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
|
49
49
|
ee/reducer.py,sha256=80LyfpjpyJj3FO36fviZIK5YcnDxssMZgrRK-Y3whSs,33740
|
|
50
50
|
ee/serializer.py,sha256=OldyytHpwmUVt28TEjlSS7J-3CE7GBZhyyXhvyMQIGs,22806
|
|
51
51
|
ee/table_converter.py,sha256=6ARbOLq1VPU1_wXY2pyv0PuzY4XyEBwM3npMt6Hp__U,2088
|
|
52
|
-
ee/terrain.py,sha256=
|
|
52
|
+
ee/terrain.py,sha256=TIbeQiVGv4okTTsHCnaP6TxSvaRF-GX_06asVIFN8dY,4873
|
|
53
53
|
ee/cli/__init__.py,sha256=YjzBDuYi6fiOv77Xfl-Qib2O6gRZj9z7Sx2Zz6teTXU,33
|
|
54
54
|
ee/cli/commands.py,sha256=8OeaoMIjseD7Eah9HoaeYzQFN6i6T9rUPYPh-9S9rZc,73544
|
|
55
55
|
ee/cli/eecli.py,sha256=1yDyingkwurai13F_PF91RYsBev6jGJ9WEoZaT2Dgy8,3043
|
|
@@ -61,7 +61,7 @@ ee/tests/_state_test.py,sha256=AKe5Vopzt24FJPiPcEce_oOT861gOkd6mUOAWZr6C0g,1175
|
|
|
61
61
|
ee/tests/_utils_test.py,sha256=bOarVj3U-VFo9Prog8WQN_hAOMwJOiWKJxevUbdFPBQ,2753
|
|
62
62
|
ee/tests/algorithms.json,sha256=Vx1Kx_MhHv0z0B3WTeVAvchM8xVd3zYE7L-qT3gDGzA,729368
|
|
63
63
|
ee/tests/apifunction_test.py,sha256=_6xpkJOd7hScYYQxzFR-8flraTQ6xfkm7gyER6JoBog,3779
|
|
64
|
-
ee/tests/batch_test.py,sha256=
|
|
64
|
+
ee/tests/batch_test.py,sha256=OKfDZgDvaMD2tQ31TaL9SyeWgogAFLJ01xDWWIeBYpo,63275
|
|
65
65
|
ee/tests/blob_test.py,sha256=uCrM-ubRfAmNgHwhmUhWn7MiXqbNQutybcXIKdVsD_Q,3587
|
|
66
66
|
ee/tests/classifier_test.py,sha256=K6-wNZ2uh9oPYo7BV0vtfU73SBFpeNcFRMRmvEFc6Pg,19087
|
|
67
67
|
ee/tests/cloud_api_discovery_document.json,sha256=SnOeL8One57YdeHa7XxGZM-ptDPCeDSymBc7-Bo_hkA,41154
|
|
@@ -71,7 +71,7 @@ ee/tests/computedobject_test.py,sha256=B27rDq9Urpvy0WqpdbKRYbt6AcT1i93HX-es7hrhW
|
|
|
71
71
|
ee/tests/confusionmatrix_test.py,sha256=46JJh1-91AiYISXWZ6-2lvY5_Njvc8ompO9kmwqlFdg,7437
|
|
72
72
|
ee/tests/data_test.py,sha256=-_TcPdCdqqfeCNA_hGU9mpjKHl1GxBnb9tCWDWsFrrc,40394
|
|
73
73
|
ee/tests/daterange_test.py,sha256=a5fpg2lko3kCJzxQPCoAc_vjXkKy2zYcXbeSZKAFovI,8583
|
|
74
|
-
ee/tests/deprecation_test.py,sha256=
|
|
74
|
+
ee/tests/deprecation_test.py,sha256=CoVug7J9YdB2utZ-BikyJcjitYPQLz49JL_z89xuQSQ,8484
|
|
75
75
|
ee/tests/deserializer_test.py,sha256=-tbrL0cjrXdSLF7M3wl-QQuj6TjXJdkjp7RZvVErUy4,3427
|
|
76
76
|
ee/tests/dictionary_test.py,sha256=IRaXMr3GzZFQ5BiHdB35Iio2TckIK67Cnp6KH0h8Aa8,11818
|
|
77
77
|
ee/tests/ee_array_test.py,sha256=JVXShdbOVOjlfSpNgYc_NVrknQatuPOZ19fG0Ii5yVU,50268
|
|
@@ -99,11 +99,11 @@ ee/tests/oauth_test.py,sha256=jYFw8GWPFmLR0jh2NvbcrMizQo_qR_bRDBVRdIZ44g0,3067
|
|
|
99
99
|
ee/tests/pixeltype_test.py,sha256=00IWKnZ7xxkVwSSCuWOlCwlTsHAb3XPyKp1Arc4S12U,10024
|
|
100
100
|
ee/tests/projection_test.py,sha256=fKXXxQPBvWdlMNtNsJze2pbsT0yHHlL7ON8Pdjm1Z7E,6871
|
|
101
101
|
ee/tests/reducer_test.py,sha256=NYJTmX6AmBZyXGjOkgUh4t3tB6E8_vGlPYQIxJQbV9Q,31518
|
|
102
|
-
ee/tests/serializer_test.py,sha256=
|
|
102
|
+
ee/tests/serializer_test.py,sha256=6pPUZODnhvXa8oIIK9i5q1EDJ8Y4gw9HJ2aHwb1-2I4,9819
|
|
103
103
|
ee/tests/table_converter_test.py,sha256=2F7DyEj-iHVbt9-W1iwAHDl-K1GA_2QHalTXzac2ot8,3373
|
|
104
|
-
ee/tests/terrain_test.py,sha256=
|
|
105
|
-
earthengine_api-1.6.
|
|
106
|
-
earthengine_api-1.6.
|
|
107
|
-
earthengine_api-1.6.
|
|
108
|
-
earthengine_api-1.6.
|
|
109
|
-
earthengine_api-1.6.
|
|
104
|
+
ee/tests/terrain_test.py,sha256=inZ2sy807nDG_HMutzGHaqcTUaLnZQOMdWyf0NrQzV0,4561
|
|
105
|
+
earthengine_api-1.6.14rc0.dist-info/METADATA,sha256=54qy1fQ37IcoXCDPPW1uj6aaXtSy1zZNZRgssj6_2ak,2197
|
|
106
|
+
earthengine_api-1.6.14rc0.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
|
|
107
|
+
earthengine_api-1.6.14rc0.dist-info/entry_points.txt,sha256=-Ax4SCU-S474r8OD2LIxata6PRmkZoDrppQ4fP_exNc,50
|
|
108
|
+
earthengine_api-1.6.14rc0.dist-info/top_level.txt,sha256=go5zOwCgm5lIS3yTR-Vsxp1gNI4qdS-MP5eY-7zMxVY,3
|
|
109
|
+
earthengine_api-1.6.14rc0.dist-info/RECORD,,
|
ee/__init__.py
CHANGED
ee/deprecation.py
CHANGED
|
@@ -204,6 +204,11 @@ def _IssueAssetDeprecationWarning(asset: DeprecatedAsset) -> None:
|
|
|
204
204
|
formatted_date = removal_date.strftime('%B %d, %Y').replace(' 0', ' ')
|
|
205
205
|
warning += f' by {formatted_date}'
|
|
206
206
|
warning += '.'
|
|
207
|
+
if asset.replacement_id:
|
|
208
|
+
warning = (
|
|
209
|
+
warning
|
|
210
|
+
+ f'\nThis dataset has been superseded by {asset.replacement_id}\n'
|
|
211
|
+
)
|
|
207
212
|
if asset.learn_more_url:
|
|
208
213
|
warning = warning + f'\nLearn more: {asset.learn_more_url}\n'
|
|
209
214
|
warnings.warn(warning, category=DeprecationWarning)
|
ee/terrain.py
CHANGED
|
@@ -13,7 +13,7 @@ class Terrain:
|
|
|
13
13
|
|
|
14
14
|
def __init__(self):
|
|
15
15
|
raise RuntimeError(
|
|
16
|
-
self.__name__
|
|
16
|
+
self.__class__.__name__
|
|
17
17
|
+ ' should not be used as an object. Only direct usage of Terrain'
|
|
18
18
|
' static methods is allowed. For example, use this: '
|
|
19
19
|
' `ee.Terrain.aspect(...)`'
|
ee/tests/batch_test.py
CHANGED
|
@@ -138,6 +138,14 @@ class TaskTest(unittest.TestCase):
|
|
|
138
138
|
):
|
|
139
139
|
self.assertFalse(task.active())
|
|
140
140
|
|
|
141
|
+
def test_success(self):
|
|
142
|
+
self.assertTrue(batch.Task.State.success(batch.Task.State.COMPLETED))
|
|
143
|
+
self.assertTrue(batch.Task.State.success('COMPLETED'))
|
|
144
|
+
for state in batch.Task.State:
|
|
145
|
+
if state != batch.Task.State.COMPLETED:
|
|
146
|
+
self.assertFalse(batch.Task.State.success(state))
|
|
147
|
+
self.assertFalse(batch.Task.State.success(state.value))
|
|
148
|
+
|
|
141
149
|
def test_repr_without_config(self):
|
|
142
150
|
task = batch.Task('an id', 'a task type', 'a state')
|
|
143
151
|
self.assertEqual('<Task "an id">', task.__repr__())
|
ee/tests/deprecation_test.py
CHANGED
|
@@ -100,7 +100,8 @@ _EXPECTED_WARNINGS = {
|
|
|
100
100
|
r'Attention required for date_and_learn_more! You are using a'
|
|
101
101
|
r' deprecated asset.\nTo make sure your code keeps working, please'
|
|
102
102
|
r' update'
|
|
103
|
-
r' it by July 1, 2024.\
|
|
103
|
+
r' it by July 1, 2024.\nThis dataset has been superseded by'
|
|
104
|
+
r' replacement_id\n\nLearn more: learn_more_url'
|
|
104
105
|
),
|
|
105
106
|
'date_only': (
|
|
106
107
|
r'Attention required for date_only! You are using a deprecated asset.\n'
|
|
@@ -124,7 +125,8 @@ _EXPECTED_WARNINGS = {
|
|
|
124
125
|
r'Attention required for learn_more_url_only! You are using a'
|
|
125
126
|
r' deprecated asset.\nTo make sure your code keeps working, please'
|
|
126
127
|
r' update'
|
|
127
|
-
r' it.\
|
|
128
|
+
r' it.\nThis dataset has been superseded by replacement_id\n\nLearn'
|
|
129
|
+
r' more: learn_more_url'
|
|
128
130
|
),
|
|
129
131
|
}
|
|
130
132
|
|
ee/tests/serializer_test.py
CHANGED
|
@@ -284,6 +284,32 @@ class SerializerTest(apitestcase.ApiTestCase):
|
|
|
284
284
|
self.assertIn('\n', serializer.toJSON(ee.Image(0), opt_pretty=True))
|
|
285
285
|
self.assertNotIn('\n', serializer.toJSON(ee.Image(0), opt_pretty=False))
|
|
286
286
|
|
|
287
|
+
def test_datetime_serialization_legacy(self):
|
|
288
|
+
a_date = datetime.datetime(2014, 8, 10, tzinfo=datetime.timezone.utc)
|
|
289
|
+
# 1407628800000000 microseconds.
|
|
290
|
+
expected = {
|
|
291
|
+
'type': 'CompoundValue',
|
|
292
|
+
'scope': [],
|
|
293
|
+
'value': {
|
|
294
|
+
'type': 'Invocation',
|
|
295
|
+
'functionName': 'Date',
|
|
296
|
+
'arguments': {'value': 1407628800000.0},
|
|
297
|
+
},
|
|
298
|
+
}
|
|
299
|
+
self.assertEqual(expected, serializer.encode(a_date, for_cloud_api=False))
|
|
300
|
+
|
|
301
|
+
def test_single_value_no_compound(self):
|
|
302
|
+
"""Verifies serialization of a single non-primitive value."""
|
|
303
|
+
self.assertEqual([1], serializer.encode([1], for_cloud_api=False))
|
|
304
|
+
|
|
305
|
+
def test_unencodable_object(self):
|
|
306
|
+
class Unencodable:
|
|
307
|
+
pass
|
|
308
|
+
with self.assertRaisesRegex(ee.EEException, 'Cannot encode object: .*'):
|
|
309
|
+
serializer.encode(Unencodable(), for_cloud_api=False)
|
|
310
|
+
with self.assertRaisesRegex(ee.EEException, 'Cannot encode object: .*'):
|
|
311
|
+
serializer.encode(Unencodable(), for_cloud_api=True)
|
|
312
|
+
|
|
287
313
|
|
|
288
314
|
if __name__ == '__main__':
|
|
289
315
|
unittest.main()
|
ee/tests/terrain_test.py
CHANGED
|
@@ -141,6 +141,14 @@ class TerrainTest(apitestcase.ApiTestCase):
|
|
|
141
141
|
result = json.loads(expression.serialize())
|
|
142
142
|
self.assertEqual(expect, result)
|
|
143
143
|
|
|
144
|
+
def test_init(self):
|
|
145
|
+
message = r'Terrain should not be used as an object.*'
|
|
146
|
+
with self.assertRaisesRegex(RuntimeError, message):
|
|
147
|
+
ee.Terrain()
|
|
148
|
+
|
|
149
|
+
def test_name(self):
|
|
150
|
+
self.assertEqual('Terrain', ee.Terrain.name())
|
|
151
|
+
|
|
144
152
|
|
|
145
153
|
if __name__ == '__main__':
|
|
146
154
|
unittest.main()
|
|
File without changes
|
{earthengine_api-1.6.13rc0.dist-info → earthengine_api-1.6.14rc0.dist-info}/entry_points.txt
RENAMED
|
File without changes
|
{earthengine_api-1.6.13rc0.dist-info → earthengine_api-1.6.14rc0.dist-info}/licenses/LICENSE
RENAMED
|
File without changes
|
|
File without changes
|