Open ryansurf opened 2 months ago
Should this be closed? It seems to be implemented by api.get_uv()
Should this be closed? It seems to be implemented by api.get_uv()
Its not quite implemented. We get the current UV when we run:
ryan@debian:~$ curl localhost:8000
Location: San Diego
.-``'.
.` .`
_.-' '._
UV index: 3.2
Wave Height: 4.0
Wave Direction: 254.0
Wave Period: 9.1
But if we want a forecast and run:
ryan@debian:~$ curl localhost:8000?forecast=5
Location: San Diego
.-``'.
.` .`
_.-' '._
UV index: 3.2
Wave Height: 4.0
Wave Direction: 254.0
Wave Period: 9.1
Date: 2024-07-22 07:00:00+00:00
Wave Height: 4.1
Wave Direction: 251.2
Wave Period: 9.4
Date: 2024-07-23 07:00:00+00:00
Wave Height: 3.3
Wave Direction: 242.0
Wave Period: 10.4
Date: 2024-07-24 07:00:00+00:00
Wave Height: 3.0
Wave Direction: 233.9
Wave Period: 10.6
Date: 2024-07-25 07:00:00+00:00
Wave Height: 3.3
Wave Direction: 234.5
Wave Period: 10.0
Date: 2024-07-26 07:00:00+00:00
Wave Height: 4.3
Wave Direction: 246.6
Wave Period: 9.2
We only get the current UV. There is a api.forecast()
function which may need to be modified to achieve this
The forecast only includes wave data(height, period, direction)
It should have UV index info too.
The API info can be found here
In
helper.py
, we have theforecast()
function for the ocean data. Reference that/add to that for the UV forecast.