I can not close window completely created by racket on macOS 13 beta

My racket version is 8.5.


For example, when I opened the about window, I can't close it neither by clicking the red button nor by press C-w. other windows have the same problem.

GUI - problem with delete-child - #5 by alexh related?

2 Likes

Anyone else running macOS 13 beta? I'd love to hear about failures to reproduce this as well as successes....

1 Like

On macOS 13 beta, nothing is closeable unless quitting drracket entirely.

video with minimum code: Imgur: The magic of the Internet

#lang racket/gui

(define main-frame
  (new frame%
       [label "OK"]))
       
(send main-frame show #t)

However, if I run the same code in terminal by racket file.rkt, the window is closable. It might be a drracket specific issue.

edit: It's also reproducible on snapshot 8.6.0.2--2022-07-23(cbd42bf/a) [cs] downloaded from utah.

3 Likes

Yep, that's pretty much completely broken. Sigh.

1 Like

@ixnij and @slbtty: Thanks for the report!

The candidate for the upcoming v8.6 release now includes a repair for this problem:

https://pre-release.racket-lang.org/

Can you check whether it works correctly on your machine?

2 Likes

Ok! I'm downloading the dmg. By the way, I'm in China mainland, there is no official racket mirror. It's quite slow for me to download racket packages.

Great! The windows are closable. But there is another problem: I can't launch DrRacket by click the icon in the launchpad, but I can launch it by ./DrRacket directly in terminal

I'm not sure I know what you mean when you refer to clicking the icon "in the launchpad".

Here's a set of sort of ridiculously fine-grained steps, I'm curious to know what happens when you do this:

  • Go to the Finder
  • Open a new window using cmd-N
  • Click "Applications" on the left side in the Favorites list
  • Scroll down to Racket v8.5.900
  • Double-click the Racket v8.5.900 folder
  • Double-click the DrRacket icon

@jbclements The launchpad is this thing:

Yes, I mean that @jbclements: I also followed the steps you said, DrRacket can't be opened either.

The fix works for me.

I have no problem using the launchpad.

I tried restarting my computer, but can't solve the problem.

I assume that DrRacket is installed at /Applications/Racket v8.x. What will happen when you run open /Applications/Racket v8.x? Does it produce any error?

open Racket\ v8.5.900
Finder was launched with the directory of Racket v8.5.900

I also tried open Racket\ v8.5.900/DrRacket.app/, nothing happened.

There are situations wherein macOS decides that because of how an application was installed, that it should not be allowed to refer to paths relative to the application's installation.

In some versions, I believe that the solution in these situations (this sounds bizarre, I know) is to drag the DrRacket application icon out of the folder that it's in, and then drag it back in again. I believe this is the same issue mentioned in the GitHub issue below, and that thread suggests running

xattr -r -d Racket\ v8.5.900/DrRacket.app

You may want to take a look at other parts of that thread, though, to do some diagnostics and figure out what's going on before fixing it...

it didn't help, and the command below has some problems either.

1 Like

I think the command is

sudo xattr -r -d com.apple.quarantine <Racket directory>

see Configure Command Line for Racket · racket/racket Wiki · GitHub

3 Likes

I like the text in the wiki, but it's not clear how the OP here would have known that this was a signing problem...

I will link the wiki to the github issue, though!

Good. It helps for me.