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

Show explicit error messages when invoking commands with no ClojureScript support #1432

Closed
bbatsov opened this issue Nov 22, 2015 · 9 comments
Assignees
Milestone

Comments

@bbatsov
Copy link
Member

bbatsov commented Nov 22, 2015

People are often wondering if some command is supposed to work with ClojureScript or not. In the interest of better UX we should raise proper errors when commands that don't work with ClojureScript are invoked in a ClojureScript connection.

Does anyone happen to have a list of those commands?

@Malabarba
Copy link
Member

we should raise proper errors

Make that user-errors. :-)

@bbatsov
Copy link
Member Author

bbatsov commented Nov 26, 2015

Sure. :-) Does anyone have a list of the commands that don't work on ClojureScript?

@expez
Copy link
Member

expez commented Nov 26, 2015

C-c C-. aka cider-find-ns doesn't work with cljs atm. An issue is open in our middleware repo to remedy that situation.

I don't think any of the tracing stuff works either.

Does the cider-test-* stuff work with cljs?

@bbatsov
Copy link
Member Author

bbatsov commented Nov 29, 2015

Does the cider-test-* stuff work with cljs?

No, although there's a port of clojure.test for cljs, so I guess this is doable.

According to the caveats sections the following don't work:

  • Grimoire lookup (don't remember why)
  • Reloading
  • Running tests
  • Tracing
  • Debugging

@bbatsov bbatsov modified the milestone: v0.11 Dec 11, 2015
@bbatsov
Copy link
Member Author

bbatsov commented Dec 14, 2015

@cichli should we add something more to the list?

We should probably create individual tickets to implement the missing cljs functionality and start tackling the simplest tasks first.

@Malabarba Malabarba self-assigned this Dec 14, 2015
@Malabarba
Copy link
Member

By the way, mind if I take this on? I have some thoughts on how to integrate this with the dynamic dispatch.

@bbatsov
Copy link
Member Author

bbatsov commented Dec 14, 2015

Sure. Go ahead.

@cichli
Copy link
Member

cichli commented Dec 14, 2015

Nothing springs to mind that's missing from your list.

  • Grimoire lookup should be trivial to do (I think all the code for that is in the client currently, and the client's CLJS-aware now).
  • Reloading - not sure if we should raise an error or not here; I often use cider-refresh even while in a CLJS REPL to reload the underlying CLJ codebase. There do of course already exist great tools like Figwheel for doing live reloading of CLJS code.
  • I have some (hacky) ideas for how to support running tests but haven't done any experiments yet.
  • Tracing is semi-difficult but probably not too bad. I haven't looked too deeply at the tools.trace implementation but I don't think there are any blockers preventing it from being ported to CLJS.
  • Debugging - I'm not too familiar with how the current debugger works but this strikes me as being kind of difficult. @Malabarba happy to assist with any questions you have here; maybe the direction we end up taking with cider-test support will give us a better idea of how to do this. There do exist good tools (source maps + Chrome debugger) for doing this already but the experience is nowhere near that of the CIDER debugger.

@Malabarba
Copy link
Member

happy to assist with any questions you have here;

Helping out with #1416 would be a very good start. :-)

Malabarba added a commit that referenced this issue Jan 16, 2016
Also mark cider-refresh as Clojure-only, but allow it to be invoked from
ClojureScript buffers.
bbatsov pushed a commit that referenced this issue Jan 19, 2016
Also mark cider-refresh as Clojure-only, but allow it to be invoked from
ClojureScript buffers.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants