I have executed the Windows version, and when I enter a new flight that is done at night, it throws the following log:
INFO 2022/10/23 00:26:29 Web Logbook 2.5.0 is ready on http://localhost:4000
ERROR 2022/10/23 00:26:55 server.go:3195: http: panic serving [::1]:52987: time: missing Location in call to Time.In
goroutine 147 [running]:
net/http.(*conn).serve.func1()
/usr/local/go/src/net/http/server.go:1825 +0xbf
panic({0x16042a0, 0x1ecb110})
/usr/local/go/src/runtime/panic.go:844 +0x258
time.Time.In(...)
/usr/local/go/src/time/time.go:1105
github.com/vsimakhin/go-nighttime.(*Place).SunriseSunset(0xc0005894a8)
/home/vsimakhin/go/pkg/mod/github.com/vsimakhin/[email protected]/nighttime.go:129 +0x105
github.com/vsimakhin/go-nighttime.(*Place).Sunrise(0x0?)
/home/vsimakhin/go/pkg/mod/github.com/vsimakhin/[email protected]/nighttime.go:139 +0x19
github.com/vsimakhin/go-nighttime.(*Route).NightTime(0xc0005894a8)
/home/vsimakhin/go/pkg/mod/github.com/vsimakhin/[email protected]/nighttime.go:198 +0x38
main.(*application).HandlerNightTime(0xc0002aa230, {0x1ecef98, 0xc000d6c230}, 0xc0000c2500)
/home/vsimakhin/Documents/github/github.com/vsimakhin/web-logbook/cmd/web/handlers_flightrecord.go:255 +0x718
net/http.HandlerFunc.ServeHTTP(0x162b480?, {0x1ecef98?, 0xc000d6c230?}, 0xc00029e180?)
/usr/local/go/src/net/http/server.go:2084 +0x2f
github.com/go-chi/chi/v5.(*Mux).routeHTTP(0xc003f46f60, {0x1ecef98, 0xc000d6c230}, 0xc0000c2500)
/home/vsimakhin/go/pkg/mod/github.com/go-chi/chi/[email protected]/mux.go:442 +0x216
net/http.HandlerFunc.ServeHTTP(0xe?, {0x1ecef98?, 0xc000d6c230?}, 0xc0001d22a0?)
/usr/local/go/src/net/http/server.go:2084 +0x2f
main.(*application).Auth.func1({0x1ecef98?, 0xc000d6c230?}, 0xc00029e180?)
/home/vsimakhin/Documents/github/github.com/vsimakhin/web-logbook/cmd/web/handlers_auth.go:21 +0xf0
net/http.HandlerFunc.ServeHTTP(0x0?, {0x1ecef98?, 0xc000d6c230?}, 0xefdd90?)
/usr/local/go/src/net/http/server.go:2084 +0x2f
github.com/go-chi/chi/v5.(*Mux).ServeHTTP(0xc003f46f60, {0x1ecef98, 0xc000d6c230}, 0xc0000c2500)
/home/vsimakhin/go/pkg/mod/github.com/go-chi/chi/[email protected]/mux.go:71 +0x48d
github.com/go-chi/chi/v5.(*Mux).Mount.func1({0x1ecef98, 0xc000d6c230}, 0xc0000c2500)
/home/vsimakhin/go/pkg/mod/github.com/go-chi/chi/[email protected]/mux.go:314 +0x19c
net/http.HandlerFunc.ServeHTTP(0x162b480?, {0x1ecef98?, 0xc000d6c230?}, 0xc00001e165?)
/usr/local/go/src/net/http/server.go:2084 +0x2f
github.com/go-chi/chi/v5.(*Mux).routeHTTP(0xc003f46f00, {0x1ecef98, 0xc000d6c230}, 0xc0000c2500)
/home/vsimakhin/go/pkg/mod/github.com/go-chi/chi/[email protected]/mux.go:442 +0x216
net/http.HandlerFunc.ServeHTTP(0xc0002b2aa0?, {0x1ecef98?, 0xc000d6c230?}, 0x0?)
/usr/local/go/src/net/http/server.go:2084 +0x2f
github.com/alexedwards/scs/v2.(*SessionManager).LoadAndSave.func1({0x1ecf658, 0xc0003c22a0}, 0xc0000c2400)
/home/vsimakhin/go/pkg/mod/github.com/alexedwards/scs/[email protected]/session.go:148 +0x34d
net/http.HandlerFunc.ServeHTTP(0x1ecfe00?, {0x1ecf658?, 0xc0003c22a0?}, 0x2e7e480?)
/usr/local/go/src/net/http/server.go:2084 +0x2f
github.com/go-chi/chi/v5.(*Mux).ServeHTTP(0xc003f46f00, {0x1ecf658, 0xc0003c22a0}, 0xc0000c2300)
/home/vsimakhin/go/pkg/mod/github.com/go-chi/chi/[email protected]/mux.go:88 +0x442
net/http.serverHandler.ServeHTTP({0x1ecdf30?}, {0x1ecf658, 0xc0003c22a0}, 0xc0000c2300)
/usr/local/go/src/net/http/server.go:2916 +0x43b
net/http.(*conn).serve(0xc003ffe000, {0x1ecfea8, 0xc000d74180})
/usr/local/go/src/net/http/server.go:1966 +0x5d7
created by net/http.(*Server).Serve
/usr/local/go/src/net/http/server.go:3071 +0x4db
ERROR 2022/10/23 00:26:55 server.go:3195: http: panic serving [::1]:52988: time: missing Location in call to Time.In