[Zope] AArgh. Zope-2_2-branch and head of CVS breaks SQLMethods.

Anthony Baxter Anthony Baxter <anthony@interlink.com.au>
Thu, 10 Aug 2000 22:40:05 +0000


This is a multipart MIME message.

--==_Exmh_-3698980880
Content-Type: text/plain; charset=us-ascii


Aha! Nailed it. It's the 1.131 version of OFS/Application.py

cvs log entry:
----------------------------
revision 1.131
date: 2000/08/02 17:31:54;  author: brian;  state: Exp;  lines: +71 -46
branches:  1.131.4;
Merged fix for products with old-style initialization not being properly
filtered by permission in the filtered add list.
----------------------------

Ok, the problem is that when it sees an initialize() method, it
stops looking for other stuff. ZSQLMethods has a __methods__ 
thing, tho. Oops. Patch appended to make it always look for
__methods__.

Note that it doesn't break ZSQLMethods from working, just from being added
or edited.

Argh. This would've been much easier to figure out if I hadn't managed 
to confuse myself (tooo many installations of zope, all slightly different -
need to make it better :)

Anthony

>>> Anthony Baxter wrote
> 
> The current Zope-2_2-branch and head of CVS is busted - you cannot add or
> edit SQLMethods. It appears that Products.ZSQLMethods.__init__.__methods__ 
> doesn't get into the namespace of the product properly, as neither
> the add or edit screens can see SQLConnectionIDs.
> 
> Blah. More to come - I'll try to figure out why it's broken, and when.
> 
> Anthony



--==_Exmh_-3698980880
Content-Type: application/x-patch ; name="app.patch"
Content-Description: app.patch
Content-Transfer-Encoding: base64
Content-Disposition: attachment; filename="app.patch"

SW5kZXg6IEFwcGxpY2F0aW9uLnB5Cj09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09
PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT0KUkNTIGZpbGU6IC9jdnNyb290
L1pvcGUvbGliL3B5dGhvbi9PRlMvQXBwbGljYXRpb24ucHksdgpyZXRyaWV2aW5nIHJldmlz
aW9uIDEuMS4xLjMKZGlmZiAtdSAtcjEuMS4xLjMgQXBwbGljYXRpb24ucHkKLS0tIEFwcGxp
Y2F0aW9uLnB5CTIwMDAvMDgvMDcgMDQ6MjI6MjkJMS4xLjEuMworKysgQXBwbGljYXRpb24u
cHkJMjAwMC8wOC8xMCAxMjo0MToxNQpAQCAtNTA3LDIwICs1MDcsNiBAQAogICAgICAgICAg
ICAgICAgICAgICAgICAgbWV0YV90eXBlWydwcm9kdWN0J109cHJvZHVjdE9iamVjdC5pZAog
ICAgICAgICAgICAgICAgICAgICAgICAgbWV0YV90eXBlcy5hcHBlbmQobWV0YV90eXBlKQog
Ci0gICAgICAgICAgICAgICAgICAgIGZvciBuYW1lLG1ldGhvZCBpbiBwZ2V0YXR0cigKLSAg
ICAgICAgICAgICAgICAgICAgICAgIHByb2R1Y3QsICdtZXRob2RzJywge30pLml0ZW1zKCk6
Ci0gICAgICAgICAgICAgICAgICAgICAgICBpZiBub3QgaGFzYXR0cihGb2xkZXIsIG5hbWUp
OgotICAgICAgICAgICAgICAgICAgICAgICAgICAgIHNldGF0dHIoRm9sZGVyLCBuYW1lLCBt
ZXRob2QpCi0gICAgICAgICAgICAgICAgICAgICAgICAgICAgaWYgbmFtZVstOTpdIT0nX19y
b2xlc19fJzogIyBub3QgSnVzdCBzZXR0aW5nIHJvbGVzCi0gICAgICAgICAgICAgICAgICAg
ICAgICAgICAgICAgIGlmIChwZXJtaXNzaW9ucy5oYXNfa2V5KG5hbWUpIGFuZAotICAgICAg
ICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgbm90IGZvbGRlcl9wZXJtaXNzaW9ucy5o
YXNfa2V5KAotICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHBlcm1p
c3Npb25zW25hbWVdKSk6Ci0gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBw
ZXJtaXNzaW9uPXBlcm1pc3Npb25zW25hbWVdCi0gICAgICAgICAgICAgICAgICAgICAgICAg
ICAgICAgICAgICBpZiBuZXdfcGVybWlzc2lvbnMuaGFzX2tleShwZXJtaXNzaW9uKToKLSAg
ICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBuZXdfcGVybWlzc2lvbnNb
cGVybWlzc2lvbl0uYXBwZW5kKG5hbWUpCi0gICAgICAgICAgICAgICAgICAgICAgICAgICAg
ICAgICAgICBlbHNlOgotICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAg
IG5ld19wZXJtaXNzaW9uc1twZXJtaXNzaW9uXT1bbmFtZV0KLQogICAgICAgICAgICAgICAg
ICAgICBpZiBuZXdfcGVybWlzc2lvbnM6CiAgICAgICAgICAgICAgICAgICAgICAgICBuZXdf
cGVybWlzc2lvbnM9bmV3X3Blcm1pc3Npb25zLml0ZW1zKCkKICAgICAgICAgICAgICAgICAg
ICAgICAgIGZvciBwZXJtaXNzaW9uLCBuYW1lcyBpbiBuZXdfcGVybWlzc2lvbnM6CkBAIC01
MjgsNiArNTE0LDE5IEBACiAgICAgICAgICAgICAgICAgICAgICAgICBuZXdfcGVybWlzc2lv
bnMuc29ydCgpCiAgICAgICAgICAgICAgICAgICAgICAgICBGb2xkZXIuX19kaWN0X19bJ19f
YWNfcGVybWlzc2lvbnNfXyddPXR1cGxlKAogICAgICAgICAgICAgICAgICAgICAgICAgICAg
IGxpc3QoRm9sZGVyLl9fYWNfcGVybWlzc2lvbnNfXykrbmV3X3Blcm1pc3Npb25zKQorCisg
ICAgICAgICAgICAgICAgZm9yIG5hbWUsbWV0aG9kIGluIHBnZXRhdHRyKHByb2R1Y3QsICdt
ZXRob2RzJywge30pLml0ZW1zKCk6CisgICAgICAgICAgICAgICAgICAgIGlmIG5vdCBoYXNh
dHRyKEZvbGRlciwgbmFtZSk6CisgICAgICAgICAgICAgICAgICAgICAgICBzZXRhdHRyKEZv
bGRlciwgbmFtZSwgbWV0aG9kKQorICAgICAgICAgICAgICAgICAgICAgICAgaWYgbmFtZVst
OTpdIT0nX19yb2xlc19fJzogIyBub3QgSnVzdCBzZXR0aW5nIHJvbGVzCisgICAgICAgICAg
ICAgICAgICAgICAgICAgICAgaWYgKHBlcm1pc3Npb25zLmhhc19rZXkobmFtZSkgYW5kCisg
ICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIG5vdCBmb2xkZXJfcGVybWlzc2lvbnMu
aGFzX2tleSgKKyAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHBlcm1pc3Np
b25zW25hbWVdKSk6CisgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHBlcm1pc3Np
b249cGVybWlzc2lvbnNbbmFtZV0KKyAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAg
aWYgbmV3X3Blcm1pc3Npb25zLmhhc19rZXkocGVybWlzc2lvbik6CisgICAgICAgICAgICAg
ICAgICAgICAgICAgICAgICAgICAgICBuZXdfcGVybWlzc2lvbnNbcGVybWlzc2lvbl0uYXBw
ZW5kKG5hbWUpCisgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGVsc2U6CisgICAg
ICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBuZXdfcGVybWlzc2lvbnNbcGVybWlz
c2lvbl09W25hbWVdCiAKICAgICAgICAgICAgICAgICBpZiBvcy5lbnZpcm9uLmdldCgnWkVP
X0NMSUVOVCcsJycpOgogICAgICAgICAgICAgICAgICAgICAjIHdlIGRvbid0IHdhbnQgdG8g
aW5zdGFsbCBwcm9kdWN0cyBmcm9tIGNsaWVudHMhCg==

--==_Exmh_-3698980880--