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

nrepl-doc and nrepl-macroexpand-1 don't work with nrepl-ritz. #72

Open
cola-zero opened this issue Jan 23, 2013 · 3 comments
Open

nrepl-doc and nrepl-macroexpand-1 don't work with nrepl-ritz. #72

cola-zero opened this issue Jan 23, 2013 · 3 comments

Comments

@cola-zero
Copy link
Contributor

Hi!
I noticed that these commands are not working with lein nrepl-ritz, but work file with lein repl.
When I use nrepl-ritz-jack-in, nrepl-doc(C-cC-d) raise error in *nrepl-doc* buffer shown bellow.

ClassNotFoundException clojure.repl  java.net.URLClassLoader$1.run (URLClassLoader.java:366)

And nrepl-macroexpand-1 show nothing (nor any error buffer).

This is because clojure.repl and clojure.pprint are not required.
When I require these libraries, they work perfect.
I think ritz-nrepl should require these libraries by default.
Does anyone have same issue? Ando how do you think about that?

@hugoduncan
Copy link
Member

The ritz server can be used in a variety of situations, and it may not always be appropriate to require clojure.repl and clojure.pprint. I think the nrepl client (I'm assuming this is with nrepl.el) should be explicitly requiring these namespaces.

I also think we should have middleware for these operations.

@cola-zero
Copy link
Contributor Author

I understand that ritz not require them by default.

I also think we should have middleware for these operations.

I can't understand it, because I don't write and understand middleware yet.
The middleware will check namespaces in every eval operation?

@hugoduncan
Copy link
Member

Middleware works by having the client specifically invoke a middleware operation. So in this case, it would invoke a :macroexpand operation, and leave the implementation to the middleware.

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

No branches or pull requests

2 participants