-
-
Notifications
You must be signed in to change notification settings - Fork 96
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
Namespace migration #4
Comments
Let me know what you think, @technomancy, @bbatsov, @trptcolin, @cursive-ide? |
I think that option 1 should be fine as long as the wire protocol hasn't changed. That means that the client and server can be upgraded independently, and I don't really see much benefit to keeping them around if the new namespaces are equivalent and it's just a matter of renaming them. It's been a while, but I don't think there's anything like namespaced keywords or anything else where the nREPL namespaces would leak into the protocol, right? |
Agreed on option 1. At first I was thinking the only issues I’d foresee w/ option 1 would be if anybody’s got themselves into a non-repeatable situation w/ version ranges or something like that? But this would be a brand new group/artifact pair anyway, so I don’t see any risk of breakage. And even if it wasn’t, there’s less risk than elsewhere because nrepl is pretty high-level and we’re unlikely to see many transitive dependencies around it. @cemerick did you have thoughts on arguments in favor of option 2? I guess maybe it saves coordination work for cases like nrepl middleware where you have several libs that need to all depend on the same ns[es]? |
@cursive-ide No, there's no namespaced keywords in use that I'm aware of. @trptcolin My sole motivation re: option (2) is to make the transition as painless as possible. A quick |
@cemerick: well, middleware users are the real interesting piece, i’d think, since they’ll now have to ensure compatibility among N middlewares. Unfortunately i’m not a middleware user so I can’t give much of an informed opinion here. |
Users only ever need to e.g. drop a middleware's var name into their project.clj; it's the authors that might be using org.clojure.*-namespaced vars in their middleware descriptors. Or am I missing something? |
I’m sure @bbatsov has a clearer picture, but i’m talking about dependency versions: if as an end user I have in my profiles.clj (or wherever) e.g. :plugins [[refactor-nrepl "2.3.1"]
[cider/cider-nrepl "0.14.0"]] Then I need to ensure those all line up and are compatible w/ my nrepl variant, including any bumps to lein/boot version. |
That's what I'd advise to do. For me updating our namespaces is going to be trivial. I think the middleware surrounding CIDER + piggieback is probably the bulk of the 3rd party middleware out there and as we have complete control over them the actual migration can happen very fast. |
Well, I guess we have consensus, then. The plan then: The next release ( Thanks for the feedback 😄 |
All of this makes perfect sense to me! 👍 |
As a consequence of #1, it seems necessary to eventually move nREPL out of the
clojure.tools.nrepl.*
namespaces associated with Clojure Contrib. After all, tools.nrepl may yet be maintained separately from this effort, and no one benefits from same-named namespaces floating around in multiple artifacts.I see two options:
cemerick.nrepl.*
namespaces, and stop distributingclojure.tools.nrepl.*
-namespaced code from here ASAP.cemerick.nrepl.*
namespaces, replacing theclojure.tools.nrepl.*
namespaces with stubs that useimmigrate
or similar to ensure API compatibility for downstream tools and libraries. This arrangement can persist for some period of time, eventually moving those stubs into a separate "nrepl-compat" library, that can be added in downstream as needed to provide thoseclojure.tools.nrepl.*
namespaces.Thoughts?
The text was updated successfully, but these errors were encountered: