Changes by Zorceta :
--
title: Customized attribute access causes infinite loop -> Unappropriate issue
___
Python tracker
<http://bugs.python.org/issu
Changes by Zorceta :
--
status: open -> closed
___
Python tracker
<http://bugs.python.org/issue24590>
___
___
Python-bugs-list mailing list
Unsubscrib
New submission from Zorceta:
Code and result:
```
>>> class A:
def __init__(self):
self.data = {'a': 1, 'b': 2, 'c': 3}
def __getattr__(self, name):
print('in __getattr__, getting %s
Zorceta added the comment:
FYI:
>>> ll = [[]]*10
>>> [id(l) for l in ll]
[67940296, 67940296, 67940296, 67940296, 67940296, 67940296, 67940296,
67940296, 67940296, 67940296]
------
nosy: +zorceta
___
Python tracker
<http://bugs.
Zorceta added the comment:
> When provided object is not from a file
should be
'When `inspect` can't find the source file of provided object'.
My mistake.
--
___
Python tracker
<http://bugs.
Changes by Zorceta :
--
components: +IDLE, Interpreter Core -Documentation
___
Python tracker
<http://bugs.python.org/issue12920>
___
___
Python-bugs-list mailin
Changes by Zorceta :
--
nosy: -docs@python
___
Python tracker
<http://bugs.python.org/issue12920>
___
___
Python-bugs-list mailing list
Unsubscribe:
Zorceta added the comment:
When provided object is not from a file, like input in interactive shell,
`inspect` internals will check for it in `linecache`, which official Python
shell and IDLE won't put interactive shell input into, yet. This can be simply
solved.
Whether interactive
New submission from Zorceta:
Both python.exe and IDLE can't. IPython is able to, as it inserts REPL input
into linecache.
--
messages: 245694
nosy: zorceta
priority: normal
severity: normal
status: open
title: inspect.getsource can't get source code if provided function isn