The internal python shell now takes into account more shell settings
in order to generate the unique hash for its name.
Also `python-shell-setup-codes' has been simplified and is not allowed
to be a list of cons anymore.
pdbtrack now handles correctly the case where the stacktrace
information is on the second line.
All python buffers not opened by the user and used for tracking are
closed automatically when tracking process finishes.
Simplified code for keeping the tracked buffer.
Removed vars:
+ python-pdbtrack-tracking-buffers
Removed functions:
+ python-pdbtrack-get-or-add-tracking-buffers
New vars:
+ python-pdbtrack-tracked-buffer
+ python-pdbtrack-buffers-to-kill
New functions:
+ python-pdbtrack-set-tracked-buffer
pdbtracking now autodetects the filename being tracked from the prompt
and not from the `inferior-python-mode-current-file' variable.
Removed vars:
+ `inferior-python-mode-current-file'
Available when using ipython v0.11. Completions on lines starting with
"from " or "import " are supplied by
IPython.core.completerlib.module_completion
ipython v0.11 configuration:
(setq python-shell-interpreter "ipython"
python-shell-completion-setup-code
"from IPython.core.completerlib import module_completion\n"
python-shell-module-completion-string-code
"';'.join(module_completion('''%s'''))\n"
python-shell-completion-string-code
"';'.join(get_ipython().Completer.all_completions('''%s'''))\n")
This avoids a "No completions for ..." message being issued when a
completion has been made. Also, reduces redundancy between the
inferior-python-mode and python-mode completion code.
The new `python-nav-jump-to-defun' function allows a user to jump fast
and easy to a function or class definition in the current buffer. For
this a entry in the menu and the C-c C-j keybinding have been
introduced.
New functions:
+ `python-nav-list-defun-positions'
+ `python-nav-read-defun'
+ `python-nav-jump-to-defun'
The new function `python-nav-list-defun-positions' does the same as a
relevant part of the `python-imenu-create-index' so the latter has
been refactored to use it.
python-shell-make-comint now passes all parent buffer variables to the
comint buffer created ensuring local variables work as intended. Also,
this function now receives a third optional argument called POP that
establishes if the created comint buffer should be displayed or not
after its creation.
when set to a string, makes the values stored in
`python-shell-process-environment' and `python-shell-exec-path' to be
modified properly so shells are started with the specified virtualenv.
New Variables:
* python-shell-virtualenv-path
New functions:
* python-shell-calculate-process-environment
* python-shell-calculate-exec-path
This new kind of shell is intended to be used for generic
communication related to defined configurations. The main difference
with global or dedicated shells is that these ones are attached to a
configuration, not a buffer. This means that can be used for example
to retrieve the sys.path and other stuff, without messing with user
shells.
New Variables:
* python-shell-internal-buffer-name,
New functions:
* python-shell-internal-get-process-name
* run-python-internal
* python-shell-internal-get-or-create-process
* python-shell-internal-send-string (makes python-send-receive obsolete)
* python-eldoc-setup-code: The code to get help now uses the
inspect element. When an object doesn't have documentation and
if it is callable it returns the signature for it. Also when
an object does contain documentation it only returns the first
line.
* python-eldoc-at-point: has been simplified to just message the
doc header of objects.
* python-info-current-defun: was not taking into account the
current indentation so point was always inside a defun, even
if the indentation was less or equal than the defun above.
Doing (setq python-indent-levels '(0)) was causing the value of
python-indent-levels to not be initialized correctly on next calls to
python-indent-calculate-indentation. Using (setq python-indent-levels
(list 0)) instead does the trick but I'm not sure why.
For this, four new variables which contain the symbol name of the
function that specifies the behavior of fill-paragraph on certain
conditions were added:
* python-fill-comment-function: For comments
* python-fill-string-function: For strings
* python-fill-decorator-function: For decorators
* python-fill-paren-function: For parens
All of these variables are safe local variables in the case the value
provided is a symbol. Out of the box, they default to these four new
functions respectively:
* python-fill-comment
* python-fill-string
* python-fill-decorator
* python-fill-paren