openclimatefix / PVConsumer

Consumer PV data from various sources
Apache License 2.0
3 stars 1 forks source link

We should remove arbitrary `start_utc - pd.Timedelta("5T")` #57

Open simlmx opened 1 year ago

simlmx commented 1 year ago

We have an arbitrary timestamp adjustment that might make sense for one PV provider, but probably not in general. https://github.com/openclimatefix/PVConsumer/blob/41972a485153c547968f6b2d8a0e4d40ed5fc478/pvconsumer/save.py#L52

Perhaps we could add an argument to change it in save_to_pv_site_database, and it should default to 0 (less surprising than "- 5 min")?

This is for the "start" timestamp, and If I'm not mistaken, the "end" timestamp is also tweak later in the process. We should probably take care of that one at the same time.

peterdudfield commented 1 year ago

I've added a note in the code for now. https://github.com/openclimatefix/PVConsumer/blob/issue/54-live-tests/pvconsumer/save.py#L55 I hope thats enough for the moment

simlmx commented 1 year ago

Thanks! I'd tend to keep the ticket open until we properly fix it but that's probably good enough for now.