Skip to content

Add DateTime.toEpochSeconds - #6470

Closed
coyaSONG wants to merge 1 commit into
Effect-TS:v3from
coyaSONG:feat/6148-datetime-epoch-seconds
Closed

Add DateTime.toEpochSeconds#6470
coyaSONG wants to merge 1 commit into
Effect-TS:v3from
coyaSONG:feat/6148-datetime-epoch-seconds

Conversation

@coyaSONG

Copy link
Copy Markdown
Contributor

Type

  • Refactor
  • Feature
  • Bug Fix
  • Optimization
  • Documentation Update

Description

Adds DateTime.toEpochSeconds for obtaining whole seconds since the Unix epoch. The conversion floors the millisecond timestamp so instants before the epoch retain the conventional Unix timestamp semantics (for example, -1 millisecond becomes -1 second rather than 0).

The change includes regression coverage for fractional positive and pre-epoch timestamps, along with the required patch changeset. It was validated with:

  • pnpm vitest packages/effect/test/DateTime.test.ts --run
  • pnpm lint-fix
  • pnpm check
  • pnpm build
  • pnpm docgen
  • git diff --check

Implementation prepared with OpenAI Codex. No human code review has been performed.

Related

@github-project-automation github-project-automation Bot moved this to Discussion Ongoing in PR Backlog Jul 17, 2026
@changeset-bot

changeset-bot Bot commented Jul 17, 2026

Copy link
Copy Markdown

🦋 Changeset detected

Latest commit: d582a14

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
effect Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@gcanti

gcanti commented Jul 17, 2026

Copy link
Copy Markdown
Contributor

@coyaSONG Version 3 is now in feature freeze as we prepare the release of v4

@effect-bot
effect-bot requested a review from fubhy July 17, 2026 22:44
@effect-bot effect-bot added enhancement New feature or request 4.0 labels Jul 17, 2026
@IMax153 IMax153 added 3.0 Used for issues, pull requests, etc. that are relevant for the `v3` branch targeting Effect v3. and removed 4.0 labels Jul 17, 2026
@tim-smart tim-smart closed this Jul 18, 2026
@github-project-automation github-project-automation Bot moved this from Discussion Ongoing to Done in PR Backlog Jul 18, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

3.0 Used for issues, pull requests, etc. that are relevant for the `v3` branch targeting Effect v3. enhancement New feature or request

Projects

Archived in project

Development

Successfully merging this pull request may close these issues.

5 participants