Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

API download fails to include eeg and extended data #277

Closed
deniztepe opened this issue Jul 1, 2022 · 4 comments
Closed

API download fails to include eeg and extended data #277

deniztepe opened this issue Jul 1, 2022 · 4 comments
Assignees
Labels
🐛 bug Something isn't working

Comments

@deniztepe
Copy link
Contributor

Calling the Mastr.download() method with API settings, it makes a different if I give the technology parameter as string or as list of strings. It shouldn't matter. Technology parameter given as string, eeg and extended data are not downloaded. This has to have something to do with parameter parsing in some deeper MastrMirror methods.

mastr.download(
    method="API",
    technology="biomass",
    api_processes=api_processes,
    api_limit=limit,
    api_chunksize=chunksize,
    api_date=date,
    api_data_types=data_types,
    api_location_types=location_types,
)
@deniztepe deniztepe added the 🐛 bug Something isn't working label Jul 1, 2022
@FlorianK13
Copy link
Member

I would suggest that we change the following: Only the upper method from mastr.download() accepts technology as string, list, or None. All methods below this, eg all xml download and soap api methods only accept technology as a list of strings.

Then we check the technology type once at the very beginning and convert string-> list and None->list, from there on we trust that type(technology) = list.

@chrwm
Copy link
Member

chrwm commented Jul 6, 2022

I think this is a good solution!

@deniztepe
Copy link
Contributor Author

Implement after refactoring #272 to avoid possible conflicts.

@deniztepe
Copy link
Contributor Author

Closing, because temporally solved with #327
Clear implementation should be added with the feature #308

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
🐛 bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants