[drakma-announce] New version 0.4.4 (Was: Couple of problems)

Edi Weitz edi at agharta.de
Sun Sep 24 20:50:47 UTC 2006


Hi!

On Sun, 24 Sep 2006 09:41:04 +0300, "Ivan Toshkov" <ivan at toshkov.org> wrote:

> First of all, thank you Edi Weitz for your excellent libraries.  I
> find them simple to use, well thought out, and with excellent
> documentation.  Again, a big thank you.

You're welcome... :)

> And thanks to whoever is working on porting Drakma.

I think that's me... :)

> I found a couple of problems:
>
> Drakma cannot receive cookies from localhost.  After a short
> investigation I found that the problem was with the method
> VALID-COOKIE-DOMAIN-P, which insist to have at least 2 dots in the
> normalized domain name.  As a workaround I used 127.0.0.1 instead of
> localhost.

Thanks for the report, I've released a new version (0.4.4) which fixes
this.

> The other problem is with an incomplete implementation of
> flexi-streams under CMUCL.  The call:
>
>> (drakma:http-request "http://www.google.com/" :parameters '(("q" . "something")))
>
> works normally, but
>
>> (drakma:http-request "http://www.google.com/search" :parameters '(("q" . "something")))
>
> gives:
>
> No matching method for the generic function
> #<STANDARD-GENERIC-FUNCTION INPUT-STREAM-P (2) {58E17501}>, when called with
> arguments (#<FLEXI-STREAMS::VECTOR-OUTPUT-STREAM {5834F8FD}>).
>    [Condition of type PCL::NO-APPLICABLE-METHOD-ERROR]
>
>   0: ("DEFMETHOD NO-APPLICABLE-METHOD (T)" #<#1=unused-arg> #<#1#>
> #<STANDARD-GENERIC-FUNCTION INPUT-STREAM-P (2) {58E17501}>
> (#<FLEXI-STREAMS::VECTOR-OUTPUT-STREAM {5834F8FD}>))
>   1: (FLEXI-STREAMS:MAKE-FLEXI-STREAM
> #<FLEXI-STREAMS::VECTOR-OUTPUT-STREAM {5834F8FD}> :EXTERNAL-FORMAT
> :LATIN-1)
>   2: (FLEXI-STREAMS:STRING-TO-OCTETS "q" :EXTERNAL-FORMAT :LATIN-1 :START ...)
>   3: (DRAKMA::URL-ENCODE "q" :LATIN-1)
>   4: (DRAKMA::ALIST-TO-URL-ENCODED-STRING (("q" . "something")) :LATIN-1)
>   5: (DRAKMA:HTTP-REQUEST #<URI http://www.google.com/search>
> :PARAMETERS (("q" . "something")))
>
> I don't have time at the moment to see if anything else is missing
> and to give patches.  For this case though the workaround seems to
> be as simple as:
>
> (defmethod input-stream-p ((s flexi-streams::vector-output-stream)) nil)

If I understand the Gray streams proposal correctly, this isn't an
incompleteness in FLEXI-STREAMS, but a problem in CMUCL's Gray streams
implementation.  Are you using the newest version of CMUCL?  Have you
asked on their mailing list?  (It is also not clear to me why the
problem only surfaces with the longer URL because URL-ENCODE has to be
called in both cases.)

Cheers,
Edi.



More information about the Drakma-announce mailing list