[Zope-dev] Yay! :-)
Hey! Who sneaked the fix that lets you customise error messages for unauthorised exceptions into Zope 2.5? Well, whoever it was, a HUGE thankyou for fixign what was quite a nasty little wart... ...now if we could only get rid of that nasty appended traceback, my world would be a happy place :-) cheers, Chris ___ Zope-Dev maillist - [EMAIL PROTECTED] http://lists.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope )
Re: [Zope-dev] File/stream like Pdata class in Zope?
On Fri, 04 Jan 2002 17:41:08 +0100, Niels Mache [EMAIL PROTECTED] wrote: I want to transmit the data of a (probably large) Pdata object (Zope module OSF/Image) over a TCP/IP socket using sock.send(). I assume you mean *not* using http. Do you *need* that to be blocking? I thought I needed something similar at one time too, but the non-blocking options are probabnly better. If you want non-blocking, File objects use RESPONSE.write which is a good start for rolling your own implementation. Toby Dickenson [EMAIL PROTECTED] ___ Zope-Dev maillist - [EMAIL PROTECTED] http://lists.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope )
Re: [Zope-dev] [Fwd: Does anyone know how to suppress display of +/- signs on a dtml-tree?]
There are no plans to change the tree tag for Zope 2.5, but later Zope versions might be helped out by your patch. - C Craeg K. Strong wrote: I would like to answer my own question (see below). According to ZOPE/lib/python/TreeDisplay/TreeTag.py, there is no way to suppress the display of the + or - signs. However, there certain parameters to __init__ that have been commented out: # opened_decoration = None, # closed_decoration = None, # childless_decoration = None, which suggests that either there was a way to control this at one time, or that it is functionality that is planned for the future. What is the plan for this in Zope 2.5? I could prepare a quickie patch if you guys don't have the time. Please advise, thanks! --Craeg ] I want to display a dtml-tree always expanded, with no controls visible ] for contracting (basically, an indented list of links). ] I set the tree to always expand via the following: ] dtml-call expr=REQUEST.set('expand_all', 1) ] dtml-tree single=0 name=catalog branches=objectValues ] But I can't figure out how to remove the little minus signs (-) from the ] branches. ] Has anyone done this? ] TIA, ] --Craeg ___ Zope-Dev maillist - [EMAIL PROTECTED] http://lists.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope ) ___ Zope-Dev maillist - [EMAIL PROTECTED] http://lists.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope )
Re: [Zope-dev] Re: [Zope] [Bug] bobobase_modification_time unreliable to catalog
On Saturday 05 January 2002 08:15 pm, kapil thangavelu allegedly wrote: On Sunday 30 December 2001 08:00 pm, Casey Duncan wrote: This behavior is logical if unintuitive. I propose that we can kill two birds with one stone to fix this: - Add a new method perhaps: getModificationTime() to the API of SimpleItem or even Persistent that returns the ZODB modification time or if the object has been changed, but not yet commited, the current date/time. - Deprecate bobobase_mod_time and perhaps even omit it entirely from Zope3. This will fix the aforementioned bug and get rid of an API anachronism. Thoughts? sounds good, i played around with an implementation to do the above. i'm not posting it here causes its inefficient, although i'm happy to email it to anyone who's interested. it basically added three methods. [snip details] there are two inefficiencies one is memory because of DateTime for every registered object and two is computational from the lack of a uniform (across subclasses) hash function for persistent objects which results in traversal of the registered object list to identify if an object is registered or not (and to determine position to figure out the index into registration_times). a much better solution memory wise would have the transaction.py keep a DateTime for its initialization and then have registered objects store registration times as deltas of that. i'm not sure what the better solution is in terms of the computational issue. but as is this solution doesn't seem scalable to me until the computational issues can be handled. For memory concerns, couldn't you just store the DateTime as a floating point number? This would incur just a small overhead to create a DateTime object when the value is looked up. I am interested in seeing this code. From my perspective it seems overly sophisticated. I'm interested how you derive the registration time in the first place. /---\ Casey Duncan, Sr. Web Developer National Legal Aid and Defender Association [EMAIL PROTECTED] \---/ ___ Zope-Dev maillist - [EMAIL PROTECTED] http://lists.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope )
[Zope-dev] Testers needed for z2.py security patch
I've made a security patch for Zope 2.5.0b3 that addresses the setuid startup issues on UNIX and plan to backport it to 2.4.4 (?) and 2.3.3 once I get some positive reports. Only UNIX users need apply this patch. Windows may well have similar issues but I have no clue how to fix them. Please check it out and let me know how it works on your system, or if any clarifications are needed. ___ Zope-Dev maillist - [EMAIL PROTECTED] http://lists.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope )
[Zope-dev] Re: Testers needed for z2.py security patch
Matt Behrens wrote: I've made a security patch for Zope 2.5.0b3 that addresses the setuid startup issues on UNIX and plan to backport it to 2.4.4 (?) and 2.3.3 once I get some positive reports. Only UNIX users need apply this patch. Windows may well have similar issues but I have no clue how to fix them. Please check it out and let me know how it works on your system, or if any clarifications are needed. Errr, it's available at http://www.zope.org/Members/zigg/UnixSecurityPatch, sorry for any confusion :-) ___ Zope-Dev maillist - [EMAIL PROTECTED] http://lists.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope )
Re: [Zope-dev] Re: [Zope] [Bug] bobobase_modification_time unreliable to catalog
On Monday 07 January 2002 06:20 am, Casey Duncan wrote: On Saturday 05 January 2002 08:15 pm, kapil thangavelu allegedly wrote: On Sunday 30 December 2001 08:00 pm, Casey Duncan wrote: This behavior is logical if unintuitive. I propose that we can kill two birds with one stone to fix this: - Add a new method perhaps: getModificationTime() to the API of SimpleItem or even Persistent that returns the ZODB modification time or if the object has been changed, but not yet commited, the current date/time. - Deprecate bobobase_mod_time and perhaps even omit it entirely from Zope3. This will fix the aforementioned bug and get rid of an API anachronism. Thoughts? sounds good, i played around with an implementation to do the above. i'm not posting it here causes its inefficient, although i'm happy to email it to anyone who's interested. it basically added three methods. [snip details] For memory concerns, couldn't you just store the DateTime as a floating point number? This would incur just a small overhead to create a DateTime object when the value is looked up. I am interested in seeing this code. From my perspective it seems overly sophisticated. I'm interested how you derive the registration time in the first place. your right, what i did was overly complex. i took your suggestions and simplified to the following two methods, which stores the txn registration time on the object as a float. it looks like an ok solution, imo. it doesn't do much for newly created persistent objects for which it falls through to the behavior of bobobase_modification_time and returns the current time. in PersistentUtil class in lib/python/App/PersistentExtra.py new method from Acquisition import aq_base def getModificationTime(self): ob = aq_base(self) if hasattr(ob, '_p_changed') and ob._p_changed: return DateTime(self._p_registration_time) else: return self.bobobase_modification_time() in Transaction class in lib/python/ZODB/Transaction.py altered register method def register(self, object): self._append(object) object._p_registration_time = time.time() cheers kapil ___ Zope-Dev maillist - [EMAIL PROTECTED] http://lists.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope )
Re: [Zope-dev] Re: [Zope] [Bug] bobobase_modification_time unreliable to catalog
On Monday 07 January 2002 07:38 am, kapil thangavelu allegedly wrote: On Monday 07 January 2002 06:20 am, Casey Duncan wrote: [snippingtons] I am interested in seeing this code. From my perspective it seems overly sophisticated. I'm interested how you derive the registration time in the first place. your right, what i did was overly complex. i took your suggestions and simplified to the following two methods, which stores the txn registration time on the object as a float. it looks like an ok solution, imo. it doesn't do much for newly created persistent objects for which it falls through to the behavior of bobobase_modification_time and returns the current time. in PersistentUtil class in lib/python/App/PersistentExtra.py new method from Acquisition import aq_base def getModificationTime(self): ob = aq_base(self) if hasattr(ob, '_p_changed') and ob._p_changed: return DateTime(self._p_registration_time) else: return self.bobobase_modification_time() in Transaction class in lib/python/ZODB/Transaction.py altered register method def register(self, object): self._append(object) object._p_registration_time = time.time() That looks nice and simple to me. Does anyone have a concern about the behavior for new objects? (I'm not sure what can be done about it...) If no one objects I can check this into the core. /---\ Casey Duncan, Sr. Web Developer National Legal Aid and Defender Association [EMAIL PROTECTED] \---/ ___ Zope-Dev maillist - [EMAIL PROTECTED] http://lists.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope )
[Zope-dev] PDF-specific Bug in the ZServer implementation??? Or just strange behavoiur of IE?
Hi! This is my first post in the new year, so best wishes for 2002 from Germany! And on we go with my problem: I have a ZClass-based Class derived from File. It holds PDF documents. SOME (not all) of them do not auto-open in Acrobat Reader as they are supposed to if MS IE 5.x is used. Opera etc. seem to work. The files themselves are o.k., and opening in Acrobat Reader AFTER downloading (via right mouseclick/save as) works fine, too. If the same document that doesn't auto-open when downloaded fom the Zope server is downloaded from plain Apache, it works ... The configuration is Zope 2.4.1 (binary release, python 2.1, linux2-x86), python 2.1.0, linux2 on a SuSE Linux with Apache as Proxy server (via proxy_pass). I checked the HTTP header with WGET, and they are identical for working and non-working PDF docs. The mime type is set to application/pdf ... Any hints on that? Joachim ___ Zope-Dev maillist - [EMAIL PROTECTED] http://lists.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope )
Re: [Zope-dev] Re: [Zope] [Bug] bobobase_modification_time unreliable to catalog
That looks nice and simple to me. Does anyone have a concern about the behavior for new objects? (I'm not sure what can be done about it...) If no one objects I can check this into the core. Or before getting ahead of myself, does this still need a proposal and all that? /---\ Casey Duncan, Sr. Web Developer National Legal Aid and Defender Association [EMAIL PROTECTED] \---/ ___ Zope-Dev maillist - [EMAIL PROTECTED] http://lists.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope )
Re: [Zope-dev] PDF-specific Bug in the ZServer implementation??? Or just strange behavoiur of IE?
On Monday 07 January 2002 03:28 pm, Joachim Werner allegedly wrote: Hi! This is my first post in the new year, so best wishes for 2002 from Germany! And on we go with my problem: I have a ZClass-based Class derived from File. It holds PDF documents. SOME (not all) of them do not auto-open in Acrobat Reader as they are supposed to if MS IE 5.x is used. Opera etc. seem to work. The files themselves are o.k., and opening in Acrobat Reader AFTER downloading (via right mouseclick/save as) works fine, too. If the same document that doesn't auto-open when downloaded fom the Zope server is downloaded from plain Apache, it works ... The configuration is Zope 2.4.1 (binary release, python 2.1, linux2-x86), python 2.1.0, linux2 on a SuSE Linux with Apache as Proxy server (via proxy_pass). I checked the HTTP header with WGET, and they are identical for working and non-working PDF docs. The mime type is set to application/pdf ... Any hints on that? Joachim Hmmm, sounds like maybe the http range code isn't quite working maybe? What version of Acrobat Reader? Maybe try an older version. If that works, that new range code might be to blame. /---\ Casey Duncan, Sr. Web Developer National Legal Aid and Defender Association [EMAIL PROTECTED] \---/ ___ Zope-Dev maillist - [EMAIL PROTECTED] http://lists.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope )
RE: [Zope-dev] PDF-specific Bug in the ZServer implementation??? Orjust strange behavoiur of IE?
Acrobat uses something called byte-serving, which is a pain to support sometimes on the server-side, because it essentially amounts to serving parts of a file up to a given byte offset; when Acrobat acts as an HTTP client, it requests the PDF file, and once it has enough of the top of the doc to get header info from the file, it is able to omit downloading the whole thing and request portions of the file between 2 byte offsets, which represent the start and end of a page, as part of the http request. Byte-serving, unfortunately is not implemented in all http servers (or is broken in some, i.e. Apache 1.3.14). I'm not sure what the story for ZServer is, but I am curious to find out if there have been any developments in this regard... More info in the IETF RFC for HTTP 1.1: http://www.w3.org/Protocols/rfc2616/rfc2616-sec3.html#sec3.12 Sean -Original Message- From: Joachim Werner [mailto:[EMAIL PROTECTED]] Sent: Monday, January 07, 2002 12:28 PM To: [EMAIL PROTECTED] Subject: [Zope-dev] PDF-specific Bug in the ZServer implementation??? Or just strange behavoiur of IE? Hi! This is my first post in the new year, so best wishes for 2002 from Germany! And on we go with my problem: I have a ZClass-based Class derived from File. It holds PDF documents. SOME (not all) of them do not auto-open in Acrobat Reader as they are supposed to if MS IE 5.x is used. Opera etc. seem to work. The files themselves are o.k., and opening in Acrobat Reader AFTER downloading (via right mouseclick/save as) works fine, too. If the same document that doesn't auto-open when downloaded fom the Zope server is downloaded from plain Apache, it works ... The configuration is Zope 2.4.1 (binary release, python 2.1, linux2-x86), python 2.1.0, linux2 on a SuSE Linux with Apache as Proxy server (via proxy_pass). I checked the HTTP header with WGET, and they are identical for working and non-working PDF docs. The mime type is set to application/pdf ... Any hints on that? Joachim ___ Zope-Dev maillist - [EMAIL PROTECTED] http://lists.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope ) ___ Zope-Dev maillist - [EMAIL PROTECTED] http://lists.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope )
Re: [Zope-dev] PDF-specific Bug in the ZServer implementation??? Or just strange behavoiur of IE?
Martijn fixed that problem some weeks ago. The fixes are in the CVS now. Andreas - Original Message - From: Casey Duncan [EMAIL PROTECTED] To: Joachim Werner [EMAIL PROTECTED]; [EMAIL PROTECTED] Sent: Monday, January 07, 2002 15:45 Subject: Re: [Zope-dev] PDF-specific Bug in the ZServer implementation??? Or just strange behavoiur of IE? On Monday 07 January 2002 03:28 pm, Joachim Werner allegedly wrote: Hi! This is my first post in the new year, so best wishes for 2002 from Germany! And on we go with my problem: I have a ZClass-based Class derived from File. It holds PDF documents. SOME (not all) of them do not auto-open in Acrobat Reader as they are supposed to if MS IE 5.x is used. Opera etc. seem to work. The files themselves are o.k., and opening in Acrobat Reader AFTER downloading (via right mouseclick/save as) works fine, too. If the same document that doesn't auto-open when downloaded fom the Zope server is downloaded from plain Apache, it works ... The configuration is Zope 2.4.1 (binary release, python 2.1, linux2-x86), python 2.1.0, linux2 on a SuSE Linux with Apache as Proxy server (via proxy_pass). I checked the HTTP header with WGET, and they are identical for working and non-working PDF docs. The mime type is set to application/pdf ... Any hints on that? Joachim Hmmm, sounds like maybe the http range code isn't quite working maybe? What version of Acrobat Reader? Maybe try an older version. If that works, that new range code might be to blame. /---\ Casey Duncan, Sr. Web Developer National Legal Aid and Defender Association [EMAIL PROTECTED] \---/ ___ Zope-Dev maillist - [EMAIL PROTECTED] http://lists.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope ) ___ Zope-Dev maillist - [EMAIL PROTECTED] http://lists.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope )
RE: [Zope-dev] Re: [Zope] [Bug] bobobase_modification_time unreliable to catalog
That looks nice and simple to me. Does anyone have a concern about the behavior for new objects? (I'm not sure what can be done about it...) If no one objects I can check this into the core. Or before getting ahead of myself, does this still need a proposal and all that? I'm ok with the change, so long as: - the folks on zodb-dev are notified and think its OK - someone takes a look at the API docs in the Zope book to decide what this affects and sends me the changes and updates to relay to Amos ...before anything is committed. After it is committed, the committer needs to coordinate with the ZODB-dev guys to make sure it percolates into StandaloneZODB, etc. Brian Lloyd[EMAIL PROTECTED] Software Engineer 540.361.1716 Zope Corporation http://www.zope.com ___ Zope-Dev maillist - [EMAIL PROTECTED] http://lists.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope )
Re: [Zope-dev] PDF-specific Bug in the ZServer implementation??? Orjust strange behavoiur of IE?
- Any hints on that? The failure to open a PDF can be caused by the browser never knowing that file is all done downloading. If Zope is running on WindowsNT and you're using Solaris (either as the workstation or else as an HTTP proxy) then you may be getting a rare bug between the WindowsNT and Solaris TCP/IP stacks. The Solaris packet sends an out-of-order FIN (or was it just a FIN with no data? Can't remember) and the WindowsNT stack never closes the connection, NOR does it acknowledge the last packet before the FIN, so you wind up just stuck. I.e., you'll see a failed PDF download. Sun and MS both know about this, but neither will claim responsibility. I don't remember the exact details, but we saw this problem a few months ago. It was more prevalent with PDFs than anything else because of large filesize and the fact that I.E. must spawn the PDF control (aka 'widget') with the browser. Just a thought. --Derek ___ Zope-Dev maillist - [EMAIL PROTECTED] http://lists.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope )
Re: [Zope-dev] PDF-specific Bug in the ZServer implementation??? Or just strange behavoiur of IE?
Hi! This was a really quick response! Thanks a lot. Just one additional question: What is the best approach to upgrading to the new code? Replacing the ZServer code by the CVS one? Is the patch in the latest 2.5 beta, too? Joachim - Original Message - From: Andreas Jung [EMAIL PROTECTED] To: Casey Duncan [EMAIL PROTECTED]; Joachim Werner [EMAIL PROTECTED]; [EMAIL PROTECTED] Sent: Monday, January 07, 2002 9:45 PM Subject: Re: [Zope-dev] PDF-specific Bug in the ZServer implementation??? Or just strange behavoiur of IE? Martijn fixed that problem some weeks ago. The fixes are in the CVS now. Andreas - Original Message - From: Casey Duncan [EMAIL PROTECTED] To: Joachim Werner [EMAIL PROTECTED]; [EMAIL PROTECTED] Sent: Monday, January 07, 2002 15:45 Subject: Re: [Zope-dev] PDF-specific Bug in the ZServer implementation??? Or just strange behavoiur of IE? On Monday 07 January 2002 03:28 pm, Joachim Werner allegedly wrote: Hi! This is my first post in the new year, so best wishes for 2002 from Germany! And on we go with my problem: I have a ZClass-based Class derived from File. It holds PDF documents. SOME (not all) of them do not auto-open in Acrobat Reader as they are supposed to if MS IE 5.x is used. Opera etc. seem to work. The files themselves are o.k., and opening in Acrobat Reader AFTER downloading (via right mouseclick/save as) works fine, too. If the same document that doesn't auto-open when downloaded fom the Zope server is downloaded from plain Apache, it works ... The configuration is Zope 2.4.1 (binary release, python 2.1, linux2-x86), python 2.1.0, linux2 on a SuSE Linux with Apache as Proxy server (via proxy_pass). I checked the HTTP header with WGET, and they are identical for working and non-working PDF docs. The mime type is set to application/pdf ... Any hints on that? Joachim Hmmm, sounds like maybe the http range code isn't quite working maybe? What version of Acrobat Reader? Maybe try an older version. If that works, that new range code might be to blame. /---\ Casey Duncan, Sr. Web Developer National Legal Aid and Defender Association [EMAIL PROTECTED] \---/ ___ Zope-Dev maillist - [EMAIL PROTECTED] http://lists.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope ) ___ Zope-Dev maillist - [EMAIL PROTECTED] http://lists.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope ) ___ Zope-Dev maillist - [EMAIL PROTECTED] http://lists.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope )
Re: [Zope-dev] PDF-specific Bug in the ZServer implementation??? Or just strange behavoiur of IE?
Hi, I have the same problem and want to fix it in Zope 2.4.3. Can anybody give a short description how to proceed ? Thanks Dirk Joachim Werner schrieb: Hi! This was a really quick response! Thanks a lot. Just one additional question: What is the best approach to upgrading to the new code? Replacing the ZServer code by the CVS one? Is the patch in the latest 2.5 beta, too? Joachim - Original Message - From: Andreas Jung [EMAIL PROTECTED] To: Casey Duncan [EMAIL PROTECTED]; Joachim Werner [EMAIL PROTECTED]; [EMAIL PROTECTED] Sent: Monday, January 07, 2002 9:45 PM Subject: Re: [Zope-dev] PDF-specific Bug in the ZServer implementation??? Or just strange behavoiur of IE? Martijn fixed that problem some weeks ago. The fixes are in the CVS now. Andreas - Original Message - From: Casey Duncan [EMAIL PROTECTED] To: Joachim Werner [EMAIL PROTECTED]; [EMAIL PROTECTED] Sent: Monday, January 07, 2002 15:45 Subject: Re: [Zope-dev] PDF-specific Bug in the ZServer implementation??? Or just strange behavoiur of IE? On Monday 07 January 2002 03:28 pm, Joachim Werner allegedly wrote: Hi! This is my first post in the new year, so best wishes for 2002 from Germany! And on we go with my problem: I have a ZClass-based Class derived from File. It holds PDF documents. SOME (not all) of them do not auto-open in Acrobat Reader as they are supposed to if MS IE 5.x is used. Opera etc. seem to work. The files themselves are o.k., and opening in Acrobat Reader AFTER downloading (via right mouseclick/save as) works fine, too. If the same document that doesn't auto-open when downloaded fom the Zope server is downloaded from plain Apache, it works ... The configuration is Zope 2.4.1 (binary release, python 2.1, linux2-x86), python 2.1.0, linux2 on a SuSE Linux with Apache as Proxy server (via proxy_pass). I checked the HTTP header with WGET, and they are identical for working and non-working PDF docs. The mime type is set to application/pdf ... Any hints on that? Joachim Hmmm, sounds like maybe the http range code isn't quite working maybe? What version of Acrobat Reader? Maybe try an older version. If that works, that new range code might be to blame. /---\ Casey Duncan, Sr. Web Developer National Legal Aid and Defender Association [EMAIL PROTECTED] \---/ ___ Zope-Dev maillist - [EMAIL PROTECTED] http://lists.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope ) ___ Zope-Dev maillist - [EMAIL PROTECTED] http://lists.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope ) ___ Zope-Dev maillist - [EMAIL PROTECTED] http://lists.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope ) ___ Zope-Dev maillist - [EMAIL PROTECTED] http://lists.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope )
Re: [Zope-dev] PDF-specific Bug in the ZServer implementation??? Or just strange behavoiur of IE?
Hi! Just to answer my own question and complete the mail archive: If you have problems with downloads that make use of the HTTP range functionality (e.g. with the latest Acrobat Reader in MS IE), Zope 2.5 fixes the problem (for me). ___ Zope-Dev maillist - [EMAIL PROTECTED] http://lists.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope )
Re: [Zope-dev] PDF-specific Bug in the ZServer implementation??? Or just strange behavoiur of IE?
On Mon, Jan 07, 2002 at 09:56:40PM +0100, Joachim Werner wrote: This was a really quick response! Thanks a lot. Just one additional question: What is the best approach to upgrading to the new code? Replacing the ZServer code by the CVS one? Is the patch in the latest 2.5 beta, too? Yes, the changes are in 2.5.0b3 as well (check the CHANGES.txt file when in doubt :)). -- Martijn Pieters | Software Engineer mailto:[EMAIL PROTECTED] | Zope Corporation http://www.zope.com/ | Creators of Zope http://www.zope.org/ - ___ Zope-Dev maillist - [EMAIL PROTECTED] http://lists.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope )
Re: [Zope-dev] PDF-specific Bug in the ZServer implementation??? Or just strange behavoiur of IE?
On Mon, Jan 07, 2002 at 09:56:40PM +0100, Joachim Werner wrote: What is the best approach to upgrading to the new code? Replacing the ZServer code by the CVS one? The code only applies to OFS/Image.py (only File and Image objects support HTTP Range) and ZPublisher/HTTPRangeSupport.py. I've attached the versions for a Zope 2.4.x installation, just drop them in the correct places in your current Zope setup. -- Martijn Pieters | Software Engineer mailto:[EMAIL PROTECTED] | Zope Corporation http://www.zope.com/ | Creators of Zope http://www.zope.org/ - ## # # Zope Public License (ZPL) Version 1.0 # - # # Copyright (c) Digital Creations. All rights reserved. # # This license has been certified as Open Source(tm). # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions are # met: # # 1. Redistributions in source code must retain the above copyright #notice, this list of conditions, and the following disclaimer. # # 2. Redistributions in binary form must reproduce the above copyright #notice, this list of conditions, and the following disclaimer in #the documentation and/or other materials provided with the #distribution. # # 3. Digital Creations requests that attribution be given to Zope #in any manner possible. Zope includes a Powered by Zope #button that is installed by default. While it is not a license #violation to remove this button, it is requested that the #attribution remain. A significant investment has been put #into Zope, and this effort will continue if the Zope community #continues to grow. This is one way to assure that growth. # # 4. All advertising materials and documentation mentioning #features derived from or use of this software must display #the following acknowledgement: # # This product includes software developed by Digital Creations # for use in the Z Object Publishing Environment # (http://www.zope.org/). # #In the event that the product being advertised includes an #intact Zope distribution (with copyright and license included) #then this clause is waived. # # 5. Names associated with Zope or Digital Creations must not be used to #endorse or promote products derived from this software without #prior written permission from Digital Creations. # # 6. Modified redistributions of any form whatsoever must retain #the following acknowledgment: # # This product includes software developed by Digital Creations # for use in the Z Object Publishing Environment # (http://www.zope.org/). # #Intact (re-)distributions of any official Zope release do not #require an external acknowledgement. # # 7. Modifications are encouraged but must be packaged separately as #patches to official Zope releases. Distributions that do not #clearly separate the patches from the original work must be clearly #labeled as unofficial distributions. Modifications which do not #carry the name Zope may be packaged in any form, as long as they #conform to all of the clauses above. # # # Disclaimer # # THIS SOFTWARE IS PROVIDED BY DIGITAL CREATIONS ``AS IS'' AND ANY # EXPRESSED OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE # IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR # PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL DIGITAL CREATIONS OR ITS # CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, # SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT # LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF # USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND # ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, # OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT # OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF # SUCH DAMAGE. # # # This software consists of contributions made by Digital Creations and # many individuals on behalf of Digital Creations. Specific # attributions are listed in the accompanying credits file. # ## Image object __version__='$Revision: 1.130.4.2 $'[11:-2] import Globals, string, struct from OFS.content_types import guess_content_type from Globals import DTMLFile from PropertyManager import PropertyManager from AccessControl.Role import RoleManager from webdav.common import rfc1123_date from webdav.Lockable import ResourceLockedError from webdav.WriteLockInterface import WriteLockInterface from SimpleItem import Item_w__name__ from cStringIO import StringIO from Globals import Persistent from Acquisition import Implicit from DateTime import DateTime from Cache import Cacheable
RE: [Zope-dev] PDF-specific Bug in the ZServer implementation??? Or just strange behavoiur of IE?
BRILLIANT!! One headache fixed. Martijn Analgesic Pieters, you are my hero for the day. Thank you. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]On Behalf Of Martijn Pieters Sent: Monday, January 07, 2002 4:12 PM To: Joachim Werner Cc: [EMAIL PROTECTED] Subject: Re: [Zope-dev] PDF-specific Bug in the ZServer implementation??? Or just strange behavoiur of IE? On Mon, Jan 07, 2002 at 09:56:40PM +0100, Joachim Werner wrote: What is the best approach to upgrading to the new code? Replacing the ZServer code by the CVS one? The code only applies to OFS/Image.py (only File and Image objects support HTTP Range) and ZPublisher/HTTPRangeSupport.py. I've attached the versions for a Zope 2.4.x installation, just drop them in the correct places in your current Zope setup. -- Martijn Pieters | Software Engineer mailto:[EMAIL PROTECTED] | Zope Corporation http://www.zope.com/ | Creators of Zope http://www.zope.org/ - ___ Zope-Dev maillist - [EMAIL PROTECTED] http://lists.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope )
[Zope-dev] ghosts of removed products haunting ZSQL Methods?
I used to have the Product TrackerBase installed and have removed it. Now, however, attempts to access the Advanced tab of ZSQL Methods is broken because a chain of events attempt to get info about a the non-existent Product: lib/python/Shared/DC/ZRDB/dtml/advanced.dtml calls manage_product_zclass_info ../ZRDB/DA.py.manage_product_zclass_info (line 546) calls self.aq_acquire('_getProductRegistryData')('zclasses') One of these items is the dict: {'id': 'Tracker', 'meta_type': 'Tracker', 'product': 'Tracker', 'meta_class': ZClass instance at d55af0} Then, line 548 calls if hasattr(z._zclass_,'_p_deactivate'). The attempt to access z._zclass_ fails because this product doesn't exist. 1) the call to z._zclass_ doesn't actuallt do anything except: ## Eek, persistent 2) Is this schizophrenic state my fault? 3) How to rectify the problem (Make *all* of Zope know that TrackerBase is gone)? Thanks in advance, traceback follows, Ziniti Error Type: ImportError Error Value: No module named TrackerBase Troubleshooting Suggestions * The URL may be incorrect. * The parameters passed to this resource may be incorrect. * A resource that this resource relies on may be encountering an error. For more detailed information about the error, please refer to the HTML source for this page. If the error persists please contact the site maintainer. Thank you for your patience. User is Last modified 2002/01/07 16:37:34.6452 GMT+0 © Copyright 2000 Channing Lab Questions or comments about this site? All Rights Reserved. Traceback (innermost last): File /u05/ilocal/opt/Zope-2.4.0-src/lib/python/ZPublisher/Publish.py, line 223, in publish_module File /u05/ilocal/opt/Zope-2.4.0-src/lib/python/ZPublisher/Publish.py, line 187, in publish File /u05/ilocal/opt/Zope-2.4.0-src/lib/python/Zope/__init__.py, line 226, in zpublisher_exception_hook (Object: new_sql_2) File /u05/ilocal/opt/Zope-2.4.0-src/lib/python/ZPublisher/Publish.py, line 171, in publish File /u05/ilocal/opt/Zope-2.4.0-src/lib/python/ZPublisher/mapply.py, line 160, in mapply (Object: manage_advancedForm) File /u05/ilocal/opt/Zope-2.4.0-src/lib/python/ZPublisher/Publish.py, line 112, in call_object (Object: manage_advancedForm) File /u05/ilocal/opt/Zope-2.4.0-src/lib/python/Shared/DC/Scripts/Bindings.py, line 324, in __call__ (Object: manage_advancedForm) File /u05/ilocal/opt/Zope-2.4.0-src/lib/python/Shared/DC/Scripts/Bindings.py, line 354, in _bindAndExec (Object: manage_advancedForm) File /u05/ilocal/opt/Zope-2.4.0-src/lib/python/App/special_dtml.py, line 241, in _exec (Object: manage_advancedForm) File /ilocal/opt/Zope-2.4.0-src/lib/python/Shared/DC/ZRDB/DA.py, line 549, in manage_product_zclass_info (Object: new_sql_2) File /u05/ilocal/opt/Zope-2.4.0-src/lib/python/ZODB/Connection.py, line 544, in setstate ImportError: (see above) ___ Zope-Dev maillist - [EMAIL PROTECTED] http://lists.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope )