admin管理员组

文章数量:1124799

I have a site which is pretty old (started at Django 1.6) but has been upgraded over time and is now at Django 4.2. It has always had USE_TZ=False and TIME_ZONE='America/Chicago'.

We have a lot of critical dates (subscriptions, purchase records, etc), many of which are fed from external webhooks from our payment processor.

I'm looking at adding another Django app, but it requires USE_TZ=True. Anyone have any insight into what might happen if I turn it on? I've turned it on in my development environment and I don't see any obvious issues, but can't easily replicate the webhooks I receive and daily tasks that extensively use date calculations. Where should I be looking for issues?

I have a site which is pretty old (started at Django 1.6) but has been upgraded over time and is now at Django 4.2. It has always had USE_TZ=False and TIME_ZONE='America/Chicago'.

We have a lot of critical dates (subscriptions, purchase records, etc), many of which are fed from external webhooks from our payment processor.

I'm looking at adding another Django app, but it requires USE_TZ=True. Anyone have any insight into what might happen if I turn it on? I've turned it on in my development environment and I don't see any obvious issues, but can't easily replicate the webhooks I receive and daily tasks that extensively use date calculations. Where should I be looking for issues?

Share Improve this question asked 2 days ago machomeautoguymachomeautoguy 6191 gold badge6 silver badges19 bronze badges 2
  • docs.djangoproject.com/en/5.1/topics/i18n/timezones/… – iklinac Commented 2 days ago
  • I don't really get what the question is? What problem do you encounter? – willeM_ Van Onsem Commented yesterday
Add a comment  | 

1 Answer 1

Reset to default 0

I'm rather confused on what you're asking. What do you mean specifically by turn on? Turn on what?

If you want to switch from True to False or vice-versa for your USE_TZ. You can go to your Django settings and change it to False. But I believe it's True by default.

Not sure if this is the answer you're looking for, your question is kind of vague.

本文标签: timezoneSwitching Django USETZ to TrueStack Overflow