Update tariffs

This commit is contained in:
Josh Deprez 2024-07-08 20:03:43 +10:00
parent 83ed014616
commit 0f904590aa
Signed by: josh
SSH key fingerprint: SHA256:zZji7w1Ilh2RuUpbQcqkLPrqmRwpiCSycbF2EfKm6Kw
3 changed files with 33 additions and 25 deletions

15
go.mod
View file

@ -2,14 +2,15 @@ module gitea.drjosh.dev/josh/sungrow
go 1.22 go 1.22
require github.com/prometheus/client_golang v1.19.0 require github.com/prometheus/client_golang v1.19.1
require ( require (
github.com/beorn7/perks v1.0.1 // indirect github.com/beorn7/perks v1.0.1 // indirect
github.com/cespare/xxhash/v2 v2.2.0 // indirect github.com/cespare/xxhash/v2 v2.3.0 // indirect
github.com/prometheus/client_model v0.6.0 // indirect github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822 // indirect
github.com/prometheus/common v0.51.0 // indirect github.com/prometheus/client_model v0.6.1 // indirect
github.com/prometheus/procfs v0.13.0 // indirect github.com/prometheus/common v0.55.0 // indirect
golang.org/x/sys v0.18.0 // indirect github.com/prometheus/procfs v0.15.1 // indirect
google.golang.org/protobuf v1.33.0 // indirect golang.org/x/sys v0.22.0 // indirect
google.golang.org/protobuf v1.34.2 // indirect
) )

30
go.sum
View file

@ -1,20 +1,22 @@
github.com/beorn7/perks v1.0.1 h1:VlbKKnNfV8bJzeqoa4cOKqO6bYr3WgKZxO8Z16+hsOM= github.com/beorn7/perks v1.0.1 h1:VlbKKnNfV8bJzeqoa4cOKqO6bYr3WgKZxO8Z16+hsOM=
github.com/beorn7/perks v1.0.1/go.mod h1:G2ZrVWU2WbWT9wwq4/hrbKbnv/1ERSJQ0ibhJ6rlkpw= github.com/beorn7/perks v1.0.1/go.mod h1:G2ZrVWU2WbWT9wwq4/hrbKbnv/1ERSJQ0ibhJ6rlkpw=
github.com/cespare/xxhash/v2 v2.2.0 h1:DC2CZ1Ep5Y4k3ZQ899DldepgrayRUGE6BBZ/cd9Cj44= github.com/cespare/xxhash/v2 v2.3.0 h1:UL815xU9SqsFlibzuggzjXhog7bL6oX9BbNZnL2UFvs=
github.com/cespare/xxhash/v2 v2.2.0/go.mod h1:VGX0DQ3Q6kWi7AoAeZDth3/j3BFtOZR5XLFGgcrjCOs= github.com/cespare/xxhash/v2 v2.3.0/go.mod h1:VGX0DQ3Q6kWi7AoAeZDth3/j3BFtOZR5XLFGgcrjCOs=
github.com/davecgh/go-spew v1.1.1 h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c= github.com/davecgh/go-spew v1.1.1 h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c=
github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
github.com/google/go-cmp v0.6.0 h1:ofyhxvXcZhMsU5ulbFiLKl/XBFqE1GSq7atu8tAmTRI= github.com/google/go-cmp v0.6.0 h1:ofyhxvXcZhMsU5ulbFiLKl/XBFqE1GSq7atu8tAmTRI=
github.com/google/go-cmp v0.6.0/go.mod h1:17dUlkBOakJ0+DkrSSNjCkIjxS6bF9zb3elmeNGIjoY= github.com/google/go-cmp v0.6.0/go.mod h1:17dUlkBOakJ0+DkrSSNjCkIjxS6bF9zb3elmeNGIjoY=
github.com/prometheus/client_golang v1.19.0 h1:ygXvpU1AoN1MhdzckN+PyD9QJOSD4x7kmXYlnfbA6JU= github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822 h1:C3w9PqII01/Oq1c1nUAm88MOHcQC9l5mIlSMApZMrHA=
github.com/prometheus/client_golang v1.19.0/go.mod h1:ZRM9uEAypZakd+q/x7+gmsvXdURP+DABIEIjnmDdp+k= github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822/go.mod h1:+n7T8mK8HuQTcFwEeznm/DIxMOiR9yIdICNftLE1DvQ=
github.com/prometheus/client_model v0.6.0 h1:k1v3CzpSRUTrKMppY35TLwPvxHqBu0bYgxZzqGIgaos= github.com/prometheus/client_golang v1.19.1 h1:wZWJDwK+NameRJuPGDhlnFgx8e8HN3XHQeLaYJFJBOE=
github.com/prometheus/client_model v0.6.0/go.mod h1:NTQHnmxFpouOD0DpvP4XujX3CdOAGQPoaGhyTchlyt8= github.com/prometheus/client_golang v1.19.1/go.mod h1:mP78NwGzrVks5S2H6ab8+ZZGJLZUq1hoULYBAYBw1Ho=
github.com/prometheus/common v0.51.0 h1:vT5R9NAlW4V6k8Wruk7ikrHaHRsrPbduM/cKTOdQM/k= github.com/prometheus/client_model v0.6.1 h1:ZKSh/rekM+n3CeS952MLRAdFwIKqeY8b62p8ais2e9E=
github.com/prometheus/common v0.51.0/go.mod h1:wHFBCEVWVmHMUpg7pYcOm2QUR/ocQdYSJVQJKnHc3xQ= github.com/prometheus/client_model v0.6.1/go.mod h1:OrxVMOVHjw3lKMa8+x6HeMGkHMQyHDk9E3jmP2AmGiY=
github.com/prometheus/procfs v0.13.0 h1:GqzLlQyfsPbaEHaQkO7tbDlriv/4o5Hudv6OXHGKX7o= github.com/prometheus/common v0.55.0 h1:KEi6DK7lXW/m7Ig5i47x0vRzuBsHuvJdi5ee6Y3G1dc=
github.com/prometheus/procfs v0.13.0/go.mod h1:cd4PFCR54QLnGKPaKGA6l+cfuNXtht43ZKY6tow0Y1g= github.com/prometheus/common v0.55.0/go.mod h1:2SECS4xJG1kd8XF9IcM1gMX6510RAEL65zxzNImwdc8=
golang.org/x/sys v0.18.0 h1:DBdB3niSjOA/O0blCZBqDefyWNYveAYMNF1Wum0DYQ4= github.com/prometheus/procfs v0.15.1 h1:YagwOFzUgYfKKHX6Dr+sHT7km/hxC76UB0learggepc=
golang.org/x/sys v0.18.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= github.com/prometheus/procfs v0.15.1/go.mod h1:fB45yRUv8NstnjriLhBQLuOUt+WW4BsoGhij/e3PBqk=
google.golang.org/protobuf v1.33.0 h1:uNO2rsAINq/JlFpSdYEKIZ0uKD/R9cpdv0T+yoGwGmI= golang.org/x/sys v0.22.0 h1:RI27ohtqKCnwULzJLqkv897zojh5/DwS/ENaMzUOaWI=
google.golang.org/protobuf v1.33.0/go.mod h1:c6P6GXX6sHbq/GpV6MGZEdwhWPcYBgnhAHhKbcUYpos= golang.org/x/sys v0.22.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA=
google.golang.org/protobuf v1.34.2 h1:6xV6lTsCfpGD21XK49h7MhtcApnLqkfYgPcdHftf6hg=
google.golang.org/protobuf v1.34.2/go.mod h1:qYOHts0dSfpeUzUFpOMr/WGzszTmLH+DiWniOlNbLDw=

View file

@ -25,12 +25,14 @@ const (
//dailySupplyCharge = 0.98234 // 1 July 2021 - 30 June 2022 //dailySupplyCharge = 0.98234 // 1 July 2021 - 30 June 2022
//dailySupplyCharge = 0.98234 // 1 July 2021 - 30 June 2022 //dailySupplyCharge = 0.98234 // 1 July 2021 - 30 June 2022
//dailySupplyCharge = 1.099030 // 1 July 2022 - 30 June 2023 //dailySupplyCharge = 1.099030 // 1 July 2022 - 30 June 2023
dailySupplyCharge = 1.26389 // 1 July 2023 - 30 June 2024 //dailySupplyCharge = 1.26389 // 1 July 2023 - 30 June 2024
dailySupplyCharge = 1.34983 // 1 July 2024 - 30 June 2025
//solarFeedInTariff = fixedTariff(0.08471) // 1 July 2020 - 30 June 2021 //solarFeedInTariff = fixedTariff(0.08471) // 1 July 2020 - 30 June 2021
//solarFeedInTariff = fixedTariff(0.06501) // 1 July 2021 - 30 June 2022 //solarFeedInTariff = fixedTariff(0.06501) // 1 July 2021 - 30 June 2022
//solarFeedInTariff = fixedTariff(0.088830) // 1 July 2022 - 30 June 2023 //solarFeedInTariff = fixedTariff(0.088830) // 1 July 2022 - 30 June 2023
solarFeedInTariff = fixedTariff(0.10869) // 1 July 2023 - 30 June 2024 //solarFeedInTariff = fixedTariff(0.10869) // 1 July 2023 - 30 June 2024
solarFeedInTariff = fixedTariff(0.08935) // 1 July 2024 - 30 June 2025
) )
var tariff93 = &onOffPeakTariff{ var tariff93 = &onOffPeakTariff{
@ -44,8 +46,11 @@ var tariff93 = &onOffPeakTariff{
//onPeak: 0.333990, //onPeak: 0.333990,
//offPeak: 0.155510, //offPeak: 0.155510,
// 1 July 2023 - 30 June 2024: // 1 July 2023 - 30 June 2024:
onPeak: 0.36198, //onPeak: 0.36198,
offPeak: 0.16855, //offPeak: 0.16855,
// 1 July 2024 - 30 June 2025:
onPeak: 0.35836,
offPeak: 0.16686,
isPeak: (&weekdayHours{ isPeak: (&weekdayHours{
zone: time.FixedZone("UTC+10", +10*60*60), zone: time.FixedZone("UTC+10", +10*60*60),
on: [24]bool{ on: [24]bool{