-
-
Notifications
You must be signed in to change notification settings - Fork 219
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
reminder的时间与系统时间不一致 #239
Comments
更改时区后有试过重启 bot 吗 我也是用的洛杉矶服务器调了时区,是正常的 |
刚刚重启了一遍bot,还是不行,我试试把系统重启一遍。 |
emmm,重启系统也没效果。 |
噢噢我之前记错了,我换了服务器之后就没用过这个功能了 看了下 cron-parser 确实有个时区选项,我加个自动检测时区 |
嗯!谢啦,期待后续版本。 |
在 node 里面分别执行这两句 process.env.TZ
Intl.DateTimeFormat().resolvedOptions().timeZone 看看输出结果 以及执行 process.env.TZ = 'Asia/Shanghai' 之后,重复之前 cron-parser 那个操作看看输出 |
看来你这个问题是 node 读取到的系统时区不正确引起的,node 默认认为你的时区是纽约,我也不清楚原因,只能通过环境变量指定时区了 更新至 v2.30.0 后,在项目根目录创建一个
就可以了 |
服务器地区为美国洛杉矶,已更改系统时间为东8区。但reminder似乎仍旧使用的是美国时间。
The text was updated successfully, but these errors were encountered: