-
-
Notifications
You must be signed in to change notification settings - Fork 56
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
Add Wetterdienst UI #398
Add Wetterdienst UI #398
Conversation
cbafad7
to
b2e5296
Compare
@@ -299,6 +299,18 @@ def __init__( | |||
|
|||
self.tidy = tidy | |||
|
|||
log.info( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We may as well move this to the .query() method and use the str/repr representation of the class.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do you mean wetterdienst.core.scalar.values.ScalarValuesCore.__str__
? Well, while I might be not be fully understanding it, currently it looks like this would have no way to see the whole picture like the provider
.
I clearly believe that this logging function is at the right place here because it covers both requests for stations and values, which is what I was aiming at.
parameter=DwdObservationDataset(parameter), | ||
resolution=DwdObservationResolution(time_resolution), | ||
period=DwdObservationPeriod(period_type), | ||
tidy=False, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I guess we should try and go via tidy here and use .groupby to create the json response. This would leave us the option to also plot the quality of the data later on. Maybe we can also create another output format for ValuesResult, that is meant to be used for the ui only?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I believe, for the first iteration, it will be fine. Pandas data frames in non-tidy format work just perfectly here. Another variant should be added carefully, maybe within another iteration.
If you want to continue working on this, you will now have a reasonable test suite at hand, which helps tremendously.
Codecov Report
@@ Coverage Diff @@
## main #398 +/- ##
==========================================
+ Coverage 88.31% 88.62% +0.30%
==========================================
Files 74 79 +5
Lines 3577 3735 +158
Branches 377 396 +19
==========================================
+ Hits 3159 3310 +151
- Misses 329 335 +6
- Partials 89 90 +1
Flags with carried forward coverage won't be shown. Click here to find out more.
Continue to review full report at Codecov.
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks Andreas for your work on bringing this into the main respository! I will try to dive deeper into this the upcoming weekend.
1c3b90b
to
46bdef5
Compare
ef0b532
to
d07fc15
Compare
This patch is an import from https://github.com/earthobservations/wetterdienst-ui.
We didn't get any sensible responses by using this system. Maybe we should use LGTM instead. However, let's just deactivate this now.
Along the lines, improve some more documents within the "Usage" section.
Also, add annotations to Figure elements in order to signal "empty data"
d07fc15
to
a6a6319
Compare
Hi there,
this patch brings in the code from the
wetterdienst-ui
repository [1] contributed by @meteoDaniel. Thank you very much!As outlined within #347 (comment), I finally have been able to take the time to bring this code to the main code base and adjust it to be compatible with the recent improvements to the Wetterdienst Python API on behalf of ec2de30.
On top of that, with 0e42cf7, I added software tests based on the
dash.testing
infrastructure.This patch is not completely ready yet, that's why I am submitting it as a preliminary draft. More details about what has to be added and fixed are summarized at the "Backlog" section below.The patch should be ready to go.With kind regards,
Andreas.
[1] https://github.com/earthobservations/wetterdienst-ui
Backlog
Edit: Resolved.
test_ui::test_app_data_values
fails, because I haven't been able to investigate the root cause yet. However, the newly introduced improved log messages will aid us with debugging this issue.dash.testing
infrastructure is running on Selenium, it needs a Browser (Firefox) and its corresponding Geckodriver package installed on the machine running the tests. We will have to adjust both the CI setup on GHA as well as the developer documentation with corresponding instructions to / how to install those prerequisites.