Re: [Zope] String problem with ZClassReverse
Hi! it seems that you have problems to access the server-sided part of ZClassReverse (I know I have to refine the error messages) Check out if you can correctly access the server-sided part of ZclassReverse, point your browser to the following (of course fill in your specific host,port and product): http://yourserver:8080/zclassInfo/getClassInfos?product=QSurvey If you see a long python dict containing the classdata, then it works, otherwise check if: 0. you have copied zclassInfo.py to your Zope's /Extensions directory 1. you have imported zclassInfo.zexp into the root folder of your ZODB you can check this, if in your ZopeRoot exists a folder called zclassInfo with three external methods declared let me know if it helped regards phil *** REPLY SEPARATOR *** On 08.01.2001 at 12:29 peter bengtson wrote: >I try to use zclassReverse 1.1.1, but when I am asked for details of the >Zclass this error (below) occurs almost instantly. This happens with all >ZClasses I have tried. >Zope 2.2.2 on WinNT. >Ideas? I have not been able to see any diagrams yet. > >Regards, Peter > >>From the JPython (1.0.3) command line in ObjectDomain Evaluation 3.00.002: > execfile('C:/Program Files/domain30/python/scripts/zclassReverse.py') >starting ZClass reverse engineering dialog... Error: ('invalid syntax', ('', 1, 1, >'Zope')) *** REPLY SEPARATOR *** On 08.01.2001 at 12:29 peter bengtson wrote: >I try to use zclassReverse 1.1.1, but when I am asked for details of the >Zclass this error (below) occurs almost instantly. This happens with all >ZClasses I have tried. >Zope 2.2.2 on WinNT. >Ideas? I have not been able to see any diagrams yet. > >Regards, Peter > >>From the JPython (1.0.3) command line in ObjectDomain Evaluation 3.00.002: > execfile('C:/Program Files/domain30/python/scripts/zclassReverse.py') >starting ZClass reverse engineering dialog... Error: ('invalid syntax', ('', 1, 1, >'Zope')) > > >___ >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 ) ___ 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 )
[Zope] Re: [Zope-dev] MySQL with LAST_INSERT_ID()
Be careful with last_insert_id() and similar sql functions and Zope and more than one simultanous user: since all requests run over the same physical database connection, it is not guaranteed that your call last_insert_id() returns YOUR last inserted record ID. if another user performs an insert in the right moment you get HIS last id. the scenario: user1 inserts (gets ID 42) user 2 inserts (gets ID 43) user1 calls last_insert_id() (gets 43) phil *** REPLY SEPARATOR *** On 08.01.2001 at 08:27 Arno Gross wrote: >Dieters assumption was right. >LAST_INSERTED_ID() returns a numeric value and >that seems to be the problem. So if I change the statement as this: >SELECT CONV(LAST_INSERT_ID(),10,10) >it works (CONV returns a string!) > >P.S. Soren, maybe you can update your HowTo with a short note. Another >possibilty instead of using LAST_INSERT_ID can be using MAX(). That should >work too. > >Thanks > Arno >On Sat, 06 Jan >2001, Dieter Maurer wrote: > Arno Gross writes: >> > SELECT LAST_INSERT_ID() >> > >> > This method works with Zope 2.2.4 under Linux and MySQL 3.22.32 >> > but I got an error with Zope 2.2.2 under NT 4.0 and MySQL 3.22.29 >> >Error, exceptions.KeyError: unhandled >> Sieht aus, als könnte der MySQL Anschluss den >> Rückgabewert von "LAST_INSERT_ID" nicht in einen Python >> Datentyp wandeln, würde deshalb gerne eine "unhandled" >> Funktion aus einen Dictionary auslesen, die leider >> nicht drin ist. >> >> Sieht für mich nach einem Upgrade auf eine neuere Version >> von MySQL bzw. seinen Python Anschluss aus. >> >> Allerdings müsste man zunächst den Traceback genau anschauen, >> ob meine Vermutung auch wirklich zutrifft. >> >> >> Dieter >--- > >___ >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 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] ODBC errors
I have worked with ODBC and Zope under Win2k and had no such problems with MSSQL,Oracle and Access. Since you work with mysql the problem seems to happen in conjunction with the mysql ODBC AND Zope, I don't have experiences with MySQL ODBc, but: If you work with mysql & Zope I would anyhow recommend Zope's native mysql adapter since it is full-threaded and ZODBCDA is not. *** REPLY SEPARATOR *** On 06.01.2001 at 10:41 Doug Brewer wrote: >Hello > >I'm relatively new to Zope, and have been working on getting mySql connected via >ZODBC on Win2k. The connection is working, however, I have one column which >repeatedly throws an error when I try to access data. The column contains text >with many "\n" to retain formatting for email messages (it's an archive). > >The error seems to be from the ODBC driver: > >Error, sql.error: ('24000', 0, '[Microsoft][ODBC Driver Manager] Invalid cursor >state') > >however I can successfully access values from this column directly from the >mysql console AND through the exact same datasource used by zope but from other >apps (I used Excel as a test, and successfully returned data). IOW, only Zope >produces this error. > >Any thoughts or pointers would be greatly appreciated. > >Doug Brewer > > >___ >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 ) ___ 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] ODBC Connection
the ZmxODBC DA uses the Zope-independent product mxODBC, that provides a generic Python DB API compliant ODBC interface to Python. ZmxODBC installs mxODBC into lib/python/Shared/mx. The problem is that this path is not in the default PythonPath. Solution: move the mx directory from lib/python/Shared into a directory that's member of PythonPath (for example lib/python). phil *** REPLY SEPARATOR *** On 12.12.2000 at 10:25 Emmon Simbo wrote: Hi I have a few customers who are using Zope and have shown an interest in using the OpenLink ODBC Drivers. Unfortunately, I am not familiar with Zope and wondered if there was a How-To that I can use to show me how to use Zope with ODBC. I have downloaded the ZmxODBCDA module but when I select this from the Products menu, it shows up as ZmxODBCDA(Broken product ZmxODBCA). If I click on the link, I get File "D:\APPS\ZopeWeb\lib\python\OFS\Application.py", line 397, in import_products product=__import__(pname, global_dict, global_dict, silly) File "D:\APPS\ZopeWeb\lib\python\Products\ZmxODBCDA\__init__.py", line 91, in ? import DA File "D:\APPS\ZopeWeb\lib\python\Products\ZmxODBCDA\DA.py", line 92, in ? from db import DB, manage_ODBCDataSources File "D:\PROGRA~1\Zope22\lib\python\Products\ZmxODBCDA\db.py", line 87, in ? ImportError: No module named mx.ODBC Any ideas what's wrong here and secondly how I can go about making an ODBC connection. Thanks for you help in advance Best Regards, Emmon Simbo Consultant OpenLink Software Tel: +44 (0) 20 8681 7701 Web: http://www.openlinksw.com XML & E-Business Infrastructure Technology Provider ___ 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 )
[Zope] unicode,python20,SQL DB Adapters
Python 2.0 has unicode support and once Zope will officially run with it -> has anybody evaluated how several database adapters will be able to read and write unicode varchars ? (of course only if the DB supports unicode :) DB's with my special interest are: Oracle MSS SQL Server and the database adapters: mxODBC ZOracleDA ZSybaseDA thanks in advance phil ___ 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] PythonMethod problem
PythonScripts will come with Zope 2.3 How did you call the method? perhaps you forgot the 'self' your call should look like this: self.foo(...) phil *** REPLY SEPARATOR *** On 10.12.2000 at 16:22 kosh wrote: >I know I am still using PythonMethods however I have not seen Python >Scripts out yet for 2.2.4. > >Okay here is the problem. How do I call one PythonMethod from another >PythonMethod? > >Example > >object foo is a python method and it takes a='',b='',c='',d='' > >does stuff >returns a string > > >foo_spec takes parameters a1='',b1='' >it should return foo(a=a1,b=b1) > >However trying to call that foo gives an error. > >I get a NameError on foo when it is used in foo_spec. However using foo >directly does work however I want to make easier customized interfaces for >users. > >Thanks > > >___ >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 ) ___ 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 )
[Zope] Intercepting NotFoundError with standard_error_message
I need to intercept NotFoundErrors, but am banging my head against a problem Normally this can be done by changing the standard_error_message, but there I have some questions: considering a minimal standard_error_message: -- Error! -- When I provoke an error by referencing a non-existent resource the message 'Error!' gets displayed, but there is also a traceback which I cannot suppress, it always gets displayed as a HTML comment and now my questions 0: How can I suppress this traceback totally, my main goal Even on zope.org whe NotFoundError returns such a hidden traceback :( 1: when I remove the standard_header and footer from my standard_error_message I would expect that just the word 'Error' gets displayed, But no way, then I get a detailed Zope Error message with a traceback. How can I archive that I just get the word 'Error!' or something similar as a result. I need that desperately because such an exception is unusable when calling methods via XMLRPC, there I need a simple clear error code and not a long traceback message. 2: what makes me most happy would be returning a single XMLRPC marshallable value by dtml-return: I already have such a standard_error_message but it just works for user-generated exception, but not for the #@%&§$ NotFoundError I cannot believe that it is not possible to do error handling of NotFoundErrors but I've not found any information on that. Thanks in advance phil ___ 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] UML
Hi! I also don't know which question Douglas ment (see bottom of page) , but both should be worth a short (or not so short) answer from a DC guru. We for our current project use ObjectDomain (www.objectdomain.com) as case tool, but do not generate code for python or ZClasses with the tool by now, we use it just for drawing the models. The problem with ObjectDomain is that it is a nice tool, but: - its sort of unstable, sometimes it crashes and eats up parts of the model :( - I don't know if the guys still work on the project. Since end of april you can still download the Beta od Release 3, but nothing new on their site since then - lots of other bugs (e.g. export to Rational Rose is buggy) Since ObjectDomain is customizable through JPython it should be possible to make it able to generate/reverse engineer ZClasses (has anybody done that already?) Do you still use ObjectDomain at DC? At the Paris Zope meeting Paul Everitt told me that DC had many troubles with it too. phil *** REPLY SEPARATOR *** On 04.11.2000 at 13:03 Michel Pelletier wrote: >Douglas Daniel Del Frari wrote: [snip] > >I'm not sure what you mean Douglas, do you want to know: > >1) If we apply a design methedology to Zope or > >2) How you can apply a design methedology to Zope? > >-Michel > >___ >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 ) ___ 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 )
[Zope] Re: [Zope-dev] pluggable brains - namespace blues
the best answers are those answered by yourself: For all who want to know it: you have to explicitely give self as an extra parameter: concerning the example below: just call: rs[0].getName(rs[0]) and it works for me. Weird, but now I can enjoy my beer phil*** REPLY SEPARATOR ***On 03.11.2000 at 12:30 Philipp Auersperg wrote: I have a problem with pluggable brains: 1. Given is a ZClass named 'Merchant' that maps to a SQL table 'Merchant' with the columns 'ID' and 'name'. 2. I the ZClass I defined a Python method 'getName' with the body: return self.name 3. I have a SQL Method with "select * from merchant" that I bind to the brain class 'Merchant' 4. I define a Python method with the following body: rs=self.Merchants()return rs[0].name And now the problems: That works fine, but when I want to access the Merchant's name through the its member function getName() with the following code: rs=self.Merchants()return rs[0].getName() then I get an AttributeError mentioning that 'name' cannot be found. when I change the getName() Python method to: return 42 it works! It seems that the namespace is somehow shreddered, I have to dig into that but if anybody can help it would spare much time! So finally my desperate question: How can I solve/workaround that problem to call methods in pluggable brains that access database-based members from a python method? thanks in advance phil
Re: [Zope] Mapping tools and Zope - SIG? Fishbowl?
Hi Trevor! That is an interesting question, we had a GIS project in the beginning of this year where we worked with and extended PMS (Practical Map Server from ArsDigita) . On our demo site we run the project (BlueGis) together with Zope (check out www.bluedynamics.com, exactly:http://www2.bluedynamics.com:8080/BlueDynamics/products/bluegis/BlueGis). PMS has a very elegant clear structure, but it is written in java (unfortunately java has stability problems under linux and PMS sometimes locks up). We had the vision to 'pythonize' PMS, since the architecture and concept of PMS should be well portable to the Python/Zope world, but had unfortunately not enough time&money to do that on our own. I am very happy to see that there exists interest in that direction and perhaps there will be the opportunity to pythonize PMS. Regards phil *** REPLY SEPARATOR *** On 01.11.2000 at 15:37 twiens wrote: >I'm writing to all who responded to my query regarding mapping tools for >Zope or others interested in this issue. In one of the responses, was >the suggestion to start a SIG or Fishbowl. > >At this point in time, I'm in a research phase for a project where a >mapping interface will be needed in Zope based web application. We are >starting to move into the design phase and so some technical decisions >will start to be made in the next two months at which point we will >begin building something. > >I've received a number of other interesting replies about GIS and Zope >and possible solutions. These have ranged from "I know about this" to "I >use this" to "We should build something". I think there might be >sufficient interest in at least starting a SIG or Fishbowl or separate >list about the problem. Is there?? > >I'm personally a bit hesitant to even consider building yet another GIS >product. There are many of them out their (see www.freegis.org) for web >display, cartography, spatial analysis, etc. Obviously our interest here >is web interfaces, but these other products are testimony to the >ubiquitous nature of the problem; a good suite of comprehensive GIS >software solutions just doesn't exist, either for free or commercially >(IMHO). The approach my team will likely take on our project will be to >examine existing open source products and determine if there is one that >is sufficient to meet our needs and simply use it. If we can build some >tools around this product to facilitate it's future use with Zope by >others, we will open source those. > >I would welcome the discussion of this issue, since it is important and >it is one of the up and coming needs for web applications. I would >welcome feedback from others who undoubtedly have significant experience >and knowledge to bring to this problem. > >T >-- >Trevor Wiens >[EMAIL PROTECTED] > >The significant problems that we face cannot be solved at the same level >of thinking we were at when we created them. (Albert Einstein) > > >___ >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 ) ___ 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 )
[Zope] Zope.org uptime listed by netcraft
on www.netcraft.com I looked at the list with the websites having the maximum uptime and found - Zope - under the top 10 ! Check it out: http://uptime.netcraft.com/today/top.avg.html phil
Re: [Zope] pluggable brains
I already found the answer myself: one can only use ZClasses as pluggable brains that are NOT persistent!! phil*** REPLY SEPARATOR ***On 31.10.2000 at 05:05 Philipp Auersperg wrote: For ZSQL Methods it is possible to bind a ZClass to the records. These can be selected from te combo box labeled 'ZClass' in the 'advanced' tab of the SQLMethod's management screen, but there is always listed just one ZClass. My question: Why is there just one ZClass selectable, even if there are many ZClasses defined? Is that a bug or a feature? thanks phil
[Zope] pluggable brains
For ZSQL Methods it is possible to bind a ZClass to the records. These can be selected from te combo box labeled 'ZClass' in the 'advanced' tab of the SQLMethod's management screen, but there is always listed just one ZClass. My question: Why is there just one ZClass selectable, even if there are many ZClasses defined? Is that a bug or a feature? thanks phil
Re: [Zope] locking help
this Postgres adapter is not multithreaded, check out the ZPoPyDA from zope.org. That is an alternative Postgres adapter that is multithreaded and does not lock up. phil *** REPLY SEPARATOR *** On 11.10.2000 at 08:48 Mark Twiddy wrote: >Hi thanks for the reply >The problem is whenever i do really big query everything stops and waits. > >im using >ZPyGreSQLDA-0.3-rjr2 >and >py-PyGreSQL-2.4 > >thanks >Mark >On Tue, 10 Oct 2000, Mike Renfro wrote: > >> On Tue, Oct 10, 2000 at 04:58:46PM +0930, Mark Twiddy wrote: >> >> > Can someone please tell me what is going on. while querying a >> > postgres database i am unable to access any crap from zope. I have >> > tried creating a db connection in a enternal method and querying >> > through that but it still locks and wont serve any requests. >> >> Don't know if this will help, but my Zope/Postgresql experience has >> gone remarkably well. >> >> I have the following packages installed on an otherwise regular Debian >> 2.2 machine: >> >> libpgsql2 7.0.2-6 Shared library libpq.so.2 for PostgreSQL >> postgresql7.0.2-6 Object-relational SQL database, descended fr >> postgresql-client 7.0.2-6 Front-end programs for PostgreSQL >> postgresql-dev7.0.2-6 Header files for libpq (postgresql library) >> postgresql-doc7.0.2-6 Documentation for the PostgreSQL database. >> python-pygresql 7.0.2-6 PostgreSQL module for Python >> zope 2.2.2-1 The Z Object Publishing Environment >> zope-pygresqlda 0.3rjr2-1 A Zope Database Adapter for PostgreSQL >> >> Between those packages, following the PostgreSQL tutorial at >> postgresql.org, and following the Z SQL Methods User's Guide >> (http://www.zope.org/Documentation/Guides/ZSQL-HTML/ZSQL.html), I'm >> working fine. Where are the actual errors? >> >> -- >> Mike Renfro / R&D Engineer, Center for Manufacturing Research, >> 931 372-3601 / Tennessee Technological University -- [EMAIL PROTECTED] >> >> ___ >> 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 ) >> > > >___ >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 ) ___ 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 )
[Zope] ZODB question: get older object versions without undo
I have two questons concerning ZODB: 1. Since ZODB does not overwrite objects on change one can get the older versions when undoing the changes. My question now: how can I access older versions of objects without undoing transactions? (I had a short glance at the ZODB classes, but found nothing) 2.Is it possible ( or will be ) to define ZODB objects for which updates are done by overwriting and not appending to the object database - That is an important issue for objects that are subject to frequent and simple changes. For example Webcounters or Advertising banners that count the clicks. Solutions to write these changes into external files (like FSCounter) are not more than emergency solutions for me. thanks phil
Re: [Zope] HTTP user authentication in Python
The core of HTTP authentication is the following (you have to put the authentication into the HTTP header): import httplib h=httplib.HTTP() h.putheader("AUTHORIZATION", "Basic %s" % string.replace( encodestring("%s:%s" % (self.username, self.password)), "\012", "")) there is a xmlrpc howto where you find a detailed description: http://www.zope.org/Members/Amos/XML-RPC good luck phil *** REPLY SEPARATOR *** On 06.10.2000 at 14:22 Hung Jung Lu wrote: >Hi, > >Where can I find out more information on HTTP user authentication? I have >seen the RFC before, but it's a bit too technical to follow. I think Python >does not include the authentication/cookie handling part probably because >out of concern about abuses. :) > >Does anyone know where I can find more info on the authentication and cookie >protocol stuff? Is there any Python module already written to handle these >things? > >The idea is to be able to fetch external webpages automatically using >Python, including providing the necessary auth and cookie info. Of course >this opens up a whole can of security worms, but heck, it's open information >and someone must already have written something in Python already. > >regards, > >Hung Jung >_ >Get Your Private, Free E-mail from MSN Hotmail at http://www.hotmail.com. > >Share information about yourself, create your own public profile at >http://profiles.msn.com. > > >___ >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 ) ___ 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] In a python method, I want to convert a XML string into a dictionary...
0. There is an XML parser in the python standard library (package xmllib, you find it in the python documentation), there also exist alternative xml parsers. 1. Take a look at www.xml-rpc.com, you find a lot of iternnformation there. 2. check out the xmlrpclib by Frederic Lundh (it comes also with Zope, look in the lib/python/xmlrpclib.h) 3. in the xmlrpclib.py you can see how the xml parser is used 4. there are several how-to's at zope.org concerning xml-rpc - just serch zope.org for 'xmlrpc' good luck phil *** REPLY SEPARATOR *** On 05.10.2000 at 10:52 Frederic Quin wrote: >Hi all, > > >I would like to create a python method which take a parameter xml_string >and return a dictionary containing all tags, values and attributes. I >know that it exists some modules for xml conversions but I don't know >very much how to use them. I am novice in Python so it's a little bite >difficult for me to understand the codes... > > >Thanks > > >Fred > >___ >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 ) ___ 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 )
[Zope] XMLRPC:XML Compressors - anybody experienced it?
Since XML blows lots of overhead over the line sending large amounts of data via XML becomes a performance question. There exist XML-compressors, for example XMill that address this problem. What I need is integrating such an XML compressor into the Zope XMLRPC mechanism, Before I do something that is already done by somebody else: Did anybody play with XML compressors for Zope or at least have a hint how to do that? thanks
[Zope] looking for XML-RPC client for C++ (urgh - but I need it)
We are involved in a project where a another company developes software written in C++ (it's their preference) that has to access data from our Zope server via XML.. I've checked out xmlrpc.com and found lots of language bindings but none for C++ (I know its more difficult to implement because of it's static nature) and one for COM. My question: Does there exist a plain C++ implementation for an XMLRPC **Client** ? thanks phil
Re: [Zope] Zope 2.2.2 breaks zdiscussions
Just for information: I also have this problem also with Zope 2.2.1 under Linux AND Windows. the Windows Zope was a fresh installation. I get the same message as Julio: thanks phil ZDBase Import Traceback Traceback (innermost last): File "/usr/local/Zope-2.2.0-linux2-x86/lib/python/OFS/Application.py", line 396, in import_products product=__import__(pname, global_dict, global_dict, silly) File "/home/bwanazulia/zope/lib/python/Products/ZDBase/__init__.py", line 86, in ? File "/home/bwanazulia/zope/lib/python/Products/ZDBase/ZDiscussions.py", line 106, in ? File "/usr/local/Zope-2.2.0-linux2-x86/lib/python/App/class_init.py", line 109, in default__class_init__ AccessControl.Permission.registerPermissions(self.__ac_permissions__) File "/usr/local/Zope-2.2.0-linux2-x86/lib/python/AccessControl/Permission.py", line 204, in registerPermissions perm, methods, default = setting ValueError: unpack sequence of wrong size *** REPLY SEPARATOR *** On 19.09.2000 at 13:24 J. Atwood wrote: >That is very strange. I know there is a bug in the ZUBB (ZDiscussions) that >I have fixed and am in the process of releasing (very soon hopefully) but >don't know about that one. > >J > >> From: "Júlio Dinis Silva" <[EMAIL PROTECTED]> >> Date: Tue, 19 Sep 2000 18:19:36 WEST >> To: [EMAIL PROTECTED] >> Cc: [EMAIL PROTECTED] >> Subject: Re: [Zope] Zope 2.2.2 breaks zdiscussions >> >>> From: "J. Atwood" <[EMAIL PROTECTED]> >>> To: Júlio Dinis Silva <[EMAIL PROTECTED]> >>> Subject: Re: [Zope] Zope 2.2.2 breaks zdiscussions >>> Date: Tue, 19 Sep 2000 12:53:24 -0400 >>> >>> Ahh.. what version of Zope did you go from? >> >> I use zdiscussions with no problems since zope 2.0.0 to 2.2.0. >> I didnt test it with (zope>220 and zope<222). Now I'm testing it >> with 222 and for the first time its broken. >> >> -- Júlio Dinis Silva >> _ >> Get Your Private, Free E-mail from MSN Hotmail at http://www.hotmail.com. >> >> Share information about yourself, create your own public profile at >> http://profiles.msn.com. >> >> > > >___ >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 ) ___ 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] How to Pass values to a DTML method ??
enclose the expression in quotes and you're happy: phil *** REPLY SEPARATOR *** On 11.09.2000 at 09:01 Stuart Foster wrote: >I have a DTML method that is called from a document. I need to pass a value >to it like a parameter would be passed to a function. > > > >Thanks > > >___ >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 ) ___ 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 )
[Zope] ZClasses - Base classes
I know that one cannot change the base classes of a ZClass after it has een created, but my question: How can I just find out / enmerate the base classes of a ZClass? thanks phil
Re: [Zope] Renderable Base Class ???
uncompresses fine, even with winzip7. perhaps a transfer error. version 0.2 is 617 bytes long, check that and download again phil *** REPLY SEPARATOR *** On 05.09.2000 at 09:11 Brian Withun wrote: >I'd read some discussion dating back to last year about a the concept of a >Renderable Base ZClass; something that would allow a ZClass to be called >like > >Have there been any developments along this line, or any plans to >incorporate the idea into Zope? I find myself in need of this >functionality. > >Also, I did notice a product on Zope.org which claims to be a renderable >base class, but it's a tgz and doesn't seem to uncompress for me on WinNT >using WinZip7. Does anybody have a copy of this (working) that they might >export and send? (It's a very small TGZ product and hopefully a very small >zexp) > > >Brian Withun > > >___ >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 ) ___ 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] PyWinTypes15.dll not found
This dll exists in in the Zope tree in the directories bin and bin\lib\win32. unfortunately none of these is in the PYTHONPATH. Remedy: copy PyWinTypes15.dll into one of the directories where it searches for ( e.g. in your case C:\programs\ZopeDev\lib\python\Products\LocalFS) or change the start.bat so that PythonPath also points to these directories phil *** REPLY SEPARATOR *** On 04.09.2000 at 08:58 Jean Jordaan wrote: >Hi Zopers .. > >I've installed Zope to start as a service. It seems to work perfectly >fine, but I notice messages like the following in the eventlog:: > >2000/09/02 10:25:36Application Popup Information None >26 N/A >JEAN Application popup: python.exe - Unable To Locate DLL : The >dynamic >link library PyWinTypes15.dll could not be found in the specified path >C:\programs\ZopeDev\lib\python\Products\LocalFS; >.; >C:\WINNT\System32; >C:\WINNT\system; >C:\WINNT; >C:\Perl\bin\; >C:\WINNT\system32; >C:\WINNT; >C:\WINNT\System32\Wbem; >C:\Program Files\Network Associates\PGPNT; >C:\Program Files\Resource Pro Kit\; >c:\programs\vim\vim57; >C:\programs\NcFTP; >c:\cygwin\bin; >c:\cygwin\usr\bin. > >(I broke the path into separate lines for clarity.) Now, when I >examine the environment variables thru >'Control Panel|System|Advanced|Environment Variables', Zope does not >feature. I also don't notice anything untoward when I examine the >registry. The registry entry that starts Zope seems to be:: > >REGEDIT4 > >[HKEY_LOCAL_MACHINE\SYSTEM\ControlSet002\Services\ZopeDev] >"Type"=dword:0010 >"Start"=dword:0002 >"ErrorControl"=dword:0001 >"ImagePath"="C:\\Programs\\ZopeDev\\bin\\lib\\win32\\PythonService.exe" >"DisplayName"="Zope (ZopeDev)" >"ObjectName"="LocalSystem" >@="" > >[HKEY_LOCAL_MACHINE\SYSTEM\ControlSet002\Services\ZopeDev\Parameters] >"start"="\"C:\\programs\\ZopeDev\\bin\\python.exe\" >\"C:\\programs\\ZopeDev\\z2.py\" -S" > >[HKEY_LOCAL_MACHINE\SYSTEM\ControlSet002\Services\ZopeDev\PythonClass] >@="C:\\programs\\ZopeDev\\ZServer\\ZService.ZServerService" > >[HKEY_LOCAL_MACHINE\SYSTEM\ControlSet002\Services\ZopeDev\Security] > >"Security"=hex:01,00,14,80,a0,00,00,00,ac,00,00,00,14,00,00,00,30,00,00,00,0 >2,\ > >00,1c,00,01,00,00,00,02,80,14,00,ff,01,0f,00,01,01,00,00,00,00,00,01,00,00,\ > >00,00,02,00,70,00,04,00,00,00,00,00,18,00,fd,01,02,00,01,01,00,00,00,00,00,\ > >05,12,00,00,00,4f,00,47,00,00,00,1c,00,ff,01,0f,00,01,02,00,00,00,00,00,05,\ > >20,00,00,00,20,02,00,00,4f,00,4e,00,00,00,18,00,8d,01,02,00,01,01,00,00,00,\ > >00,00,05,0b,00,00,00,20,02,00,00,00,00,1c,00,fd,01,02,00,01,02,00,00,00,00,\ > >00,05,20,00,00,00,23,02,00,00,4f,00,4e,00,01,01,00,00,00,00,00,05,12,00,00,\ >00,01,01,00,00,00,00,00,05,12,00,00,00 > >(This also occurs as >[HKEY_LOCAL_MACHINE\SYSTEM\ControlSet001\Services\ZopeDev] >except that the 'ControlSet001' version has an additional key, 'Enum':: > >[HKEY_LOCAL_MACHINE\SYSTEM\ControlSet001\Services\ZopeDev\Enum] >"0"="Root\\LEGACY_ZOPEDEV\\" >"Count"=dword:0001 >"NextInstance"=dword:0001 > >Now for the questions: > > - What is the difference between the 'ControlSet002' version and the > 'ControlSet001' version? > > - How and where does 'LocalFS' get into the path? > > - Why isn't 'C:\programs\ZopeDev\bin\lib\win32\PyWinTypes15.dll' > found? > > - What, for that matter, is the difference between *that* > PyWinTypes15 and this one: > 'C:\programs\ZopeDev\bin\PyWinTypes15.dll'? > >Any answers sorely appreciated! > >Regards, >-- >Jean Jordaan --technical writer-- >Mosaic Software--Zope 2.1.6 on WinNT and W2K > >___ >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 ) ___ 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] Oracle DB Connection
Did you also build the *DCOracle* package that is needed by the ZOracleDA? you have to exactly follow the build instructions that come with this package. When you have built it there are two shared libraries: Buffer.so and oci_.so. Your traceback says that Buffer cannot be imported, that means python cannot find Buffer.so Solution: 1. Build the DCOracle package 2. You have to check that the two .so files are to the *lib/python1.5/site-packes* directory under your Zope main directory Good luck Philipp Auersperg (zwork) *** REPLY SEPARATOR *** On 02.09.2000 at 15:23 Coleman, Bryan wrote: >I have tried to install the ZOracleDA product for Zope and there is a little >broken box to the product listing which I am assuming meens it is not >working. I also get an error that says. > >ZOracleDA Import Traceback >Traceback (innermost last): > File "C:\PROGRA~1\QUESTC~1\lib\python\OFS\Application.py", line 396, in >import_products >product=__import__(pname, global_dict, global_dict, silly) > File "C:\PROGRA~1\QUESTC~1\lib\python\Products\ZOracleDA\__init__.py", >line 91, in ? >import DA > File "C:\PROGRA~1\QUESTC~1\lib\python\Products\ZOracleDA\DA.py", line 91, >in ? >from db import DB > File "C:\PROGRA~1\QUESTC~1\lib\python\Products\ZOracleDA\db.py", line 89, >in ? >import DCOracle, DateTime > File >"C:\PROGRA~1\QUESTC~1\lib\python\Products\ZOracleDA\DCOracle\__init__.py", >line 52, in ? >import sys, Buffer >ImportError: No module named Buffer > >I am using Zope 2.2.1, is there another module I should be using or is this >the right one? > >- Bryan Patrick Coleman > Questcon Technologies > (336)273-2428 ext-416 > [EMAIL PROTECTED] > > > >___ >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 ) ___ 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] Re: HappySession
Hi! I do not have any reference to HappySession in my headers. I enclosed the session.set(..) in in order to catch the SessionNotFoundError, your slution just tests if the item exists in the session but does it prevent from the SessionNotFoundError exception? thanks phil *** REPLY SEPARATOR *** On 01.09.2000 at 08:15 Hung Jung Lu wrote: >>From: "Philipp Auersperg" <[EMAIL PROTECTED]> >> >>I also use HappySession and when catching the SessionNotFoundError >>weird things happen: >>here my code: >> >> >> >> >>session error! >> >> >>When the session is expired the error is not caught correctly and I get the >>error mentioned below. Plus, I have to restart my server because ZODB >>reports a transactional error and sets itself to read-only. > >I would guess you have the same problem as Diego Rodrigo... could you check >your standard_html_header? Does it make any reference to SESSION? > >One thing about HappySession is that I made it so no initialization is >required. So please do not call SESSION object in standard_html_header to >initialize it. (In the next release I'll make it safe even if someone calls >it in standard_html_header.) > >I will try to guess what you want to do: you want to initialize FLinkID at >the beginning of the session? If so, since HappySession's dictionary does >not require initialization, you can do something like: > > > > >... normal operation here ... > > >(If an item does not exist, SESSION['FLinkID'] returns ._None) > >regards, > >Hung Jung > >_ >Get Your Private, Free E-mail from MSN Hotmail at http://www.hotmail.com. > >Share information about yourself, create your own public profile at >http://profiles.msn.com. > > >___ >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 ) ___ 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] Wish for the next Zope Release: Doc tab for every Zope entity
Is DC planning to do something in that matter? also the docstring should perhaps not be just one property, but structured (author,parameters,prerequisites...) as it is in javadoc (ok, we don't like java, but thats a point where we can learn from java) The next point: if there is a 'Documentation' tab then every Zope developer is leaded to document his code. ( DTML is not always simple to read for other people except the author ;-) just my 2 cents... phil *** REPLY SEPARATOR *** On 01.09.2000 at 08:16 Chris McDonough wrote: >I agree that instances of DTML methods, DTML documents, SQL methods, >Python methods, objects based on ZClasses, etc. should have "docstring" >capabilities in some sort of common-denominator fashion. > > is the only way this can be done for DTML methods. > >The other objects can have properties, which could be documentation. > >-Original Message- >From: Philipp Auersperg [mailto:[EMAIL PROTECTED]] >Sent: Friday, September 01, 2000 6:23 AM >To: [EMAIL PROTECTED] >Subject: [Zope] Wish for the next Zope Release: Doc tab for every Zope >entity > > >Mostly when developing a project it should be documented as well :) >The best would be a strucutral documentation that can be generated >out of the project so that it always keeps track of the software and is >up to date > >- Python has that because there are the doc strings for classes and >methods >- Java has it (javadoc) >- Zope - ? > >For Zope it would be fine if every entity in the ODB has a >'Documentation' tab >So I could when developing a Zope site always on the fly document its >structure >without having to leave y developing environment. > >Then its an easy thing to write a doc generator that queries the objects >in the ODB >and their documentation. > >Did I miss something and such a beast exists or is there really >something to be done? >I don't mean documentation in , I mean documentation as >seperate >property for each object and method. > >Philipp Auersperg (zwork) ___ 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] Re: HappySession
I also use HappySession and when catching the SessionNotFoundError weird things happen: here my code: session error! When the session is expired the error is not caught correctly and I get the error mentioned below. Plus, I have to restart my server because ZODB reports a transactional error and sets itself to read-only. thanks Philipp Auersperg (zwork) --- Zope Error Zope has encountered an error while publishing this resource. Error Type: KeyError Error Value: SessionUID --- and the traceback: Traceback (innermost last): File /usr/local/Zope-2.1.4-linux2-x86/lib/python/ZPublisher/Publish.py, line 214, in publish_module File /usr/local/Zope-2.1.4-linux2-x86/lib/python/ZPublisher/Publish.py, line 179, in publish File /usr/local/Zope-2.1.4-linux2-x86/lib/python/Zope/__init__.py, line 202, in zpublisher_exception_hook (Object: ElementWithAttributes) File /usr/local/Zope-2.1.4-linux2-x86/lib/python/ZPublisher/Publish.py, line 169, in publish File /usr/local/Zope-2.1.4-linux2-x86/lib/python/ZODB/Transaction.py, line 275, in commit File /usr/local/Zope-2.1.4-linux2-x86/lib/python/Shared/DC/ZRDB/TM.py, line 120, in tpc_finish (Object: TM) File /usr/local/Zope-2.1.4-linux2-x86/lib/python/Products/HappySession/HappySession.py, line 168, in _finish (Object: TM) File /usr/local/Zope-2.1.4-linux2-x86/lib/python/Products/HappySession/HappySession.py, line 291, in _onTransactionEnded (Object: SESSION) File /usr/local/Zope-2.1.4-linux2-x86/lib/python/Products/HappySession/HappySession.py, line 255, in _store (Object: SESSION) KeyError: (see above) *** REPLY SEPARATOR *** On 31.08.2000 at 19:03 Hung Jung Lu wrote: >My conjecture now is that your error-handling HTML might be accessing >attributes from Zope server. A more correct way of handling exceptions >should have been using the .. block. >But I kind of make a cheat sheet recipe recommendation, tweaking the >standard_error_message, which was not a good idea. When Zope arrives to >standard_error_message, the transaction has been aborted and if your >session_not_found_html is not simple enough and uses more DTML features, I >can see that it can cause transaction error. > >Can you send me your session_not_found_html? I think this was the problem. > >In the future I will remove the standard_error_message trick from the help >file and instead tell people to use proper exception handling, which is the >right way of doing things. But it will require people to structure their >sites more carefully so they can catch the SessionNotFound exception. >Basically, it is recommended that you have single (or few) index_html on >your site, and place a .. block to >capture all exceptions from Zope and deal with them. It's the right way of >doing things, it's just that many people tend to have many index_html and it >will make their site harder to catch exceptions and deal with them in a >centralized way. > >In short, HappySession itself is probably not the cause of the transaction >error. The problem probably comes from bad exception handling. If you want >to use the standard_error_message trick, then please use a simple html page >for session_not_found_html without additional Zope features. If I find out >more, I'll let you know. > >regards, > >Hung Jung > >_ >Get Your Private, Free E-mail from MSN Hotmail at http://www.hotmail.com. > >Share information about yourself, create your own public profile at >http://profiles.msn.com. > > >___ >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 ) ___ 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 )
[Zope] Wish for the next Zope Release: Doc tab for every Zope entity
Mostly when developing a project it should be documented as well :) The best would be a strucutral documentation that can be generated out of the project so that it always keeps track of the software and is up to date - Python has that because there are the doc strings for classes and methods - Java has it (javadoc) - Zope - ? For Zope it would be fine if every entity in the ODB has a 'Documentation' tab So I could when developing a Zope site always on the fly document its structure without having to leave y developing environment. Then its an easy thing to write a doc generator that queries the objects in the ODB and their documentation. Did I miss something and such a beast exists or is there really something to be done? I don't mean documentation in , I mean documentation as seperate property for each object and method. Philipp Auersperg (zwork)
Re: [Zope] Newbie SQL problem: Query Error: Cannot render query template
When starting Zope as a service under Win NT always make sure that the ODBC data sources you use are *system* data sources and not *user* data sources. This could explain why your ODBC connections work when you start Zope from the console and don't work when starting it as service. Anyhow: Zope 2.1.6 is not the best for SQL (problems with recordsets show up when used in ) Zope 2.2.0 has problems with ZODBC under Windows 2000 (Authorisation dialogs pop up). My hint: Use 2.1.4 or 2.2.1 (does it fine with SQL under Linux and Windows ) phil *** REPLY SEPARATOR *** On 31.08.2000 at 06:40 Stephen Nosal wrote: >Troy- > >Have you tried running this from the DOS prompt? I ran into all sorts of problems >running 2.1.6 on NT4WS with the ODBCDA. Everything was fine when I used the start and >stop scripts from the command line. When I moved to starting zope as a service, my >ODBC connections kept failing. Never did find an NT solution, I just moved everything >to Linux. > >It's worth a try. > >- Steve > >On Wed, 30 August 2000, "Farrell, Troy" wrote: > >> >> Hello. >> >> I am running Zope as a service on NT4WS. I have multiple MS Access >> databases connected to different ZJetDAs and I am not able to modify the >> data in them with SQL statements. For example, INSERT INTO test VALUES >> (, ) >> returns the error "Query Error: Cannot render query template". Can you tell >> me what the cause is. I think it might be a permissions problem, but I have >> everything wide open and I can't figure it out. >> >> Thanks. >> Troy Farrell >> >> Troy Farrell >> Video Operations Technician II >> Williams VYVX Services >> 918.573.3029 >> 918.573.1441 fax >> mailto:[EMAIL PROTECTED] >> http://www.williams.com >> >> >> ___ >> 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 ) > > >__ >Get your Private, Anti-Spam, Free Email at http://e3mil.com >and Step into a Friendly Universe! > >___ >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 ) ___ 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 )
[Zope] Z Database Connections - pass uid/pwd to RDB
When you create a Z database connection you must supply a fixed connection string with a fixed uid/pwd to open that connection. So every user that connects to Zope connects with the fixed uid/pwd to the relational database. Is there any way or workaround to dynamically pass the Zope uid/password to the relational database? This is important when user security is maintained by the database scheme. Not that I really want this feature for my use but we have projects where the customer has the database model ready and wants the users to be individually authenticated at the relational database (in this case: Oracle). thanks Philipp Auersperg(zwork)
Re: [Zope] SSL and PGP
Sounds interesting, I ve checked out M2Crypto (downloaded it and checked the files but no install), it patches Medusa and ZServer in order to handle HTTPS, so Zope itself becomes a SSL enabled server without needing a proxy or gateway. But modifications to Zope's core components such as Medusa seem risky to me as long as Digital Creations don't integrate them into the official release, because every update to a new Zope release can become a horror trip when the SSL patches clash with the new Zope version. Are there any plans by DC to do something in that matter? Philipp Auersperg (zwork) *** REPLY SEPARATOR *** On 29.08.2000 at 19:39 R. David Murray wrote: >On Tue, 29 Aug 2000, Diego Rodrigo Neufert wrote: >> Anyone know how to send a pgp cryped email in zope? (using or >> anything else) >> >> and >> >> How to run a SSL server with ZServer? > >Search for M2Crypto on zope.org. It does both. > >--RDM > > >___ >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 ) ___ 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] calling (SQL) methods dynamically from External methods
Thanks for the answer, it helped me, but you missed what I really wanted. I don't want to call SQL queries by query string, what I want is to use Z SQL Methods, but I need to identify them by their name as string, because in this project we have many complicated queries with parameters. But finally I am happy because that works: m1=getattr(self,'dbTest') #dbTest is a ZSQL method rs=m1(self) for r in rs: ... Thanks Philipp Auersperg(zwork) *** REPLY SEPARATOR *** On 21.08.2000 at 13:32 Andrew Kenneth Milton wrote: >+---[ Philipp Auersperg ]-- >| >| What I want to do is calling a SQL method given its >| name as string, so I first have to get the method out of >| the self.__dict__ and then call it. I need that for calling >| the SQL methods dynamically for example out of an URL >| string. > >realConnection=getattr(self,connectionId) >realConnection().query(query_in_a_string) > >-- >Totally Holistic Enterprises Internet| P:+61 7 3870 0066 | Andrew Milton >The Internet (Aust) Pty Ltd | F:+61 7 3870 4477 | >ACN: 082 081 472 ABN: 83 082 081 472 | M:+61 416 022 411 | Carpe Daemon >PO Box 837 Indooroopilly QLD 4068|[EMAIL PROTECTED]| ___ 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] SQL trees...
Which Zope version do you use ? When I read your message I have a deja-vu: I encountered the same output when I use SQL based trees under Zope 2.1.6, it is a bug somewhere in the SQL method handling that appeared in 2.1.6 and is fixed in 2.2.0. Solution: switch back to 2.1.4 or forward to 2.2.0 or patch the existing 2.1.6 Philipp Auersperg (zwork) *** REPLY SEPARATOR *** On 21.08.2000 at 16:43 Mayers, Philip J wrote: >Excellent. That answers that. > >I'm loath to ask this, since it's supposedly a FAQ, but I'm having trouble >with the tree... > >Following: > >http://www.zope.org/Members/anthony/tree-coding-tricks > >I've got: > > > > > > > >The SQL query is working - "test"ing network_children will give the correct >hierarchy. However, the tree generated looks like this: > >192.168/16 > 192.168/16 >192.168/16 >10/8 >172.20/16 > 10/8 >192.168/16 >10/8 >172.20/16 > 172.20/16 >192.168/16 >10/8 >172.20/16 >10/8 > > >Basically, the tree only seems to ever contain the top-level (children of >the root of the tree). The children of all the nodes is... another copy of >the root top-level nodes! Whu?!? A search for several variations of "SQL >tree" in all the relevant list/site archives didn't seem to help. Any ideas? > >Regards, >Phil > >+--+ >| Phil Mayers, Network Support | >| Centre for Computing Services| >| Imperial College | >+--+ > >-Original Message- >From: Chris Withers [mailto:[EMAIL PROTECTED]] >Sent: 21 August 2000 15:23 >To: Mayers, Philip J >Cc: '[EMAIL PROTECTED]' >Subject: Re: [Zope] dtml-let and quoting(?) or forcing to string > > >"Mayers, Philip J" wrote: >> >> >> >> >> > >Anything in a DTML tag that's inside "" is python, usually ;-) > >So, your dtml-let should be: > > >which is kinda yucky, don't you think? > >cheers, > >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 ) > >___ >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 ) ___ 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 )
[Zope] calling (SQL) methods dynamically from External methods
What I want to do is calling a SQL method given its name as string, so I first have to get the method out of the self.__dict__ and then call it. I need that for calling the SQL methods dynamically for example out of an URL string. The problem: -- when I call the method like that it does not find its database connection, it seems that it cannot access other members of 'self' When I call the SQL Method directly everything works (see full example below after the line) Interesting fact: When retrieving the method object with "m=self.dbTest" and then with "m1=self.__dict__['dbTest']" "print m,m1" show the same string but "m==m1" results to false! What am I doing wrong? There seems something mixed up with namespaces, but I am too solly to solve it :( any help appreciated Philipp Auersperg (zwork) --- def callSQLMethod(self,REQUEST): m1=self.__dict__['dbTest'] #get method via dict , #dbTest is a normal Z SQL method like 'select * from test' # it uses the db connection 'mysql_test' rs=m1(self)#then the called method #does not find the database #connection full example def callSQLMethod(self,REQUEST): rs=self.dbTest()#normal call, works - of course m=self.dbTest #first get method, then call it rs=m(self) #that works too m1=self.__dict__['dbTest'] #get method via dict print 'Methods',m,m1,m==m1 #m and m1 print the same #name but are not equal!! rs=m1(self) #then the called method #does not find the database #connection - Error message: The database connection mysql_test cannot be found. Traceback (innermost last): File /usr/local/Zope-2.1.4-linux2-x86/lib/python/ZPublisher/Publish.py, line 214, in publish_module File /usr/local/Zope-2.1.4-linux2-x86/lib/python/ZPublisher/Publish.py, line 179, in publish File /usr/local/Zope-2.1.4-linux2-x86/lib/python/Zope/__init__.py, line 202, in zpublisher_exception_hook (Object: ElementWithAttributes) File /usr/local/Zope-2.1.4-linux2-x86/lib/python/ZPublisher/Publish.py, line 165, in publish File /usr/local/Zope-2.1.4-linux2-x86/lib/python/ZPublisher/mapply.py, line 160, in mapply (Object: callSQLMethod) File /usr/local/Zope-2.1.4-linux2-x86/lib/python/ZPublisher/Publish.py, line 102, in call_object (Object: callSQLMethod) File /usr/local/Zope-2.1.4-linux2-x86/lib/python/Products/ExternalMethod/ExternalMethod.py, line 248, in __call__ (Object: callSQLMethod) (Info: ((, formcookiestree-seJyLjlZ3hANPW3UdhWgkEXdXdJFQA1v1WDAAAK2tDwAsql_pref__cols80dtpref_cols65sql_pref__rows20dtpref_rows15otherBASE5http://192.7.2.21:8080/Test/Stream/getRecords/callSQLMethodAUTHENTICATION_PATHsql_pref__rows20dtpref_rows15BASE3http://192.7.2.21:8080/Test/StreamURL3http://192.7.2.21:8080/TestURL0http://192.7.2.21:8080/Test/Stream/getRecords/callSQLMethodBASE1http://192.7.2.21:8080URL2http://192.7.2.21:8080/Test/StreamURL4http://192.7.2.21:8080BASE0http://192.7.2.21:8080URL1http://192.7.2.21:8080/Test/Stream/getRecordsSERVER_URLhttp://192.7.2.21:8080tree-seJyLjlZ3hANPW3UdhWgkEXdXdJFQA1v1WDAAAK2tDwAURLhttp://192.7.2.21:8080/Test/Stream/getRecords/callSQLMethodAUTHENTICATED_USERphilBASE2http://192.7.2! .21:8080/Testdtpref_co valign="top" align="left">sql_pref__cols80BASE4http://192.7.2.21:8080/Test/Stream/getRecordsURL0http://192.7.2.21:8080/Test/Stream/getRecords/callSQLMethodURL1http://192.7.2.21:8080/Test/Stream/getRecordsURL2http://192.7.2.21:8080/Test/StreamURL3http://192.7.2.21:8080/TestURL4http://192.7.2.21:8080BASE0http://192.7.2.21:8080BASE1http://192.7.2.21:8080BASE2http://192.7.2.21:8080/TestBASE3http://192.7.2.21:8080/Test/StreamBASE4http://192.7.2.21:8080/Test/Stream/getRecordsBASE5http://192.7.2.21:8080/Test/Stream/getRecords/callSQLMethodenvironHTTP_ACCEPT_ENCODINGgzip, deflatechannel.creation_time966817971SERVER_PROTOCOL1.1SERVER_PORT8080PATH_INFO/Test/Stream/getRecords/callSQLMethodHTTP_HOST192.7.2.21:8080REQUEST_METHODGETPATH_TRANSLATED/Test/Stream/getRecords/callSQLMethodHTTP_COOKIEdtpref_rows="15"; dtpref_cols="65"; sql_! pref__rows="20&q
Re: [Zope] Ivalid Integer from Zope
I will fix this for the next release (est. next week). This happens when nothing is entered in the textfield for the integer value. In the meanwhile you have to do the check in the insert/update SQL method: null *** REPLY SEPARATOR *** On 13.08.2000 at 10:31 Herring, William O. wrote: >I am using the Znolk Input Wizzard with postgresql tables. One of the >variables in the table is an integer and can have null values. However, in >the update and insert forms, if I attempt to leave the value null, I get the >following error from Zope: > >"Invalid integer value for weight.bcs" > > >The variable is defined throughout as : > >Any help would be appreciated. > >___ >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 ) ___ 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] Parameter in ZSQL
call : with you just define a variable in the current namespace Philipp Auersperg (zwork) *** REPLY SEPARATOR *** On 13.08.2000 at 17:27 Indra Gunawan wrote: >Hello All >here's the problem >my Zope 2.2.0 is running on win98 >my Database is a MySQL > >I created a ZSQL method named ShowProduct with parameter product_id > >the template as follows : select * from products where type=string> > >why can't I call the ZSQL method directly (without using the GET/POST >variables)? >I try to call it like this > > > >...(i would like to insert some of programs here if this is working) > > > > >it always returns error like this >Error Type: Bad Request >Error Value: ['product_id'] > >can anyone help please? is there any workaround for this? >TIA > >-IGUN- >ICQ:1474584 > > > > >___ >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 ) ___ 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 )
[Zope] RESPONSE.write() slow
I want to be able to download dynamic content (coming from a relational database) via Zope as a file. I do this by calling RESPONSE.write() which works fine but it is very slow When I download a greater package with an External method (on the bottom of the mail), I just get downloads of 3 to 12 KB/s in my LAN and even locally on the same machine. Also the thread sending the data uses >90% CPU. Can anybody tell me why it is so slow or how I can speed that up? I am using a standalone Zope 2.2.0 with standard ZServer Thanks in advance Philipp Auersperg def streamTest(self,RESPONSE): RESPONSE.setHeader('Content-Type','text/richtext') i=0 while i< 10: RESPONSE.write('hallo') i=i+1 RESPONSE.close() ___ 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 )
[Zope] Using Zope as App Server for non http-Protocols
We want to (mis)use zope as an application server servicing a proprietary non-http protocol for transmitting compressed data. Our idea is a specially written client that connects on a proprietary port to zope where a special product is listening and serving the request. Our question: How can I implement a product listening on a specific port and servicing requests and sending back binary (in our case compressed) data. But the product should of course be able to use the infrastructure of Zope (ODB,External methods,ZSQL methods...) Another question is how does the authentification work for such a non-http connection. Any hints? Thanks in advance Philipp Auersperg
Re: [Zope] Znolk - Not recognizing ODBC
I just checked Znolk and ODBC - it works correctly (I checked that with Win 2k, NT4 on different machines with Zopes >= 2.1.4, Oracle and MSSQL ODBC drivers ) check the following: - Have you verified that you have a valid ZODBC database connection in the scope of your actual folder ( you can check that with for example a Z Search interface ) - clear the browser's cache (memory and disk) , do a refresh - uuhrg, last try with restarting Zope If nothing helps: feed me with more information, I am sure that I can help you with that Philipp Auersperg (zwork) *** REPLY SEPARATOR *** On 27.07.2000 at 16:47 Jim Sanford wrote: >I have downloaded the latest Znolk which claims to now support the Z ODBC DA. When I >try to run the Znolk wizard it tells me I have >no DB connections when I do. > >Any suggestions? > > __ > > Jim Sanford > . Database Engineer > / \ / Accelerated Technology, Inc. >/ / 720 Oak Circle Drive East > / / \Mobile, AL 36609 > / / \ Voice: 334-661-5770 fax: 334-661-5788 > / \ E-Mail: [EMAIL PROTECTED] > Web: http://www.atinucleus.com > > Nucleus. All You NEED in an RTOS. Royalty Free > __ > > > > >___ >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 ) ___ 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 )
[Zope] Zope stability problems under Linux SuSe 6.4 (Kernel 2.2.14)
Quite regularily I encounter stability problems with Zope: Suddenly without heavy use My Zope process rises the below mentioned error message and then does not accept any IP connections and must be manually stopped and restarted. These lockups happen under SuSe 6.4, I can reproduce it on two different machies : - celeron 400 MHz single processor 256 MB and - Pentium III 650 MHz dual processor 256 MB Also the seem to be independent of the Zope version ,I encountered them with the versions 2.1.4, all 2.2.0 betas 2.2.0 release The problems happen with standard config and with multiple threads (-t 10 option) --2000-07-27T14:58:02 ERROR(200) ZServer uncaptured python exception, closing channel (exceptions.TypeError:unpack non-sequence [/usr/local/Zope-2.1.4-linux2-x86/ZServer/medusa/asyncore.py|poll|59] [/usr/local/Zope-2.1.4-linux2-x86/ZServer/medusa/asyncore.py|handle_read_event|285] [/usr/local/Zope-2.1.4-linux2-x86/ZServer/medusa/http_server.py|handle_accept|609] ) -- Any hints? it's quite annoying, I dont want to run Zope under Windows (it runs stable there). I have no clue because I did not fiddle around in the Zope source nor in the Linux kernel (2.2.14), but considering that zope.org runs under linux there must be a solution thanks in advance Philipp Auersperg (zwork)
Re: [Zope] Announcement: Znolk 0.1.1
Thanks, due to a renaming the link was broken, I have fixed that now phil *** REPLY SEPARATOR *** On 25.07.2000 at 11:01 Jim Tittsler wrote: >On Sun, Jul 23, 2000 at 02:07:39PM +0200, Philipp Auersperg wrote: >> I've uploaded Znolk 0.1.1 to http://www.zope.org/Members/zwork with minor >> bug fixes and added support for ZPoPy connections. > >The link to Znolk on that page appears to be broken. > >Jim > >-- >Jim Tittsler, Tokyo >Python Starship http://starship.python.net/crew/jwt/ ___ 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 )
[Zope] Announcement: Znolk 0.1.1
I've uploaded Znolk 0.1.1 to http://www.zope.org/Members/zwork with minor bug fixes and added support for ZPoPy connections. Important hint: At the third screen of the wizard where you select the columns you MUST select at least one column as 'Primary key' because Znolk needs the PK to identify the record to be edited. Otherwise you get the following error message when clicking the 'edit' link in the BrowseReport: Error Type: OperationalError Error Value: ERROR: parser: parse error at or near "" Philipp Auersperg ___ 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 )