-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
I dont know if this is a bug... or I am doing something wrong or something.
One of my utils classes looks somewhat like this:
class UserUtils:
store = None
def __init__(self):
if UserUtils.store == None:
print "Store == None"
UserUtils.store = MySQLObjectStore(user='USER', passwd='PASS')
UserUtils.store.readModelFileNamed('path_to_file')
And then I have been referencing the store like this:
UserUtils.store.somemethod()
Except... I think for some reason I think I get a new instance of store each
time I reference to it.
Looking at the output from WebKit, it only shows the object store being
created once (Which is good). (The print line print "Store == None" only
happens once)
However... It seems that unless the server is restarted, none of my changes to
the database seem to have any effect. Even when UserUtils.store.saveChanges()
is called.
Also... I eventually get an error telling me I have run out of db connections.
Which leads me to believe that somehow, I am getting a copy of the ObjectStore
instead of the original object.
Any ideas?
- --
Luke Holden
eBI Solutions
Main: (949) 387-5182
Email: [EMAIL PROTECTED]
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.1 (GNU/Linux)
iD8DBQE+J48Y3q5xXfLZTQkRAr6WAJsG+/N6hwTVWcVViNok7+/pc8/ATQCgwE9U
zDuabw9S4co959RfFESXnxQ=
=EiPB
-----END PGP SIGNATURE-----
-------------------------------------------------------
This SF.NET email is sponsored by: Thawte.com
Understand how to protect your customers personal information by implementing
SSL on your Apache Web Server. Click here to get our FREE Thawte Apache
Guide: http://ads.sourceforge.net/cgi-bin/redirect.pl?thaw0029en
_______________________________________________
Webware-devel mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/webware-devel