From rpgoldman at sift.info Sun Nov 4 19:59:59 2012 From: rpgoldman at sift.info (Robert Goldman) Date: Sun, 04 Nov 2012 13:59:59 -0600 Subject: [cl-json-devel] cl-json depends on lisp reader? In-Reply-To: <38DA2487-A5C4-4C29-AA9D-6CDC9F474811@gmail.com> References: <8F79A86E-279B-4FF9-9F7E-C159E73FA0B4@doremir.com> <38DA2487-A5C4-4C29-AA9D-6CDC9F474811@gmail.com> Message-ID: <5096C93F.4070702@sift.info> On 10/31/12 Oct 31 -5:26 PM, Boris Smilga wrote: > On Wed, Oct 31, 2012 at 5:07 PM, Sven Emtell > wrote: >> >> I use cl-json with LispWorks 6.1. >> When delivering an app, I am trying to minimize the size of it by >> setting delivery level 5. >> The cl-json function "decode-json-from-string" does not seem to like >> this without explicitly keeping the Lisp Reader using the delivery >> keyword (:keep-lisp-reader). >> Since the Lisp Reader is unnecessary for the rest of the app, I would >> like to leave it out when delivering. >> Any thoughts on this? > > The Lisp reader is used on just one occasion, namely, in the function > PARSE-NUMBER in src/decoder.lisp (line 417ff., four uses of > READ-FROM-STRING). You can easily ditch it by supplying another parser > for numbers. For this end, you have three options: A) wait for someone > to develop a replacement?without guarantees; B) write a replacement > yourself, send a patch to the maintainers, and wait for it to be pushed > to the repository; C) customize DECODE-JSON in your own code, by setting > or binding the handlers for number token. If you choose option C, I'd > suggest you read the relevant chapter in the User Guide > (http://common-lisp.net/project/cl-json/#DECODER-CUSTOMIZATION). The > handlers in question are represented by the variables *INTEGER-HANDLER* > and *REAL-HANDLER*. Wouldn't it be possible to replace all uses of READ-FROM-STRING here with PARSE-INTEGER? We would have to change the structure here from "try READ-FROM-STRING and if that fails, parse by hand" to just "parse by hand," but I think that would be reasonable. If so, I suggest we simply do that.... I have a patch, but it could use some review and check on multiple lisp implementations. I'll try to get it out today. Best, Robert From rpgoldman at sift.info Sun Nov 4 21:57:11 2012 From: rpgoldman at sift.info (Robert Goldman) Date: Sun, 04 Nov 2012 15:57:11 -0600 Subject: [cl-json-devel] cl-json depends on lisp reader? In-Reply-To: <38DA2487-A5C4-4C29-AA9D-6CDC9F474811@gmail.com> References: <8F79A86E-279B-4FF9-9F7E-C159E73FA0B4@doremir.com> <38DA2487-A5C4-4C29-AA9D-6CDC9F474811@gmail.com> Message-ID: <5096E4B7.6060804@sift.info> OK, I have a patch along the lines of my previous email. I will try to convince darcs to let me pass it on. It passes tests on ACL 8.2 SBCL 1.1 CCL 1.8 clisp 2.49 ABCL 1.0.1 [but I had to fix ARNESI, see below, or the tests wouldn't run] It *FAILS* the tests on ECL, seemingly because of problems with floating point comparisons: JSON-NUMBER []: (DECODE-JSON-FROM-STRING "-2.3e3") evaluated to -2300.0002, which is not = to -2300.0.. -------------------------------- -------------------------------- JSON-NUMBER []: (DECODE-JSON-FROM-STRING "-3e4") evaluated to -30000.004, which is not = to -30000.0.. -------------------------------- -------------------------------- JSON-NUMBER []: (DECODE-JSON-FROM-STRING "3e4") evaluated to 30000.004, which is not = to 30000.0.. -------------------------------- -------------------------------- JSON-NUMBER []: (DECODE-JSON-FROM-STRING "2e40") evaluated to 2.0000000000000315e40, which is not = to 2.e40.. -------------------------------- -------------------------------- JSON-NUMBER []: (WITH-FP-OVERFLOW-HANDLER (INVOKE-RESTART 'BIGNUMBER-STRING "BIG:") (DECODE-JSON-FROM-STRING "2e444")) evaluated to #.ext::single-float-positive-infinity, which is not EQUALP to "BIG:2e444".. -------------------------------- -------------------------------- JSON-NUMBER []: Unexpected Error: # #.. I do not know how to fix these. I need to check and see if these tests pass under the current version of CL-JSON with ECL, or if the failures are independent of my modifications. * I was not able to test on ABCL because the matcher function definition in ARNESI (which is used by FiveAM), cannot be compiled in ABCL: (defstruct (match-state (:conc-name ||)) target bindings matched) Changing the :CONC-NAME to "" fixed the problem. I don't know if this is a bug in ABCL or ARNESI. From rpgoldman at sift.info Sun Nov 4 21:57:16 2012 From: rpgoldman at sift.info (rpgoldman at sift.info) Date: Sun, 4 Nov 2012 15:57:16 -0600 (CST) Subject: [cl-json-devel] darcs patch: fix-fiveam-test-comparisons (and 1 more) Message-ID: <20121104215716.93F39480A1F9@rpgoldman-3.local> 2 patches for repository http://common-lisp.net/project/cl-json/darcs/cl-json: Sun Nov 4 15:49:32 CST 2012 rpgoldman at sift.info * fix-fiveam-test-comparisons FiveAM would like the expected value to be before the computed value, for best printing when tests fail. I reversed the arguments to the JSON-NUMBER test to agree with this convention. Sun Nov 4 15:52:54 CST 2012 rpgoldman at sift.info * remove-read-from-string-from-parse-number PARSE-NUMBER used to use READ-FROM-STRING. This was causing problems with some application-building systems. We replace use of the reader (through read-from-string) by PARSE-NUMBER. -------------- next part -------------- A non-text attachment was scrubbed... Name: fix_fiveam_test_comparisons.dpatch Type: text/x-darcs-patch Size: 16582 bytes Desc: A darcs patch for your repository! URL: From rpgoldman at sift.info Mon Nov 5 00:54:41 2012 From: rpgoldman at sift.info (rpgoldman at sift.info) Date: Sun, 4 Nov 2012 18:54:41 -0600 (CST) Subject: [cl-json-devel] darcs patch: fix-fiveam-test-comparisons (and 1 more) Message-ID: <20121105005442.C8815480C1B0@rpgoldman-3.local> 2 patches for repository http://common-lisp.net/project/cl-json/darcs/cl-json: Sun Nov 4 15:49:32 CST 2012 rpgoldman at sift.info * fix-fiveam-test-comparisons FiveAM would like the expected value to be before the computed value, for best printing when tests fail. I reversed the arguments to the JSON-NUMBER test to agree with this convention. Sun Nov 4 15:52:54 CST 2012 rpgoldman at sift.info * remove-read-from-string-from-parse-number PARSE-NUMBER used to use READ-FROM-STRING. This was causing problems with some application-building systems. We replace use of the reader (through read-from-string) by PARSE-NUMBER. -------------- next part -------------- A non-text attachment was scrubbed... Name: fix_fiveam_test_comparisons.dpatch Type: text/x-darcs-patch Size: 16582 bytes Desc: A darcs patch for your repository! URL: From henrik at evahjelte.com Mon Nov 5 21:04:18 2012 From: henrik at evahjelte.com (Henrik Hjelte) Date: Mon, 5 Nov 2012 22:04:18 +0100 Subject: [cl-json-devel] darcs patch: fix-fiveam-test-comparisons (and 1 more) In-Reply-To: <20121104215716.93F39480A1F9@rpgoldman-3.local> References: <20121104215716.93F39480A1F9@rpgoldman-3.local> Message-ID: On Sun, Nov 4, 2012 at 10:57 PM, wrote: > 2 patches for repository > http://common-lisp.net/project/cl-json/darcs/cl-json: > > Sun Nov 4 15:49:32 CST 2012 rpgoldman at sift.info > * fix-fiveam-test-comparisons > Sun Nov 4 15:52:54 CST 2012 rpgoldman at sift.info > * remove-read-from-string-from-parse-number > Applied, thanks ! /Henrik -------------- next part -------------- An HTML attachment was scrubbed... URL: From rpgoldman at sift.info Mon Nov 5 21:20:12 2012 From: rpgoldman at sift.info (Robert Goldman) Date: Mon, 05 Nov 2012 15:20:12 -0600 Subject: [cl-json-devel] darcs patch: fix-fiveam-test-comparisons (and 1 more) In-Reply-To: References: <20121104215716.93F39480A1F9@rpgoldman-3.local> Message-ID: <50982D8C.9030300@sift.info> On 11/5/12 Nov 5 -3:04 PM, Henrik Hjelte wrote: > On Sun, Nov 4, 2012 at 10:57 PM, > wrote: > > 2 patches for repository > http://common-lisp.net/project/cl-json/darcs/cl-json: > > > > Sun Nov 4 15:49:32 CST 2012 rpgoldman at sift.info > > * fix-fiveam-test-comparisons > Sun Nov 4 15:52:54 CST 2012 rpgoldman at sift.info > > * remove-read-from-string-from-parse-number > > > Applied, thanks ! > /Henrik Thanks. It would be great if someone could test CL-JSON on ECL, both before and after my modification. I don't know if my modification causes ECL to fail to pass its tests, or whether (as I suspect), it reveals problems with the I am embarrassed to reveal that darcs is all busted on my machine, and my attempts to revert CL-JSON simply resulted in my working copy getting wiped, and two bug reports to darcs... So I'm not capable of checking this myself. One patch I should have applied, but didn't, was a bump to CL-JSON's patch level.... Maybe someone could do that. Best, r From rpgoldman at sift.info Mon Nov 5 21:38:57 2012 From: rpgoldman at sift.info (Robert Goldman) Date: Mon, 05 Nov 2012 15:38:57 -0600 Subject: [cl-json-devel] darcs patch: fix-fiveam-test-comparisons (and 1 more) In-Reply-To: <50982D8C.9030300@sift.info> References: <20121104215716.93F39480A1F9@rpgoldman-3.local> <50982D8C.9030300@sift.info> Message-ID: <509831F1.4040900@sift.info> Ah, crumbs -- pressed "send" too soon. What I meant to say was that I couldn't tell if I broke the float tests on ECL or, as I suspect, they weren't passing before, because of float comparison errors. I don't know enough about the differences between ECL's implementation of floating point and that used in other CL implementations to hazard a guess. And I can't tell because my working copy is destroyed.... :-( From rpgoldman at sift.info Thu Nov 8 03:52:49 2012 From: rpgoldman at sift.info (Robert Goldman) Date: Wed, 07 Nov 2012 21:52:49 -0600 Subject: [cl-json-devel] Any interest in moving from darcs to git? Message-ID: <509B2C91.5060709@sift.info> I have had some unpleasant issues with darcs working on cl-json, and I find that working with it is very badly hampered by its lack of mindshare compared with other DVCSes. In particular: 1. The darcs maintainers are unable to supply binaries for Mac OSX. 2. No one has stepped up to the plate to provide a graphical UI for working with darcs. Not only are these a nuisance in and of themselves (the former especially, since darcs does not build on an out-of-the-box install of the Haskell Platform), they are the signs of a tool that does not have an adequately robust support community. Combine this with the oddity of the usage model, compared with other DCVSes,[1] and you have real problems. I am not volunteering to maintain CL-JSON, so it is ultimately not up to me. But I have submitted a number of patches, so I feel that I have standing at least to offer the suggestion. Note that I don't think that darcs, in and of itself, is a bad system. But there are more than enough DCVSes out there, and we can use one less of them. Best regards, Robert [1] See, for example: http://darcs.net/FAQ#how-do-i-go-back-to-an-older-version-of-my-repository From henrik at evahjelte.com Thu Nov 8 07:31:19 2012 From: henrik at evahjelte.com (Henrik Hjelte) Date: Thu, 8 Nov 2012 08:31:19 +0100 Subject: [cl-json-devel] Any interest in moving from darcs to git? In-Reply-To: <509B2C91.5060709@sift.info> References: <509B2C91.5060709@sift.info> Message-ID: On Thu, Nov 8, 2012 at 4:52 AM, Robert Goldman wrote: > Note that I don't think that darcs, in and of itself, is a bad system. > But there are more than enough DCVSes out there, and we can use one less > of them. > I think it is a good idea, it crossed my mind too. Also github is a good environment for cooperating. I think the darcs repo should live for some time while we double-commit. If no one objects, I'll try to do it quite soon. /Henrik -------------- next part -------------- An HTML attachment was scrubbed... URL: From rpgoldman at sift.info Thu Nov 8 15:53:31 2012 From: rpgoldman at sift.info (Robert Goldman) Date: Thu, 08 Nov 2012 09:53:31 -0600 Subject: [cl-json-devel] Any interest in moving from darcs to git? In-Reply-To: References: <509B2C91.5060709@sift.info> Message-ID: <509BD57B.4050705@sift.info> On 11/8/12 Nov 8 -1:31 AM, Henrik Hjelte wrote: > On Thu, Nov 8, 2012 at 4:52 AM, Robert Goldman > wrote: > > Note that I don't think that darcs, in and of itself, is a bad system. > But there are more than enough DCVSes out there, and we can use one less > of them. > > > I think it is a good idea, it crossed my mind too. Also github is a good > environment for cooperating. > I think the darcs repo should live for some time while we double-commit. > If no one objects, I'll try to do it quite soon. Sounds good. I have a preference for a canonical git repo at c-l.net, although a pointer from the c-l.net web page to one on github would be ok. What I'd like us to avoid is that mess where there are a dozen github repos for the same library, and no one knows which one is canonical. And I think we should still provide tarballs. I don't really get github's additional structure on top of vanilla git usage, and am not that excited about learning it. But I would be happy to continue to submit patches in the old school way, through 'git email'. Cheers, r From henrik at evahjelte.com Mon Nov 12 23:32:06 2012 From: henrik at evahjelte.com (Henrik Hjelte) Date: Tue, 13 Nov 2012 00:32:06 +0100 Subject: [cl-json-devel] Any interest in moving from darcs to git? In-Reply-To: <509BD57B.4050705@sift.info> References: <509B2C91.5060709@sift.info> <509BD57B.4050705@sift.info> Message-ID: On Thu, Nov 8, 2012 at 4:53 PM, Robert Goldman wrote: > On 11/8/12 Nov 8 -1:31 AM, Henrik Hjelte wrote: > > On Thu, Nov 8, 2012 at 4:52 AM, Robert Goldman > > wrote: > > > > Note that I don't think that darcs, in and of itself, is a bad > system. > > But there are more than enough DCVSes out there, and we can use one > less > > of them. > > > > > > I think it is a good idea, it crossed my mind too. Also github is a good > > environment for cooperating. > > I think the darcs repo should live for some time while we double-commit. > > If no one objects, I'll try to do it quite soon. > > Sounds good. I have a preference for a canonical git repo at c-l.net, > although a pointer from the c-l.net web page to one on github would be > ok. I read this mail after I did the git migration, but I did it like that. The docs are still on common-lisp but mentions the github url. > What I'd like us to avoid is that mess where there are a dozen > github repos for the same library, and no one knows which one is > canonical. I did a git-repo here: https://github.com/hankhero/cl-json I am not sure it would add something to host it on common-lisp.net instead. Other such as hunchentoot seem to be on github. > And I think we should still provide tarballs. > If someone asks on the mailing-list or me directly for a tarball, then I can do them. But does anyone use them? I don't really get github's additional structure on top of vanilla git > usage, and am not that excited about learning it. I think it will stimulate more patches, even from people that don't take their time or wish to send patches for various reasons. I think a lot of people think it is easier to ask for a pull-request. It is just a guess though. > But I would be happy > to continue to submit patches in the old school way, through 'git email'. > > Well that's great! Best wishes, Henrik -------------- next part -------------- An HTML attachment was scrubbed... URL: From avodonosov at yandex.ru Tue Nov 13 00:09:22 2012 From: avodonosov at yandex.ru (Anton Vodonosov) Date: Tue, 13 Nov 2012 04:09:22 +0400 Subject: [cl-json-devel] Any interest in moving from darcs to git? In-Reply-To: References: <509B2C91.5060709@sift.info> <509BD57B.4050705@sift.info> Message-ID: <174361352765362@web16e.yandex.ru> An HTML attachment was scrubbed... URL: From rpgoldman at sift.info Tue Nov 13 01:08:39 2012 From: rpgoldman at sift.info (Robert Goldman) Date: Mon, 12 Nov 2012 19:08:39 -0600 Subject: [cl-json-devel] Any interest in moving from darcs to git? In-Reply-To: References: <509B2C91.5060709@sift.info> <509BD57B.4050705@sift.info> Message-ID: <50A19D97.3040508@sift.info> On 11/12/12 Nov 12 -5:32 PM, Henrik Hjelte wrote: > On Thu, Nov 8, 2012 at 4:53 PM, Robert Goldman > wrote: > > On 11/8/12 Nov 8 -1:31 AM, Henrik Hjelte wrote: > > On Thu, Nov 8, 2012 at 4:52 AM, Robert Goldman > > > >> wrote: > > > > Note that I don't think that darcs, in and of itself, is a bad > system. > > But there are more than enough DCVSes out there, and we can > use one less > > of them. > > > > > > I think it is a good idea, it crossed my mind too. Also github is > a good > > environment for cooperating. > > I think the darcs repo should live for some time while we > double-commit. > > If no one objects, I'll try to do it quite soon. > > Sounds good. I have a preference for a canonical git repo at > c-l.net , > although a pointer from the c-l.net web page to one > on github would be > ok. > > > I read this mail after I did the git migration, but I did it like that. > The docs are still on common-lisp but mentions the github url. > > > What I'd like us to avoid is that mess where there are a dozen > github repos for the same library, and no one knows which one is > canonical. > > > I did a git-repo here: https://github.com/hankhero/cl-json > I am not sure it would add something to host it on common-lisp.net > instead. Other such as hunchentoot seem to be > on github. That looks great, thanks! Really appreciate your doing this. Best, Robert From rpgoldman at sift.info Tue Nov 13 15:11:02 2012 From: rpgoldman at sift.info (Robert Goldman) Date: Tue, 13 Nov 2012 09:11:02 -0600 Subject: [cl-json-devel] Any objection to bumping the ASDF :version Message-ID: <50A26306.9010401@sift.info> The new version of CL-JSON offers a READ-free version of the library. Since there was interest in this for shipping compiler-free executables, maybe we should make it detectable in ASDF dependencies. I'd propose either bumping to 0.4.3 (patchlevel) or, since this feature is persistent, we might want to bump to 0.5.0 The latter would permit people who want the READ-free version of the library to require (:version cl-json 0.5) in their dependencies. Also, how about we add tags to the repo for releases? Cheers, r From henrik at evahjelte.com Sun Nov 18 13:55:34 2012 From: henrik at evahjelte.com (Henrik Hjelte) Date: Sun, 18 Nov 2012 14:55:34 +0100 Subject: [cl-json-devel] Any objection to bumping the ASDF :version In-Reply-To: <50A26306.9010401@sift.info> References: <50A26306.9010401@sift.info> Message-ID: I have now made an 0.5.0 version of cl-json, made tar files, and tagged it v0.5.0. Seems github automatically serves zip-files of tagged versions. Also I made a nickname cl-json that was once requested here, and I have mailed to zach/quicklisp to change their pointer. Also I made an attempt to fix the one remaining failing testcase, but I didn't succeed. /Henrik -------------- next part -------------- An HTML attachment was scrubbed... URL: From sven.emtell at doremir.com Tue Nov 27 10:25:18 2012 From: sven.emtell at doremir.com (Sven Emtell) Date: Tue, 27 Nov 2012 11:25:18 +0100 Subject: [cl-json-devel] cl-json depends on lisp reader? In-Reply-To: <5096E4B7.6060804@sift.info> References: <8F79A86E-279B-4FF9-9F7E-C159E73FA0B4@doremir.com> <38DA2487-A5C4-4C29-AA9D-6CDC9F474811@gmail.com> <5096E4B7.6060804@sift.info> Message-ID: Just want to let you know that we now use cl-json 0.5.0 without having to keep the lisp reader when delivering. Thanks everyone! Sven 4 nov 2012 kl. 22:57 skrev Robert Goldman: > OK, I have a patch along the lines of my previous email. I will try to > convince darcs to let me pass it on. > > It passes tests on > > ACL 8.2 > SBCL 1.1 > CCL 1.8 > clisp 2.49 > ABCL 1.0.1 [but I had to fix ARNESI, see below, or the tests wouldn't run] > > > It *FAILS* the tests on ECL, seemingly because of problems with floating > point comparisons: > > JSON-NUMBER []: > (DECODE-JSON-FROM-STRING "-2.3e3") evaluated to -2300.0002, which > is not = to -2300.0.. > -------------------------------- > -------------------------------- > JSON-NUMBER []: > (DECODE-JSON-FROM-STRING "-3e4") evaluated to -30000.004, which is > not = to -30000.0.. > -------------------------------- > -------------------------------- > JSON-NUMBER []: > (DECODE-JSON-FROM-STRING "3e4") evaluated to 30000.004, which is > not = to 30000.0.. > -------------------------------- > -------------------------------- > JSON-NUMBER []: > (DECODE-JSON-FROM-STRING "2e40") evaluated to > 2.0000000000000315e40, which is not = to 2.e40.. > -------------------------------- > -------------------------------- > JSON-NUMBER []: > (WITH-FP-OVERFLOW-HANDLER (INVOKE-RESTART 'BIGNUMBER-STRING "BIG:") > (DECODE-JSON-FROM-STRING "2e444")) evaluated > to #.ext::single-float-positive-infinity, which is not EQUALP to > "BIG:2e444".. > -------------------------------- > -------------------------------- > JSON-NUMBER []: > Unexpected Error: # > #.. > > I do not know how to fix these. > > I need to check and see if these tests pass under the current version of > CL-JSON with ECL, or if the failures are independent of my modifications. > > > * I was not able to test on ABCL because the matcher function definition > in ARNESI (which is used by FiveAM), cannot be compiled in ABCL: > > (defstruct (match-state (:conc-name ||)) > target > bindings > matched) > > Changing the :CONC-NAME to "" fixed the problem. I don't know if this > is a bug in ABCL or ARNESI. > > _______________________________________________ > cl-json-devel mailing list > cl-json-devel at common-lisp.net > http://lists.common-lisp.net/cgi-bin/mailman/listinfo/cl-json-devel --- Sven Emtell, CTO, DoReMIR Music Research www.scorecleaner.com Check out the ScoreCleaner introductory video here -------------- next part -------------- An HTML attachment was scrubbed... URL: