spacemacs

Spacemacs docs: http://develop.spacemacs.org/doc/DOCUMENTATION.html http://develop.spacemacs.org/layers/+lang/clojure/README.html https://practicalli.github.io/spacemacs/
jumar 2020-07-02T06:15:18.006700Z

Sharing here - maybe someone has a good tip how to make this faster: https://clojurians.slack.com/archives/C0617A8PQ/p1593590912213400

jumar 2020-07-02T06:15:40.006900Z

jumar  [3:05 PM] My problem is that Emacs/Cider is just really slow in this case - in terminal it’s fine but Emacs will freeze for up to a minute while waiting for the output to be written to the repl buffer; the process that generates this output only takes several seconds

practicalli-john 2020-07-02T06:24:19.007100Z

If the log messages have long lines (which is common) then Emacs is going to be slow. Disabling font locking (if enabled) may make it not quite so slow, e.g by putting a buffer into fundamental-mode. Although I doubt much difference will be noticed. My only advice is to log to a rotating file or send logs as objects directly to a proper logging tool like Elastic search/Kibana. If that's not possible, avoid using the REPL buffer directly.

jumar 2020-07-02T06:30:41.007400Z

The log messages are NOT usually very long but there are quite a few of them (TRACE logging) and I have font locking disabled. I tried to set the REPL buffer mode to fundamental-mode but it just broke. In general, I should probably write to a separate log file but it's just much more convenient (and the default production setup anyway) to log to STDOUT; also in this case I was debugging an issue which only happened with TRACE logging enabled and written to stdout. What do you mean "avoid using the REPL buffer directly"?

jumar 2020-07-02T06:32:44.007700Z

(Btw. another time when it gets noticably slower is when a larger data structure (such as ring request) is printed into the REPL - and it can be quite convenient to be able to copy this structure and use it for experiments; although I understand that in many cases I can just use def or perhaps dump it to an edn file too)

practicalli-john 2020-07-02T06:35:33.007900Z

From a quick internet search, I found this minor mode that may be worth a try (I haven't tried it). If it works it would be better than switch ING to fundamental-mode https://github.com/rakete/too-long-lines-mode

jumar 2020-07-02T06:49:41.008200Z

Thanks I'll have a look at it.

dev4openid 2020-07-02T09:10:20.009100Z

When I open spacemacs I receive this message: Skipping check for new version (reason: dotfile) custom-initialize-reset: Creating directory: Permission denied, /path

dev4openid 2020-07-02T09:11:14.009600Z

How can I diagnose this?

practicalli-john 2020-07-02T09:14:05.012800Z

I suggest looking at the docs for that function, SPC h d f custom-initialize-reset to see what it does. If it's from a Spacemacs layer, then check if the documentation mentions it

practicalli-john 2020-07-02T09:15:33.015300Z

I think Spacemacs only creates files / directories in elpa (for packages) .cache and private (both under .emacs.d). I assume you have checked read write permission on .emacs.d directory.

practicalli-john 2020-07-02T09:16:35.016700Z

Most likely it's some package that is trying to write somewhere. The docs should say which file it's in.

dev4openid 2020-07-02T09:16:56.016900Z

the help does not list SPC h d f custom-initialize-reset

practicalli-john 2020-07-02T09:19:04.019700Z

SPC / with a file open from inside .emacs.d ?? If nothing found, did you add something to .spacemacs

dev4openid 2020-07-02T09:19:20.020500Z

I looked at .emacs.d I have group permissions under my name XXX as R&W however the access is granted none. If I grant access R&W it must be recursive?

dev4openid 2020-07-02T09:23:07.023300Z

Well I changed permissions and now the SPC h d f custom-initialize-reset provides data

dev4openid 2020-07-02T09:27:10.025100Z

From the help, the custome.el. link led to custom.el.gz file

(defun custom-initialize-reset (symbol exp)
  "Initialize SYMBOL based on EXP.
Set the symbol, using its `:set' function (or `set-default' if it has none).
The value is either the symbol's current value
 (as obtained using the `:get' function), if any,
or the value in the symbol's `saved-value' property if any,
or (last of all) the value of EXP."
  (funcall (or (get symbol 'custom-set) #'set-default-toplevel-value)
           symbol
           (condition-case nil
               (let ((def (default-toplevel-value symbol))
                     (getter (get symbol 'custom-get)))
                 (if getter (funcall getter symbol) def))
             (error

dev4openid 2020-07-02T09:27:53.026100Z

Now I do not have custome-init...... in my .spacemacs file

practicalli-john 2020-07-02T09:28:03.026200Z

No need to paste in the function source, it looks like a function that comes with Emacs.

dev4openid 2020-07-02T09:28:54.027500Z

Yes, but it has no reference in .spacemacs and this messgae is persistent

practicalli-john 2020-07-02T09:28:55.027600Z

It seems its just a permissions issue with your .emacs.d directory, make sure you can read/write and create files and dirs recursively

practicalli-john 2020-07-02T09:29:33.028200Z

Oh, so you rebooted after updating the .emacs.d file permissions? If so, you have really broken something badly

dev4openid 2020-07-02T09:30:04.028500Z

Bi I did not reboot

dev4openid 2020-07-02T09:30:26.028900Z

I have permissions to create files etc in .emacs.d

dev4openid 2020-07-02T09:31:42.029900Z

emacs generally works fine however I have this darn message

dev4openid 2020-07-02T09:36:28.032Z

I updated the emacs version and updated all packages - seems fine but same error message

practicalli-john 2020-07-02T09:40:10.035100Z

Unless you know what you changed before getting this message, I would wipe .emacs.d and .spacemacs and start again. I cant help if I dont know what has been changed. Alterntatively, raise an issue on Spacemacs github repository with SPC h I , that will provide info about your system and layers used.

dev4openid 2020-07-02T09:40:27.035200Z

I can add/create recursively files in emacs.d I have/can update packages without problems. I have updated with git pull --rebase the emacs I can emacs edit files and run cider BUT I cant resolve this message for some reason. I am not sure as to how it is even referred to

dev4openid 2020-07-02T09:41:08.035500Z

OK start again 😰

dev4openid 2020-07-02T09:44:57.035700Z

thx @jr0cket

practicalli-john 2020-07-02T10:00:10.038400Z

As the error message is from a built in Emacs function, then it seems likely that something is calling that function incorrectly. As the error message doesnt show where that call is from or give any clues as to the path its trying to write, then isolating the issue is going to be tricky.