MCPcopy
hub / github.com/google/earthengine-api / NotFoundError

Function NotFoundError

python/ee/tests/data_test.py:23–29  ·  view source on GitHub ↗

Creates a mock HttpError with a 404 status code.

()

Source from the content-addressed store, hash-verified

21
22
23def NotFoundError() -> googleapiclient.errors.HttpError:
24 """Creates a mock HttpError with a 404 status code."""
25 resp = httplib2.Response({'status': '404', 'reason': 'Not Found'})
26 content = json.dumps({'error': {'code': 404, 'message': 'Not Found'}}).encode(
27 'utf-8'
28 )
29 return googleapiclient.errors.HttpError(resp, content)
30
31
32def NewFolderAsset(

Calls 1

encodeMethod · 0.45

Tested by

no test coverage detected