Fork me on GitHub
#cider
<
2018-05-06
>
bozhidar05:05:11

@gonewest818 Quick question - how can we generate the API docs for orchard 0.1? I noticed the CI config has hardcoded master and I’m not quite certain how to use codox manually.

gonewest81818:05:55

Let me go back and refresh my memory. I’m using another oss project to provide simpler automation for codox. Initially that wrapper script didn’t handle multiple versions, but I contributed a patch and got it accepted. In theory, with the right version of that script you can enable other branches in CI and they’ll publish to distinct subdirectories of “gh-pages”.

dominicm07:05:10

just looking over my changes, cleaning up some derelict code.

dominicm07:05:07

I suspect my next refactor for 0.18 is going to end up being a graphql-like interface for vars 😂 We expose vars differently all over the codebase. Everything should really go centrally through info or metadata, and then have the requested attributes sent back.

dominicm07:05:01

It would be useful to have apropos send back line numbers & columns in some cases, to prevent round trips. For tests I have some code which sends an info for every failed test, so I can build up a vim quickfix buffer, which requires the filename/line/column ahead of time.

dominicm07:05:34

tbh, that turned out not to be so slow. But it feels like we should either agree that round-trips are fine, and send back a reference that works with info in all places OR give the option to grab any of the attributes from info in results.

bozhidar08:05:41

I’ve commented a bit on your PR. > I suspect my next refactor for 0.18 is going to end up being a graphql-like interface for vars 😂 We expose vars differently all over the codebase. Everything should really go centrally through info or metadata, and then have the requested attributes sent back. Yeah, that’d be nice. > It would be useful to have apropos send back line numbers & columns in some cases, to prevent round trips. For tests I have some code which sends an info for every failed test, so I can build up a vim quickfix buffer, which requires the filename/line/column ahead of time. Perhaps. Roundtrips may or may not be a problem depending on how many of those you need. 🙂

bozhidar08:05:13

> tbh, that turned out not to be so slow. But it feels like we should either agree that round-trips are fine, and send back a reference that works with info in all places OR give the option to grab any of the attributes from info in results.

bozhidar08:05:21

Yeah, we should decide upon this for sure. I don’t have a strong preference here, but I like the second option a bit more.

dominicm08:05:01

Yeah, this definitely needs some checking to see if round-trips are bad or fine. I have used cider over a tenuous double-ssh'd proxy over GSM to another country, so I definitely have sympathy for reducing round trips, and general network chatter.

dominicm08:05:22

I'll go over the PR comments soon, just writing backwards compatibility code for cider's apropos, it's rather easy.

dominicm08:05:01

You've caught me doing bad docs again 😉 I'll get the hang of this one day.

bozhidar08:05:28

I didn’t become so picky about them in a day. You should the code I was writing 15 years ago. 😄 And you won’t see any docs there. 😄 😄 😄

dominicm08:05:08

Our project deadlines don't leave much time for documentation, nor do they tend to have much long-term maintenance to warrant it. Docstrings aren't on any mental checklists for me, I actually comb my code before any PR, but docs never get noticed.

dominicm08:05:18

Something quite interesting about these changes it that it would allow retest to be managed by the client.

dominicm09:05:14

I'm going to leave the namespace middleware alone for this version, as it touches on clojurescript, which Orchard hasn't made a decision on yet. I would hope that the fact my query is data-based means that it's a piece of cake to port it to cljs.

dominicm09:05:02

I was hoping to use that as direct access to running these queries in order to do a test listing buffer which allowed you to run groups of tests together...

dominicm09:05:03

That can wait until the next set of snapshots though, I've got some additional functionality to build clients for already.

bozhidar10:05:46

> I’m going to leave the namespace middleware alone for this version, as it touches on clojurescript, which Orchard hasn’t made a decision on yet.

bozhidar10:05:15

Can’t you just update this in cljs-tooling? Despite the name of the project it’s actually a pure Clojure project that simply inspect the cljs compiler state.

bozhidar10:05:02

The only reason why I haven’t merged this into orchard yet is that it would add a hard dependency to ClojureScript for orchard, which might be a bit excessive.

dominicm10:05:34

I think I would be replicating the new list functions in cljs-tooling, is that right? I might be wrong.

bozhidar10:05:01

Yeah, that’s pretty much what you’d have to do.

dominicm10:05:34

I can look into that, I will make that a second pass for later, either this weekend or next. I'm starting to run a little short on time, the weather is nice for once in the UK. I do really want this to work for the namespace explorer, as I'm a user of clojurescript, and I have some really neat ideas about things I'd like to try in replant.

bozhidar10:05:51

Sure, no rush.

dominicm10:05:07

The rush is the imminent 0.17 release, if any 😛

bozhidar10:05:38

Well, there will be other releases, right? 😉

dominicm10:05:02

Exactly 😛

bozhidar10:05:52

I kept pushing this back, because I wanted to add more and more, but eventually I realized how flawed this thinking is. Probably the next 2-3 releases would be much smaller, and ideally just 1-2 months apart.

dominicm10:05:07

Makes sense. I think it's easy to fall into the trap of wanting every release to be fireworks, but incremental releases are great too.

dominicm10:05:32

Right, so tests all passing on orchard. Only one last thing, the hardest thing in computer science: naming it!

bozhidar10:05:59

Yeah, that’s true. I’ve been wondering of list-* should be query/find-* or something like this. Generally I don’t expect for list to do any filtering.

dominicm10:05:31

I've been thinking the same tbh. Or "search" too.

bozhidar11:05:11

Yeah, that’s an option as well.

dominicm11:05:47

It could be that the namespace is named find or query only something like that.

bozhidar11:05:04

Yep. Or you can use a nice alias (query/vars ...).

bozhidar11:05:44

I’m writing too much Elisp and I keep forgetting other languages don’t have to prefix everything. 😄

dominicm11:05:37

query is sounding good. orchard.query and vars feels like a winner, I'm going for namespaces over nss though.

dominicm11:05:10

That's renamed.

dominicm11:05:51

@bozhidar how do I manage the required dependency bump between cider-nrepl & orchard, in terms of making the PR?

bozhidar11:05:15

Commits to orchard automatically trigger clojar deployments (on successful builds at least). This means you can just add 0.2-SNAPSHOT as a dependency and things should be OK.

bozhidar14:05:04

@dominicm Btw, maybe you can submit your document for the cider-nrepl API to cider-nrepl and we can maintain it there. Thinking about how to best communicate example usages and deprecations I was reminded of it.

dominicm14:05:32

I might put it in the wiki for now, having more open push access is useful until it's up to date

bozhidar15:05:15

Or I can give you push access to the repo. 😉

dominicm18:05:25

Or that 😛

dominicm18:05:04

toggle-trace-var might be an interesting one to add var-query to. Trace everything private in ns.x.

dominicm18:05:56

Trace everything that matches .*!$ in the current namespace (everything that affects state)

dominicm18:05:05

Serious power-user tool potentially

dominicm18:05:24

@bozhidar what is undef used for?

bozhidar20:05:21

“undef”ing a single var. Useful when you don’t want the big guns like refresh.

bozhidar20:05:51

I’ve rarely used it myself, it was contributed 4 years ago by @hugod.

dominicm20:05:47

I see. As simple as that. I've not found myself wanting it, so I haven't added it.

bozhidar20:05:36

I’ve mostly used it when I saw some annoying “dead” candidate appear in completions or whatever.

bozhidar20:05:22

E.g. when I renamed something after I had already evaluated it.

bhauman21:05:05

@bozhidar can we cut another release of cider/piggieback?