Skip to content

Releases: adelsz/pgtyped

v2.3.0

07 Oct 21:04
Compare
Choose a tag to compare

New features

  • Experimental mode to generate a unique typed SQL tag by @JesseVelden in #520
  • Generated imports are forced to be type-only where possible
  • Introduced a config variable to limit the max number of worker threads

Bug fixes

  • Generated import paths fixed on Window machines by @lucas-gregoire in #533
  • Separate name and definition of union types to prevent Array naming issues by @leifniem in #521
  • Added dir_base template parameter for emitTemplate by @mrsafalpiya in #515
  • PG ranges are no longer parsed as params
  • Non-identifier object keys are properly escaped in generated code

New Contributors

Full Changelog: v2.2.1...v2.3.0

v2.2.0

30 Apr 21:26
Compare
Choose a tag to compare

What's Changed

New Contributors

Full Changelog: v2.1.0...v2.2.0

v2.1.0

03 Mar 01:46
Compare
Choose a tag to compare

New features

Bug fixes

  • Postgres dollar string parsing fixed by @adelsz in #493 πŸ’²

New Contributors

Full Changelog: v2.0.1...v2.1.0

v2.0.1

04 Feb 18:42
Compare
Choose a tag to compare

Bug fixes

  • Fix fragmented TCP packet handling that had been causing random CLI hangs on big PG data types (#487)

Full Changelog: v2.0.0...v2.0.1

v2.0.0

29 Jan 16:06
Compare
Choose a tag to compare

Features:

  • All packages and code migrated to ES modules πŸ“š (#478)
  • Introduced new @pgtyped/runtime package. πŸƒ (#478)
    It is the only package needed to run pgTyped generated queries and is optimized for package size (ESM & CommonJS compatible).
  • Environment variable DATABASE_URL now supported as an alternative to PGURI (thanks to @msakrejda in #484)
  • Nullable scalar parameter are no longer required when running a query (#482) πŸ₯‚
  • Queries returning anonymous columns are now forbidden and result in an error
  • PgTyped in watch mode warns & exits on config file changes (2515f15) πŸ‘€
  • Migrate to a more modern and performant threadpool Piscina. 🐠

Bug fixes:

  • failOnError config option now kills the threadpool and exits pgTyped with an error code (aada874) πŸ™…

Development changes:

  • Lerna upgraded to latest version, meaning we now use native npm workspaces.
  • Jest upgraded to latest version, number of tests rewritten to work with ESM and latest Jest. Mocking no longer supported.
  • `@pgtyped/example" Integration tests now using Jest.
  • Docs upgraded to Docusaurus 2.

Funding

New Contributors

v1.1.0

22 Jan 10:56
Compare
Choose a tag to compare

Features:

  • Support type overrides (thanks @nick-keller) πŸ› οΈ
  • Hungarian notation in interface names is now opt-in (thanks @snarky-puppy) πŸ‡­πŸ‡Ί

Bug fixes:

  • Fixed the parser to support Unicode characters that were breaking some queries 🌏

v1.0.2

22 Jul 00:47
Compare
Choose a tag to compare

Bug fixes:

  • Adding a query with a JsonArray type now correctly emits a Json type as well (thanks @logan12358) πŸ“š
  • Fixed the bug where pgTyped would leave orphan worker processes after shutdown 🚸
  • Fixed invalid dbUrl in the example config file πŸ”—

v1.0.0

17 May 22:40
Compare
Choose a tag to compare

New features:

  • File processing logic is now parallelized, meaning much faster runs on large codebases (thanks @golergka) 🏎️
  • Output nullability overriding that provides a workaround for Postgres type inference quirks (thanks @JesseVelden) πŸŽ‰
  • Column comments are now included in generated types (thanks @danvk) πŸ’¬
  • Stable SQL query IR preventing git diffs on irrelevant query file changes (thanks @bradleyayers) πŸ›οΈ
  • Postgres tsvector datatype now supported (thanks @bradleyayers) πŸ”–

Bug fixes:

  • Improved parsing of SQL comments (thanks @bradleyayers)
  • Lexer bug for params with specials chars preceding
  • Multiline comments parsing bug fixed
  • More verbose file processing messages

v0.13.0

25 Dec 00:30
Compare
Choose a tag to compare

New features:

  • Support enum array types (thanks @maylukas ) πŸ“š
  • Support SCRAM-SHA-256 authentication (thanks @JesseVelden) πŸ”‘
  • Introduce deterministic field ordering (thanks @fmmoret) πŸ”’

Bug fixes:

  • Fix non-nullable parameters parsing edgecase 🐞
  • Use unknown instead of never for unsupported types (thanks @theswerd) ❔

v0.12.0

16 Sep 22:49
Compare
Choose a tag to compare

New features:

  • Allow to specify param nullability as :paramName! (thanks @JohnnyCrazy) πŸ₯‡
  • Postgis point type support (thanks @joecarver ) βšͺ

Bug fixes:

  • esModuleInterop: false compatibility fix (thanks @bag-man) πŸ“¦
  • Cast numeric/decimal/money as a string (thanks @jgonera) πŸ’΅