Setting Custom provider as preferred doesn't work
See original GitHub issueDescribe the bug Setting custom provider as preferred doesn’t seem to work.
Code To Reproduce
from eodag import setup_logging
from eodag.api.core import EODataAccessGateway
if __name__ == "__main__":
# Create an EODAG custom STAC provider
setup_logging(verbose=3)
dag = EODataAccessGateway()
# Add the custom STAC provider + output + login an password
outputs_prefix = r"D:\capella_eodag"
dag.update_providers_config("""
capella_provider:
search:
type: StaticStacSearch
api_endpoint: https://capella-open-data.s3.us-west-2.amazonaws.com/stac/capella-open-data-by-product-type/capella-open-data-slc/collection.json
products:
GENERIC_PRODUCT_TYPE:
productType: '{productType}'
download:
type: AwsDownload
flatten_top_dirs: True
outputs_prefix: %s
""" % (outputs_prefix))
# Set the custom STAC provider as preferred
dag.set_preferred_provider("capella_provider")
print(dag.get_preferred_provider())
Output
2022-12-07 10:40:35,074 eodag.config [INFO ] (config ) Loading user configuration from: C:\Users\rbraun\.config\eodag\eodag.yml
2022-12-07 10:40:35,236 eodag.core [INFO ] (core ) usgs: provider needing auth for search has been pruned because no crendentials could be found
2022-12-07 10:40:35,236 eodag.core [INFO ] (core ) aws_eos: provider needing auth for search has been pruned because no crendentials could be found
2022-12-07 10:40:35,360 eodag.core [DEBUG ] (core ) Opening product types index in C:\Users\rbraun\.config\eodag\.index
2022-12-07 10:40:35,370 eodag.core [INFO ] (core ) Locations configuration loaded from C:\Users\rbraun\.config\eodag\locations.yml
2022-12-07 10:40:35,370 eodag.config [INFO ] (config ) capella_provider: unknown provider found in user conf, trying to use provided configuration
('peps', 1)
Environment:
- Python version: Python 3.9.13
- EODAG version:
eodag (Earth Observation Data Access Gateway): version 2.7.0
Additional context
The custom provider comes from #519
Issue Analytics
- State:
- Created 9 months ago
- Comments:5 (3 by maintainers)
Top Results From Across the Web
Providing dependencies in modules - Angular
A provider is an instruction to the Dependency Injection system on how to obtain a value for a dependency. Most of the time,...
Read more >Providers | NestJS - A progressive Node.js framework
Many of the basic Nest classes may be treated as a provider – services, ... If your class doesn't extend another provider, you...
Read more >User and Workspace Settings - Visual Studio Code
To open the Settings editor, use the following VS Code menu command: On Windows/Linux - File > Preferences > Settings. On macOS -...
Read more >Customize accessibility settings for specific apps on iPhone
Go to Settings > Accessibility > Per-App Settings. Tap Add App, then choose an app, Home Screen, or Settings. Tap the app or...
Read more >About client settings in Configuration Manager - Microsoft Learn
Learn about the default and custom settings for controlling client behaviors.
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Can you try to install v2.7.0 in a new virtual environment, and to use a new empty configuration file (instead of your
~/.config/eodag/eodag.yml
) ? This may help us to identify what causes this issue.I also tried your example on windows, and got
capella_provider
as preferred provider as expected…I tried to add one lib at a time, and it seems to fail when adding
eodag-sentinelsat
but I don’t know why 😰