ProdType not found for scihub
loiclozinrae opened this issue · 1 comments
loiclozinrae commented
Describe the bug
When searching products on scihub for prodtype 'S1_SAR_GRD' or 'S2_MSI_L2A', Eodag warns that product type is not available
Code To Reproduce
from eodag.utils.logging import setup_logging
setup_logging(verbose=3)
from eodag import EODataAccessGateway
dag= EODataAccessGateway()
dag.set_preferred_provider("scihub")
dag.search(
productType='S1_SAR_GRD',
geom='POLYGON ((-3.000272 48.753013, -1.506731 48.743337, -1.535213 47.755819, -3.000267 47.765167, -3.000272 48.753013))'),
start='2022-05-01',
end='2022-08-31'
)
Output
2023-03-29 10:26:04,517 eodag.core [DEBUG ] (core ) Searching for all the products with provider peps and a maximum of 500 items per page.
2023-03-29 10:26:04,517 eodag.core [WARNING ] (core ) Product type 'S1_SAR_GRD' is not available with provider 'scihub'. Searching it on provider 'peps' instead.
2023-03-29 10:26:04,518 eodag.core [DEBUG ] (core ) Using plugin class for search: QueryStringSearch
2023-03-29 10:26:04,518 eodag.core [INFO ] (core ) Iterate search over multiple pages: page #1
2023-03-29 10:26:04,518 eodag.plugins.search.qssearch [DEBUG ] (qssearch ) Mapping eodag product type to provider product type
2023-03-29 10:26:04,518 eodag.plugins.search.qssearch [DEBUG ] (qssearch ) Getting provider product type definition parameters for S1_SAR_GRD
2023-03-29 10:26:04,518 eodag.plugins.search.qssearch [DEBUG ] (qssearch ) Getting provider product type definition parameters for S1_SAR_GRD
2023-03-29 10:26:04,519 eodag.plugins.search.qssearch [DEBUG ] (qssearch ) Building the query string that will be used for search
2023-03-29 10:26:04,519 eodag.plugins.search.qssearch [DEBUG ] (qssearch ) Retrieving queryable metadata from metadata_mapping
2023-03-29 10:26:04,519 eodag.plugins.search.qssearch [INFO ] (qssearch ) Sending search request: https://peps.cnes.fr/resto/api/collections/S1/search.json?startDate=2022-05-01&completionDate=2022-08-31&geometry=POLYGON ((-3.0003 48.7530, -1.5067 48.7433, -1.5352 47.7558, -3.0003 47.7652, -3.0003 48.7530))&productType=GRD&maxRecords=500&page=1
2023-03-29 10:26:05,209 eodag.plugins.search.qssearch [DEBUG ] (qssearch ) Adapting 72 plugin results to eodag product representation
2023-03-29 10:26:05,301 eodag.core [DEBUG ] (core ) Iterate over pages: last products found on page 1
2023-03-29 10:26:05,301 eodag.core [INFO ] (core ) Found 72 result(s) on provider 'peps'
Environment:
- Python version: 3.8.10
- EODAG version:
eodag 2.9.1
- eodag-sentinelsat 0.4.1
loiclozinrae commented
I found the pb. I was triyng to insert scihub credentials throught the method dag.update_providers_config(yml_config) with yml_config as string containing YAML formated scihub configuration.
By initialising EODataAccessGateway with user_conf_file_path, the search works normaly.