-
-
Notifications
You must be signed in to change notification settings - Fork 4.1k
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
weather status used in dashboard #22124
Conversation
4b92eea
to
77b61bc
Compare
cc @berdosi of the Weather app, maybe you are interested to take a look at this? :) This is explicitly direct integration only (in Dashboard and possibly in Calendar), and it would still make sense to have a bespoke Weather app. |
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.
Aaaaawesome! :)
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.
Looks great 😍 small nitpicks
The GitHub Actions failures look related but easy to fix 😁 |
caf4c24
to
44a7e8e
Compare
I think you need to add your new app to
integration-provisioning-v1 pass. And maybe also https://github.com/nextcloud/server/blob/7b91cb502907f5ebc3323567422dbbe1c9537d62/core/shipped.json to enable it by default?
|
@splitt3r Thanks for the hints. I can't figure out how to get rid of this last CI-drone failure... Any idea? |
688114e
to
d58a203
Compare
I think that one is unrelated. Looks like the test fails in all recent MRs e.g. #22151 (comment). |
d58a203
to
57494ab
Compare
@juliushaertl History and code cleanup done, rebased on master, ready to merge 🎉. |
You should Think about caching or do the weather requests on the client. Otherwise you might violate the tos of the api, especially on big instances. And thus might get blocked etc. |
Thanks for the feedback. With one request per hour, even if the request is cached on the client, it would be useless as we want a forecast update every hour. I figured one request per hour per user was not so much, even with a large number of users. If caching was done on server side, it would factorize all requests for the same location. I'll probably do it but it's not trivial, it requires to store results, clean cache at some point... |
How do you limit to 1 request per hour on the server. Through client caching? |
Spacing between statuses will be fixed in dashboard PR as mentioned earlier (#22124 (comment)) |
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.
Some PHP coding style comments.
Also I noticed: my location is New York, my language en US and my locale en US. I should see the temperature in °F ? but it just says 23°
so I grab a jacket and go fetch my skiers? At least 23° C
needs to be shown, but if possible °F
06abff3
to
2e991e8
Compare
Recent changes:
Rebased on master and commits squashed. |
2e991e8
to
727e53e
Compare
The remaining complain is just about more fixed stuff, just ignore for now. 🚀 good go |
@MorrisJobke There should be a CI job checking the validity of the CI jobs check code 😉 Thanks for the hint. |
I have already something in mind to avoid this mess, but one step after the other :) |
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.
🐘
Signed-off-by: Julien Veyssier <eneiluj@posteo.net>
Signed-off-by: Jan C. Borchardt <hey@jancborchardt.net>
727e53e
to
f0a306c
Compare
Rebased now that the Dashboard background is merged, and fixed the small design issues (statuses touching, font size being too small, them not wrapping on mobile, background of weather status button looking different). |
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.
Good from my side! :)
Signed-off-by: Julien Veyssier <eneiluj@posteo.net>
a791bd5
to
143db7f
Compare
🤖 beep boop beep 🤖 Here are the logs for the failed build: Status of 32029: failureacceptance-app-files
Show full log
|
@eneiluj
|
AH yes you need to listen to the event when you show this and enable it. Let me see if I can do that. |
Congrats on the merge! :) Finally it all works in concert together! |
@jancborchardt thanks! so nice to use everything without rebuilding 😁. the design is simply awesome. thanks a lot! |
I did more or less the same as the user status. It's inserted in dashboard statuses.
There's a new
weather_status
module that needs to be built.It's an independent app in case we want to use it in Calendar for example.
It uses
api.met.no
to get forecasts andnominatim.openstreetmap.org
to search and resolve locations.One thing I'm not sure about: How to make sure the weather status script is loaded when browsing dashboard page. I did it in the dashboard template...
Todo: