leif
2017-8-21 13:34:25

Does anyone know why scribble would print out a ??? as the result of an expression in an examples block?


leif
2017-8-21 13:34:36

When I run the same example in a repl, I get the correct output.


samth
2017-8-21 13:35:28

@leif I think that means it’s unprintable in some fashion


leif
2017-8-21 13:36:31

@samth That would make sense, except that it still shows up in the repl just fine.


leif
2017-8-21 13:37:04

I did add a prop:convertible property, that might be doing it….


mflatt
2017-8-21 13:40:16

@leif Yes, it looks like the base renderer prints "???" for any convertible (where convertible values not recognized by the HTML renderer fall through to the base renderer). Maybe that’s a bad idea in the base renderer.


leif
2017-8-21 13:41:21

@mflatt Mmmm…maybe. Given the convertible? interface I don’t think we can do much better though.


leif
2017-8-21 13:41:36

It probably should be documented somewhere though.


leif
2017-8-21 13:42:50

@mflatt Although in this case, looking, it looks like assuming I can convert it into an image is bad.


leif
2017-8-21 13:43:37

Like, I can convert it into a video, but I would honestly just rather it print out its type like in a repl: #<producer>


leif
2017-8-21 13:49:11

@mflatt Mmm…looking at the docs, it actually says: > If pretty-print? is true, the sandbox’s printer is set to pretty-print-handler. In that case, values that are convertible in the sense of convertible? are printed using write-special,


leif
2017-8-21 13:49:30

However, when I call write-special directly from within drracket, it shows up as you would expect:


leif
2017-8-21 13:49:43
#lang scratch

(require video/base)
(define x (clip "green"))

(write-special x)

mflatt
2017-8-21 13:50:25

write-special means that rendering is up to the port; Scribble doesn’t use DrRacket’s editor%-based port


leif
2017-8-21 13:50:40

AH


leif
2017-8-21 13:50:41

okay


leif
2017-8-21 13:51:39

In that case, if I turn off #:pretty-print? when defining the evaluator, will the text no longer be formatted in a nicely indented way?


leif
2017-8-21 13:52:00

(I say that because it would make sense to have a middle ground here, where you want the nice indentation, but not the auto-conversion.)


mflatt
2017-8-21 13:54:46

You could turn off #:pretty-print?, but I think adjusting the base renderer is more likely the right change


leif
2017-8-21 13:57:52

Fair. It also looks like it still tries to convert it even when pretty-print? is set to #f. :disappointed:


leif
2017-8-21 13:58:06

So, when you say adjust the base renderer, do you mean submitting a PR?


leif
2017-8-21 13:58:17

Or just for the documentation for one package?


mflatt
2017-8-21 13:58:18

I’m looking into the right change.


leif
2017-8-21 13:59:24

Okay cool, thanks.


mflatt
2017-8-21 14:07:48

@leif Setting #:pretty-print? to #f has no effect because the default operation–as long as current-print and print-as-expression are not changed–is to take the result value and typeset it with to-element


leif
2017-8-21 14:09:45

That makes sense.


mflatt
2017-8-21 14:43:42

@leif Change pushed


leif
2017-8-21 16:44:53

@mflatt cool, thank. checking them out now


leif
2017-8-21 16:56:11

@mflatt Also, just to make sure, the package server builds the docs with the latest stable version of racket?


mflatt
2017-8-21 16:56:35

No, http://docs.racket-lang.org\|docs.racket-lang.org is built with the current release


leif
2017-8-21 16:57:02

Err…ya, okay.


leif
2017-8-21 16:57:16

Basically 6.10, until the next version comes out.


leif
2017-8-21 16:57:19

(As I understand it anyway)


mflatt
2017-8-21 17:00:03

Sorry – I misread what you wrote. “latest stable version” is a reasonable synonym for “current release”!


leif
2017-8-21 17:00:21

No worries.


leif
2017-8-21 17:00:44

Just wondering how long the ??? will stay on the package server’s docs. :slightly_smiling_face:


leif
2017-8-21 17:01:08

Also, fyi, it looks like packages with conflicts don’t show up in the search results.


leif
2017-8-21 17:01:27

I suspect that’s probably because the package server doesn’t know which one to pick.


mflatt
2017-8-21 17:03:26

right


leif
2017-8-21 17:05:24

Is there any way to tell the package server which one it should choose as the primary package?


leif
2017-8-21 17:10:38

(Also cool. After compiling the new build it looks like the base renderer is working as expected, thanks. :slightly_smiling_face: )


blerner
2017-8-21 21:22:51

@blerner has joined the channel


lexi.lambda
2017-8-21 23:47:13

@ryanc when running raco check-requires on a file of mine, I’m getting an error that looks like this: derivation-parser: error on token #229: &lt;local-value, #&lt;syntax:/Users/alexis/gits/racket/racket/racket/collects/syntax/parse/private/lib.rkt:63:55 -string&gt;&gt;


lexi.lambda
2017-8-21 23:47:48

I am not sure what that means. does that mean anything to you, or should I just open a bug?


zenspider
2017-8-21 23:48:40

I’ve got a demo file to prototype how I want a new hash-lang to be… right now I just want to poke around quickly so I’m using #lang reader "literal.rkt" and that file does port->list to just dump everything it saw. It is failing on a line with a single \| in it because it isn’t balanced. Is there another #lang reader (or whatever) that does a looser parse? I just want to prototype the syntax at this point and not get tripped up on racket readerisms…


lexi.lambda
2017-8-21 23:49:59

@zenspider that is due to port-&gt;list, not reader. port-&gt;list calls read. is that really what you want, or do you want port-&gt;lines or something like that?


zenspider
2017-8-21 23:50:32

I’m currently line oriented, but I don’t need to be… I want balanced parens and just about nothing else


zenspider
2017-8-21 23:50:42

I only did port-&gt;list because it calls read until exhausted, right?


lexi.lambda
2017-8-21 23:51:01

you could use port-&gt;list, but parameterize read-accept-bar-quote to #f


zenspider
2017-8-21 23:51:16

interesting… I’ll try that


lexi.lambda
2017-8-21 23:51:17

that would make \| not act as a special character


zenspider
2017-8-21 23:52:09

thanks. that did it. perfect


zenspider
2017-8-21 23:52:25

I’m making a hash-lang for lexers… so I want bare \|s


ryanc
2017-8-22 00:43:22

@lexi.lambda, it means that that macro debugger’s parser and the macro expander’s instrumentation are out of sync. Yes, please file a bug in the macro-debugger repo.


mflatt
2017-8-22 00:49:21

@leif The pkg-build service should pay attention to rings to pick among conflicting packages; it doesn’t, yet. I’ll try to make that improvement sometime soon.