: `read' access denied for

Hi! Newish to Racket and I hope this is appropriate. I am going thought the material in Berkeley's CS61A and I am running into the following error when I run their autograder locally as in
racket -tm grader.rkt -- hw1-tests.rkt hw1.rkt

An error occurred:
file-or-directory-modify-seconds: `read' access denied for /Users/bernardino/Library/Preferences/org.racket-lang.prefs.rktd

I looked around and did find some Github issue but it wasn't helpful. I could just extract all their tests but I would like to understand what's off.

Any pointers?
Thank you

1 Like

I'm not sure how or why this happened, but I would check the permissions on ~/Library/Preferences/org.racket-lang.prefs.rktd and try to adjust them with chmod.

If that doesn't work, maybe removing that file will cause it to be re-created? Or re-installing Racket?

If Ben's advice doesn't work, we'll need to know your OS and how you installed Racket.

I'm not sure if this is relevant, but are you trying to run the grader while DrRacket is open?

Thanks everyone for the support and apologies for the late feedback... I tried changing permissions and even running as sudo. Nothing. Then deleted the incriminated file and finally reinstalled everything. Still getting that error.
@soegaard I'm running MacOS Ventura13.0 on an Apple M1 Silicon MacBook Air. Racket was installed with the provided installer from the racket-lang site for the Silicon architecture ....

At this stage I am just being stubborn I guess, it's not a huge deal.

In that case I suspect the fault is in the grader.

Is it this one?

Homework 0.1 - CS 61AS Textbook

If so, just run the test manually:


E.g. for this test:

    (check-equal? (sum-of-squares 3 4) 25)
    (check-equal? (sum-of-squares -1 -2) 5)
    (check-equal? (sum-of-squares 1 2) 5))

try the expressions (sum-of-squares 3 4), (sum-of-squares -1 -2) etc in the repl
and see if you get the right result.

A possibility, related to @soegaard 's diagnosis,a is that the solution you're trying to run through the autograder is using a library that the homework's authors did not intend (e.g., the framework) and that library is, behind the scenes, trying to use the preferences file.

The grader is here:


And the evaluator has this:

#:allow-for-require (list '(planet dyoo/simply-scheme)

So it looks like, the grader want's you to use simply-scheme?

1 Like

@soegaard (and everyone) thanks

it looks like, the grader want's you to use simply-scheme?

How do I do that?

Yes, I am already running the tests manually (as I mentioned in the first post) but like I said I'd be interested in just solving what's wrong for the sake of it

Looking more closely at the Berkeley page, I see there is a template for the first homework.

It just starts with #lang racket so I don't think they are using Simply Scheme at all.
So I think it is safe to forget about Simply Scheme.


Yeah I was wondering about that ....
This is what I found but let's say it's not exactly clear to me...

Does your code use the 2htdp/image library?

Also, reading over that issue, it looks like you might simply need to add (require racket/gui/base) to the grading script (outside the sandbox, so not in your sample solution).

1 Like