Skip to content
New issue

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

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

Already on GitHub? Sign in to your account

Updates metadata. Makes check if station is in metadata #50

Merged
merged 15 commits into from
Sep 23, 2024
Merged

Conversation

dulte
Copy link
Collaborator

@dulte dulte commented Sep 13, 2024

Small changes to eeareader

@dulte dulte self-assigned this Sep 13, 2024
@dulte dulte added the bug Something isn't working label Sep 13, 2024
@dulte dulte added this to the m2024-10 milestone Sep 13, 2024
@dulte dulte requested a review from heikoklein September 13, 2024 09:48
@dulte
Copy link
Collaborator Author

dulte commented Sep 13, 2024

I've added the possibility to change units with a factor. Factor is added to data.toml. Might want a separate file for these factors

@dulte
Copy link
Collaborator Author

dulte commented Sep 13, 2024

I'm not sure with the files fail due to not finding data.toml. Will have a look next week

@dulte dulte marked this pull request as draft September 13, 2024 10:13
Copy link
Member

@heikoklein heikoklein left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tests not working (still draft)? Very strange choice of variable/file-names.

@@ -73,6 +78,7 @@ def __init__(
self._set_filters(filters)

self.metadata = self._read_metadata(filename)
self.datafile = self._read_data()
Copy link
Member

@heikoklein heikoklein Sep 13, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

both datafile and _read_data and data.toml are very confusing here. It is everything but data=measurement of e.g. 17.35µg/m³, please find a better name. cfg or setup? And definitely don't call something for file which is neither a filename nor filehandle.

@dulte
Copy link
Collaborator Author

dulte commented Sep 13, 2024

@heikoklein . Yes, right before you answered I changed it to a draft. The tests fail because they can't find data.toml, and I'm not entirely sure why... going to look at it over the weekend.

I've added a simple unit conversion field as well in data.toml. It seems to work, but I have to add some tests for that as well before the pr is ready for review. It might also be the wrong way of doing a unit change (changing it without making a new variable). So some work before the pr is ready

@dulte
Copy link
Collaborator Author

dulte commented Sep 15, 2024

Note to self: remove unit change from data.toml, and add it as a possible argument to the reader instead.

Or maybe it as a wrapper to pyaro, similar to the variable name change wrapper, so all readers can do unit change.

@dulte dulte marked this pull request as ready for review September 16, 2024 14:06
@dulte
Copy link
Collaborator Author

dulte commented Sep 16, 2024

@heikoklein. Fixed some problems, and made some new ones. But it is now ready for review

Copy link
Member

@heikoklein heikoklein left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good, except for linting. You should really fix your black setup.

@dulte dulte merged commit 002af79 into main-dev Sep 23, 2024
4 checks passed
@dulte dulte deleted the update_eea branch September 23, 2024 08:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants