Re: [racket-users] Thread and filesystem watching

2017-01-24 Thread David Storrs
On Tue, Jan 24, 2017 at 7:26 PM, Jon Zeppieri  wrote:

> Hi David,
>
> On Tue, Jan 24, 2017 at 6:52 PM, David Storrs 
> wrote:
>
>> [snip]
>>
>> - When I create the 'monitor this' event, I will need to wrap the sync in
>>> a thread since (sync) is synchronous.
>>
>>
>>
>> If I understand you correctly, you're considering creating a separate
> thread for each directory that you monitor. You could do that, but I'd
> suggest this instead:
> - build a list of `filesystem-change-evt`s
> - create a single thread, and in it monitor all of them at once with
> `(apply sync list-of-evts)`
>
> - Jon
>
>
That would neatly solve my concern about too many threads.  Thanks, Jon.
And since Racket threads are preemptive but not parallel it doesn't
actually cost me anything.

Oh, that reminds me:  can I be confident that all events will be
delivered?  Will an event be canceled if, e.g., it isn't synced in a
certain amount of time?

-- 
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.
For more options, visit https://groups.google.com/d/optout.


Re: [racket-users] Stickers!

2017-01-24 Thread Sam Caldwell
Thanks Ben, these look great!

On Tue, Jan 24, 2017 at 4:15 PM, Ben Greenman 
wrote:

> Hi Racket Users,
>
> I ordered a bunch of Racket stickers to celebrate the 6.8 release. Here's
> proof:
> http://www.ccs.neu.edu/home/types/resources/stickers.jpg
>
> If you send me your address, I will mail you some stickers. For free!*
>
> I'm thinking 4 stickers per request (2 rectangles, 2 circles), but if you
> live outside the US and promise to serve as a "volunteer regional sticker
> distributor" then I'll send more.**
>
> Peace, Love, and Racket,
> Ben
>
>
> * While supplies last. And if you want un-free stickers, you can make your
> own on stickermule.com or send a donation to RacketCon 2017.
>
> ** While supplies last, and subject to the internal dimensions of the
> cheapest padded envelope at my local US post office.
>
> --
> 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.
> For more options, visit https://groups.google.com/d/optout.
>

-- 
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.
For more options, visit https://groups.google.com/d/optout.


Re: [racket-users] Thread and filesystem watching

2017-01-24 Thread Jon Zeppieri
Hi David,

On Tue, Jan 24, 2017 at 6:52 PM, David Storrs 
wrote:

> [snip]
>
> - When I create the 'monitor this' event, I will need to wrap the sync in
>> a thread since (sync) is synchronous.
>
>
>
> If I understand you correctly, you're considering creating a separate
thread for each directory that you monitor. You could do that, but I'd
suggest this instead:
- build a list of `filesystem-change-evt`s
- create a single thread, and in it monitor all of them at once with
`(apply sync list-of-evts)`

- Jon

-- 
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.
For more options, visit https://groups.google.com/d/optout.


[racket-users] Re: Stickers!

2017-01-24 Thread Lehi Toskin
Stickers? For free?? Count me in! How would you like me to contact you in 
private?

On Tuesday, January 24, 2017 at 1:15:59 PM UTC-8, Ben Greenman wrote:
> 
> If you send me your address, I will mail you some stickers. For free!*
> 

-- 
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.
For more options, visit https://groups.google.com/d/optout.


[racket-users] Thread and filesystem watching

2017-01-24 Thread David Storrs
I mentioned before that I'm writing a system to watch the filesystem for
changes.  I'm finishing that up and I have a few questions about
concurrency issues.


1) How do I determine what a safe maximum number of threads is?

2) I think that (fold-files) is the best way to walk a directory tree,
since it will process the files in constant space without building a giant
list of files the way (find-files) would. Is there a better option?  For
this specific purpose all I care about is getting the subdirectories --
processing the actual files happens elsewhere -- so if there was a way to
say "

3) If you have any comments on the following they would be appreciated:

First, the spec:

- Monitor a directory tree for any changes, ensure that the DB accurately
records what's on the disk.
- The tree probably isn't more than 5-10 directories deep, but it could be
arbitrarily more.
- There are potentially (tens of) millions of files in the tree.
- Any given directory probably only has a few thousand files at most.

I monitor a directory with this:

(define change(sync (filesystem-change-evt "/foo")))
...do something with 'change'...

but that only monitors /foo, not the subdirectories of /foo.  To monitor
the rest of the tree I will need to walk down from /foo creating new
monitor events for each subdirectory.

I believe that:

- When I create the 'monitor this' event, I will need to wrap the sync in a
thread since (sync) is synchronous.

- The result of the sync will be the event itself, so I can then do
whatever it takes and then plug it back into sync to keep watching.

- It's okay to have each monitoring thread do its own DB processing as
opposed to having it instruct a different thread (probably via a channel)
to deal with it.


Thoughts?

-- 
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.
For more options, visit https://groups.google.com/d/optout.


Re: [racket-users] Mann-Whitney test?

2017-01-24 Thread Mitchell Wand
Yo!  This conversation has gone seriously off-topic.  Can y'all carry it on
with some other subject line?
--Mitch

On Tue, Jan 24, 2017 at 11:38 AM, Tim Chase  wrote:

> Here is an interesting alternative: https://www.opencpu.org.
>
> You communicate with R processes via JSON. So, you wouldn't want a lot of
> back-and-forth, but I can see doing some setup logic and data prep in
> Racket, then sending off the JSON request, then interpreting the results.
> OpenCPU happens to be R in the middle right now, but as far as Racket is
> concerned, it is a black box that takes in JSON and returns JSON.
>
>
> On Monday, January 23, 2017 at 1:23:01 PM UTC-5, Leif Andersen wrote:
> > You _could_ use the FFI, but you'd have to use the Racket FFI to go to
> C, and then use R's FFI to go to C, and then coerce all of R's data to
> Racket and all of Racket's data back to R.
> >
> > Because of this (provided no one makes a #lang R first ;)  ), I think it
> would be easier to just spawn up a new R process using something like
> system* or process, and use pipes to send data back and forth directly.
> Yes, all of the data would need to be serialized into streams, but you
> would do an analogous process going from R to C to Racket.
> >
> >
> >
> >
> >
> >
> >
> > ~Leif Andersen
> >
> >
> > On Sun, Jan 22, 2017 at 12:19 AM, James  wrote:
> >
> >
> > > Does anybody have an implementation of the Mann-Whitney U test (or the
> equivalent Wilcoxson Rank test) in Racket?  I imagine I could easily hack
> up my own, but somebody else may have done a better job of it already.
> >
> >
> >
> > I see that no one has answered this question yet.  This is something
> which I would do and have done in R.  So this brings me to a question I was
> going to ask anyway which is how to do multi-language development including
> Racket and R.  Would it be FFI from Racket to R?  I already have a body of
> R code of my own which I would like to be able to call from Racket.  The
> general idea is that It would be an application where things like the GUI
> and networking elements are done in Racket but computations are done in R.
> >
> >
> >
> > James
> >
> >
> >
> >
> >
> > --
> >
> > 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...@googlegroups.com.
> >
> > For more options, visit https://groups.google.com/d/optout.
>
>

-- 
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.
For more options, visit https://groups.google.com/d/optout.


[racket-users] Stickers!

2017-01-24 Thread Ben Greenman
Hi Racket Users,

I ordered a bunch of Racket stickers to celebrate the 6.8 release. Here's
proof:
http://www.ccs.neu.edu/home/types/resources/stickers.jpg

If you send me your address, I will mail you some stickers. For free!*

I'm thinking 4 stickers per request (2 rectangles, 2 circles), but if you
live outside the US and promise to serve as a "volunteer regional sticker
distributor" then I'll send more.**

Peace, Love, and Racket,
Ben


* While supplies last. And if you want un-free stickers, you can make your
own on stickermule.com or send a donation to RacketCon 2017.

** While supplies last, and subject to the internal dimensions of the
cheapest padded envelope at my local US post office.

-- 
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.
For more options, visit https://groups.google.com/d/optout.


[racket-users] Racket v6.8

2017-01-24 Thread Vincent St-Amour
Racket version 6.8 is now available from

http://racket-lang.org/

- Racket sports a new logo, courtesy of Matthew Butterick.

- MacBook Pro laptops with touch bars are supported.

- Support for FreeBSD on PowerPC.

- Initial support for GTK3 on Wayland is available. GL contexts, GC
  blits, and dialog placement currently do not work.

- The macro stepper provides a command-line interface via the
  `raco macro-stepper` command.

- Typed Racket more efficiently represents and computes types and
  propositions, resulting in faster type checking for many programs.
  For more details, see this blog post by Andrew Kent:
  https://pnwamk.github.io/blog/2017/01/08/some-changes-in-typed-racket-v6-8/

- The bytecode optimizer can reduce more expressions of the form
  `(equal? x y)` to `(eqv? x y)` or `(eq? x y)` when the type of `x` or
  `y` is known.

- The bytecode optimizer avoids dropping stack frames in some reductions.
  This provides better stack traces for errors when errotrace is enabled.

- The bytecode compiler detects more optimization opportunities,
  including when variables always hold a boolean value. In particular in
  expressions like `(or (symbol? x) (something))`, the optimizations
  avoid the creation of an intermediate variable to store the result of
  `(symbol? x)`.

- The `syntax` form preserves syntax properties on all template pieces.

- The `scribble/html/extra` module provides renderers for HTML elements
  that are part of the WHATWG HTML standard but not part of the `scribble/html`
  language by default (e.g., `map`, `time`, `video`).

- The DeinProgramm teaching languages support pattern matching using the
  `match` form.

- In the DeinProgramm languages, `define-record-procedures` supports
  specifying signatures as part of the form, instantly enabling
  properties quantifying over such records.

The following people contributed to this release:
Aleksej Saushev, Alex Knauth, Alexander Hedges, Alexander Shopov, Alexis
King, Andrew Kent, Asumu Takikawa, Ben Greenman, Celeste Hollenbeck,
Craig Allen, Don March, Georges Dupéron, Gustavo Massaccesi, James
Bornholt, Jay McCarthy, Jerry James, John Clements, Juan Francisco
Cantero Hurtado, Leandro Facchinetti, Leif Andersen, Matthew Butterick,
Matthew Flatt, Matthias Felleisen, Max New, Mike Sperber, Phil Nguyen,
Reid D McKenzie, Reuben Thomas, Robby Findler, Ryan Culpepper, Sam
Tobin-Hochstadt, Shu-Hung You, Spencer Florence, Stephen Chang, Tim
Brown, Tony Garnock-Jones, Vincent St-Amour, WarGrey Gyoudmon Ju, and
William G Hatch.

Feedback Welcome

-- 
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.
For more options, visit https://groups.google.com/d/optout.


Re: [racket-users] DrRacket: Interactive choice of what submodules to run when clicking Run

2017-01-24 Thread Laurent
I have a keybinding (or rather, a script menu item) that inserts the
following into the interaction window:
(require (only-in racket/enter dynamic-enter!)
   (only-in syntax/location quote-module-path))
(dynamic-enter! (quote-module-path main))

then I just press enter and the 'main submodule is loaded. That's hack but
it's the best I found so far.

On Tue, Jan 24, 2017 at 6:04 PM, David Christiansen <
da...@davidchristiansen.dk> wrote:

> In Greg Hendershott's racket-mode for Emacs, the "run" command will run
> the submodule that's under the cursor. Something similar that would let one
> right-click a submodule to run it in DrRacket would be quite nice.
>
> /David
>
>
>
> On 01/24/2017 12:17 PM, Robby Findler wrote:
>
>> There's not a simple way to do that right now, but I think a change to
>> the code to make that more configurable would be great.
>>
>> It is probably best to make this as a change to DrRacket proper and
>> support a cleaner interface all around. It might be nice to be able to
>> click on things in the interactions window to change the set that will
>> be run next time, for example.
>>
>> I've been thinking that this needs cleanup but haven't find time to
>> actually do it, sadly.
>>
>> Robby
>>
>>
>> On Tue, Jan 24, 2017 at 11:13 AM, Laurent 
>> wrote:
>>
>>> Hi all,
>>>
>>> Currently we can choose what submodules to run via the 'Choose
>>> Language...'
>>> settings.
>>>
>>> I'd like to make a keyboard shortcut that executes the current module but
>>> first asks the user what submodules she wants to run.
>>>
>>> So far I found
>>> (add-drs-function "run"  (λ (frame) (send frame execute-callback)))
>>> https://github.com/racket/drracket/blob/da4d2db396290edebee0
>>> e87908a0ff265c4c6f3a/drracket/drracket/private/rep.rkt#L213
>>>
>>> and the 'execute-callback':
>>> https://github.com/racket/drracket/blob/da4d2db396290edebee0
>>> e87908a0ff265c4c6f3a/drracket/drracket/private/unit.rkt#L2854
>>>
>>> But it seems that what submodules are run may be buried in
>>> 'module-language-settings'. Or is there a simple way to dynamically
>>> override
>>> these settings, say with an argument to 'execute-callback'?
>>>
>>> If that's too difficult, as a workaround I could go with running the
>>> module
>>> without any submodule---so I can choose afterwards what submodules to
>>> enter.
>>>
>>> Thanks,
>>> Laurent
>>>
>>> --
>>> 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.
>>> For more options, visit https://groups.google.com/d/optout.
>>>
>>
>>
> --
> 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.
> For more options, visit https://groups.google.com/d/optout.
>

-- 
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.
For more options, visit https://groups.google.com/d/optout.


Re: [racket-users] DrRacket: Interactive choice of what submodules to run when clicking Run

2017-01-24 Thread David Christiansen
In Greg Hendershott's racket-mode for Emacs, the "run" command will run 
the submodule that's under the cursor. Something similar that would let 
one right-click a submodule to run it in DrRacket would be quite nice.


/David


On 01/24/2017 12:17 PM, Robby Findler wrote:

There's not a simple way to do that right now, but I think a change to
the code to make that more configurable would be great.

It is probably best to make this as a change to DrRacket proper and
support a cleaner interface all around. It might be nice to be able to
click on things in the interactions window to change the set that will
be run next time, for example.

I've been thinking that this needs cleanup but haven't find time to
actually do it, sadly.

Robby


On Tue, Jan 24, 2017 at 11:13 AM, Laurent  wrote:

Hi all,

Currently we can choose what submodules to run via the 'Choose Language...'
settings.

I'd like to make a keyboard shortcut that executes the current module but
first asks the user what submodules she wants to run.

So far I found
(add-drs-function "run"  (λ (frame) (send frame execute-callback)))
https://github.com/racket/drracket/blob/da4d2db396290edebee0e87908a0ff265c4c6f3a/drracket/drracket/private/rep.rkt#L213

and the 'execute-callback':
https://github.com/racket/drracket/blob/da4d2db396290edebee0e87908a0ff265c4c6f3a/drracket/drracket/private/unit.rkt#L2854

But it seems that what submodules are run may be buried in
'module-language-settings'. Or is there a simple way to dynamically override
these settings, say with an argument to 'execute-callback'?

If that's too difficult, as a workaround I could go with running the module
without any submodule---so I can choose afterwards what submodules to enter.

Thanks,
Laurent

--
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.
For more options, visit https://groups.google.com/d/optout.




--
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.
For more options, visit https://groups.google.com/d/optout.


Re: [racket-users] DrRacket: Interactive choice of what submodules to run when clicking Run

2017-01-24 Thread Laurent
Ok, thanks for the quick answer, Robby. I don't have time currently to try
anything deep either, unfortunately.

On Tue, Jan 24, 2017 at 5:17 PM, Robby Findler 
wrote:

> There's not a simple way to do that right now, but I think a change to
> the code to make that more configurable would be great.
>
> It is probably best to make this as a change to DrRacket proper and
> support a cleaner interface all around. It might be nice to be able to
> click on things in the interactions window to change the set that will
> be run next time, for example.
>
> I've been thinking that this needs cleanup but haven't find time to
> actually do it, sadly.
>
> Robby
>
>
> On Tue, Jan 24, 2017 at 11:13 AM, Laurent 
> wrote:
> > Hi all,
> >
> > Currently we can choose what submodules to run via the 'Choose
> Language...'
> > settings.
> >
> > I'd like to make a keyboard shortcut that executes the current module but
> > first asks the user what submodules she wants to run.
> >
> > So far I found
> > (add-drs-function "run"  (λ (frame) (send frame execute-callback)))
> > https://github.com/racket/drracket/blob/da4d2db396290edebee0e87908a0ff
> 265c4c6f3a/drracket/drracket/private/rep.rkt#L213
> >
> > and the 'execute-callback':
> > https://github.com/racket/drracket/blob/da4d2db396290edebee0e87908a0ff
> 265c4c6f3a/drracket/drracket/private/unit.rkt#L2854
> >
> > But it seems that what submodules are run may be buried in
> > 'module-language-settings'. Or is there a simple way to dynamically
> override
> > these settings, say with an argument to 'execute-callback'?
> >
> > If that's too difficult, as a workaround I could go with running the
> module
> > without any submodule---so I can choose afterwards what submodules to
> enter.
> >
> > Thanks,
> > Laurent
> >
> > --
> > 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.
> > For more options, visit https://groups.google.com/d/optout.
>

-- 
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.
For more options, visit https://groups.google.com/d/optout.


Re: [racket-users] DrRacket: Interactive choice of what submodules to run when clicking Run

2017-01-24 Thread Robby Findler
There's not a simple way to do that right now, but I think a change to
the code to make that more configurable would be great.

It is probably best to make this as a change to DrRacket proper and
support a cleaner interface all around. It might be nice to be able to
click on things in the interactions window to change the set that will
be run next time, for example.

I've been thinking that this needs cleanup but haven't find time to
actually do it, sadly.

Robby


On Tue, Jan 24, 2017 at 11:13 AM, Laurent  wrote:
> Hi all,
>
> Currently we can choose what submodules to run via the 'Choose Language...'
> settings.
>
> I'd like to make a keyboard shortcut that executes the current module but
> first asks the user what submodules she wants to run.
>
> So far I found
> (add-drs-function "run"  (λ (frame) (send frame execute-callback)))
> https://github.com/racket/drracket/blob/da4d2db396290edebee0e87908a0ff265c4c6f3a/drracket/drracket/private/rep.rkt#L213
>
> and the 'execute-callback':
> https://github.com/racket/drracket/blob/da4d2db396290edebee0e87908a0ff265c4c6f3a/drracket/drracket/private/unit.rkt#L2854
>
> But it seems that what submodules are run may be buried in
> 'module-language-settings'. Or is there a simple way to dynamically override
> these settings, say with an argument to 'execute-callback'?
>
> If that's too difficult, as a workaround I could go with running the module
> without any submodule---so I can choose afterwards what submodules to enter.
>
> Thanks,
> Laurent
>
> --
> 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.
> For more options, visit https://groups.google.com/d/optout.

-- 
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.
For more options, visit https://groups.google.com/d/optout.


[racket-users] DrRacket: Interactive choice of what submodules to run when clicking Run

2017-01-24 Thread Laurent
Hi all,

Currently we can choose what submodules to run via the 'Choose Language...'
settings.

I'd like to make a keyboard shortcut that executes the current module but
first asks the user what submodules she wants to run.

So far I found
(add-drs-function "run"  (λ (frame) (send frame execute-callback)))
https://github.com/racket/drracket/blob/da4d2db396290edebee0e87908a0ff265c4c6f3a/drracket/drracket/private/rep.rkt#L213

and the 'execute-callback':
https://github.com/racket/drracket/blob/da4d2db396290edebee0e87908a0ff265c4c6f3a/drracket/drracket/private/unit.rkt#L2854

But it seems that what submodules are run may be buried in
'module-language-settings'. Or is there a simple way to dynamically
override these settings, say with an argument to 'execute-callback'?

If that's too difficult, as a workaround I could go with running the module
without any submodule---so I can choose afterwards what submodules to enter.

Thanks,
Laurent

-- 
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.
For more options, visit https://groups.google.com/d/optout.


Re: [racket-users] Mann-Whitney test?

2017-01-24 Thread Tim Chase
Here is an interesting alternative: https://www.opencpu.org. 

You communicate with R processes via JSON. So, you wouldn't want a lot of 
back-and-forth, but I can see doing some setup logic and data prep in Racket, 
then sending off the JSON request, then interpreting the results. OpenCPU 
happens to be R in the middle right now, but as far as Racket is concerned, it 
is a black box that takes in JSON and returns JSON. 


On Monday, January 23, 2017 at 1:23:01 PM UTC-5, Leif Andersen wrote:
> You _could_ use the FFI, but you'd have to use the Racket FFI to go to C, and 
> then use R's FFI to go to C, and then coerce all of R's data to Racket and 
> all of Racket's data back to R.
> 
> Because of this (provided no one makes a #lang R first ;)  ), I think it 
> would be easier to just spawn up a new R process using something like system* 
> or process, and use pipes to send data back and forth directly. Yes, all of 
> the data would need to be serialized into streams, but you would do an 
> analogous process going from R to C to Racket.
> 
> 
> 
> 
> 
> 
> 
> ~Leif Andersen
> 
> 
> On Sun, Jan 22, 2017 at 12:19 AM, James  wrote:
> 
> 
> > Does anybody have an implementation of the Mann-Whitney U test (or the 
> > equivalent Wilcoxson Rank test) in Racket?  I imagine I could easily hack 
> > up my own, but somebody else may have done a better job of it already.
> 
> 
> 
> I see that no one has answered this question yet.  This is something which I 
> would do and have done in R.  So this brings me to a question I was going to 
> ask anyway which is how to do multi-language development including Racket and 
> R.  Would it be FFI from Racket to R?  I already have a body of R code of my 
> own which I would like to be able to call from Racket.  The general idea is 
> that It would be an application where things like the GUI and networking 
> elements are done in Racket but computations are done in R.
> 
> 
> 
> James
> 
> 
> 
> 
> 
> --
> 
> 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...@googlegroups.com.
> 
> For more options, visit https://groups.google.com/d/optout.

-- 
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.
For more options, visit https://groups.google.com/d/optout.


[racket-users] PLDI workshop and proposal deadline - Jan 30

2017-01-24 Thread Tobias Grosser
Reminder!

The final deadline for PLDI W proposals is coming up on January 30.
Please see the PLDI website for more information.
http://conf.researchr.org/track/pldi-2017/pldi-2017-workshops-and-tutorials.

Tobias Grosser
PLDI Publicity Chair

-- 
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.
For more options, visit https://groups.google.com/d/optout.


Re: [racket-users] Safely using port->string where nothing has been written to the port

2017-01-24 Thread Sean Kemplay
Hi David,

Indeed it does!! Thanks for your help.

Sean

On Monday, January 23, 2017 at 7:16:58 PM UTC, David K. Storrs wrote:
> Hi Sean,
> 
> Does (byte-ready?) work for your case?
> 
> https://docs.racket-lang.org/reference/Byte_and_String_Input.html?q=peek#%28def._%28%28quote._~23~25kernel%29._byte-ready~3f%29%29
> 
> 
> 
> On Mon, Jan 23, 2017 at 6:05 AM, Sean Kemplay  wrote:
> Hello,
> 
> 
> 
> I am using the URL library to interact with a REST API.
> 
> 
> 
> One of the Endpoints sends returns no content for a POST request with a 
> status code of 204 (a little unusual however it is an external API so we have 
> to cater to it).
> 
> 
> 
> I can check the status code for 204 and only apply string->port if it isn't a 
> 204 - however I was wondering if there is any check that can be made at the 
> port level that no content will be written - in case we encounter a malformed 
> response which does not send through a body.
> 
> 
> 
> Currently without the checks port->string will hang on a 204 response.
> 
> 
> 
> This would be good to know more generally when dealing with ports as well.
> 
> 
> 
> Kind regards,
> 
> Sean
> 
> 
> 
> --
> 
> 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...@googlegroups.com.
> 
> For more options, visit https://groups.google.com/d/optout.

-- 
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.
For more options, visit https://groups.google.com/d/optout.