[ZCM] [ZC] 2212/ 4 Resolve "KeyError in Module Shared.DC.ZRDB.DA, line 375, in _cached_result"

"Collector: Zope Bugs, Features, and Patches ..." <[email protected]>
Newsgroups gmane.comp.web.zope.devel.collector-monitor
Message-ID <[email protected]>
Issue #2212 Update (Resolve) "KeyError in Module Shared.DC.ZRDB.DA, line 375, in _cached_result"
 Status Resolved, Zope/bug+solution critical
To followup, visit:
  http://www.zope.org/Collectors/Zope/2212

==============================================================
= Resolve - Entry #4 by chrisw on Nov 17, 2006 1:33 pm

 Status: Pending => Resolved

This is now fixed on the 2.9 branch, 2.10 branch and trunk.

It should make the 2.9.6 and 2.10.1 releases.

If you have any further problems, please let me know.
________________________________________
= Edit - Entry #3 by chrisw on Nov 17, 2006 11:00 am

 Changes: submitter email, edited transcript, importance (medium => critical), new comment

I've just checked in a test case which reproduces this (see the assertRaises(KeyError,... in Shared/DC/ZRDB/tests/test_caching.py) and am about to start trying to "fix" this code :-S
________________________________________
= Comment - Entry #2 by chrisw on Oct 11, 2006 4:51 am

This message:

http://mail.zope.org/pipermail/zope-db/2006-September/004684.html

...and the thread that hangs off it contains more about this issue.

It's not isolated but does affect Zope instances under high load.

It's tempting to raise this issue to "critical" but I'm not sure what that would achieve :-/
________________________________________
= Request - Entry #1 by Dirk.Datzert on Oct 10, 2006 11:59 am


Uploaded:  "Zope-2.8.6-cached-result.patch"
 - http://www.zope.org/Collectors/Zope/2212/Zope-2.8.6-cached-result.patch/view
Hi,

I work with cached results in ZSQL-Methods and got a KeyError for _cached_result:

  Module Shared.DC.Scripts.Bindings, line 311, in __call__
  Module Shared.DC.Scripts.Bindings, line 348, in _bindAndExec
  Module Products.PythonScripts.PythonScript, line 325, in _exec
  Module None, line 38, in draw_line
   - <PythonScript at /webgraf/Typ2/draw_line>
   - Line 38
  Module Shared.DC.ZRDB.DA, line 453, in __call__
   - <SQL at /webgraf/sql_get_data used for /webgraf/Typ2>
  Module Shared.DC.ZRDB.DA, line 375, in _cached_result
  KeyError: ("select * from DBA.DATA\nwhere ID='KCB00XXX'\n
    and AUSBLENDEN=false\norder by X_SORT", 1000, '\nDBConnId: None')

I did found the real bug, but have a workaround attached.

Regards,
Dirk
==============================================================
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.