Uploaded image for project: 'tools.namespace'
  1. TNS-50

`require :reload` fails where `load-file` succeeds

    Details

    • Type: Bug
    • Status: Open
    • Priority: Minor
    • Resolution: Unresolved
    • Labels:
      None
    • Environment:
      • Version 0.2.11
      • Mac OS 10.13., Java 8., Clojure 1.8.0

      Description

      Here are steps to reproduce at the REPL:

      • `(c.t.n.r/refresh)` succeeds
      • Modify any file in the classpath
      • `(c.t.n.r/refresh)` fails from not having found certain namespace(s) (not always the same one(s))

      This always happens with a particular project, but no (known) others of relatively similar complexity. AOT compilation/execution works with the project in question, as do `require`s without using `(c.t.n.r/refresh)`. For `(c.t.n.r/refresh)`, `load-file` works in place of `require :reload` in `clojure.tools.namespace.reload/track-reload-one`. It is not known what the root cause of this bug is beyond `require :reload`, or why `load-file` works instead, but it's a simple enough patch with no known downsides. For now I'm hot-swapping code every time at the REPL.

      A fork is available at https://github.com/alexandergunnarson/tools.namespace from which I can submit a patch if desired.

        Attachments

          Activity

            People

            • Assignee:
              stuart.sierra Stuart Sierra
              Reporter:
              alex+import import
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated: