[racket] raco exe error help

From: Joe Gibbs Politz (joe at cs.brown.edu)
Date: Sun Sep 8 20:39:34 EDT 2013

I got the following error from raco exe, and could use some pointers
in turning it into something actionable.  I think I just don't have a
very good mental model of what raco exe is trying to do.  Here's the
output:

$ raco exe -o binary <path>/main.rkt

find-module: module referenced both as a library and through a path:
<path-to-repo>/lib/whalesong/whalesong/lang/js/js.rkt
  context...:
   /usr/lib/racket/collects/compiler/../racket/private/map.rkt:64:19: loop
   /usr/lib/racket/collects/compiler/embed-unit.rkt:342:4: get-code
   /usr/lib/racket/collects/compiler/../racket/private/map.rkt:64:19: loop
   /usr/lib/racket/collects/compiler/embed-unit.rkt:342:4: get-code
   /usr/lib/racket/collects/compiler/../racket/private/map.rkt:64:19: loop
   /usr/lib/racket/collects/compiler/embed-unit.rkt:342:4: get-code
   /usr/lib/racket/collects/compiler/../racket/private/map.rkt:64:19: loop
   /usr/lib/racket/collects/compiler/embed-unit.rkt:342:4: get-code
   /usr/lib/racket/collects/compiler/../racket/private/map.rkt:64:19: loop
   /usr/lib/racket/collects/compiler/embed-unit.rkt:342:4: get-code
   /usr/lib/racket/collects/compiler/embed-unit.rkt:938:4:
do-write-module-bundle
   /usr/lib/racket/collects/compiler/embed-unit.rkt:1414:51
   /usr/lib/racket/collects/compiler/private/elf.rkt:190:6: temp19
   /usr/lib/racket/collects/compiler/commands/exe.rkt: [running body]
   /usr/lib/racket/collects/raco/raco.rkt: [running body]
   /usr/lib/racket/collects/raco/main.rkt: [running body]


My best guess is that this is complaining because there are both

(require "<stuff>/whalesong/lang/js/js.rkt")

and

(require whalesong/lang/js/js)

and even

#lang s-exp whalesong/lang/js/js

in the codebase.  I'm using raco link to manage several collections,
including this one (whalesong), if that helps.  I didn't write all the
code that I'm dealing with, so I'm a tad hesitant to dive into
renaming things without knowing it's the right approach.

Is this assumption correct?  Will finding places where both of these
require styles appear and making them consistent (path vs library
name) help, or is that the wrong thing to do?

Is there any way to avoid doing that?

What's the underlying problem that this error is avoiding so I can
understand what to avoid in the future?

Thanks!
Joe

Posted on the users mailing list.