tab completion fails for a piggieback cljs repl #69

Closed
xeqi opened this Issue Aug 22, 2012 · 6 comments

Comments

Projects
None yet
5 participants
@xeqi
Contributor

xeqi commented Aug 22, 2012

When in a cljs repl using cemerick/piggieback tab completion always returns "No match".

Quoting @cemerick

it should either (a) use a different session for tooling stuff, or (b) stop using "eval" and work towards a common introspection middleware.

piggieback hijacks "eval" for cljs, so Clojure stuff sent on the same session that is running cljs/piggieback won't work

While (a) might be a good idea, I'm not sure it will let me tab complete clojurescript.

@cemerick

This comment has been minimized.

Show comment Hide comment
@cemerick

cemerick Aug 22, 2012

Contributor

This is veering off-topic just a bit, but to expand on why (b) would more easily allow tools to e.g. complete ClojureScript symbols:

Once an introspection middleware exists with a sufficiently-capable "vocabulary", that same vocabulary could be used by a ClojureScript (/ Piggieback?)-aware alternative that would simply query an active ClojureScript REPL environment in response to introspection requests, instead of querying e.g. Clojure namespaces and such. Thus, all the same UI actions would "just work" for completion, just as a Piggieback ClojureScript REPL is indistinguishable from a Clojure REPL from the perspective of an nREPL client/tool.

Contributor

cemerick commented Aug 22, 2012

This is veering off-topic just a bit, but to expand on why (b) would more easily allow tools to e.g. complete ClojureScript symbols:

Once an introspection middleware exists with a sufficiently-capable "vocabulary", that same vocabulary could be used by a ClojureScript (/ Piggieback?)-aware alternative that would simply query an active ClojureScript REPL environment in response to introspection requests, instead of querying e.g. Clojure namespaces and such. Thus, all the same UI actions would "just work" for completion, just as a Piggieback ClojureScript REPL is indistinguishable from a Clojure REPL from the perspective of an nREPL client/tool.

@johnbendi

This comment has been minimized.

Show comment Hide comment
@johnbendi

johnbendi Dec 8, 2013

What's the status of this issue. If directions are given I could help work on this. I would like to see cljs tab completions work.

What's the status of this issue. If directions are given I could help work on this. I would like to see cljs tab completions work.

@jackrusher

This comment has been minimized.

Show comment Hide comment
@jackrusher

jackrusher Dec 8, 2013

I'm also interested in this.

I'm also interested in this.

@cemerick

This comment has been minimized.

Show comment Hide comment
@cemerick

cemerick Dec 11, 2013

Contributor

The status is unchanged AFAIK. Ritz is the furthest along in defining and using structured messages for introspection/completion/etc (rather than bare eval, and read of the response values), though I'm not familiar with how well (if at all) it works with cider.

Contributor

cemerick commented Dec 11, 2013

The status is unchanged AFAIK. Ritz is the furthest along in defining and using structured messages for introspection/completion/etc (rather than bare eval, and read of the response values), though I'm not familiar with how well (if at all) it works with cider.

@bbatsov

This comment has been minimized.

Show comment Hide comment
@bbatsov

bbatsov Dec 11, 2013

Member

Totally meant to respond to this 3 days ago, but alas - I forgot. The status is the following:

  • cider's default completion is based on evaluation forms from the clojure-complete library, which is Clojure-only...
  • If you're using an nREPL middleware providing a complete op - cider will use it instead
  • Ritz's completion middleware is Clojure-only (as it uses clojure-complete internally)

Obviously the best solution would be to create a middleware that's will work with both Clojure & ClojureScript. I'm planning to implement at some point standard cider middleware for Clojure, but as I'm yet to try ClojureScript I don't pay that much attention to it.

Member

bbatsov commented Dec 11, 2013

Totally meant to respond to this 3 days ago, but alas - I forgot. The status is the following:

  • cider's default completion is based on evaluation forms from the clojure-complete library, which is Clojure-only...
  • If you're using an nREPL middleware providing a complete op - cider will use it instead
  • Ritz's completion middleware is Clojure-only (as it uses clojure-complete internally)

Obviously the best solution would be to create a middleware that's will work with both Clojure & ClojureScript. I'm planning to implement at some point standard cider middleware for Clojure, but as I'm yet to try ClojureScript I don't pay that much attention to it.

@bbatsov

This comment has been minimized.

Show comment Hide comment
@bbatsov

bbatsov Jan 26, 2014

Member

Finally solved in #461

Member

bbatsov commented Jan 26, 2014

Finally solved in #461

@bbatsov bbatsov closed this Jan 26, 2014

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment