eodag 3.6.0__py3-none-any.whl → 3.8.0__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.
Files changed (35) hide show
  1. eodag/api/core.py +110 -189
  2. eodag/api/product/metadata_mapping.py +42 -3
  3. eodag/cli.py +6 -3
  4. eodag/config.py +7 -1
  5. eodag/plugins/authentication/openid_connect.py +1 -2
  6. eodag/plugins/download/aws.py +145 -178
  7. eodag/plugins/download/base.py +3 -2
  8. eodag/plugins/download/creodias_s3.py +10 -5
  9. eodag/plugins/download/http.py +14 -6
  10. eodag/plugins/download/s3rest.py +7 -3
  11. eodag/plugins/manager.py +1 -1
  12. eodag/plugins/search/base.py +34 -4
  13. eodag/plugins/search/build_search_result.py +3 -0
  14. eodag/plugins/search/cop_marine.py +2 -0
  15. eodag/plugins/search/data_request_search.py +6 -1
  16. eodag/plugins/search/qssearch.py +64 -25
  17. eodag/resources/ext_product_types.json +1 -1
  18. eodag/resources/product_types.yml +30 -171
  19. eodag/resources/providers.yml +87 -328
  20. eodag/resources/stac.yml +1 -2
  21. eodag/resources/stac_provider.yml +1 -1
  22. eodag/resources/user_conf_template.yml +0 -11
  23. eodag/rest/core.py +5 -16
  24. eodag/rest/stac.py +0 -4
  25. eodag/utils/__init__.py +41 -27
  26. eodag/utils/exceptions.py +4 -0
  27. eodag/utils/free_text_search.py +229 -0
  28. eodag/utils/s3.py +605 -65
  29. {eodag-3.6.0.dist-info → eodag-3.8.0.dist-info}/METADATA +7 -9
  30. {eodag-3.6.0.dist-info → eodag-3.8.0.dist-info}/RECORD +34 -34
  31. eodag/types/whoosh.py +0 -203
  32. {eodag-3.6.0.dist-info → eodag-3.8.0.dist-info}/WHEEL +0 -0
  33. {eodag-3.6.0.dist-info → eodag-3.8.0.dist-info}/entry_points.txt +0 -0
  34. {eodag-3.6.0.dist-info → eodag-3.8.0.dist-info}/licenses/LICENSE +0 -0
  35. {eodag-3.6.0.dist-info → eodag-3.8.0.dist-info}/top_level.txt +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: eodag
3
- Version: 3.6.0
3
+ Version: 3.8.0
4
4
  Summary: Earth Observation Data Access Gateway
5
5
  Home-page: https://github.com/CS-SI/eodag
6
6
  Author: CS GROUP - France
@@ -54,7 +54,6 @@ Requires-Dist: stream-zip
54
54
  Requires-Dist: tqdm
55
55
  Requires-Dist: typing_extensions>=4.8.0
56
56
  Requires-Dist: urllib3
57
- Requires-Dist: Whoosh
58
57
  Provides-Extra: all
59
58
  Requires-Dist: eodag[all-providers,csw,server,tutorials]; extra == "all"
60
59
  Provides-Extra: all-providers
@@ -86,6 +85,7 @@ Requires-Dist: imageio; extra == "tutorials"
86
85
  Requires-Dist: rasterio; extra == "tutorials"
87
86
  Requires-Dist: netcdf4; extra == "tutorials"
88
87
  Requires-Dist: cartopy; extra == "tutorials"
88
+ Requires-Dist: covjsonkit; extra == "tutorials"
89
89
  Provides-Extra: dev
90
90
  Requires-Dist: eodag[all-providers,csw,server,stubs]; extra == "dev"
91
91
  Requires-Dist: pytest; extra == "dev"
@@ -175,23 +175,21 @@ data provider. The EODAG SDK is structured around three functions:
175
175
 
176
176
  * List product types: list of supported products and their description
177
177
 
178
- * Search products (by product type or uid) : searches products according to the search criteria provided
178
+ * Search products (by product type or uid): searches products according to the search criteria provided
179
179
 
180
- * Download products : download product “as is"
180
+ * Download products: download product “as is"
181
181
 
182
182
  EODAG is developed in Python. It is structured according to a modular plugin architecture, easily extensible and able to
183
183
  integrate new data providers. Three types of plugins compose the tool:
184
184
 
185
- * Catalog search plugins, responsible for searching data (OpenSearch, CSW, ...), building paths, retrieving quicklook,
185
+ * Catalog search plugins, responsible for searching data (STAC, OpenSearch, OData, ...), building paths, retrieving quicklook,
186
186
  combining results
187
187
 
188
- * Download plugins, allowing to download and retrieve data locally (via FTP, HTTP, ..), always with the same directory
188
+ * Download plugins, allowing to download and retrieve data locally (via HTTP, S3, ...), always with the same directory
189
189
  organization
190
190
 
191
191
  * Authentication plugins, which are used to authenticate the user on the external services used (JSON Token, Basic Auth, OAUTH, ...).
192
192
 
193
- EODAG can be run as STAC client or server <https://eodag.readthedocs.io/en/latest/stac.html>`_.
194
-
195
193
  Read `the documentation <https://eodag.readthedocs.io/en/latest/>`_ for more insights.
196
194
 
197
195
  .. image:: https://raw.githubusercontent.com/CS-SI/eodag/develop/docs/_static/eodag_overview.png
@@ -318,7 +316,7 @@ An eodag instance can be exposed through a STAC compliant REST api from the comm
318
316
 
319
317
  .. code-block:: bash
320
318
 
321
- docker run -p 5000:5000 --rm csspace/eodag-server:3.6.0
319
+ docker run -p 5000:5000 --rm csspace/eodag-server:3.8.0
322
320
 
323
321
  You can also browse over your STAC API server using `STAC Browser <https://github.com/radiantearth/stac-browser>`_.
324
322
  Simply run:
@@ -1,15 +1,15 @@
1
1
  eodag/__init__.py,sha256=qADIO6H3KR0CMs0qePdJROjSzcGnHaYpv-RFIk18WGQ,1608
2
- eodag/cli.py,sha256=fcowMh_LRYdW1XPPxrxpyK0tn66iYTjx497BF3zoSHI,30253
3
- eodag/config.py,sha256=YgAoxFYAsM0jgjw_UUq1T1J0JmGNqsKFfqF1rLf8Zws,48012
2
+ eodag/cli.py,sha256=XCa5Q1rt5ZCq4QNm8SGknNyadYlS9TIEZRukMvcEgH4,30326
3
+ eodag/config.py,sha256=Y_2WBjeLZz7aHMBouCDKWNtsqCWAUstVjOylbNNl4f0,48438
4
4
  eodag/crunch.py,sha256=fLVAPGVPw31N_DrnFk4gkCpQZLMY8oBhK6NUSYmdr24,1099
5
5
  eodag/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
6
6
  eodag/api/__init__.py,sha256=ytr30NUVmEtmJTsp3QCwkCIhS1nF6UlFCv0vmySHN7g,735
7
- eodag/api/core.py,sha256=_Vu-TfwUMCbjqCHFmI7NAl2YAXSiCxqhjjamfTwQu6Y,112822
7
+ eodag/api/core.py,sha256=QM2w7pFw5EjidSgWVEZyJE76dLtJaUHN4cN5qQqAE18,109071
8
8
  eodag/api/search_result.py,sha256=2Y2W3xDUyainwcyYBQljGRi6oyOqTTspgCgIlNG4kCc,14383
9
9
  eodag/api/product/__init__.py,sha256=k5iNHxXX6wDLsUo725W4U_Jz8CVbZTbfE8R9s1YQwKA,2508
10
10
  eodag/api/product/_assets.py,sha256=9bWIe_SYvsQO-q_lQFd7SxhUIWv7feze2-wnXOe8hhs,7570
11
11
  eodag/api/product/_product.py,sha256=UXCaWUtkAGWVCfF68zWCYDoEUUfxAdC0RGaNLZ3vUQ8,26794
12
- eodag/api/product/metadata_mapping.py,sha256=-zcdnpPIrx3dDUKhRAOyV1S1R2Pd3tjEnpPSdpWuK_A,73554
12
+ eodag/api/product/metadata_mapping.py,sha256=qnoGAbptn2EZZBUSW9eeZhzQa38P-BIDp-ZgsdCKiFY,75163
13
13
  eodag/api/product/drivers/__init__.py,sha256=Sy9bGmDhWCAxvxRUf3QGijjQoQvzS1LSUMN34Usq6fM,3357
14
14
  eodag/api/product/drivers/base.py,sha256=iPAE5Jx3isxmHHFPP-jysdUylYbsbIq6UejU3qsMROE,4111
15
15
  eodag/api/product/drivers/generic.py,sha256=RER088E5_mqyGw1Pa4Kxea5YMFakAHFNcZEQINRiDwM,2069
@@ -17,7 +17,7 @@ eodag/api/product/drivers/sentinel1.py,sha256=xpvhOvVhpuwVihPMo_q79VI67ru-FqKtbR
17
17
  eodag/api/product/drivers/sentinel2.py,sha256=dMfIrcwF4h8KoyUj94yPUhRiN7FIef4mTzfbkkhLIc8,3124
18
18
  eodag/plugins/__init__.py,sha256=KQkD5aVwb9I6C-Rmi5ABEG1-j8w5FP1zKN12vagsT9Y,739
19
19
  eodag/plugins/base.py,sha256=bBp4k8QYJFEE6CRctrVwjws6suBwQdCLrLmvoGAmG3A,2670
20
- eodag/plugins/manager.py,sha256=W_LO0gisjtHWgR50DHpduoD2wcP4yxx8YB4t4jl_mAw,20150
20
+ eodag/plugins/manager.py,sha256=EJOMg3nxaZB_J9gt5wqMMm7Rs1zHKyYehwyYNfVrMbE,20143
21
21
  eodag/plugins/apis/__init__.py,sha256=PyY4f7P2iu3MkLPnw5eOrVew2fuavbBL3Asci3Ulwoo,744
22
22
  eodag/plugins/apis/base.py,sha256=oCEKVtIbOjzNgM3lzaCCtO-DhU2PvGfKaATG6OxR-V8,2818
23
23
  eodag/plugins/apis/ecmwf.py,sha256=xIUCjFOTtVdcpNj7MRKlSOXN8nZGusbH5tqEb0su3No,11387
@@ -29,7 +29,7 @@ eodag/plugins/authentication/generic.py,sha256=z-u4WMixeG4nKwc70cUGVBXt3IVheDPA6
29
29
  eodag/plugins/authentication/header.py,sha256=U_KnUqgZTLHXM5OKdGbH6jRqoQ0uIfOoxO6krUeAAcQ,4284
30
30
  eodag/plugins/authentication/keycloak.py,sha256=m5c6Os_T8UGfdXS9SemhuUBhwsC4foxmrVA6VXEXamU,7358
31
31
  eodag/plugins/authentication/oauth.py,sha256=fCMx7OxS3JNO9lLZhQNnL9lsBB9nFwZJLEYXI49QRtw,1952
32
- eodag/plugins/authentication/openid_connect.py,sha256=jj1iAvENJTIlBr8nnlQJ5TW8-Qi9V_85QVBLExy41HA,27068
32
+ eodag/plugins/authentication/openid_connect.py,sha256=lj-9RPz2BADU-1ckawLmuSi3TSexABsDDPCHLp8Frsc,27084
33
33
  eodag/plugins/authentication/qsauth.py,sha256=bkepO_sFRIhYm3Dzecx3VJP0Ap37vUuJSRmEY8HrV1U,3947
34
34
  eodag/plugins/authentication/sas_auth.py,sha256=bDqMgcteUH15Vs8vBoYCeA0hxCrCHIPwFYRrEtMtp9Y,4767
35
35
  eodag/plugins/authentication/token.py,sha256=f2SossIJ_XlnBuOw_OprLNrF1p-uolL_KEX71_BhzKw,15798
@@ -42,29 +42,29 @@ eodag/plugins/crunch/filter_latest_tpl_name.py,sha256=pP4EDP73mQg1zvkVm1Uo4nGAgw
42
42
  eodag/plugins/crunch/filter_overlap.py,sha256=mkm5_ljgK_7QOOp-KgJjDjbVfss4gwRjIYUTMyKrw5o,7272
43
43
  eodag/plugins/crunch/filter_property.py,sha256=2BKb7wxw1Yi2NTtnPCBtdZ-caJXxlVUUS2ps4LHXOMI,3187
44
44
  eodag/plugins/download/__init__.py,sha256=zqszaeNgYP0YHlZDkLMf6odcwNw0KrAahGpcA-l0kAw,740
45
- eodag/plugins/download/aws.py,sha256=zXlB6V9zJ-_dSxJA6tculCr3Oz9IMxdGByJ3oXwOahU,58592
46
- eodag/plugins/download/base.py,sha256=60k2qZahGsNYA-Oul3f7-aWNh7ZVd7cHxPN1CMuTqMI,30736
47
- eodag/plugins/download/creodias_s3.py,sha256=RoEhYHtsPDbfrZhBllYoek0r7YzP8Upf5CPgc-PnlZM,4151
48
- eodag/plugins/download/http.py,sha256=foXxlzn68foXZb1WCTJXFTB20L_QSIfOCq04mJ2L35U,58288
49
- eodag/plugins/download/s3rest.py,sha256=K5zukTNw99I3s0rpKujhIIZK3CFgeHVwUccYWk5kfj0,14999
45
+ eodag/plugins/download/aws.py,sha256=9TdWseGib-sLWivfI0w4l-9O-ZlppgMsbzLSuirYzXE,57249
46
+ eodag/plugins/download/base.py,sha256=hllNFdDMWnTq0zjiTQPr-p4iX_OksCJ6PAt0a35qX1A,30813
47
+ eodag/plugins/download/creodias_s3.py,sha256=9YrBwb7FiLnREVcaJB5ktlrDeIHPRAC-tH1qDjkwCMs,4350
48
+ eodag/plugins/download/http.py,sha256=CBr7x0KLsQb3X6QqZ7FZvQEm0z-MN9BfKVWyZKudRSE,58354
49
+ eodag/plugins/download/s3rest.py,sha256=RoMFpy7HPXFwK_gpy8tkZG1coNITvRj2D9hAmdrAnv0,15147
50
50
  eodag/plugins/search/__init__.py,sha256=bBrl3TffoU1wVpaeXmTEIailoh9W6fla4IP-8SWqA9U,2019
51
- eodag/plugins/search/base.py,sha256=NqlEBCjdBlW_9jf6aaMwjs2jZ8BhhhDub7Q5GAZgSzg,18839
52
- eodag/plugins/search/build_search_result.py,sha256=CaiWWqQGMifVJqULhnWHLhEqyoakftdxloryW-OsGZk,57635
53
- eodag/plugins/search/cop_marine.py,sha256=GIDMeyuzXApHfxbMxSMUZyqR685NpuPYKHAHf2OeMt4,20373
51
+ eodag/plugins/search/base.py,sha256=tqn1JB2JV4Z_yRXFHUiAfMGjcJqr90_QYyevV0DoGLE,20017
52
+ eodag/plugins/search/build_search_result.py,sha256=9a2HZijHvQWplyJav1vr_dDgoOPQeI1MIttSf3rBYBA,57652
53
+ eodag/plugins/search/cop_marine.py,sha256=-GrFQjVZb7SfS6BbI0wnGc2VuRcQu7aqtWg3EWjQhE0,20485
54
54
  eodag/plugins/search/creodias_s3.py,sha256=rBZf3Uza7z3VuBdoUJQ9kuufGgACKVsEvK3phUo7C7M,3379
55
55
  eodag/plugins/search/csw.py,sha256=de8CNjz4bjEny27V0RXC7V8LRz0Ik3yqQVjTAc_JlyA,12548
56
- eodag/plugins/search/data_request_search.py,sha256=IN6sgQqx5fedQI6jxOkUdUk_mRLAKmCRW8S7pHgOOnA,27332
57
- eodag/plugins/search/qssearch.py,sha256=u8bAFwyyUcmbIovDnquuxitahEvYNPu3mZF4sO1DvFQ,92687
56
+ eodag/plugins/search/data_request_search.py,sha256=m38kpTXJT2fC8Mk894KlxKb14dz-nhAs_71-5kpnehU,27461
57
+ eodag/plugins/search/qssearch.py,sha256=qAqpgeUGytxRi6s1oVnw3fw7EsyNOtW_nFxF1Tb1g0M,94795
58
58
  eodag/plugins/search/stac_list_assets.py,sha256=OOCMyjD8XD-m39k0SyKMrRi4K8Ii5mOQsA6zSAeQDGI,3435
59
59
  eodag/plugins/search/static_stac_search.py,sha256=CPynjpNw0gXa6g6hA2zSkbwhfgU-9IBCmJtknuhnFKk,10515
60
- eodag/resources/ext_product_types.json,sha256=TI9CVhLp92DlbQvufRKA4JMUQF14HZ06ipq_DpTeBYU,3117426
60
+ eodag/resources/ext_product_types.json,sha256=J-vJ6y_rtcfmhXZNUC64t_jM8Ss0141duF0brdPxArg,2474095
61
61
  eodag/resources/locations_conf_template.yml,sha256=_eBv-QKHYMIKhY0b0kp4Ee33RsayxN8LWH3kDXxfFSk,986
62
- eodag/resources/product_types.yml,sha256=Ci1tncz_tARYuft74lSoogJJ5_oDC-4VIJ5if4nyGCM,417283
63
- eodag/resources/providers.yml,sha256=oSz1NkGj4tjiaZjJfBFxmaXBFptdSD5SNySzDdqOdA0,224138
64
- eodag/resources/stac.yml,sha256=XgQFkJEfu_f2ZiVM5L1flkew7wq55p_PJmDuVkOG3fs,10442
62
+ eodag/resources/product_types.yml,sha256=GWtWBa0MvoWfD1ZuBR3IQYt6GcZvCTvGwqVFxoE0U2k,412710
63
+ eodag/resources/providers.yml,sha256=14UWxfc1saS926uI9GaZp2iUlqS7bk3gNLUxcYWsKak,212940
64
+ eodag/resources/stac.yml,sha256=QnrBulL2pHZrPH4pI7rQtKDxmgP2ZbBcufFqFJPCL7A,10473
65
65
  eodag/resources/stac_api.yml,sha256=2FdQL_qBTIUlu6KH836T4CXBKO9AvVxA_Ub3J1RP81A,68881
66
- eodag/resources/stac_provider.yml,sha256=2yfdnuhJYV1f5el3aFkunoPqHAcD8oCDzvASbmldIvY,6703
67
- eodag/resources/user_conf_template.yml,sha256=VitU2oHwcWNd7CoONfHabMBGwCPfYjwyU3cX63oJaIs,7765
66
+ eodag/resources/stac_provider.yml,sha256=VbRGLXAv5rgGNnmmcqOeFcfmco56YpGGvpnT0PMvcwY,6714
67
+ eodag/resources/user_conf_template.yml,sha256=rjgc-gp4Ufw9dLV-D9lQFBm-YLApZtGTybq3cHT48as,7508
68
68
  eodag/resources/shp/ne_110m_admin_0_map_units.VERSION.txt,sha256=CHSo_jbv-4d4D0MYRbWn2FvmV_K9mYzo7qznF4YNO3g,7
69
69
  eodag/resources/shp/ne_110m_admin_0_map_units.cpg,sha256=FG1nif_gM6UpfBrQRuamLuNTGbhrAhRE8FtuoqqKH0o,6
70
70
  eodag/resources/shp/ne_110m_admin_0_map_units.dbf,sha256=uEEO22hZ_crWxMNhuQ_ix889c1Us1awYXAglxbf1K-s,393747
@@ -75,11 +75,11 @@ eodag/rest/__init__.py,sha256=v4SI9gLuFP81YXi5_k98lvVNGzz6h8YZ_aUdhKAbE2M,916
75
75
  eodag/rest/cache.py,sha256=dSgpw6uWDq45qxfD25LXkB-9Qk0OEb5L8UOl7yuMPEU,2097
76
76
  eodag/rest/config.py,sha256=qWXukdSB6cSpkZszkPSGPGn5oiVfKEC3rPGp0q-2c4E,2112
77
77
  eodag/rest/constants.py,sha256=XsNgjzv0Qvw1hhjeuscDuyQpCm99g3O-hEyslPSiFzQ,945
78
- eodag/rest/core.py,sha256=PFhYnp2k3IsreZvKwuzED4T6hvjDd8o3QFL3FqaP_Ds,26612
78
+ eodag/rest/core.py,sha256=rZD6AFxCORvnNFeYSR8eab3UuVymEnDQJBouVGKNUA4,26432
79
79
  eodag/rest/errors.py,sha256=ShYTl_cQej3H20jRtX_HLNKpnB6J4mbl0uhJTifzDj0,6736
80
80
  eodag/rest/server.py,sha256=yssir9bumRwoEibgTTKOgXBli3uwTJkhbVW7Q7F2Uqc,18253
81
81
  eodag/rest/server.wsgi,sha256=ssM4JQi8tZpOYj03CTdM0weyUF1b3Lbh38pdD-vBfXs,152
82
- eodag/rest/stac.py,sha256=5t7qsSr4qVINHhjebW2SyYZVE0yzSyD1xa9zOcIuvNs,36655
82
+ eodag/rest/stac.py,sha256=aBAoJ0hneBPej-n4e7TXlPBix7cm2IaDnVCY0dDL548,36496
83
83
  eodag/rest/templates/README,sha256=qFgCBE6XC4YiXkpPoSHkYbMTQr8Zg5Wc5eAKVcooXmw,57
84
84
  eodag/rest/types/__init__.py,sha256=Bu0C3dzXHe8kocnz2PIHV0GjQWlAQas6ToIfwusNPQs,742
85
85
  eodag/rest/types/collections_search.py,sha256=TRZI72a1W29a2e_mg9cQpFUcTTEG3_SSsfYrZZuXMLA,1527
@@ -94,22 +94,22 @@ eodag/types/bbox.py,sha256=jbfX58KOKIl0OoGZc93kAYhG_mEOjuBQGJtR2hl3-_Y,4354
94
94
  eodag/types/download_args.py,sha256=urSl5KbLRN1XetMa2XzxYltny8CCFmHpjxU3j3BEGO8,1565
95
95
  eodag/types/queryables.py,sha256=1Bb-n05YKSUq-rsVm-_2HoYaCBWp4SFHI4uWngpRmiw,10551
96
96
  eodag/types/search_args.py,sha256=EtG8nXnApBnYrFo5FVvsvvEqRlqTxJ0lrmIem9Wtg8c,5649
97
- eodag/types/whoosh.py,sha256=VXpWAZaXLR_RRnI9gh5iwkqn1n63krVGj2SX0rB2mQo,7225
98
- eodag/utils/__init__.py,sha256=7YemLhM5VhUWvxjo10ghUXVfKLy54BLh8Ml403si4O8,53830
97
+ eodag/utils/__init__.py,sha256=xpFPjYZdMBhaWV4M5wTBv7_FY16K1mge-8V2soiTZ5U,54187
99
98
  eodag/utils/cache.py,sha256=UNvnzhJnNBuKLdH_0KnhuTMlBvz4GS3nr2IH2Lj6Swc,2580
100
99
  eodag/utils/env.py,sha256=_sgCzDmaJnMnCv1qk9xe9jBhBKqqXbEYmsyGYwYw4NI,1085
101
- eodag/utils/exceptions.py,sha256=hYeq5GzMqW50o6mSUUlvOpsfU0eRjwhpqXTSE5MFv9Q,4452
100
+ eodag/utils/exceptions.py,sha256=64M6xNsWWThEspIrZvxPYCS47wBH4PL7YXXw8fcPCbo,4588
101
+ eodag/utils/free_text_search.py,sha256=et6nn5qmzbUq0T9tup6M2kMCwn2CvQgwVq6M6XOKEpg,8057
102
102
  eodag/utils/import_system.py,sha256=1vwcSRlsZwuaP8ssrpRBP5jldZ54eLv2ttNCdLf0TtA,3901
103
103
  eodag/utils/logging.py,sha256=KoMsyS1f6O1hr_SMDOIxvt842mOJgmu_yLUk0-0EKFs,3507
104
104
  eodag/utils/notebook.py,sha256=AUxtayvu26qYf3x3Eu3ujRl1XDgy24EfQaETbqmXSZw,2703
105
105
  eodag/utils/repr.py,sha256=o6NhScogBPI69m83GsHh3hXONb9-byPfuWgJ1U39Kfw,5463
106
106
  eodag/utils/requests.py,sha256=avNHKrOZ7Kp6lUA7u4kqupIth9MoirLzDsMrrmQDt4s,4560
107
107
  eodag/utils/rest.py,sha256=a9tlG_Y9iQXLeyeLyecxFNbopGHV-8URecMSRs0UXu0,3348
108
- eodag/utils/s3.py,sha256=2mspYgEYGA1IDbruMMDdJ2DoxyX3riSlV7PDIu7carg,7989
108
+ eodag/utils/s3.py,sha256=hHlliahIJjQQP8VnRAhbw17_FFa4E6gFo52HchgarVU,29553
109
109
  eodag/utils/stac_reader.py,sha256=8r6amio5EtwGF9iu9zHaGDz4oUPKKeXRuyTzPNakrO4,9406
110
- eodag-3.6.0.dist-info/licenses/LICENSE,sha256=4MAecetnRTQw5DlHtiikDSzKWO1xVLwzM5_DsPMYlnE,10172
111
- eodag-3.6.0.dist-info/METADATA,sha256=LAE9cM2bit_qM8ThmCs7hfRo2c0mnn2Jy7KZJZQ4YoQ,15537
112
- eodag-3.6.0.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
113
- eodag-3.6.0.dist-info/entry_points.txt,sha256=krdrBOQso6kAcSekV9ItEYAkE8syTC4Ev75bI781VgE,2561
114
- eodag-3.6.0.dist-info/top_level.txt,sha256=025IMTmVe5eDjIPP4KEFQKespOPMQdne4U4jOy8nftM,6
115
- eodag-3.6.0.dist-info/RECORD,,
110
+ eodag-3.8.0.dist-info/licenses/LICENSE,sha256=4MAecetnRTQw5DlHtiikDSzKWO1xVLwzM5_DsPMYlnE,10172
111
+ eodag-3.8.0.dist-info/METADATA,sha256=enfy80bL9Ag3dGbxmgU8D4kzlDUdO_3UTiUyvjtXa5k,15472
112
+ eodag-3.8.0.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
113
+ eodag-3.8.0.dist-info/entry_points.txt,sha256=krdrBOQso6kAcSekV9ItEYAkE8syTC4Ev75bI781VgE,2561
114
+ eodag-3.8.0.dist-info/top_level.txt,sha256=025IMTmVe5eDjIPP4KEFQKespOPMQdne4U4jOy8nftM,6
115
+ eodag-3.8.0.dist-info/RECORD,,
eodag/types/whoosh.py DELETED
@@ -1,203 +0,0 @@
1
- # -*- coding: utf-8 -*-
2
- # Copyright 2024, CS Systemes d'Information, https://www.csgroup.eu/
3
- #
4
- # This file is part of EODAG project
5
- # https://www.github.com/CS-SI/EODAG
6
- #
7
- # Licensed under the Apache License, Version 2.0 (the "License");
8
- # you may not use this file except in compliance with the License.
9
- # You may obtain a copy of the License at
10
- #
11
- # http://www.apache.org/licenses/LICENSE-2.0
12
- #
13
- # Unless required by applicable law or agreed to in writing, software
14
- # distributed under the License is distributed on an "AS IS" BASIS,
15
- # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16
- # See the License for the specific language governing permissions and
17
- # limitations under the License.
18
- from whoosh.fields import Schema
19
- from whoosh.index import _DEF_INDEX_NAME, FileIndex
20
- from whoosh.matching import NullMatcher
21
- from whoosh.qparser import OrGroup, QueryParser, plugins
22
- from whoosh.query.positional import Phrase
23
- from whoosh.query.qcore import QueryError
24
- from whoosh.util.text import utf8encode
25
- from whoosh.writing import SegmentWriter
26
-
27
-
28
- class RobustPhrase(Phrase):
29
- """
30
- Matches documents containing a given phrase.
31
- """
32
-
33
- def matcher(self, searcher, context=None):
34
- """
35
- Override the default to not raise error on match exception but simply return not found
36
- Needed to handle phrase search in whoosh.fields.IDLIST
37
- """
38
- try:
39
- return super().matcher(searcher, context)
40
- except QueryError:
41
- return NullMatcher()
42
-
43
-
44
- class EODAGQueryParser(QueryParser):
45
- """
46
- A hand-written query parser built on modular plug-ins.
47
-
48
- Override the default to include specific EODAG configuration
49
- """
50
-
51
- def __init__(
52
- self,
53
- filters: list[str],
54
- schema: Schema,
55
- ):
56
- """
57
- EODAG QueryParser initialization
58
-
59
- :param filters: list of fieldnames to filter on
60
- :param schema: Whoosh Schema
61
- """
62
- super().__init__(
63
- None,
64
- schema=schema,
65
- plugins=[
66
- plugins.SingleQuotePlugin(),
67
- plugins.FieldsPlugin(),
68
- plugins.WildcardPlugin(),
69
- plugins.PhrasePlugin(),
70
- plugins.GroupPlugin(),
71
- plugins.OperatorsPlugin(),
72
- plugins.BoostPlugin(),
73
- plugins.EveryPlugin(),
74
- plugins.RangePlugin(),
75
- plugins.PlusMinusPlugin(),
76
- plugins.MultifieldPlugin(filters, fieldboosts=None),
77
- ],
78
- phraseclass=RobustPhrase,
79
- group=OrGroup,
80
- )
81
-
82
-
83
- class CleanSegmentWriter(SegmentWriter):
84
- """Override to clean up writer for failed document add when exceptions were absorbed
85
- cf: https://github.com/whoosh-community/whoosh/pull/543
86
- """
87
-
88
- def add_document(self, **fields):
89
- """Add document"""
90
- self._check_state()
91
- perdocwriter = self.perdocwriter
92
- schema = self.schema
93
- docnum = self.docnum
94
- add_post = self.pool.add
95
-
96
- docboost = self._doc_boost(fields)
97
- fieldnames = sorted(
98
- [name for name in fields.keys() if not name.startswith("_")]
99
- )
100
- self._check_fields(schema, fieldnames)
101
-
102
- perdocwriter.start_doc(docnum)
103
-
104
- try:
105
- for fieldname in fieldnames:
106
- value = fields.get(fieldname)
107
- if value is None:
108
- continue
109
- field = schema[fieldname]
110
-
111
- length = 0
112
- if field.indexed:
113
- # TODO: Method for adding progressive field values, ie
114
- # setting start_pos/start_char?
115
- fieldboost = self._field_boost(fields, fieldname, docboost)
116
- # Ask the field to return a list of (text, weight, vbytes)
117
- # tuples
118
- items = field.index(value)
119
- # Only store the length if the field is marked scorable
120
- scorable = field.scorable
121
- # Add the terms to the pool
122
- for tbytes, freq, weight, vbytes in items:
123
- weight *= fieldboost
124
- if scorable:
125
- length += freq
126
- add_post((fieldname, tbytes, docnum, weight, vbytes))
127
-
128
- if field.separate_spelling():
129
- spellfield = field.spelling_fieldname(fieldname)
130
- for word in field.spellable_words(value):
131
- word = utf8encode(word)[0]
132
- add_post((spellfield, word, 0, 1, vbytes))
133
-
134
- vformat = field.vector
135
- if vformat:
136
- analyzer = field.analyzer
137
- # Call the format's word_values method to get posting values
138
- vitems = vformat.word_values(value, analyzer, mode="index")
139
- # Remove unused frequency field from the tuple
140
- vitems = sorted(
141
- (text, weight, vbytes) for text, _, weight, vbytes in vitems
142
- )
143
- perdocwriter.add_vector_items(fieldname, field, vitems)
144
-
145
- # Allow a custom value for stored field/column
146
- customval = fields.get("_stored_%s" % fieldname, value)
147
-
148
- # Add the stored value and length for this field to the per-
149
- # document writer
150
- sv = customval if field.stored else None
151
- perdocwriter.add_field(fieldname, field, sv, length)
152
-
153
- column = field.column_type
154
- if column and customval is not None:
155
- cv = field.to_column_value(customval)
156
- perdocwriter.add_column_value(fieldname, column, cv)
157
- except Exception as ex:
158
- # cancel doc
159
- perdocwriter._doccount -= 1
160
- perdocwriter._indoc = False
161
- raise ex
162
-
163
- perdocwriter.finish_doc()
164
- self._added = True
165
- self.docnum += 1
166
-
167
-
168
- class CleanFileIndex(FileIndex):
169
- """Override to call CleanSegmentWriter"""
170
-
171
- def writer(self, procs=1, **kwargs):
172
- """file index writer"""
173
- if procs > 1:
174
- from whoosh.multiproc import MpWriter
175
-
176
- return MpWriter(self, procs=procs, **kwargs)
177
- else:
178
- return CleanSegmentWriter(self, **kwargs)
179
-
180
-
181
- def create_in(dirname, schema, indexname=None):
182
- """
183
- Override to call the CleanFileIndex.
184
-
185
- Convenience function to create an index in a directory. Takes care of
186
- creating a FileStorage object for you.
187
-
188
- :param dirname: the path string of the directory in which to create the
189
- index.
190
- :param schema: a :class:`whoosh.fields.Schema` object describing the
191
- index's fields.
192
- :param indexname: the name of the index to create; you only need to specify
193
- this if you are creating multiple indexes within the same storage
194
- object.
195
- :returns: :class:`Index`
196
- """
197
-
198
- from whoosh.filedb.filestore import FileStorage
199
-
200
- if not indexname:
201
- indexname = _DEF_INDEX_NAME
202
- storage = FileStorage(dirname)
203
- return CleanFileIndex.create(storage, schema, indexname)
File without changes