Re: [Zope] Can't reproduce :-(

2001-01-26 Thread Dieter Maurer

Ian Sealy writes:
 > I've finally managed to replicate the bug consistently, so I've just
 > submitted it to the Collector:
 > 
 >  http://classic.zope.org:8080/Collector/1895/view
Very good!

In fact, this problem was known but not recognized in the new
context!

The incompatibility between "subtransaction" and "Z SQL methods"
is a well known problem documented with ZCatalog.

Apparently, someone at DC decided that subtransaction are
good, too, to upload images. Maybe, this was not so good an
idea. While for ZCatalog, subtransactions can be disabled,
this apparently is not the case for image uploads.



Dieter

___
Zope maillist  -  [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope-dev )




Re: [Zope] Can't reproduce :-(

2001-01-26 Thread Oliver Bleutgen

Ian Sealy wrote:

> I've finally managed to replicate the bug consistently, so I've just
> submitted it to the Collector:

>   http://classic.zope.org:8080/Collector/1895/view

> I now know what causes it so I'm able to work around it, which means
> that I'm afraid the offer of 400 quid to fix the bug is now
> withdrawn. Sorry.

> The bug only occurs if the DTML Method that adds the large file tries to
> call a Z SQL Method that uses the ZPyGreSQLDA. Here's the description I
> just submitted to the Collector:

Yeah great, 
I'm bitten again. We had the same (upload) problem here and I didn't have
time to think about it, but thanks to your debugging I know now for sure that
I have quite a problem.


Michel Pelletier and Chris McDonough explained it a bit in 
answers to this message:
http://zope.nipltd.com/public/lists/zope-archive.nsf/ByKey/7C20E9F401FF8087


Chris even had a workaround:
---

A solution is to add the following methods to the database
adapter's DB class inside DB.py:

def commit_sub(self, *arg, **kw):
   pass

def abort_sub(self, *arg, **kw):
   pass

---

The above is also used in the alpha version of DC's newest oracle adapter DCOracle2,

As we use Loginmanager with postgres, I have know idea how to not invoke
Z SQL methods when upload. 
Has anybody an idea if and under what circumstances the above snipped could do harm?


cheers,
oliver

___
Zope maillist  -  [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope-dev )




Re: [Zope] Can't reproduce :-(

2001-01-26 Thread Ian Sealy

Dear all,

> > > > We need to get this fixed ASAP so my boss has told me to send this
> > > > message to the list and offer 400 pounds (sterling) to anyone who can
> > > > fix this bug. Any takers?
> > >
> > > What version of Zope are you using?
> > 
> > 2.2.5 on Red Hat 6.2.
>   > 
> > Zope version: Zope 2.2.5 (source release, python 1.5.2, linux2)
> > Python version: 1.5.2 (#1, Nov 18 2000, 20:03:24) [GCC egcs-2.91.66 19990314/Linux 
>(egcs-
> > System Platform: linux2
> 
> Well, sorry to say, on Zope 2.2.4 and 2.2.5 under Linux and WinNT using files
> between 1kb and 110Mb (Boy, did Netscape like that ;-), I can't reproduce this
> :-(
> 
> If anyone comes up with a fail safe way of reproducing the bug, I'd love to nail
> it, 'cos it sounds like fun :-)

I've finally managed to replicate the bug consistently, so I've just
submitted it to the Collector:

http://classic.zope.org:8080/Collector/1895/view

I now know what causes it so I'm able to work around it, which means
that I'm afraid the offer of 400 quid to fix the bug is now
withdrawn. Sorry.

The bug only occurs if the DTML Method that adds the large file tries to
call a Z SQL Method that uses the ZPyGreSQLDA. Here's the description I
just submitted to the Collector:

Occurs on Zope 2.2.5 with ZPyGreSQLDA-0-0-3 installed. If you have a
form like this:



Filename: 



and a DTML Method called addfile:



OK

where sql is a Z SQL Method that uses a PyGreSQL database connection.
Trying to upload a file larger than about 128 kb gives:

Error Type: AttributeError
Error Value: abort_sub

Traceback (innermost last):
  File /usr/local/zope/lib/python/ZPublisher/Publish.py, line 222, in publish_module
  File /usr/local/zope/lib/python/ZPublisher/Publish.py, line 187, in publish
  File /usr/local/zope/lib/python/Zope/__init__.py, line 221, in 
zpublisher_exception_hook
(Object: Traversable)
  File /usr/local/zope/lib/python/ZPublisher/Publish.py, line 175, in publish
  File /usr/local/zope/lib/python/Zope/__init__.py, line 235, in commit
  File /usr/local/zope/lib/python/ZODB/Transaction.py, line 290, in commit
AttributeError: (see above)

Cheers,
Ian


___
Zope maillist  -  [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope-dev )




Re: [Zope] Can't reproduce :-(

2001-01-26 Thread Chris Withers

Ian Sealy wrote:
> 
> Dear Chris,
> 
> > > We need to get this fixed ASAP so my boss has told me to send this
> > > message to the list and offer 400 pounds (sterling) to anyone who can
> > > fix this bug. Any takers?
> >
> > What version of Zope are you using?
> 
> 2.2.5 on Red Hat 6.2.
> 
> Zope version: Zope 2.2.5 (source release, python 1.5.2, linux2)
> Python version: 1.5.2 (#1, Nov 18 2000, 20:03:24) [GCC egcs-2.91.66 19990314/Linux 
>(egcs-
> System Platform: linux2

Well, sorry to say, on Zope 2.2.4 and 2.2.5 under Linux and WinNT using files
between 1kb and 110Mb (Boy, did Netscape like that ;-), I can't reproduce this
:-(

If anyone comes up with a fail safe way of reproducing the bug, I'd love to nail
it, 'cos it sounds like fun :-)

good luck for now,

Chris

___
Zope maillist  -  [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope-dev )