doobie
doobie copied to clipboard
Typechecking documentation shows wrong .check output
The first query check (the one where there are issues) in
https://tpolecat.github.io/doobie/docs/06-Checking.html (/modules/docs/src/main/tut/docs/06-Checking.md)
returns the same output as the second one (the one where issues are fixed).
For reference, this is the incorrect output. It is printed twice in the document. The first printing is the error (it should produce a failed check not a successful check). The second printing is correct:
biggerThan(0).check.unsafeRunSync
// Query0[Session.App.Country2] defined at 06-Checking.md:83
// select code, name, population, gnp
// from country
// where population > ?
// ✓ SQL Compiles and TypeChecks
// ✓ P01 Int → INTEGER (int4)
// ✓ C01 code CHAR (bpchar) NOT NULL → String
// ✓ C02 name VARCHAR (varchar) NOT NULL → String
// ✓ C03 population INTEGER (int4) NOT NULL → Int
// ✓ C04 gnp NUMERIC (numeric) NULL → Option[BigDecimal]
My company gives me something similar to google's 20% time, so I'll work on this today during that time and submit a PR.
This has actually already been fixed: @tpolecat, the microsite needs to be republished with the new docs. See: https://github.com/tpolecat/doobie/pull/1152