please contact the developers
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Launchpad itself |
Fix Released
|
High
|
Gary Poster | ||
Storm |
Fix Released
|
High
|
Gustavo Niemeyer |
Bug Description
And so I am, so I am.
I'm in the middle of refactoring an lp bug search method from sqlobject to storm, and this is happening.
We get a resultset, call count() on it, change the backing data (using storm), then call count() again, and finally __getitem__.
To reproduce, my lp:~lifeles/launchpad/milestones branch will be of great assistance.
The blowing up outer layer looks like this:
>>> params = BugTaskSearchPa
>>> found_tasks = firefox_
>>> found_tasks.count()
0
When a nomination is approved, one task is created, targeted at
firefox_trunk.
>>> firefox_
>>> firefox_
True
>>> firefox_
False
>>> firefox_
False
>>> found_tasks.count()
1
>>> bugtask = found_tasks[0]
And the exception (I've added __str__ to have some hope of debugging this).
File "<doctest bug-nomination.
File "/home/
value = self.result_
File "/home/
obj = result_set._any()
File "/home/
return self._load_
File "/home/
return self._find_
File "/home/
File "/home/
values, keep_defined=True)
File "/home/
column, lazy_value, value))
RuntimeError: Unexpected situation. Please contact the developers. column <class 'lp.bugs.
(the exception source is now:
)
'calculate_
So this is *AFAICT* correctly setting the objects heat to the value we want to get from the DB.
OTOH perhaps the lazy value should never have been set. I've no idea where to go from here as I don't understand why the exception is being raised anyway : any help gratefully appreciated.
Related branches
- Gustavo Niemeyer: Disapprove
-
Diff: 12 lines (+1/-1)1 file modifiedstorm/store.py (+1/-1)
- Thomas Herve (community): Needs Information
- Jamu Kakar (community): Approve
-
Diff: 124 lines (+39/-16)4 files modifiedNEWS (+2/-0)
storm/store.py (+18/-14)
tests/store/base.py (+18/-0)
tests/zope/testing.py (+1/-2)
- Aaron Bentley (community): Approve
-
Diff: 15 lines (+1/-4)1 file modifiedversions.cfg (+1/-4)
Changed in storm: | |
assignee: | nobody → Gustavo Niemeyer (niemeyer) |
status: | New → In Progress |
importance: | Undecided → High |
milestone: | none → 0.18 |
Changed in storm: | |
status: | In Progress → Fix Committed |
Changed in launchpad-foundations: | |
status: | New → Triaged |
importance: | Undecided → High |
assignee: | nobody → Gary Poster (gary) |
Changed in storm: | |
status: | Fix Committed → Fix Released |
tags: |
added: qa-untestable removed: qa-needstesting |
Changed in launchpad-foundations: | |
status: | Fix Committed → Fix Released |
Fixed in stable r11792 <http:// bazaar. launchpad. net/~launchpad- pqm/launchpad/ stable/ revision/ 11792>.