@vantreeseba/drizzle-graphql 8.0.0 → 8.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +13 -1
- package/dist/README.md +13 -1
- package/dist/index.cjs +2059 -2454
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +10 -2
- package/dist/index.d.ts +10 -2
- package/dist/index.js +1944 -2339
- package/dist/index.js.map +1 -1
- package/dist/package.json +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -1818,11 +1818,23 @@ to match on prose:
|
|
|
1818
1818
|
|
|
1819
1819
|
- `code` classifies the failure — `DRIZZLE_MULTI_ROW_MATCH`, `DRIZZLE_WHERE_REQUIRED`,
|
|
1820
1820
|
`DRIZZLE_LIMIT_EXCEEDED`, `DRIZZLE_NO_VALUES`, `DRIZZLE_INVALID_FILTER`,
|
|
1821
|
-
`DRIZZLE_INVALID_CURSOR`, and so on. The full union is
|
|
1821
|
+
`DRIZZLE_INVALID_CURSOR`, `DRIZZLE_INVALID_INPUT_VALUE`, and so on. The full union is
|
|
1822
|
+
exported as `DrizzleErrorCode`.
|
|
1822
1823
|
- `drizzle` says what it was about: the Drizzle schema key of the `table`, the `operation`,
|
|
1823
1824
|
the generated `field`, and the `relation` for a relation field. The type is exported as
|
|
1824
1825
|
`DrizzleErrorContext`.
|
|
1825
1826
|
|
|
1827
|
+
A value the request could not supply is `DRIZZLE_INVALID_INPUT_VALUE` — a date that does not
|
|
1828
|
+
parse, a `BigInt` argument that is not an integer, a malformed JSON column value — and a write
|
|
1829
|
+
naming something that is not a column of its table is `DRIZZLE_UNKNOWN_COLUMN`. The mirror
|
|
1830
|
+
image, a stored value the scalar transporting it cannot represent, is
|
|
1831
|
+
`DRIZZLE_UNREPRESENTABLE_VALUE`; it says the data is out of range, not that the request was
|
|
1832
|
+
wrong.
|
|
1833
|
+
|
|
1834
|
+
The `drizzle` block is only on errors raised from inside a field. An argument rejected while
|
|
1835
|
+
GraphQL coerces the request — a `BigInt` variable that is not an integer, say — is rejected
|
|
1836
|
+
before any resolver runs, so it carries its `code` but no `drizzle` and no `path`.
|
|
1837
|
+
|
|
1826
1838
|
The **generated** field name is in `extensions.drizzle.field` rather than in the message on
|
|
1827
1839
|
purpose. A schema that republishes these fields under other names — `RenameRootFields`, a
|
|
1828
1840
|
stitched gateway, a hand-written façade — renames the schema, not the inside of a message, so
|
package/dist/README.md
CHANGED
|
@@ -1818,11 +1818,23 @@ to match on prose:
|
|
|
1818
1818
|
|
|
1819
1819
|
- `code` classifies the failure — `DRIZZLE_MULTI_ROW_MATCH`, `DRIZZLE_WHERE_REQUIRED`,
|
|
1820
1820
|
`DRIZZLE_LIMIT_EXCEEDED`, `DRIZZLE_NO_VALUES`, `DRIZZLE_INVALID_FILTER`,
|
|
1821
|
-
`DRIZZLE_INVALID_CURSOR`, and so on. The full union is
|
|
1821
|
+
`DRIZZLE_INVALID_CURSOR`, `DRIZZLE_INVALID_INPUT_VALUE`, and so on. The full union is
|
|
1822
|
+
exported as `DrizzleErrorCode`.
|
|
1822
1823
|
- `drizzle` says what it was about: the Drizzle schema key of the `table`, the `operation`,
|
|
1823
1824
|
the generated `field`, and the `relation` for a relation field. The type is exported as
|
|
1824
1825
|
`DrizzleErrorContext`.
|
|
1825
1826
|
|
|
1827
|
+
A value the request could not supply is `DRIZZLE_INVALID_INPUT_VALUE` — a date that does not
|
|
1828
|
+
parse, a `BigInt` argument that is not an integer, a malformed JSON column value — and a write
|
|
1829
|
+
naming something that is not a column of its table is `DRIZZLE_UNKNOWN_COLUMN`. The mirror
|
|
1830
|
+
image, a stored value the scalar transporting it cannot represent, is
|
|
1831
|
+
`DRIZZLE_UNREPRESENTABLE_VALUE`; it says the data is out of range, not that the request was
|
|
1832
|
+
wrong.
|
|
1833
|
+
|
|
1834
|
+
The `drizzle` block is only on errors raised from inside a field. An argument rejected while
|
|
1835
|
+
GraphQL coerces the request — a `BigInt` variable that is not an integer, say — is rejected
|
|
1836
|
+
before any resolver runs, so it carries its `code` but no `drizzle` and no `path`.
|
|
1837
|
+
|
|
1826
1838
|
The **generated** field name is in `extensions.drizzle.field` rather than in the message on
|
|
1827
1839
|
purpose. A schema that republishes these fields under other names — `RenameRootFields`, a
|
|
1828
1840
|
stitched gateway, a hand-written façade — renames the schema, not the inside of a message, so
|