Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

cider-expected-ns returns nil on boot projects #1651

Closed
Malabarba opened this issue Apr 3, 2016 · 3 comments
Closed

cider-expected-ns returns nil on boot projects #1651

Malabarba opened this issue Apr 3, 2016 · 3 comments
Labels

Comments

@Malabarba
Copy link
Member

This happens because the list of strings returned by (cider-sync-request:classpath) apparently doesn't include the project directory.
This, in turn, happens because boot masks the project under: `~/.boot/cache/tmp/FULL/PATH/ followed by some gibberish.

As a (hopefully) temporary patch, I'll make this function fallback on clojure-expected-ns.

@bbatsov
Copy link
Member

bbatsov commented Apr 4, 2016

This bites us every time. I'm guessing we can reuse some of boot-related code for the info middleware.

@grzm
Copy link
Contributor

grzm commented Nov 15, 2017

Digging into this a bit, it looks like the issue is related to the values returned by cider-sync-request:classpath. Boot added a :fake-class-path key to the boot environment (also available via the "fake.class.path" system property) to address issues like the one here. Some of this was addressed in clojure-emacs/cider-nrepl@fbcecba to access resource paths. Does it make sense for cider-sync-request:classpath to return :fake-class-path when running under boot? From what I can see, the only usage of this is in cider-expected-ns.

@grzm
Copy link
Contributor

grzm commented Nov 16, 2017

I've put together a POC here: grzm/cider-nrepl@4fe4a70. If this looks good, I'll submit a PR to cider-nrepl. (Should we continue this discussion under a ticket for cider-nrepl?)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants