shu--hung
2021-1-28 18:09:25

Anyone getting DB tests failure? Run racket\raco.exe test -l tests/db/all-tests raco test: "C:\\Users\\runneradmin\\AppData\\Roaming\\Racket\\8.0.0.3\\pkgs\\db-test\\tests\\db\\all-tests.rkt" raco test: @(test-responsible '(ryanc)) ERROR: Connection failed! Check DSN for test: name="sqlite3, memory, with #:use-place=os-thread", sys='sqlite3, flags='(issl async). use-os-thread: not supported context...: D:\a\racket\racket\racket\collects\db\private\sqlite3\connection.rkt:504:4: use-os-thread method in connection% C:\Users\runneradmin\AppData\Roaming\Racket\8.0.0.3\pkgs\db-lib\db\private\sqlite3\place.rkt:10:0: sqlite3-connect C:\Users\runneradmin\AppData\Roaming\Racket\8.0.0.3\pkgs\db-test\tests\db\config.rkt:138:4 .../racket/unit.rkt:996:20 .../racket/unit.rkt:1707:32 "C:\Users\runneradmin\AppData\Roaming\Racket\8.0.0.3\pkgs\db-test\tests\db\all-tests.rkt": [running body] C:\Users\runneradmin\AppData\Roaming\Racket\8.0.0.3\pkgs\compiler-lib\compiler\commands\test.rkt:180:16 all-tests.rkt: raco test: test raised an exception Error: Process completed with exit code 1.


shu--hung
2021-1-28 18:29:12

I opened an issue.


ben.knoble
2021-1-28 21:33:36

Is ,require-reloadable working for folks? MRE: #lang racket (provide foo) (define foo 1) with ,r: > ,r some.rkt > foo 1 with ,rr: > ,rr some.rkt > foo ; foo: undefined; ; cannot reference an identifier before its definition ; in module: top-level ; [,bt for context]


gregor.kiczales
2021-1-28 22:35:59

For autograding I’d like to be able to take some beginning/intermediate student defines and an expression, and perform one evaluation step on the expression. Is there a simple way to do that buried in the stepper?


soegaard2
2021-1-28 22:36:30

@jbclements ^


jbclements
2021-1-28 23:11:31

Part of this is already implemented, at



jbclements
2021-1-28 23:12:15

The vital missing piece is the calls to reconstruct the source terms from the sequence of break-infos.


jbclements
2021-1-28 23:12:58

This is definitely possible, probably 10–20 hours of work, and possibly useful to others. Is this something that might be useful to you for a long time to come, or something that’s just a one-off?


jbclements
2021-1-28 23:13:54

Also, please please tag me @jbclements on any reply, because I absolutely don’t check slack without a direct ping (thanks, @soegaard2) !


gregor.kiczales
2021-1-29 00:05:54

@jbclements Now that we’ve been driven to fully online exams, we’re looking at ways of automating things we used to do by hand. When we hand graded stepping we dinged one mark for a bad step, but then the TAs looked at what the next step was from there and so on. There was a general sense it was more fair that way, because otherwise one mis-step at the beginning and it’s game over. So we are trying to recreate that in full autograding. TLDR — I believe we would continue to use it for a while, yes.


notjack
2021-1-29 00:41:40

Style question: if you saw #lang racket/base code that used (map (lambda (v) …) …), would you rewrite it to (for/list ([v (in-list …)]) …)?


capfredf
2021-1-29 00:46:40

I would not rewrite only because of style preference, but I would do it if there was a bug in the code.


sorawee
2021-1-29 01:19:03

@notjack: here’s something that I think should be rewritten: define-struct -> struct.

They are not quite the same though. One generates make-x and the other generates x, but generally struct is preferable


notjack
2021-1-29 01:19:18

I’ve got that one :p


sorawee
2021-1-29 01:19:26

nice :slightly_smiling_face:


samdphillips
2021-1-29 01:43:20

I would only rewrite if it was a “big” map


samdphillips
2021-1-29 01:43:37

Rather if the lambda was big


samdphillips
2021-1-29 01:44:36

Like I probably wouldn’t rewrite: (map list a* b* c*)


notjack
2021-1-29 02:02:14

If the mapper function isn’t a literal lambda I definitely wouldn’t do it


greg
2021-1-29 03:04:04

I’d be more inclined to rewrite (slightly) more complicated things like (filter (map (lambda ___) ___)).

I’d be more interested in changing that to for/list, than in changing to using something like filter-map (or defining something like filter-map if it didn’t already exist). I’d feel like, well, for/list is general, whereas filter-map is bespoke (albeit a pretty common use case).

So the benefit feels bigger — but the risk is higher, too. Which I think is similar to what @capfredf said. If I started mucking around, while not already fixing a bug, I’d worry I’m probably creating a new bug and slap my hand. :slightly_smiling_face:


greg
2021-1-29 03:04:38

If a snazzy refactoring tool could promise to make a change safely, I might push the button. :eyes:


notjack
2021-1-29 03:24:32

I think limiting for-ification to cases where there’s more than just one list operation makes a lot of sense


notjack
2021-1-29 03:25:23

maybe including stuff like this: (map f (vector->list vec))


notjack
2021-1-29 06:18:12

What’s a good way to figure out where all the comments are in a #lang racket/base file?