Skip to content

Relax time upper bound to < 1.17 - #438

Merged
parsonsmatt merged 1 commit into
masterfrom
matt/allow-time-1.14
Aug 19, 2026
Merged

Relax time upper bound to < 1.17#438
parsonsmatt merged 1 commit into
masterfrom
matt/allow-time-1.14

Conversation

@parsonsmatt

@parsonsmatt parsonsmatt commented Aug 17, 2026

Copy link
Copy Markdown
Collaborator

Summary

Relaxes the time upper bound from <=1.13 to <1.17, admitting every released time version (1.14, 1.15, 1.16, 1.16.0.1), and bumps the version to 3.6.0.3.

All of these need base >= 4.19, so they're only reachable on GHC 9.8+; older GHCs keep solving with older time under the unchanged lower bound.

What changed in time 1.14–1.16.0.1

  • 1.14: Lift/Generic instances, Show CalendarDiffTime fix, maximal-munch parsing (%q/%Q, optional timezone for UTCTime, ISO8601 optionals)
  • 1.15: additive API (durations, patterns, parsing instances); hides Data.Time.Format.Internal (nothing in esqueleto's dep tree used it)
  • 1.16: adds periodIn, GHC 9.14 support, template-haskell-lift for Lift on 9.14+
  • 1.16.0.1: bugfixes (case-insensitive AM/PM parsing, overflow rejection in numeric parsers, DST/timezone fixes)

esqueleto's only direct use of time is the UTCTime type (Database.Esqueleto.PostgreSQL.now_); everything else flows through persistent's serialization, so the parsing changes were the thing to smoke out against real databases.

Testing

Each version pinned via constraints: and exercised in turn:

time lib GHC 9.8.4 lib GHC 9.12.4 suite build GHC 9.10.2 SQLite PostgreSQL (live PG 16)
1.14 181 ✅ 292 ✅
1.15 181 ✅ 292 ✅
1.16 ✅ * 181 ✅ 292 ✅
1.16.0.1 ✅ * 181 ✅ 292 ✅

The PostgreSQL runs include now_ (parses a live server timestamp into UTCTime) and the date_trunc round-trip tests. The 2 pending tests everywhere are the long-standing composite-PK pendings, unrelated to time.

* time 1.16.x is not yet solvable in the wild without allow-newer: *:timetime-compat, text-iso8601, and aeson still cap time < 1.16. They all compile and pass against 1.16.x under allow-newer, so this is just waiting on routine Hackage revisions upstream; <1.17 means esqueleto is already ready when they land. time 1.14 and 1.15 solve with no allow-newer at all (persistent 2.18.1.0 and friends already accept them).

Other notes:

  • GHC 9.12 can't build the test suite for a pre-existing reason unrelated to time: mysql-0.2.1's custom Setup.hs doesn't compile against Cabal ≥ 3.14 (why 9.12 is commented out of the CI matrix). The library builds clean there.
  • MySQL tests weren't run locally (no local server) — relying on the CI service container for that leg.

🤖 Generated with Claude Code

Allows time-1.14, 1.15, and 1.16. These releases are additive or
bugfix-level for esqueleto's purposes: esqueleto's only direct use of
time is the UTCTime type, and everything else flows through
persistent's serialization. The SQLite and PostgreSQL test suites pass
against time-1.14, 1.15, 1.16, and 1.16.0.1 (including now_ and
date_trunc round-trips). time 1.16.x currently needs
allow-newer: *:time upstream (time-compat, text-iso8601, aeson still
cap at < 1.16), but esqueleto itself is ready.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@parsonsmatt
parsonsmatt force-pushed the matt/allow-time-1.14 branch from 63ef58e to e5b4ff0 Compare August 18, 2026 03:23
@parsonsmatt parsonsmatt changed the title Allow time-1.14 Relax time upper bound to < 1.17 Aug 18, 2026
@juhp

juhp commented Aug 19, 2026

Copy link
Copy Markdown

Thank you I came here to say this...

@parsonsmatt
parsonsmatt marked this pull request as ready for review August 19, 2026 16:28
@parsonsmatt
parsonsmatt merged commit d547cd3 into master Aug 19, 2026
8 checks passed
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.

2 participants