2
0
Fork 0
mirror of git://git.savannah.gnu.org/guix/guix-cuirass.git synced 2024-12-29 11:40:16 +01:00
guix-cuirass/.dir-locals.el
Ludovic Courtès bde190c1e4
database: Redefine ‘with-transaction’ to roll back upon exception.
Until now, uncaught exceptions within a transaction could lead to that
transaction being neither rolled back nor committed.  As a result, the
corresponding PostgreSQL connection in the pool would become
unusable (PostgreSQL throws: “current transaction is aborted, commands
ignored until end of transaction block”).

* src/cuirass/database.scm (with-transaction): Rewrite.
(db-add-evaluation, db-register-builds): Use it instead of literal
transactions.
* src/cuirass/metrics.scm (db-update-metrics): Likewise.
* tests/database.scm ("db-add-evaluation with wrong spec name"): New test.
2024-07-05 14:18:54 +02:00

24 lines
944 B
EmacsLisp

;;; Directory Local Variables
;;; For more information see (info "(emacs) Directory Variables")
((nil
(fill-column . 78)
(tab-width . 8)
(bug-reference-url-format . "http://bugs.gnu.org/%s")
(bug-reference-bug-regexp
. "<https?://\\(debbugs\\|bugs\\)\\.gnu\\.org/\\([0-9]+\\)>"))
(scheme-mode
(indent-tabs-mode)
(eval put 'with-store/non-blocking 'scheme-indent-function 1)
(eval put 'call-with-time 'scheme-indent-function 1)
(eval put 'test-error 'scheme-indent-function 1)
(eval put 'with-time-logging 'scheme-indent-function 1)
(eval put 'with-timing-check 'scheme-indent-function 1)
(eval put 'make-parameter 'scheme-indent-function 1)
(eval put 'with-database 'scheme-indent-function 0)
(eval put 'with-transaction 'scheme-indent-function 1)
(eval put 'with-resource-from-pool 'scheme-indent-function 2))
(texinfo-mode
(indent-tabs-mode)
(fill-column . 72)
(ispell-local-dictionary . "american")))