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
time.now () Obtains the current time of the linux system
What did you see happen?
After the time zone of the golang program running in the linux environment is modified, the time zone obtained by using time.now () in the golang program is still the time zone before the modification, and the time zone of the golang program must be updated again. How to solve this problem?
What did you expect to see?
After updating the time zone of the linux system, the golang program automatically refreshes without restarting
The text was updated successfully, but these errors were encountered:
mengzhuo
changed the title
time.now () uses the time zone to modify the problem
time: time.now () uses the time zone to modify the problem
Jan 23, 2024
Go version
go1.21.5 linux amd64
Output of
go env
in your module/workspace:What did you do?
time.now () Obtains the current time of the linux system
What did you see happen?
After the time zone of the golang program running in the linux environment is modified, the time zone obtained by using time.now () in the golang program is still the time zone before the modification, and the time zone of the golang program must be updated again. How to solve this problem?
What did you expect to see?
After updating the time zone of the linux system, the golang program automatically refreshes without restarting
The text was updated successfully, but these errors were encountered: