Skip to content

@blazetrails/pg ​

The PostgreSQL client, mirroring Ruby's pg gem

MeasureValue
Rails counterpartpg v1.6.2
API methods matched100% (120 of 120)
Rails tests matched100% (28 of 28) (360 permanent)
Ruby files ported19
Ruby files unported0
Measured atfe89b44726

Gaps by file ​

No gaps recorded for this package.

Missing methods ​

None recorded for this package.

Unported Ruby files ​

Every compared Ruby file has a TypeScript file.

Deviation receipts ​

JSDoc receipt tags in the package's source, by the receipt each carries.

TagPERMANENTCONVERGEABLEnone
@noRailsEquivalent2100
@missingRailsCall100
@missingRailsArgs500
@inventedArm300
@internal0056

Permanently skipped tests ​

A String has no encoding tag either (1)

Ratified deviations ​

Each rule below is ratified in the repository's CLAUDE.md files. The first paragraph is quoted; the link opens the full section at this build's commit.

A String has no encoding tag either ​

str.encoding, force_encoding and String#b read or change a per-object encoding. A JS string has none, and trails adds none: the carrier that would hold it is the carrier this section rejects. ruby-compat tags a Uint8Array only. A Rails body that branches on a String's encoding ports the UTF-8 arm, and a test asserting str.encoding is permanently unportable for that assertion.

CLAUDE.md →

The pg port carries only what trails calls (PG::Connection, PG::Result) ​

@blazetrails/pg wraps the pg npm client (node-pg) the way packages/bcrypt wraps bcryptjs. The gem's Ruby files and its C extension (vendor/pg/v1.6.2/ext/) define far more than Rails uses: large objects, pipeline mode, the sync_* / async_* / send_* variants, SSL and trace hooks, connection-info readers and PG::Result's field accessors. Most of it is libpq surface that node-pg, which speaks the wire protocol itself, does not expose.

packages/pg/CLAUDE.md →

Source ​

packages/pg on GitHub →