2

BTW, you will get a more complete backtrace if you load the source file instead of the byte-compiled file, for the code that defines run-python. (https://emacs.stackexchange.com/a/20265/12031)

How do I load the source file for debug purpose?

currently I have

Debugger entered--Lisp error: (wrong-type-argument arrayp nil)
  replace-regexp-in-string("\\`\\^" "" nil)
  python-shell-comint-end-of-output-p(">>> ")
  python-util-comint-end-of-output-p()
  python-eldoc--get-doc-at-point()
  python-eldoc-function(#f(compiled-function (string &rest plist) #<bytecode -0xec60eba7fe247cd>))
  #f(compiled-function (f) #<bytecode -0x191cde0269aa4cd>)(python-eldoc-function)
  eldoc--documentation-compose-1(nil)
  eldoc-documentation-compose()
  eldoc--invoke-strategy(nil)
  eldoc-print-current-symbol-info()
  #<subr F616e6f6e796d6f75732d6c616d626461_anonymous_lambda_11>()
  apply(#<subr F616e6f6e796d6f75732d6c616d626461_anonymous_lambda_11> nil)
  timer-event-handler([t 0 0 500000 nil #<subr F616e6f6e796d6f75732d6c616d626461_anonymous_lambda_11> nil idle 0 nil])
eugene
  • 481
  • 1
  • 5
  • 11

1 Answers1

1

Simply specify the .el suffix explicitly, using any of the load methods.

Interactively, that's one of:

  • M-x load-library RET python.el
  • M-x load-file RET /path/to/python.el

Or you can visit the .el file and use M-x eval-buffer

phils
  • 48,657
  • 3
  • 76
  • 115
  • `python.el` was a problem in the linked question, but in this question it looks as if `eldoc` stuff needs to be loaded: all of the byte-compiled gobbledegook seems to come from a timer that runs an anonymous function (sigh...) and functions called from `eldoc-documentation-compose-1` and `python-eldoc-function`. Loading `python.el` is not going to help in this case. – NickD Jul 29 '23 at 15:07