[issue24590] Customized attribute access causes infinite loop

2015-07-08 Thread Zorceta
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' % name) if name in self.data

[issue24589] Wrong behavior for list of lists

2015-07-08 Thread Zorceta
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 rep...@bugs.python.org http

[issue24590] Unappropriate issue

2015-07-08 Thread Zorceta
Changes by Zorceta zorc...@gmail.com: -- title: Customized attribute access causes infinite loop - Unappropriate issue ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue24590

[issue24590] Customized attribute access causes infinite loop

2015-07-08 Thread Zorceta
Changes by Zorceta zorc...@gmail.com: -- status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue24590 ___ ___ Python-bugs-list

[issue12920] inspect.getsource only works for objects loaded from files, not interactive session

2015-06-24 Thread Zorceta
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 rep...@bugs.python.org http://bugs.python.org/issue12920

[issue24491] inspect.getsource can't get source code if provided function isn't from a file

2015-06-23 Thread Zorceta
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't from

[issue12920] inspect.getsource only works for objects loaded from files, not interactive session

2015-06-23 Thread Zorceta
Changes by Zorceta zorc...@gmail.com: -- nosy: -docs@python ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12920 ___ ___ Python-bugs-list mailing

[issue12920] inspect.getsource only works for objects loaded from files, not interactive session

2015-06-23 Thread Zorceta
Changes by Zorceta zorc...@gmail.com: -- components: +IDLE, Interpreter Core -Documentation ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12920

[issue12920] inspect.getsource only works for objects loaded from files, not interactive session

2015-06-23 Thread Zorceta
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 shell