xonsh/news
Angus Hollands 5091c8368e
Refactor: make session loading explicit (#4540)
* Refactor: Don't modify XSH in Execer

This is not an invariant change - the __del__ method of the execer now does not unload the session. This is probably what we want - the session should be the final arbiter of when it goes out of scope, and we might need an explicit mechanism to handle this.

* Refactor: make import hook Execer explicit

This is ugly for now, but helps raise the global state modifications to the surface

* Style: run black

* Refactor: add `update_cache` to `CommandsCache`

Previously a lot of internal usage of `all_commands` was for the updating side-effect. Now we make that a separate routine.

* Refactor: remove args from XonshSession constructor

* Refactor: move non stateful XonshSession methods to __init__

* Refactor: don't create custom class for namespace

* Refactor: auto-generate set of default builtins

* Refactor: set session attributes to None in constructor

* Refactor: don't test hasattr for known attribute

* Refactor: add methods to restore and disable Python exit

* Refactor: add initial value for XSH.aliases

* Refactor: don't default getattr for known attribute

* Refactor: make _lastflush a closer and move to `load()`

* Fix: catch $path even if empty.

This shouldn't ever actually manifest itself, but whilst we're here!

* Refactor: support existing usage of install_import_hooks

* Style: run black

* Refactor: remove unneeded import

* Docs: add news item

* Fix: news item

* Refactor: remove unused arg

* docs: fix news item

* fix: no duplicate calls

add helpers properties to completion-context

* refactor: importing a module should not affect the session

the user has to have XSH loaded before

* fix: todo item for testing imphooks

Co-authored-by: Noortheen Raja <jnoortheen@gmail.com>
2021-12-21 13:07:53 +05:30
..
alises-completer.rst Ap/aliases completer (#4486) 2021-11-23 12:34:12 -05:00
ap-long-opts.rst feat: option to show only longest/descriptive arg-completions (#4483) 2021-11-29 10:56:20 -05:00
cmd-completion-desc.rst feat: update command completions to show description as well (#4488) 2021-12-07 10:33:41 -05:00
completer-cmd.rst feat: add sub-command to print current completions (#4586) 2021-12-12 08:47:47 +05:30
fish-completer.rst add fish shell based completer (#4569) 2021-11-29 21:02:32 +05:30
fix-conda-env-system.rst Fix: support Conda environments when running on non-conda interpreter (#4532) 2021-12-10 10:18:16 +05:30
fix-windows-oserror.rst Fix OSError on Windows with GnuWin32 (#4599) 2021-12-16 16:09:52 -05:00
fix-xonshrc-dir-welcome.rst Fix: don't display welcome if $XONSHRC_DIR member is found (#4531) 2021-11-18 12:42:29 -05:00
foreign-funcs-completions.rst feat: auto-completion support for source-foreign (#4564) 2021-11-27 16:28:04 +05:30
history-transfer.rst history transfer (#4604) 2021-12-20 08:36:29 +05:30
nep-0029.rst adopt NEP-0029 (#4568) 2021-11-29 12:48:48 -05:00
refactor-session-loading.rst Refactor: make session loading explicit (#4540) 2021-12-21 13:07:53 +05:30
remove-ptk2.rst refactor: remove xonsh.ptk2 module (#4570) 2021-11-30 08:22:31 -05:00
simplify-foreign-functions.rst Simplify foreign functions (#4393) 2021-11-23 17:01:42 -05:00
sublime-xonsh.rst Add Sublime Text 4 extension to the Editors page (#4552) 2021-11-23 04:06:48 +05:30
TEMPLATE.rst single instance of string.Formatter 2018-10-20 12:22:59 -06:00
vox-improvements.rst Vox improvements (#4549) 2021-11-26 23:37:35 +05:30
xontrib-default-command.rst New xontribs (#4544) 2021-11-23 04:09:21 +05:30
xontrib-up.rst New xontribs (#4544) 2021-11-23 04:09:21 +05:30