Skip to content

chore: add IANA timezone column to site schema#806

Open
anonymoususer72041 wants to merge 1 commit into
opencats:masterfrom
anonymoususer72041:chore/add-iana-timezone-column
Open

chore: add IANA timezone column to site schema#806
anonymoususer72041 wants to merge 1 commit into
opencats:masterfrom
anonymoususer72041:chore/add-iana-timezone-column

Conversation

@anonymoususer72041

Copy link
Copy Markdown
Contributor

Summary

This PR adds a new time_zone_iana column to the site table.

Fresh installations now create the column as part of the base schema and existing installations receive it through schema update. The column defaults to UTC.

This PR intentionally does not change the existing legacy site.time_zone column, installer behavior, runtime timezone handling, timestamp storage or timestamp display behavior.

Motivation

OpenCATS currently relies on a legacy numeric timezone offset. This is not sufficient for future timezone-aware timestamp handling, especially if timestamp storage is later migrated toward UTC and display logic needs to use real regional timezone rules.

Before the installer or settings screens can start writing an IANA timezone identifier, the database schema must provide a place to store it. This is especially important for upgraded installations: the installer may run before later schema migrations or setup changes can depend on the new field. Without adding the column first, future installer or upgrade logic would not be able to reliably persist the selected IANA timezone for both fresh and existing instances.

This PR is therefore a small preparatory schema change. It makes site.time_zone_iana available while keeping all existing offset-based behavior unchanged. The actual transition to writing IANA timezone values, changing runtime timezone handling, migrating timestamps to UTC, ..., are intentionally left for follow-up PRs.

@anonymoususer72041 anonymoususer72041 requested a review from RussH June 10, 2026 13:54
@anonymoususer72041

Copy link
Copy Markdown
Contributor Author

@RussH we want to merge this PR rather sooner than later as it needs to be included in a previous release regarding upcoming UTC work.

@anonymoususer72041 anonymoususer72041 force-pushed the chore/add-iana-timezone-column branch from de96a9e to b5fd6cb Compare June 14, 2026 10:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant