You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'd like to be able to customize what now() returns on a per-thread basis. Alternatively, I'd like to be able to instantiate a new time module with injected now() (or both).
Thank you!
The text was updated successfully, but these errors were encountered:
I would accept a PR to make the now function consult a starlark.Thread-local variable (of type func() time.Now) before falling back to the standard time.Now implementation.
This is a follow up for #435.
Global var is still there in the
time
module:starlark-go/lib/time/time.go
Line 74 in 2232540
I'd like to be able to customize what
now()
returns on a per-thread basis. Alternatively, I'd like to be able to instantiate a newtime
module with injectednow()
(or both).Thank you!
The text was updated successfully, but these errors were encountered: