Racket v8.7 Release Thread

I adjusted a diagram I made earlier for @jbclements to reflect @elibarzilay's suggestion (AIUI), because I found a visualization helped me understand the details:

This makes sense to me, I think. I'm currently wrestling with the fact that our most recent first-ever merge of stable into the release branch means that my "commits that appear on the release branch but not in the last tagged release" now includes all cherry-picked commits going back to the beginning of time. I believe this won't happen again, though.

@LiberalArtist , can you formulate what you & Eli are proposing as they would appear in a checklist? That is:

  • branch day: (execute these commands)
  • release day: (execute these commands)

I do not know whether they were bugs, but I show a few things I have noticed.

1. a struct with #:transparent + a SRFI-1's circular list shows messed print-outs.

I had made a program of the Old-maid. The source is here.
This works fine, but let's say, when I wanted to see an environmental value, w, embedded in the game-eval, I noticed the display shows something strange.

;; Sorry, comments are written in Japanese.
(define (oldmaid n)
  (let loop ((w (initialize n)))
    ;;; ここで例外処理を記述する
    (with-handlers ((exn:fail:contract?
                     ;;; 例外処理
                     (lambda (ext) (display "入力が不正です\n")
                       (loop w))))
      ;;; 本体
      (if (game-ends? w)
          (display (showResult (world-id1 w)))
          ;;; Read-Eval-Print loop
          (begin (display w) ;; Adding this for debugging, for instance
                 (loop (print (world-go (input w) w))))))))


You see, the w, or the World struct has an circular list in it, and the process itself has no problem at all; however, the print shown becomes messed-up.
The existence of a circular list may affect to the printing.
You see, for instance, #0=#(struct:Card C 5) #1=(0 1 2 3 . #1#) (#0# #(struct:Card H 5)) and those are meaningless. The printing of struct is affected.

2. module seems to work incorrectly
According to module syntax, if we provided a cake.rkt file as shown bellow:

;;#lang racket

(module cake racket
  (provide print-cake)
  (define (print-cake n)
    (show "   ~a   " n #\.)
    (show " .-~a-. " n #\|)
    (show " | ~a | " n #\space)
    (show "---~a---" n #\-))
  (define (show fmt n ch)
    (printf fmt (make-string n ch))

it should be "required"; however, it does not work.


3. module having pictures gives an error.

I had made a binary-search tree like this:

#lang racket

(provide list->bst bst-search *av-list*)

(define (list->bst lst (cmp <) #:key (fn identity))
  (define (loop lst cmp fn)
    (if (null? lst)
        (let ((pivot (car (drop lst (quotient (length lst) 2)))))
          (let ((left (loop (filter (lambda (x)
                                      (cmp (fn x) (fn pivot)))
                                    lst) cmp fn))
                (right (loop (filter (lambda (x)
                                       (cmp (fn pivot) (fn x)))
                                     lst) cmp fn)))
            (cond ((list? pivot) `(,@pivot ,left ,right))
                  ((pair? pivot) (match-let (((cons k v) pivot))
                                   `(,k ,v ,left ,right)))
                  (else `(,pivot ,left ,right)))))))
  (loop (sort lst cmp #:key fn) cmp fn))

(define (bst-search v tree (cmp equal?) #:keyfn (kfn <) #:key (fn car))
  (match tree
    ('() #f)
    (`(,lvp ... ,left ,right)
     (cond ((cmp v (fn lvp)) lvp)
           ((kfn v (fn lvp)) (bst-search v left cmp #:keyfn kfn #:key fn))
           (else (bst-search v right cmp #:keyfn kfn #:key fn))))))

[ image removed by admin ]
[ image removed by admin ]

The pictures are embedded in the source file.
The problem is, if you want to "require" this, the error occurs.



  1. Are you familiar with how Racket prints circular lists? You can see an example at


Specifically, things like #0 are used to define "placeholders" to allow printed representations to refer to themselves.

  1. It looks to me like you're running the require in the interactions window. There are circumstances in which modules can be bound to quoted values like this, but they're uncommon. (Put differently: it doesn't appear to me that this is a bug?).

Here's some code that works; tell me what about this is different from what you want:

#lang racket

(module cake racket
  (provide print-cake)
  (define (print-cake n)
    (show "   ~a   " n #\.)
    (show " .-~a-. " n #\|)
    (show " | ~a | " n #\space)
    (show "---~a---" n #\-))
  (define (show fmt n ch)
    (printf fmt (make-string n ch))

(require 'cake)

(print-cake 34)
  1. haven't looked at #3

Hello. Mr. jbclements.

Are you familiar with how Racket prints circular lists? You can see an example at

Yes. I was familiar with that in ANSI Common Lisp.

The problem is not the expression like #0='(1 . #0#). The unrelated thing is influenced by circular-list expression. That is the problem.

Let me explain step by step.
The first situation is like this.


The World struct, or w consists of card, circular-list, discarded, dpair, id1, id2, and players. Well, anyway, the second slot has an circular-list.
And all the stuffs are displayed O.K.
But in the second turn,


Do you notice? The #0 stuff spreads over the other stuffs.
#0=#(struct:Card S J) does not mean anything, nor (#0# #(struct:Card C J)).
They are not circular lists, and I did of course not mean it.
#0=#(struct:Card S J) should be just (struct:Card S J) and (#0# #(struct:Card C J)) should be just #(struct:Card C J).
However, the game progresses with no problem; therefore, I doubted this is a sort of bug around displaying.

It looks to me like you're running the require in the interactions window.

Yes, it does, but that is not what I made. What I did was on the Racket Guide.
Thus, if what I wrote was not compatible to the present Racket, somebody should rewrite it.
I barely remember, anyway, this module style worked in PLT Scheme era. Probably.
So I think this happens quite recently. Perhaps with Chez Scheme? I do not know, though.

haven't looked at #3



On circular lists

What you're seeing is a combination of printing of sharing (eg #0#=(list 1 2)) and the display version of printing of structures that do not have a "read"-able form but are transparent

Consider this program:

#lang racket
(define z (shared ([x (list 1 2 3 x)]) x))
(struct p (v) #:transparent #:mutable)
(displayln z) ; prints #0='(1 2 3 #0#)
(displayln (p 1)) ; prints #(struct:p 1)
(displayln (p z)) ; prints #(struct:p #0=(1 2 3 #0#))
(displayln (shared ([x (list (p x))]) x)) ; prints #0=(#(struct:p #0#))

On modules and the REPL

I think you put the code in a file and then did something with it. That's not what the Guide is showing. Instead, it's demonstrating this interaction:

[samth@huor:~ plt] racket
Welcome to Racket v8.7.0.3 [cs].
> (module cake racket
    (provide print-cake)
    (define (print-cake n)
      (show "   ~a   " n #\.)
      (show " .-~a-. " n #\|)
      (show " | ~a | " n #\space)
      (show "---~a---" n #\-))
    (define (show fmt n ch)
      (printf fmt (make-string n ch))
> (require 'cake)
> (print-cake 1)
 |   | 

which works correctly as the Guide shows.

Compilation with images

The problem here is that you can't compile the file with the images in it to a zo file. (You can see the same error when running raco make on the file in question.) DrRacket is trying to automatically compile the file, which leads to that error. You can work around the problem by disabling "Populate compiled directories" in the "Language" dialog (go to the Language menu, select Choose Language, then click Show Details to see this option).


Hello, Mr. samth.

As you mentioned, the module with pictures works fine, when I disabled the "Populate compile the file".

[ image removed by admin ]


Thinking about this a bit more. I kind of like the fact that currently, the master branch has a single thread. I realize that merge commits that are made with merge -s ours don't represent "real" dependencies, but that's not obvious unless you dig into the commits and see that the merge has no diff. So I'm inclined to drop back to the "merge-with-the-release-branch-when-its-created" strategy. I'd really like to hear from others, though. @samth ? @mflatt ?

This should probably be a separate topic...

1 Like

Perhaps too late, but in the future please avoid making references to pornorgraphy.

I’d suggest that whatever this refers to should be fixed asap. Please let me know if I can help.

@cametan if the images in your file are pornographic or obvious references to pornography, I think it would probably be appropriate for you to delete the image or the post.

I've removed the images where I'm unsure of the content.


@zyga is working on a snap package for 8.7

I pointed him to https://github.com/racket/racket/releases/tag/v8.7

@zyga asked:

I could really use the same style of source tarball + prebuilt packages as for 8.6

Best regards



How the Racket Snap is built

Launchpad https://launchpad.net/~zyga/+snap/racket

The snap edge channel now contains a snapshot. I would like to build 8.7 but, at least during the 8.6 time-frame, I was advised to use the source tarball + pre-built packages which is not available for 8.7 (either yet or at all, I'm not sure).

I could transition to build the snap from source code entirely, for both the core and the packages around it, but that was a bit hard last time I looked, due to the way snapcraft build environment looks like. The GNOME extension which technically provides the runtime dependencies and build-time dependencies is in a non-default location, so some things related to (AFAIR, I would have to check), fonts was failing at build-time. Using pre-built packages papers-over this problem.

I've tried source build just now, with make unix-style, it failed in some graphical parts of the stack:

2022-11-14 15:31:34.599 :: 2022-11-14 14:28:12.218 :: examples: exception raised in example
2022-11-14 15:31:34.599 :: 2022-11-14 14:28:12.218 ::   error: "set-pen in dc<%>: bad argument combination: (object:color% ...) 44064.72 'solid"
2022-11-14 15:31:34.599 :: 2022-11-14 14:28:12.218 ::   context...:
2022-11-14 15:31:34.599 :: 2022-11-14 14:28:12.219 ::    /root/parts/racket/install/snap/racket/current/usr/share/racket/collects/racket/private/more-scheme.rkt:163:2: select-handler/no-breaks
2022-11-14 15:31:34.599 :: 2022-11-14 14:28:12.219 ::    /root/parts/racket/install/snap/racket/current/usr/share/racket/pkgs/scribble-lib/scribble/eval.rkt:356:9
2022-11-14 15:31:34.599 :: 2022-11-14 14:28:12.219 ::    .../private/map.rkt:40:19: loop
2022-11-14 15:31:34.599 :: 2022-11-14 14:28:12.219 ::    body of "/root/parts/racket/install/snap/racket/current/usr/share/racket/pkgs/redex-doc/redex/scribblings/tut.scrbl"
2022-11-14 15:31:34.599 :: 2022-11-14 14:28:12.219 ::
2022-11-14 15:31:34.599 :: 2022-11-14 14:28:12.219 ::   context...:
2022-11-14 15:31:34.599 :: 2022-11-14 14:28:12.219 ::    /root/parts/racket/install/snap/racket/current/usr/share/racket/collects/setup/parallel-do.rkt:333:4: work-done method in list-queue%
2022-11-14 15:31:34.600 :: 2022-11-14 14:28:12.219 ::    /root/parts/racket/install/snap/racket/current/usr/share/racket/collects/setup/parallel-do.rkt:283:17
2022-11-14 15:31:34.600 :: 2022-11-14 14:28:12.220 ::    /root/parts/racket/install/snap/racket/current/usr/share/racket/collects/setup/parallel-do.rkt:237:4
2022-11-14 15:31:34.600 :: 2022-11-14 14:28:12.220 ::    /root/parts/racket/install/snap/racket/current/usr/share/racket/pkgs/racket-index/setup/scribble.rkt:139:0: setup-scribblings
2022-11-14 15:31:34.600 :: 2022-11-14 14:28:12.220 ::    /root/parts/racket/install/snap/racket/current/usr/share/racket/collects/setup/setup.rkt:78:3
2022-11-14 15:31:34.600 :: 2022-11-14 14:28:12.220 ::    /root/parts/racket/install/snap/racket/current/usr/share/racket/collects/pkg/main.rkt:17:0: setup
2022-11-14 15:31:34.600 :: 2022-11-14 14:28:12.220 ::    body of (submod "/root/parts/racket/install/snap/racket/current/usr/share/racket/collects/pkg/main.rkt" main)
2022-11-14 15:31:34.600 :: 2022-11-14 14:28:12.220 ::    /root/parts/racket/install/snap/racket/current/usr/share/racket/collects/raco/raco.rkt:41:0
2022-11-14 15:31:34.600 :: 2022-11-14 14:28:12.220 ::    body of "/root/parts/racket/install/snap/racket/current/usr/share/racket/collects/raco/raco.rkt"
2022-11-14 15:31:34.600 :: 2022-11-14 14:28:12.220 ::    body of "/root/parts/racket/install/snap/racket/current/usr/share/racket/collects/raco/main.rkt"

There were several other errors that are similar. I can share the full log if someone has a clue as to what may be wrong.

For the record, on the mailing list, said references to pornography were unusable.
References to nonpornograhic images are likewise unusable.

To the extent that they are an important part of the message, they should probably be converted to proper https: links to the actual files in the discourse website,
I don't know how eager discourse would be to fix this.

-- hendrik

The 8.7 release is not out yet, which is why the source tarball is not yet available. We were waiting for the doc build to complete; it's now complete, and the release is moving forward, and should be released later today. At that point, the source tarballs should be available in exactly the same way for 8.7 as they are for 8.6. Let me know if that's not the case!

1 Like

Racket 8.7 is now being built to the candidate channel. Once the build is done I would appreciate if someone could:

snap refresh --candidate racket

and send an ack here that it's all good.

In case nothing is reported I will publish the build to stable later today.

EDIT: the build is now ready, in the candidate channel. I gave it a quick go on my headless system and it worked just fine.

1 Like

I've released racket 8.7 to the stable channel. Existing users will receive the update automatically, unless they have held the snap at the current version.

1 Like