[postmodern-devel] *silently-truncate-ratios*

Attila Lendvai attila.lendvai at gmail.com
Fri Feb 6 16:13:12 UTC 2009


> Thanks for the patch. I've revised the writer function a bit -- there
> was some useless cruft in it, and you misspelled floating as foating
> -- and added a switch to turn off the raising of errors,


thanks for the cleanup, it was just a quick'n'dirty result of a longer
debugging session...


> *silently-truncate-literals*, which defaults to T, since I suspect not
> everyone is happy with errors like that popping up. You can set it to
> NIL and get the behaviour you're after.


...but i really don't like the default of that special.

rationale: 1) you start using the lib, do some calculations involving
db storage, some time later realize that they are somewhat off, start
digging where the hell it goes wrong, waste a lot of time looking at
too many things until you finally realize that 7/10 written to the
database silently comes back as something else than 7/10.

imho, that special should default to NIL for the least surprises and
for bringing the symptoms of the error *much* closer to their cause.

then: 2) user stars using lib, stores ratios in db, at some point
faces a descriptive error message which includes a hint about the
above mentioned special, reads up on the issue if necessary, based on
necessary understanding of the issue decides to add required coercions
to his code or to set/bind the special to T.

summing up all the time people would spend with the use-case 1) is a
lot more than people would spend with 2).

now, i don't care much, because i've been through 1) already... :) but
i suggest these changes for everyone's good.

i've pushed what i think to my repo, but i will not stick to it. if
you decide to keep things as they are, i'll eventually unpull my patch
to enjoy the benefit of the zero distance from the official repo.

hth,

-- 
 attila

ps: i've cc'd the list if other lib users want to speak up on the issue...




More information about the postmodern-devel mailing list