Skip to content

integrations: local Postgres fixtures discard supported source type modifiers #336

Closed

Description

@allisonmahmood

Problem

Discovery records numeric scale and timestamp precision, but generated fixture DDL reconstructs only the base type. The same invented INSERT can therefore produce different ordinary values locally than in the discovered source schema.

Reproduction

Create a disposable source table with numeric(8,2) and timestamp(0). Discover it through Source.discover, then build the local Dev.dev fixture from that snapshot and insert the same values in both:

numeric input 9.995: source "10.00", fixture "9.995"
numeric input 9: source "9.00", fixture "9"
timestamp fractional input: source rounds to whole second, fixture retains fractions

The investigator isolated the reconstruction difference with the same PGlite engine on both sides. The independent reviewer then ran native PostgreSQL 18.4 discovery through Dev.dev and actual operation handlers. Numeric/timestamp list and equality/range results differed. A base-type table matched all five reads, and already-normalized data matched. character(4) differed in a raw length query, but typed-list character output matched and is not claimed broken.

This is local fixture fidelity evidence, not a production incident or full PostgreSQL parity claim. No external database or actual company rows were used.

Cause and scope

Discovery retains formatted type information, but nativeType emits a base type, and fixture DDL uses it. Fixture guidance also omits modifiers.

Preserve validated structured modifiers for supported builtin numeric, character and timestamp types in fixture DDL and guidance. Keep documented domain/view/extension limits; do not treat the source's formatted type string as executable DDL. If modifier-free fixtures are an intentional product limit, document it explicitly rather than promising source-native behavior. The review found no such existing exception for plain builtin modifiers.

Audited at ef3e790. Found and independently checked by separate GPT-6 Astra agents in Oh My Pi, using only ordinary offline workflows and synthetic data.

Activity

  1. added
    bug
    needs-triage
    area:cli
    area:integrations
    on Sep 20, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    area:cliarea:integrationsbugneeds-triage

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions