Re: [racket-users] Trouble shooting net/http-client

2020-05-15 Thread Jon Zeppieri
I can't reproduce this with a simple example.

```
#lang racket/base

(require net/http-client)

(define data "hello world!")

(http-sendrecv "postman-echo.com"
   "/post"
   #:ssl? #f
   #:method #"POST"
   #:data data)
```

Maybe you could post your code?

- Jon


On Fri, May 15, 2020 at 3:57 PM je back  wrote:
>
> I'm having trouble with formatting the #:data parameter to a http-sendrecv 
> request.  If I insert the string literal after #:data "my string" it works, 
> if I bind the string to a symbol (define my-string "my string") and call with 
> #:data my-string i get an error from the severs: HTTP/1.1 400 Bad Request .  
> Is there a way to echo or examine the request as sent?
>
> Also, I can't figure out where the source code for this library is located.
>
> Thanks,
> Jan Erik
>
>
> --
> You received this message because you are subscribed to the Google Groups 
> "Racket Users" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to racket-users+unsubscr...@googlegroups.com.
> To view this discussion on the web visit 
> https://groups.google.com/d/msgid/racket-users/b786e6fa-512b-4694-885a-afde1a011cf1%40googlegroups.com.

-- 
You received this message because you are subscribed to the Google Groups 
"Racket Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to racket-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/racket-users/CAKfDxxxQ-LA9ood8n5xca3jQf-ux%3DcWfPFwb2G-ijVeVreKhvQ%40mail.gmail.com.


Re: [racket-users] Trouble shooting net/http-client

2020-05-15 Thread Sam Tobin-Hochstadt
The source code is here:
https://github.com/racket/racket/blob/master/racket/collects/net/http-client.rkt

Sam

On Fri, May 15, 2020 at 3:57 PM je back  wrote:
>
> I'm having trouble with formatting the #:data parameter to a http-sendrecv 
> request.  If I insert the string literal after #:data "my string" it works, 
> if I bind the string to a symbol (define my-string "my string") and call with 
> #:data my-string i get an error from the severs: HTTP/1.1 400 Bad Request .  
> Is there a way to echo or examine the request as sent?
>
> Also, I can't figure out where the source code for this library is located.
>
> Thanks,
> Jan Erik
>
>
> --
> You received this message because you are subscribed to the Google Groups 
> "Racket Users" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to racket-users+unsubscr...@googlegroups.com.
> To view this discussion on the web visit 
> https://groups.google.com/d/msgid/racket-users/b786e6fa-512b-4694-885a-afde1a011cf1%40googlegroups.com.

-- 
You received this message because you are subscribed to the Google Groups 
"Racket Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to racket-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/racket-users/CAK%3DHD%2BbYgz35ZN8ZSe8B_Njspet0n9kK%3DEtsvH-5ob_Y9YyQWg%40mail.gmail.com.