mirror of
https://github.com/xonsh/xonsh.git
synced 2025-03-04 16:34:47 +01:00
Add __dir__
to DynamicAccessProxy
This restores tab-completion to objects proxied through DynamicAccessProxy
This commit is contained in:
parent
a7c48deacc
commit
19856ee258
2 changed files with 27 additions and 0 deletions
24
news/fix_DAP_completion.rst
Normal file
24
news/fix_DAP_completion.rst
Normal file
|
@ -0,0 +1,24 @@
|
|||
**Added:**
|
||||
|
||||
* <news item>
|
||||
|
||||
**Changed:**
|
||||
|
||||
* <news item>
|
||||
|
||||
**Deprecated:**
|
||||
|
||||
* <news item>
|
||||
|
||||
**Removed:**
|
||||
|
||||
* <news item>
|
||||
|
||||
**Fixed:**
|
||||
|
||||
* Added proxied ``__dir__`` method to ``DynamicAccessProxy`` to restore
|
||||
tab-completion for objects that use the proxy (especially ``events``)
|
||||
|
||||
**Security:**
|
||||
|
||||
* <news item>
|
|
@ -1489,6 +1489,9 @@ class DynamicAccessProxy:
|
|||
def __call__(self, *args, **kwargs):
|
||||
return self.obj.__call__(*args, **kwargs)
|
||||
|
||||
def __dir__(self):
|
||||
return self.obj.__dir__()
|
||||
|
||||
|
||||
class DeprecationWarningProxy:
|
||||
"""Proxies access, but warns in the process."""
|
||||
|
|
Loading…
Add table
Reference in a new issue