Skip to content

feat: add Duration.toMicros - #9973

Merged
tim-smart merged 6 commits into
Effect-TS:v4/next-minorfrom
yordis:yordis/feat-duration-to-micros
Oct 27, 2026
Merged

tim-smart merged 6 commits into
Effect-TS:v4/next-minorfrom
yordis:yordis/feat-duration-to-micros

Conversation

@yordis

@yordis yordis commented Oct 26, 2026 •

Copy link
Copy Markdown
Contributor

Type

  • Feature

Description

Microsecond metrics need a direct duration conversion to avoid repeated application code and extra rounding through milliseconds.

Related

Closes EFF-2972

@changeset-bot

changeset-bot Bot commented Oct 26, 2026 •

Copy link
Copy Markdown

🦋 Changeset detected

Latest commit: acf80d9

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

This PR includes changesets to release 33 packages
Name Type
effect Minor
@effect/opentelemetry Minor
@effect/vitest Minor
@effect/ai-anthropic Minor
@effect/ai-cloudflare Minor
@effect/ai-openai-compat Minor
@effect/ai-openai Minor
@effect/ai-openrouter Minor
@effect/ai-typesafe Minor
@effect/atom-react Minor
@effect/atom-solid Minor
@effect/atom-vue Minor
@effect/platform-browser Minor
@effect/platform-bun Minor
@effect/platform-deno Minor
@effect/platform-node-shared Minor
@effect/platform-node Minor
@effect/sql-clickhouse Minor
@effect/sql-d1 Minor
@effect/sql-libsql Minor
@effect/sql-mssql Minor
@effect/sql-mysql2 Minor
@effect/sql-pg Minor
@effect/sql-pglite Minor
@effect/sql-sqlite-bun Minor
@effect/sql-sqlite-do Minor
@effect/sql-sqlite-node Minor
@effect/sql-sqlite-react-native Minor
@effect/sql-sqlite-wasm Minor
@effect/docgen Minor
@effect/doctest Minor
@effect/graphql-generator Minor
@effect/openapi-generator Minor

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

@github-actions

github-actions Bot commented Oct 26, 2026 •

Copy link
Copy Markdown
Contributor

Bundle Size Analysis

Generated from PR build output; treat the content below as untrusted.

File Name Current Size Previous Size Difference
arbitrary-combinators.ts 39.33 KB 39.33 KB 0.00 KB (0.00%)
basic.ts 7.18 KB 7.18 KB 0.00 KB (0.00%)
batching.ts 11.05 KB 11.05 KB 0.00 KB (0.00%)
brand.ts 6.84 KB 6.84 KB 0.00 KB (0.00%)
cache.ts 11.48 KB 11.48 KB 0.00 KB (0.00%)
config.ts 22.75 KB 22.75 KB 0.00 KB (0.00%)
differ.ts 21.88 KB 21.88 KB 0.00 KB (0.00%)
http-client.ts 26.73 KB 26.73 KB 0.00 KB (0.00%)
http-router.ts 36.68 KB 36.68 KB 0.00 KB (0.00%)
logger.ts 11.95 KB 11.95 KB 0.00 KB (0.00%)
metric.ts 9.41 KB 9.41 KB 0.00 KB (0.00%)
optic.ts 7.05 KB 7.05 KB 0.00 KB (0.00%)
pubsub.ts 15.96 KB 15.96 KB 0.00 KB (0.00%)
queue.ts 12.76 KB 12.76 KB 0.00 KB (0.00%)
schedule.ts 11.73 KB 11.73 KB 0.00 KB (0.00%)
schema-bigdecimal.ts 13.99 KB 13.99 KB 0.00 KB (0.00%)
schema-binary.ts 41.03 KB 41.03 KB 0.00 KB (0.00%)
schema-class.ts 21.53 KB 21.53 KB 0.00 KB (0.00%)
schema-fromJsonSchemaDocument.ts 29.50 KB 29.50 KB 0.00 KB (0.00%)
schema-representation-roundtrip.ts 27.89 KB 27.89 KB 0.00 KB (0.00%)
schema-string-transformation.ts 15.25 KB 15.25 KB 0.00 KB (0.00%)
schema-string.ts 12.23 KB 12.23 KB 0.00 KB (0.00%)
schema-template-literal.ts 16.17 KB 16.17 KB 0.00 KB (0.00%)
schema-toArbitrary.ts 38.86 KB 38.86 KB 0.00 KB (0.00%)
schema-toCodeDocument.ts 26.06 KB 26.06 KB 0.00 KB (0.00%)
schema-toCodecJson.ts 20.81 KB 20.81 KB 0.00 KB (0.00%)
schema-toEquivalence.ts 20.95 KB 20.95 KB 0.00 KB (0.00%)
schema-toFormatter.ts 21.05 KB 21.05 KB 0.00 KB (0.00%)
schema-toJsonSchemaDocument.ts 26.08 KB 26.08 KB 0.00 KB (0.00%)
schema-toRepresentation.ts 21.14 KB 21.14 KB 0.00 KB (0.00%)
schema.ts 20.73 KB 20.73 KB 0.00 KB (0.00%)
stm.ts 14.14 KB 14.14 KB 0.00 KB (0.00%)
stream.ts 10.32 KB 10.32 KB 0.00 KB (0.00%)

@effect-bot
effect-bot changed the base branch from main to v4/next-minor October 27, 2026 00:39
Comment thread packages/effect/src/Duration.ts Resolved
@tim-smart
tim-smart enabled auto-merge (squash) October 27, 2026 00:39
@effect-bot
effect-bot force-pushed the yordis/feat-duration-to-micros branch from 3dd933f to 881772a Compare October 27, 2026 00:47
@effect-bot
effect-bot force-pushed the yordis/feat-duration-to-micros branch from 881772a to 3b5d4e1 Compare October 27, 2026 00:49
@effect-bot
effect-bot force-pushed the yordis/feat-duration-to-micros branch from 3b5d4e1 to fbbdb74 Compare October 27, 2026 00:50
@effect-bot
effect-bot force-pushed the yordis/feat-duration-to-micros branch from fbbdb74 to 39c21fb Compare October 27, 2026 00:50
@effect-bot
effect-bot force-pushed the yordis/feat-duration-to-micros branch from 39c21fb to dbc6774 Compare October 27, 2026 00:51
@tim-smart tim-smart closed this Oct 27, 2026
auto-merge was automatically disabled October 27, 2026 00:52

Pull request was closed

@tim-smart tim-smart reopened this Oct 27, 2026
@tim-smart
tim-smart enabled auto-merge (squash) October 27, 2026 00:52
@effect-bot
effect-bot force-pushed the yordis/feat-duration-to-micros branch from dbc6774 to acf80d9 Compare October 27, 2026 01:03
@tim-smart
tim-smart merged commit c95bf78 into Effect-TS:v4/next-minor Oct 27, 2026
10 checks passed
@effect-bot effect-bot mentioned this pull request Oct 27, 2026
tim-smart added a commit that referenced this pull request Oct 27, 2026
Signed-off-by: Yordis Prieto <[email protected]>
Co-authored-by: Effect Bot <[email protected]>
Co-authored-by: Tim <[email protected]>
effect-bot added a commit that referenced this pull request Oct 27, 2026
Signed-off-by: Yordis Prieto <[email protected]>
Co-authored-by: Effect Bot <[email protected]>
Co-authored-by: Tim <[email protected]>
effect-bot added a commit that referenced this pull request Oct 27, 2026
Signed-off-by: Yordis Prieto <[email protected]>
Co-authored-by: Effect Bot <[email protected]>
Co-authored-by: Tim <[email protected]>
tim-smart added a commit that referenced this pull request Oct 27, 2026
Signed-off-by: Yordis Prieto <[email protected]>
Co-authored-by: Effect Bot <[email protected]>
Co-authored-by: Tim <[email protected]>
tim-smart added a commit that referenced this pull request Oct 27, 2026
Signed-off-by: Yordis Prieto <[email protected]>
Co-authored-by: Effect Bot <[email protected]>
Co-authored-by: Tim <[email protected]>
effect-bot added a commit that referenced this pull request Oct 27, 2026
Signed-off-by: Yordis Prieto <[email protected]>
Co-authored-by: Effect Bot <[email protected]>
Co-authored-by: Tim <[email protected]>
effect-bot added a commit that referenced this pull request Oct 27, 2026
Signed-off-by: Yordis Prieto <[email protected]>
Co-authored-by: Effect Bot <[email protected]>
Co-authored-by: Tim <[email protected]>
tim-smart added a commit that referenced this pull request Oct 27, 2026
Signed-off-by: Yordis Prieto <[email protected]>
Co-authored-by: Effect Bot <[email protected]>
Co-authored-by: Tim <[email protected]>
effect-bot added a commit that referenced this pull request Oct 27, 2026
Signed-off-by: Yordis Prieto <[email protected]>
Co-authored-by: Effect Bot <[email protected]>
Co-authored-by: Tim <[email protected]>
effect-bot added a commit to wmaurer/effect that referenced this pull request Oct 27, 2026
Signed-off-by: Yordis Prieto <[email protected]>
Co-authored-by: Effect Bot <[email protected]>
Co-authored-by: Tim <[email protected]>
effect-bot added a commit that referenced this pull request Oct 27, 2026
Signed-off-by: Yordis Prieto <[email protected]>
Co-authored-by: Effect Bot <[email protected]>
Co-authored-by: Tim <[email protected]>
effect-bot added a commit to wmaurer/effect that referenced this pull request Oct 27, 2026
Signed-off-by: Yordis Prieto <[email protected]>
Co-authored-by: Effect Bot <[email protected]>
Co-authored-by: Tim <[email protected]>
effect-bot added a commit that referenced this pull request Oct 27, 2026
Signed-off-by: Yordis Prieto <[email protected]>
Co-authored-by: Effect Bot <[email protected]>
Co-authored-by: Tim <[email protected]>
effect-bot added a commit to wmaurer/effect that referenced this pull request Oct 28, 2026
Signed-off-by: Yordis Prieto <[email protected]>
Co-authored-by: Effect Bot <[email protected]>
Co-authored-by: Tim <[email protected]>
effect-bot added a commit to wmaurer/effect that referenced this pull request Oct 28, 2026
Signed-off-by: Yordis Prieto <[email protected]>
Co-authored-by: Effect Bot <[email protected]>
Co-authored-by: Tim <[email protected]>
effect-bot added a commit to wmaurer/effect that referenced this pull request Oct 28, 2026
Signed-off-by: Yordis Prieto <[email protected]>
Co-authored-by: Effect Bot <[email protected]>
Co-authored-by: Tim <[email protected]>
effect-bot added a commit to wmaurer/effect that referenced this pull request Oct 28, 2026
Signed-off-by: Yordis Prieto <[email protected]>
Co-authored-by: Effect Bot <[email protected]>
Co-authored-by: Tim <[email protected]>
effect-bot added a commit that referenced this pull request Oct 28, 2026
Signed-off-by: Yordis Prieto <[email protected]>
Co-authored-by: Effect Bot <[email protected]>
Co-authored-by: Tim <[email protected]>
effect-bot added a commit to wmaurer/effect that referenced this pull request Oct 28, 2026
Signed-off-by: Yordis Prieto <[email protected]>
Co-authored-by: Effect Bot <[email protected]>
Co-authored-by: Tim <[email protected]>
effect-bot added a commit that referenced this pull request Oct 28, 2026
Signed-off-by: Yordis Prieto <[email protected]>
Co-authored-by: Effect Bot <[email protected]>
Co-authored-by: Tim <[email protected]>
tim-smart added a commit that referenced this pull request Oct 28, 2026
Signed-off-by: Yordis Prieto <[email protected]>
Co-authored-by: Effect Bot <[email protected]>
Co-authored-by: Tim <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants