Clojurians
#cider
<
2016-05-09
>

This page is not created by, affiliated with, or supported by Slack Technologies, Inc.

bvulpes00:05:11

> upgrading {emacs,cider}

bvulpes00:05:15

that's a demerit

bvulpes00:05:07

:stuck_out_tongue:

bozhidar05:05:34

CIDER is available on the two major package.el community maintained repos - MELPA Stable and MELPA.

bozhidar05:05:44

that’s the previous line in the manual

bozhidar05:05:48

before the installation command

surreal.analysis14:05:48

I made a thing to help me regularly learn new Cider commands - http://cider.surrealanalysis.com/ - changes every day

surreal.analysis14:05:34

Definitely needs some improvements, as some of the shortcuts are worthless without context (e.g. the fact that http://cider.surrealanalysis.com/#/11 only works in cider-debug) but hopefully will be useful to some as is

plexus14:05:35

@surreal.analysis: very cool! could be useful to also show the emacs command it runs

surreal.analysis14:05:04

Definitely. Longer term it needs to really have a datasource that I update, or is relatively consistent. Right now it just hits GitHub, looking for things like <kbd>..</kbd>… | …. which is the format the docs are written in.

surreal.analysis14:05:11

Incredibly hacky, but hey, it works :simple_smile:

turbopape14:05:12

That’s pretty cool @surreal.analysis

turbopape14:05:09

But I think some of the keys need context, like s to show stack traces in the stack trace pop up...

surreal.analysis14:05:35

Yeah, definitely. Longer term I think the main things that should be added are mode (e.g. cider-debug, or others), Emacs function (e.g. cider-jack-in for C-c M-j), links to readthedocs, and ideally source links. But to the best of my knowledge, there’s no way to generate that programmatically, so I started with something simple I could scrape. Within the next few weeks, I’ll try documenting all the cider functions in a csv or something. Anyone have suggestions for fields other than: keybinding, description, named command, mode, documentation source, and elisp source?

turbopape15:05:10

There was the keymaps table but I can’t find it...

turbopape15:05:37

You can use this to scrape until the upper level of the key map and spit this as its info

turbopape15:05:55

but once again, I can’t find it… I didn’t read the docs since a while :simple_smile:

nonrecursive15:05:21

hoping to get a little help - since upgrading to 0.12.0 I get this when I use cider-connect: CIDER's version (0.12.0) does not match cider-nrepl's version (nil). Things will break!

nonrecursive15:05:02

I’ve tried deleting my profile.boot and updating it to read

(require 'boot.repl)

(swap! boot.repl/*default-dependencies* conj
       '[cider/cider-nrepl "0.12.0"])

turbopape15:05:17

I think cider now injects all of this himself, maybe you shall try avoid any referring to nrepl or cider-nrepl

turbopape15:05:24

and you’ll get his sorted, I think...

nonrecursive15:05:21

i’ve tried to remove all the references to nrepl and cider-nrepl :sob:

nonrecursive15:05:57

i must be missing something but I have no idea what… thanks for confirming what the problem probably is though

plexus15:05:12

@surreal.analysis: you should be able to export all of that straight from emacs. That would also be a good opportunity to improve the docstrings of these functions. Happy to help with emacs-lisp!

surreal.analysis15:05:29

Thanks, I'll probably take you up on that

brian_mingus15:05:30

at the bottom left of the Cider documentation page there is a "Read the Docs" link and if you click it an option to download a PDF of the Cider documentation pops up http://cider.readthedocs.io/en/latest/

brian_mingus15:05:50

this PDF doesn't contain the documentation, but is instead basically empty

nonrecursive15:05:10

looks like the issue was that I was using cider-connect, which doesn’t do the auto injection

benedek15:05:38

you are right, it does not. as cider does not start up the repl it can’t really control the middlewares

malabarba16:05:29

@nonrecursive: Sorry for the confusion. In the current snapshots this warning will link you to a more informative page in the manual:

malabarba16:05:08

Which should help you reach that conclusion more easily. :simple_smile:

nonrecursive16:05:48

@malabarba: thanks! the docs were actually helpful and are what led me to find the solution :simple_smile: I just had to take take the time to read them carefully

malabarba16:05:22

Wonderful :simple_smile:

surreal.analysis16:05:53

@brian_mingus: That appears to be true of all the downloads (pdf, html, epub)

jcsims17:05:05

Does anyone else use refactor-nrepl when they start their own nrepl server? It seems to confuse cider, because I get the version mismatch warning, and cider-nrepl’s version is nil.

jcsims17:05:26

e.g. something like this:

(nrepl/start-server :port nrepl-port
                      :handler (refactor/wrap-refactor cider/cider-nrepl-handler))

jcsims17:05:17

everything seems to work as expected, I just get that warning on startup

brian_mingus17:05:21

@surreal.analysis: anyone in here we can ping?

brian_mingus17:05:42

would like a nice pdf to print

surreal.analysis17:05:28

Unfortunately, it’d require reworking the entire process

surreal.analysis17:05:53

Cider uses MkDocs not Sphinx, so it cannot generate PDFs

surreal.analysis17:05:10

Right now I think the solution (to the incorrect links, not your wanting a PDF) is to add a readthedocs.yml - https://read-the-docs.readthedocs.io/en/latest/yaml-config.html - and use none as in the first example for formats

bozhidar17:05:57

@surreal.analysis: yeah, when I adopted mkdocs I didn’t know how broken the support for it was

bozhidar17:05:13

ideally the docs should be reformatted using sphinx and rst

bozhidar17:05:19

but I don’t have time to deal with this

bozhidar17:05:26

with mkdocs even the search is broken

bozhidar17:05:46

obviously supporting it is not important for the team behind readthedocs

bozhidar17:05:25

@brian_mingus: someone should either fix readthedocs or rewrite the manual in rst :simple_smile:

surreal.analysis17:05:45

I think (but definitely do not know) that it’d be a minor transition of only some files. ReadTheDocs should support markdown and rst with Sphinx, based on this - http://docs.readthedocs.io/en/latest/getting_started.html. But it also seems like they might devalue some tech over others based on MkDocs vs Sphinx. If I get a chance, I’ll try to see if I can make a simple migration.

surreal.analysis17:05:14

Yeah, based on “How we build documentation” I don’t think my markdown comment was correct

bozhidar18:05:16

I think I read this

bozhidar18:05:29

and it seemed to me sphinx doesn’t support markdown good

bozhidar18:05:54

so the only way to properly handle this would be to convert everything

bozhidar18:05:01

which is probably a simple task

bozhidar18:05:10

and to extent can be done using a tool like pandoc

bozhidar18:05:19

but I have no time to work on something like this

roberto19:05:39

asciidoctor is also an option. They have a java library https://github.com/asciidoctor/asciidoctorj

brian_mingus20:05:32

any idea why I sometimes get stack traces that only show up in the Messages buffer and are hardly scrutable?

brian_mingus20:05:57

and other times, i get nicely formatted stack traces

malabarba20:05:12

@brian_mingus: That I know of, stacktraces only go to the *Messages* buffer on one condition: if they happen during REPL startup and kill the REPL.

malabarba20:05:41

If they happen in ClojureScript, they go to the REPL buffer.

malabarba21:05:04

If they happen somewhere entirely outside cider's control (like a background thread) they stay on the *nrepl-server ...* buffer.

malabarba21:05:20

@jcsims: I don't know if that's the right way to add refactor-nrepl to a server

malabarba21:05:49

Could you post the contents of the *nrepl-messages ...* buffer immediately after connecting?

brian_mingus22:05:18

what do you guys think of using core dumps to speed up popping a repl?

malabarba22:05:30

@jcsims: that's all? @bozhidar don't we log the first few messages exchanged with a repl?

malabarba22:05:18

@brian_mingus: I'd love to speed up the repl startup. But how does it work and what are the tradeoffs?

brian_mingus22:05:40

i'm not entirely sure, i just want to do it, and i had an idea about how

brian_mingus22:05:51

which is basically to create and then re-instantiate core dumps

jcsims22:05:53

@malabarba: yup, that’s all. Let me restart the app and get the very first connection to it - would that have any extra log messages?

brian_mingus22:05:21

i think we'll need some kind of dependency tracking system that detects when we need to create a new core dump

brian_mingus22:05:56

@malabarba: thoughts?

jcsims22:05:33

@malabarba: yeah, no change in a fresh start of the server

jcsims22:05:15

I’ll take a look later at the proper way to wrap with refactor - like I said, it seems to work fine right now, so I haven’t looked into the issue much at all yet

brian_mingus22:05:22

@malabarba: check out CRIU http://criu.org

brian_mingus22:05:45

it allows you to checkpoint and restore apps

bvulpes23:05:40

dear cider contributors

bvulpes23:05:50

i am blazing through fixing tests

bvulpes23:05:59

due approximately 100% to cider test mode

bvulpes23:05:08

y'all are great