gotcha/ipdb — Issue #18: NameError when using a generator
Author: dandavison
Created: 2012-03-07 21:43:24+00:00
State: open

After calling ```ipdb.set_trace()```

```python
ipdb> y = 4
ipdb> x = list(y for i in [1])
*** NameError: global name 'y' is not defined
```
This code works as expected in pdb in a regular python shell.

Bug shows in released versions ipython version 0.12 and ipdb 0.6.1 and also latest git HEAD for both projects:

ipdb 4ff7999d8c159 2012-02-28
ipython 96d5447cf90f 2012-03-06