Re: [Zope3-Users] Zope3-users Digest, Vol 71, Issue 5
Hello David, Install a C compiler. Thursday, October 21, 2010, 6:26:28 PM, you wrote: da Hi Toni and others, da Yes zope list is quite silent unlike other open source projects. da I'm new to zope and have been having problems dealing with so many da versions available in zope. I finally settled to get acquainted da with zope 3, when i discovered that zope3 and bluebream are the da same thing even though nobody use bluebream to describe zope 3, da i'm interested in zope because the project i'm managing key da component is developed using zope 3. da Now can someone please clarify my assumption that zope and bluebream are the same platform? da Secondly, I have been following the tutorial on bluebream da available at da http://bluebream.zope.org/doc/1.0/gettingstarted.html, but i got da stuck at this point ./bin/buildout with this error; da (my_zope_env)da...@ubusvr101:/var/local/study/sampleproject$ sudo ./bin/buildout da Develop: '/var/local/study/sampleproject/.' da install_dir /var/local/study/sampleproject/develop-eggs/tmpvV1gjcbuild da Installing app. da Getting distribution for 'zope.security==3.7.3'. da install_dir /var/local/study/sampleproject/eggs/tmpUo9VBT da src/zope/security/_proxy.c:19: fatal error: Python.h: No such file or directory da compilation terminated. da error: Setup script exited with error: command 'gcc' failed with exit status 1 da An error occured when trying to install zope.security 3.7.3. Look da above this message for any errors that were output by easy_install. da While: da Installing app. da Getting distribution for 'zope.security==3.7.3'. da Error: Couldn't install: zope.security 3.7.3 da How do I resolve this ? da David da On Thu, Oct 21, 2010 at 5:00 PM, zope3-users-requ...@zope.org wrote: da Send Zope3-users mailing list submissions to dazope3-users@zope.org da To subscribe or unsubscribe via the World Wide Web, visit dahttps://mail.zope.org/mailman/listinfo/zope3-users da or, via email, send a message with subject or body 'help' to dazope3-users-requ...@zope.org da You can reach the person managing the list at dazope3-users-ow...@zope.org da When replying, please edit your Subject line so it is more specific da than Re: Contents of Zope3-users digest... da Today's Topics: da 1. z3c.form: small patch (Toni Mueller) da -- da Message: 1 da Date: Thu, 21 Oct 2010 15:47:16 +0200 da From: Toni Mueller support-...@oeko.net da Subject: [Zope3-Users] z3c.form: small patch da To: zope3-users@zope.org da Message-ID: 20101021134716.32278.qm...@oak.oeko.net da Content-Type: text/plain; charset=us-ascii da Hello, da since the zope3-dev list appears to be dead, and since I have no better da idea about where to put this, I send you a small patch for z3c.form da version 2.4.1. da Background: https://bugs.launchpad.net/singing-dancing/+bug/620608 da Users of SingingDancing in Plone need to detect whether z3c.form has da certain features. The patch adds a feature declaration to z3c.form. da --- configure.zcml.orig 2010-10-21 15:24:05.0 +0200 da +++ configure.zcml 2010-10-21 15:40:58.0 +0200 da @@ -1,6 +1,7 @@ da configure da xmlns=http://namespaces.zope.org/zope; da xmlns:i18n=http://namespaces.zope.org/i18n; da +xmlns:meta=http://namespaces.zope.org/meta; da i18n_domain=z3c.form da !-- default z3c.form layer -- da @@ -9,6 +10,8 @@ da type=zope.publisher.interfaces.browser.IBrowserSkinType da / da + meta:provides feature=z3c.form.checkbox-widget / da + meta:provides feature=z3c.form.radio-widget / da !-- Validators -- da adapter da It would be great if this patch could make it into the next version of da z3c.form, or into a small patch release. da Kind regards, da --Toni++ da -- da ___ da Zope3-users mailing list da Zope3-users@zope.org da https://mail.zope.org/mailman/listinfo/zope3-users da End of Zope3-users Digest, Vol 71, Issue 5 da ** -- Best regards, Adam GROSZERmailto:agros...@gmail.com -- Quote of the day: Froud's Law: A transistor protected by a fast acting fuse will protect the fuse by blowing first. ___ Zope3-users mailing list Zope3-users@zope.org https://mail.zope.org/mailman/listinfo/zope3-users
Re: [Zope3-Users] Accessing raw post data
Hello Edoardo, I think the simplest would be to make the upload a multipart/form-data, with some headers added if you can. Worst case putting the necessary text manually around the binary? Then it's a usual POST request what's easily parsed by zope. Otherwise it could be really nasty. Tuesday, August 24, 2010, 10:30:59 PM, you wrote: ES Hi Adam, ES thanks for your help, z3c.jsonrpc did what I was looking for. ES I now need to access the raw post data because I also have to deal with non JSON content. ES I'm handling a file upload through javascript and the file ES content is passed in the request body. ES Do you know how to handle that? ES Thanks ES Edoardo ES On Jul 22, 2010, at 11:02 AM, Adam GROSZER wrote: Hello Edoardo, You might be interested in z3c.json, z3c.jsonrpc. Especially z3c.jsonrpc, that should handle such requests with ease. Wednesday, July 21, 2010, 7:33:29 PM, you wrote: ES Hi guys, ES I need to access the body of an HTTP POST request. ES The request has content type of 'application/json' and the body is a JSON-encoded string. ES I tried to access the bodyStream attribute of the BrowserRequest object but it always returns an ES empty string. ES I used a network analyzer to see the content of the HTTP Request which follows: ES POST /facebook-realtime-callback.html HTTP/1.1 ES Host: www.satisfly.com ES Accept: */* ES Content-Type: application/json ES X-Hub-Signature: sha1=d2a5fd64c731bfdc50578db1a297b195853b5bac ES Content-Length: 173 ES {object:user,entry:[{uid:11314277196,changed_fields:[picture],time:1279728528},{uid:11314277196,changed_fields:[picture],time:1279728528}]} ES I'm using Zope 3.3.1 on debian etch ES Your help would be really appreciated ES Regards, ES Edoardo Serra ES SATISFLY Limited ES 66/F The Center ES 99 Queen's Road Central ES Hong Kong ES http://www.satisfly.com/airline ES ___ ES Zope3-users mailing list ES Zope3-users@zope.org ES https://mail.zope.org/mailman/listinfo/zope3-users -- Best regards, Adam GROSZERmailto:agros...@gmail.com -- Quote of the day: Nothing ever built arose to touch the skies unless some man dreamed that it should, some man believed that it could, and some man willed that it must. - Charles F. Kettering ES Edoardo Serra ES SATISFLY Limited ES 66/F The Center ES 99 Queen's Road Central ES Hong Kong ES http://www.satisfly.com/airline ES ___ ES Zope3-users mailing list ES Zope3-users@zope.org ES https://mail.zope.org/mailman/listinfo/zope3-users -- Best regards, Adam GROSZERmailto:agros...@gmail.com -- Quote of the day: There is no remedy for sex but more sex. ___ Zope3-users mailing list Zope3-users@zope.org https://mail.zope.org/mailman/listinfo/zope3-users
Re: [Zope3-Users] Accessing raw post data
Hello Edoardo, You might be interested in z3c.json, z3c.jsonrpc. Especially z3c.jsonrpc, that should handle such requests with ease. Wednesday, July 21, 2010, 7:33:29 PM, you wrote: ES Hi guys, ES I need to access the body of an HTTP POST request. ES The request has content type of 'application/json' and the body is a JSON-encoded string. ES I tried to access the bodyStream attribute of the BrowserRequest object but it always returns an ES empty string. ES I used a network analyzer to see the content of the HTTP Request which follows: ES POST /facebook-realtime-callback.html HTTP/1.1 ES Host: www.satisfly.com ES Accept: */* ES Content-Type: application/json ES X-Hub-Signature: sha1=d2a5fd64c731bfdc50578db1a297b195853b5bac ES Content-Length: 173 ES {object:user,entry:[{uid:11314277196,changed_fields:[picture],time:1279728528},{uid:11314277196,changed_fields:[picture],time:1279728528}]} ES I'm using Zope 3.3.1 on debian etch ES Your help would be really appreciated ES Regards, ES Edoardo Serra ES SATISFLY Limited ES 66/F The Center ES 99 Queen's Road Central ES Hong Kong ES http://www.satisfly.com/airline ES ___ ES Zope3-users mailing list ES Zope3-users@zope.org ES https://mail.zope.org/mailman/listinfo/zope3-users -- Best regards, Adam GROSZERmailto:agros...@gmail.com -- Quote of the day: Nothing ever built arose to touch the skies unless some man dreamed that it should, some man believed that it could, and some man willed that it must. - Charles F. Kettering ___ Zope3-users mailing list Zope3-users@zope.org https://mail.zope.org/mailman/listinfo/zope3-users
Re: [Zope3-Users] Zope 3.4.1 KGS released!
Hello Thierry, I think it is available: http://pypi.python.org/pypi/zope.configuration/3.4.1 Friday, June 25, 2010, 2:50:19 PM, you wrote: TF Le jeudi 24 juin 2010, TF Adam GROSZER agros...@gmail.com a écrit : TF == == Zope 3.4.1 Released! == June 22, 2010 - The Zope 3 development team announces the Zope 3.4.1 release. The 3.4.1 is the long awaited next bugfix version of 3.4.0. Major changes ~ - setuptools update to 0.6c11, so that it supports svn 1.6. - z3c.layer update to 0.2.4, which is a **SECURITY** fix. For details see the changelog. TF == TF Hi, TF I've tried to build a new zc.buildout based project this morning using TF Zope-3.4.1 versions.cfg as reference. TF I think there's a small problem with zope.configuration package, as TF release 3.4.1 mentionned in KGS is not available on Pypi... TF Hope this helps, TF Thierry -- Best regards, Adam GROSZERmailto:agros...@gmail.com -- Quote of the day: When Christ ascended; Triumphantly, from star to star, He left the gates of heaven ajar. - Henry Wadsworth Longfellow ___ Zope3-users mailing list Zope3-users@zope.org https://mail.zope.org/mailman/listinfo/zope3-users
Re: [Zope3-Users] threads, pool size and cache recommendations (quad core)
Hey Roy, I'd say put a small benchmark together that does the expected load and see which config performs better. I guess on the short run it's easier to get by with a single FileStorage and multiple threads, but on the long run maybe with more processes. Wednesday, December 16, 2009, 2:32:35 PM, you wrote: RM Hope this helps make things a bit clearer: RM Concurrent users: 100 RM Concurrent requests (worst case): 100 RM Concurrent writes: 1-2 per request RM Application: online quiz RM Data written: small updates (100 bytes, approximately) RM RM Thanks... I am just looking for some rough guidelines. RM On Wed, Dec 16, 2009 at 6:58 PM, Andreas Jung li...@zopyx.com wrote: RM RM -BEGIN PGP SIGNED MESSAGE- RM Hash: SHA1 RM RM schrieb Roy Mathew: RM Folks, I am looking for some configuration advice. I am running a zope3 application that uses the ZODB. I expect a peak load of a 100 concurrent users, and am on a *quad* core Intel Xeon Linux box. Am I better off running 2 or 3 ZEO clients talking to the app-server (I am assuming that the OS will load balance so that all processors are utilized well). Or should I not use ZEO at all, and simply assign a large cache, a large connection pool and lots of threads to a single process. I am sure that this is an issue many of you have had to contend with. I would appreciate some rough idea of what the numbers should be for each of the 2 scenarios I outline. RM RM RM You have to provide much more details like #concurrent users, RM #concurrent requests, #concurrent writes, reads, the nature of the RM application, RM kind of data etc. RM RM - -aj RM -BEGIN PGP SIGNATURE- RM Version: GnuPG v1.4.10 (Darwin) RM Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ RM RM iEYEARECAAYFAkso4IUACgkQCJIWIbr9KYxrTQCePlLWkkBhL4JmTIQuVWTh/BDO RM N08AnA9PX/JweJoEwJgwLQhj9DzEaW10 RM =Nczp RM -END PGP SIGNATURE- RM RM -- Best regards, Adam GROSZERmailto:agros...@gmail.com -- Quote of the day: True humility is not an abject, groveling, self-despising spirit; it is but a right estimate of ourselves as God sees us. - Tryon Edwards ___ Zope3-users mailing list Zope3-users@zope.org https://mail.zope.org/mailman/listinfo/zope3-users
Re: [Zope3-Users] unregister, delete and pack, still no gc?
Hey Roy, Can happen that BTrees keep deleted objects referenced, so they're not gc'ed. See https://bugs.launchpad.net/bugs/294788 Tuesday, December 23, 2008, 8:35:22 AM, you wrote: RM Hi Folks, RM I have either stumbled on a storage leak in the ZODB, or I am RM missing something in my understanding of registration. RM Briefly, if I add a folder to the ZODB, make it a site, then RM unregister it, delete it and pack the ZODB, I see the ZODB RM increase in size.Each time I run the tests, the ZODB keeps growing RM (by about 7KB). I restarted the ZODB to see if it would help, but no! RM Here are my exact steps: RM 1. add a Folder RM 2. make a the folder a site. RM 3. register the folder (unnamed utility of type ISite) RM 4. remove the registration from the registrations tab. RM 5. delete the folder. RM 6. pack the ZODB. RM I have also attached a selenium test that performs all of this. -- Best regards, Adam GROSZERmailto:agros...@gmail.com -- Quote of the day: I must do something will always solve more problems than Something must be done. - Unknown ___ Zope3-users mailing list Zope3-users@zope.org http://mail.zope.org/mailman/listinfo/zope3-users
Re: [Zope3-Users] thoughts about z3c.form-package
Hey Roger, Yes, you're right, thanks for the explanation. Wednesday, October 8, 2008, 3:32:04 PM, you wrote: RI Hi Tim, Adam Betreff: Re: [Zope3-Users] thoughts about z3c.form-package On Wed, 2008-10-08 at 06:25 +0200, Roger Ineichen wrote: Adam Groszer is working on a ObjectWidget implementation. What is the proposed functionality of ObjectWidget? RI The ObjectWidget is a widget for an IObject field. RI This field is used for attributes which provide a own RI schema and hold a refenece to a pyton instance RI providing this schema. (does this make sense?) RI Probably a sample explains it better. RI The attribute door in the sample below is an Object field. RI class IDoor(zope.interface.Interface): RI A cars door. RI color = zope.schem.TextLine( RI title=u'Color') RI class ICar(zope.interface.Interface): RI A car. RI door = zope.schem.Object( RI title=u'A cars door', RI schema=IDoor) RI ... RI The ObjectWidget is now responsible for render an input RI widgets in an EditForm for the color attribte of the door. RI Adam, is this correct? RI Regards RI Roger Ineichen Thanks, Tim -- Timothy Cook, MSc Health Informatics Research Development Services LinkedIn Profile:http://www.linkedin.com/in/timothywaynecook Skype ID == timothy.cook ** *You may get my Public GPG key from popular keyservers or * *from this link http://timothywayne.cook.googlepages.com/home* ** RI ___ RI Zope3-users mailing list RI Zope3-users@zope.org RI http://mail.zope.org/mailman/listinfo/zope3-users -- Best regards, Adam GROSZERmailto:[EMAIL PROTECTED] -- Quote of the day: She who loves roses must be patient and not cry out when she is pierced by thorns. - Brouman, Olga ___ Zope3-users mailing list Zope3-users@zope.org http://mail.zope.org/mailman/listinfo/zope3-users
Re: [Zope3-Users] thoughts about z3c.form-package
Hello Tim, Wednesday, October 8, 2008, 3:52:20 PM, you wrote: TC I am assuming, though haven't tried, that I can specify an interface TC that is maybe 3,4 or more steps through Object attributes and have the TC correct widget (text, textline, etc.) render? It should, but actually those 3,4 levels sound like you'd need some sort of subforms or even separated forms for those. (I say that without having a look at your interfaces) -- Best regards, Adam GROSZERmailto:[EMAIL PROTECTED] -- Quote of the day: All changes, even the most longed for, have their melancholy; for what we leave behind is a part of ourselves; we must die to one life before we can enter into another! - Anatole France ___ Zope3-users mailing list Zope3-users@zope.org http://mail.zope.org/mailman/listinfo/zope3-users
[Zope3-Users] zope.i18n.locales and currency
Hello, Which is the sane to format currencies? locale.numbers.getFormatter('currency').format(value) Holds something like: ¤1,000,000.00 Should I simply replace ¤ with the currency sign or is there a better way? -- Best regards, Adam GROSZER mailto:[EMAIL PROTECTED] -- Quote of the day: I believe that there are too many accommodating preachers... Jesus Christ did not say Go into the world and tell the world that it is quite right. The Gospel is something completely different. In fact, it is directly opposed to the world. - C.S. Lewis ___ Zope3-users mailing list Zope3-users@zope.org http://mail.zope.org/mailman/listinfo/zope3-users
Re: [Zope3-Users] Pure python packages for zope.component and zope.interface
Hello Darryl, I think zope.interface will work without the C stuff, those are just optimizations. Actually it should work with jython already. zope.proxy might not be so simple to get working without C. (Hopefully) there will be some GSoC projects that will bring the subject and your problem forward: - Porting zope 3 to jython: http://www.gossamer-threads.com/lists/zope/dev/213430 - Zope without ZODB Saturday, April 19, 2008, 1:43:19 AM, you wrote: DC Hi, DC The ZCA framework is developed as part of the Zope 3 project. As noted DC earlier, it is a pure Python framework, so it can be used in any kind of DC Python application. [1] DC I was hoping to try using ZCA for a googleappengine experiment. Using DC Ian Bickings post [2] I set up a environment to install zca packages. DC zope.interface and zope.proxy both have .so files that aren't usable in DC a gae project. (_zope_interface_coptimizations.so and DC _zope_proxy_proxy.so). From the quote above and other mentions on the web I gather that there DC exist pure-python ZCA packages. Could someone point me to where to find DC them? DC Best regards, DC Darryl DC [1] http://www.muthukadan.net/docs/zca.html DC [2] http://blog.ianbicking.org/2008/04/13/app-engine-and-pylons/ -- Best regards, Adam GROSZERmailto:[EMAIL PROTECTED] -- Quote of the day: Any fool can criticize, condemn, and complain - and most fools do. - Dale Carnegie ___ Zope3-users mailing list Zope3-users@zope.org http://mail.zope.org/mailman/listinfo/zope3-users
[Zope3-Users] Re[4]: [Zope-dev] testing a meta-egg
Hello Jim, Sounded like a good idea at first, but now you opened my eyes. I guess I'll stick with the manually added eggs for the tests. Thanks. Friday, April 4, 2008, 3:08:27 PM, you wrote: JF I wouldn't want anyone doing this who wasn't willing to spend the time JF becoming fairly familiar with the setuptools APIs. The full set of JF packages uses is described by the working set, which is available (or JF obtainable) to the recipe. To include tests of all dependencies, you JF would include each of the locations from the working set as test JF directories for the test t runner, being careful to avoid system JF packages -- unless you want to test all system packages on which you JF depend too. Even then, you could get into trouble, as individual JF package tests might not be runnable without additional facilities you JF don't have. For example, some packages might have test dependencies JF that you haven't included. There is no standard way of specifying JF test dependencies for installed distributions. JF In general, I find implicitly including packages for testing is JF fraught with peril. -- Best regards, Adam GROSZERmailto:[EMAIL PROTECTED] -- Quote of the day: Only God can make random selections. ___ Zope3-users mailing list Zope3-users@zope.org http://mail.zope.org/mailman/listinfo/zope3-users
Re: [Zope3-Users] Zope3 packages inside a standalone application
Hello Marco, I would say it won't hurt if you flatten the namespace. You might also try to add all required packages to the PYTHONPATH then hopefully py2exe will find them. Test it well, also with the exe built. Thursday, April 3, 2008, 8:33:02 AM, you wrote: MDF I'm using zope3 packages inside a standalone application. MDF I've found references that the zca package tree can be used outside of MDF zope, but I'm using also zope.wfmc and related (including zodb3). MDF To be able to build an exe file with py2exe I've flattened the namespace MDF of the packages I'm using, by copying them in my app folder recreating a MDF single zope namespace (py2exe doesn't support namespaces yet). MDF Is this kind of unusual zope3 packages use possible, or am I going to MDF have trouble with it being totally unsupported? MDF Please note that I'm not yet a zope3 expert and I didn't run tests on MDF this setup, but it seems to work. MDF Thanks MDF ___ MDF Zope3-users mailing list MDF Zope3-users@zope.org MDF http://mail.zope.org/mailman/listinfo/zope3-users -- Best regards, Adam GROSZERmailto:[EMAIL PROTECTED] -- Quote of the day: Things are more like they used to be than they are now. ___ Zope3-users mailing list Zope3-users@zope.org http://mail.zope.org/mailman/listinfo/zope3-users
[Zope3-Users] bsquare'ing
Hello, I'm trying to setup a buildbot here for our buildout based packages. What I don't get is, how that works: f.addStep(Compile(name='bootstrap', command='buildout bootstrap .', description=['bootstrapping'], descriptionDone=['bootstrap'])) We used to issue python2.4 bootstrap.py, buildout bootstrap . gives an error, unless I'm missing something. Also, I'd propose some enhancements too: -def configure(svn_url, http_port=8010, allowForce=False): +def configure(svn_url, svnuser=None, svnpasswd=None, http_port=8010,allowForce=False, poller=None): Creates a buildout master configuration. The configuration returned is almost functional. You just need to add slaves. c = {} c['slavePortnum'] = 8989 -c['change_source'] = SVNPoller(svn_url, split_file=split_file, pollinterval=30) +if poller: + c['change_source'] = poller +else: + c['change_source'] = SVNPoller(svn_url, svnuser=svnsuer, svnpasswd=svnpasswd, split_file=split_file, pollinterval=30) Christian, opinions? Where to make those changes? -- Best regards, Adam GROSZER mailto:[EMAIL PROTECTED] -- Quote of the day: Life is 10% of what happens to you and 90% of how you respond to it. ___ Zope3-users mailing list Zope3-users@zope.org http://mail.zope.org/mailman/listinfo/zope3-users
[Zope3-Users] Re[2]: [Zope-dev] bsquare'ing
Hello, It's real simple: in dir /home/agroszer/buildbot/slave/cache/build (timeout 1200 secs) watching logfiles {} argv: ['/bin/sh', '-c', 'buildout bootstrap .'] environment: ... closing stdin using PTY: True /bin/sh: line 1: buildout: command not found program finished with exit code 127 Thursday, April 3, 2008, 2:21:50 PM, you wrote: BY Adam GROSZER wrote: We used to issue python2.4 bootstrap.py, buildout bootstrap . gives an error, unless I'm missing something. BY I'm not familiar with Christian's work with bsquare, but suspect giving BY him the actual error message would be helpful. -- Best regards, Adam GROSZERmailto:[EMAIL PROTECTED] -- Quote of the day: If you want to know how old a man is, ask his brother-in-law. ___ Zope3-users mailing list Zope3-users@zope.org http://mail.zope.org/mailman/listinfo/zope3-users
Re: [Zope3-Users] Vocabulary, unicode
Hallo Katja, I would say that's because tokens are used in the widgets for item identification. Usual business is to utf-8 and base64 encode unicode tokens. Monday, January 7, 2008, 5:35:46 PM, you wrote: KS SimpleTerm of zope.schema does not allow tokens to be unicode. Why this? KS ___ KS Zope3-users mailing list KS Zope3-users@zope.org KS http://mail.zope.org/mailman/listinfo/zope3-users -- Best regards, Adam Groszermailto:[EMAIL PROTECTED] -- Quote of the day: Not only is there no God, but try getting a plumber on the weekend. - Woody Allan ___ Zope3-users mailing list Zope3-users@zope.org http://mail.zope.org/mailman/listinfo/zope3-users
Re: [Zope3-Users] Implementing a DropdownWidget for a country-code vocabulary
Hello Jesper, That should be solved already. Look for z3c.widget.country. svn://svn.zope.org/repos/main/z3c.widget/trunk/src/z3c/widget/country Saturday, September 15, 2007, 6:08:19 PM, you wrote: Hello! I'm trying to implement a DropdownWidget for my country list. In my app i'd like to have a dropdown menu where a user can choose a country (for my main content object, a job). My vocabulary is created from a list of strings, and stored in a local utility: SimpleVocabulary.fromValues( [u'AD', u'AE', 'AF', ...] ) But in my dropdown widget i want to display the country name for each option too.. and not just the same value on both the value attribute and inside the element: option value="AD"Andorra/option So i send in a different vocabulary.. one that looks like this: [(u'AD', u'Andorra'),...] So i coded this: - class CountryDropDown(DropdownWidget): def __init__(self, field, request): #This returns a dict: {'countrycode':'countryname'} territories = request.locale.displayNames.territories # Invert the territories dict: keys=names, values=ccodes self.territories = sorted(territories.items (), key=itemgetter(1)) #not using this any longer.. #voc = getUtility(IVocabularyFactory, u'Country codes') voc = SimpleVocabulary.fromItems(self.territories) super(CountryDropDown, self).__init__(field, voc, request) def textForValue(self, term): return term.value - But it seems like when i choose a country, e.g Andorra, the constraint fails. I think it is because my modified vocabulary that i sent in which it is now checking constraints against fails. I want the constraints to be checked in my ordinary vocabulary but i want to use a different one when populating the dropdown.. any ideas? -- Instant Foo - Naturally Flavoured -- Best regards, Adam mailto:[EMAIL PROTECTED] ___ Zope3-users mailing list Zope3-users@zope.org http://mail.zope.org/mailman/listinfo/zope3-users
Re[2]: [Zope3-Users] most useful zope 3 libraries
Hello Christophe, Something like this was proposed by Stephan some 1.5 year ago. He did some quite detailed specs for it. Tuesday, September 4, 2007, 8:45:15 AM, you wrote: Carlos de la Guardia a écrit : Hi, the other day I commented on my blog [1] about the lack of information on the Zope3 wiki about popular/important libraries or modules (I wanted to say products but I hear that's passé). Since I brought this up, I though the least I could do was to create a page about this myself, but I need help, because I'm just a Zope 3 beginner. Could some of you please mention your favorite or most useful libraries for Zope 3? I will research some of those mentioned and create a wiki page based on this information. Thanks a lot. Carlos de la Guardia That's a really good idea! I wanted to do this once my current job is finished. We can already browse the modules on pypi, but it would be good to have a page that summarizes all the useful zope3-only packages, with a user point-of-view, common use cases for each package, with schemas and screen captures (if there are widgets). And not only for 3rd-party packages, but also for the core zope3 packages. I regularly discover new components in it. I will surely help Christophe ___ Zope3-users mailing list Zope3-users@zope.org http://mail.zope.org/mailman/listinfo/zope3-users -- Best regards, Adammailto:[EMAIL PROTECTED] -- Quote of the day: I don't know who my grandfather was; I am much more concerned to know what his grandson will be. - Abraham Lincoln ___ Zope3-users mailing list Zope3-users@zope.org http://mail.zope.org/mailman/listinfo/zope3-users
Re: [Zope3-Users] Overriding cssClass on all input widgets
Hello Greg, You can do your own widgets where you just override the cssClass property, then in an overrides.zcml you register them instead of the stock widgets. See zope.app.form.browser/configure.zcml. An alternative way could be to create a new zope skin and adapdt your css according to what the widgets use. Friday, August 24, 2007, 9:01:07 PM, you wrote: I'm trying to make a skin for my program, but am having trouble getting the input forms converted over. I have a skin created by a graphic artist, my problem now is figuring out how to change the cssClass attribute for all my widgets. Currently my forms are registered like this: browser:page for=zope.app.container.interfaces.IAdding name=ship.IncidentReport class=.incidentreport.IncidentReportAddForm permission=zope.View / where .incidentreport.IncidentReportAddForm specifies the template for the form. I plan to register all the forms like this. Any ideas as to how I can do this? Greg ___ Zope3-users mailing list Zope3-users@zope.org http://mail.zope.org/mailman/listinfo/zope3-users -- Best regards, Adammailto:[EMAIL PROTECTED] ___ Zope3-users mailing list Zope3-users@zope.org http://mail.zope.org/mailman/listinfo/zope3-users
Re[2]: [Zope3-Users] How do I get the value of security proxied attributes from a view template
Hello Yuan, Try to add some security declaration to decimal.Decimal instead of using removeSecurityProxy. something like this (untested): class class=decimal.Decimal require permission=zope.Public attributes=... / /class Saturday, August 25, 2007, 1:59:26 PM, you wrote: On 8/24/07, Andreas Reuleaux [EMAIL PROTECTED] wrote: from zope.security.proxy import removeSecurityProxy price=removeSecurityProxy(proxiedPrice) Yes, it works fine. Thanks. However it would mean that I have to add a view class to all my objects which contains a decimal attribute, and add removeSecurityProxy to all decimal attributes that I wish to present through the web? That would be too much unnecessary duplicate code, since I am trying to build a web shop with Zope3, in which the decimal type is almost everywhere. I read in several places that the Security Proxy is supposed only to wrap mutable objects. Integer and float for example shall not to be proxied. But a decimal.Decimal is also immutable, why is it wrapped then? Is there an easier way to go around this, like to tell security proxy not to wrap all decimal objects? -- Best regards, Adammailto:[EMAIL PROTECTED] ___ Zope3-users mailing list Zope3-users@zope.org http://mail.zope.org/mailman/listinfo/zope3-users
Re: [Zope3-Users] possible bug in zope\app\authentication\principalfolder.py
Hello Shailesh, Which version of Z3 re you using? As I remember that was fixed, but I can't dig the info from SVN. Tuesday, August 7, 2007, 5:28:02 PM, you wrote: Hi, I was using InternalPrincipal object and specified a password with non-ascii characters. Since Password is derived from TextLine, hence its supposed to be acceptable. But I found that if I use MD5 or SHA1 password managers, it leads to problems. The following exception is thrown. I guess the password needs to be encoded in UTF8 before being hashed by md5 or sha1. File C:\Python24\Lib\site-packages\zope\app\authentication\principalfolder.py, line 124, in __init__ self.password = password File C:\Python24\Lib\site-packages\zope\app\authentication\principalfolder.py, line 144, in setPassword self._password = passwordManager.encodePassword(password) File C:\Python24\Lib\site-packages\zope\app\authentication\password.py, line 76, in encodePassword return md5.new(password).hexdigest() With regards, -Shailesh ___ Zope3-users mailing list Zope3-users@zope.org http://mail.zope.org/mailman/listinfo/zope3-users -- Best regards, Adammailto:[EMAIL PROTECTED] ___ Zope3-users mailing list Zope3-users@zope.org http://mail.zope.org/mailman/listinfo/zope3-users
Re[2]: [Zope3-Users] possible bug in zope\app\authentication\principalfolder.py
Hello Shailesh, As I remember the fix was later. Thursday, August 9, 2007, 10:51:18 AM, you wrote: I have Zope 3.3.1 the official release. With regards, -Shailesh On 8/9/07, Adam Groszer [EMAIL PROTECTED] wrote: Hello Shailesh, Which version of Z3 re you using? As I remember that was fixed, but I can't dig the info from SVN. Tuesday, August 7, 2007, 5:28:02 PM, you wrote: Hi, I was using InternalPrincipal object and specified a password with non-ascii characters. Since Password is derived from TextLine, hence its supposed to be acceptable. But I found that if I use MD5 or SHA1 password managers, it leads to problems. The following exception is thrown. I guess the password needs to be encoded in UTF8 before being hashed by md5 or sha1. File C:\Python24\Lib\site-packages\zope\app\authentication\principalfolder.py, line 124, in __init__ self.password = password File C:\Python24\Lib\site-packages\zope\app\authentication\principalfolder.py, line 144, in setPassword self._password = passwordManager.encodePassword(password) File C:\Python24\Lib\site-packages\zope\app\authentication\password.py, line 76, in encodePassword return md5.new(password).hexdigest() With regards, -Shailesh ___ Zope3-users mailing list Zope3-users@zope.org http://mail.zope.org/mailman/listinfo/zope3-users -- Best regards, Adammailto:[EMAIL PROTECTED] -- Best regards, Adammailto:[EMAIL PROTECTED] ___ Zope3-users mailing list Zope3-users@zope.org http://mail.zope.org/mailman/listinfo/zope3-users
Re: [Zope3-Users] Zope3 PID file ?
Hello Thierry, What about zopectl logreopen? Tuesday, July 17, 2007, 11:17:50 AM, you wrote: TF Hi, TF I need to write scripts to handle Zope3 logfiles rotation. TF But I can't find any PID file for the running instance. TF Do I have to call for Zope restart or is there any other way which could TF avoid restarting Zope and flushing all caches ? TF Thanks for any advise, TF Thierry Florac -- Best regards, Groszer Adam ___ Zope3-users mailing list Zope3-users@zope.org http://mail.zope.org/mailman/listinfo/zope3-users
Re: [Zope3-Users] Custom Schemas, form widgets
Hello Hermann, Look for z3c.schema, z3c.widget. There are some. Sometimes google spits out some usable third party packages too. Tuesday, July 3, 2007, 1:32:26 PM, you wrote: Hi, I wonder if there's a package that extends Zope's schemas and widgets as Zope covers only basic ones. There are several missing schemas that derive from a TextLine but have custom validation methods, e.g. for URLs, for an email address etc. Moreover there are several widgets missing, e.g. a select widget for date/datetime fields. Probably people do this on their own, however I think it would be a good idea to share code, so perhaps it is possible to add a package where people can contribute? Ah yes, I think the package should be based on z3c.form, not on formlib. Best Regards, Hermann -- Best regards, Adammailto:[EMAIL PROTECTED] -- Quote of the day: Happiness is not a reward- it is a consequence. Suffering is not a punishment- it is a result. - Robert Green Ingersoll ___ Zope3-users mailing list Zope3-users@zope.org http://mail.zope.org/mailman/listinfo/zope3-users
Re: [Zope3-Users] Utility for removing unneeded import statements
Hello Hermann, Z3 has an importchecker: Import checker This utility finds unused imports in Python modules. Its output is grep-like and thus emacs-friendly. ... Althought pyflakes works for me better. http://www.divmod.org/projects/pyflakes Tuesday, June 5, 2007, 12:50:40 PM, you wrote: Hi, During development and especially refactoring, I'm often confronted with cleaning up import statements. Missing imports are reported by Python, however, unneeded imports are not. I don't know if unneded imports are a performance issue, nevertheless it probably makes sense to clean them up from time to time. Therefore I wonder if there's some tool that can automatically check if an import is needed or not. Probably this is easy to write, but perhaps somebody has already done so? What would be nice, would also be a tool that crawls through a python package and also checks any missing imports and reports all of them at once. When I refactor code, I often have to restart zope3 over and over, only due to missing import statements. Best Regards, Hermann -- Best regards, Adammailto:[EMAIL PROTECTED] -- Quote of the day: Everything comes to him who waits, among other things, death. - Francis Bradley ___ Zope3-users mailing list Zope3-users@zope.org http://mail.zope.org/mailman/listinfo/zope3-users
Re[2]: [Zope3-Users] Utility for removing unneeded import statements
Hello Marius, Tuesday, June 5, 2007, 6:03:52 PM, you wrote: pyflakes doesn't handle imports that are used by doctests only, e.g.: ... Can the import checker in Z3 handle this? I don't think so. As I remember it did not find all unnecessary imports, that's why I switched to pyflakes. -- Best regards, Adammailto:[EMAIL PROTECTED] -- Quote of the day: Don't get stuck in a closet -- wear yourself out. ___ Zope3-users mailing list Zope3-users@zope.org http://mail.zope.org/mailman/listinfo/zope3-users
Re: [Zope3-Users] Sorry about that last email
Hello Greg, Quite easily, you can write: contains('mypackage.package.IReport') That gets not resolved at import time. Friday, May 11, 2007, 1:43:44 PM, you wrote: GB Hrm, it appears that ctrl-enter in kmail actually sends emails... Sorry about GB that last one.. GB Anyway, my question: GB interfaces.py: GB -- GB class IReport(Interface): GB containers(IReportContainer) GB class IReportContainer(IContainer): GB contains(IReport) GB the above two classes reside in the same module, interfaces.py... Since they GB both depend on each other, I am having the problem of a circular dependency. GB How can I resolve this? GB Greg GB ___ GB Zope3-users mailing list GB Zope3-users@zope.org GB http://mail.zope.org/mailman/listinfo/zope3-users -- Best regards, Groszer Adam -- Quote of the day: Katz' Law: Man and nations will act rationally when all other possibilities have been exhausted. ___ Zope3-users mailing list Zope3-users@zope.org http://mail.zope.org/mailman/listinfo/zope3-users
Re[2]: [Zope3-Users] correct display of Text field in a view
Hello Ivan, I don't think that you'll need IMultiLineText and MultiLineText. That's why IText and Text are there for. You'll have to register the widget for IText or use it directly in your view with CustomWidgetFactory. In fact it's a good question why Z3 doesn't provide such a widget for Text. The current widget is just Displaywidget which eats the newlines. BTW: br \ should be br / Wednesday, March 14, 2007, 9:30:19 AM, you wrote: Darryl, Frank, thank you your answers, but finally i keep the widget solution instead of TextAreaWidget i inherited my widget from DisplayWidget, and of course used your replace solution. class IMultiLineText(IText): this field will be used for the comment because of the correct display of html tags pass class MultiLineText(Text): the field implementation implements(IMultiLineText) class MultiLineTextWidget(DisplayWidget): the widget to display the description def __call__(self): return super(MultiLineTextWidget, self).__call__().replace(\n,br \) Darryl Cousins wrote: On Fri, 2007-03-09 at 10:06 +0100, Ivan Horvath wrote: - modify the description widget data with PlainTextToHTMLRenderer.render(), but then in the browser i can see only encoded chars instead of br Hi, As for Frank's suggestion try: p tal:content=structure view/description / when rendering the text2html content. That should allow the html tags through. Regards, Darryl -- Best regards, Adammailto:[EMAIL PROTECTED] ___ Zope3-users mailing list Zope3-users@zope.org http://mail.zope.org/mailman/listinfo/zope3-users
[Zope3-Users] Community opinion about search+filter
Hello, I'd like to ask your opinion, your experiences about searching and filtering in quite large object DBs. We need to add search and filter functions to our current app, where the user might be able to create quite _sophisticated_ filter criterias. (The app is a pure Z3 app, subject is document management) Currently we're looking at something based on catalog/indexes. As I checked the most comfortable solution would be based on hurry.query. Some questions arose: - Is it necessary/worth adding indexes on all attributes? - How does the index perform on modification and retrieval? The biggest problem is that this will be our first try, so we're missing experiences and are a bit puzzled about the right solution. Certain is that moving to RDB is not an option. Thanks, -- Best regards, Adam mailto:[EMAIL PROTECTED] ___ Zope3-users mailing list Zope3-users@zope.org http://mail.zope.org/mailman/listinfo/zope3-users
[Zope3-Users] Re: [Zope3-dev] Community opinion about workflow engine
Hello Godefroid, I'm having a bit biased view, because I know just zope.wfmc and have the luck developing a pure Z3 application. I think with zope.wfmc you have - WFMC/XPDL support, you can shine with standards and big companies love standards - because it's XPDL support there's a graphical process editor jpEd - the core itself is quite sophisticated, but still misses some things for complete WFMC coverage (the WFMC spec is rather huge) - you can/should add some layers on top of it: - z3c.wfmcpersistent to store the processes in ZODB - ecm.workflow to have a higher level of APIs and functions (That was written by Roger Ineichen, but as nuxeo moved to jboss it was not maintained by them. Therefore I intend to move that code to z3c.wfmc, when I have some time to breathe. I have some improvements to the code. We even have plans to implement time management or scheduling with the package) All in all we're quite comfortable with zope.wfmc in our project. The project is about document management, also a bit of administrative thing. Monday, March 12, 2007, 4:48:24 PM, you wrote: Hi all, We have the opportunity to bid for a project concerning the automation of administrative processes. The client currently has software in Python and Zope/Plone. They are quite explicit that they want their new applications to be built as much as possible with a mix of generic shareable modules and of custom modules. This is a quite big project that, among others, includes the aspects of collaboration with / support of the community. One of the questions we are exploring is : which workflow engine should we use/expand on ? In order to help us make a proposal, we would be very interested to hear your comments both - about the existing workflows (DCWorkflow, Zope3.wfmc, AlphaFlow, OpenFlow...) - or about the directions that you would suggest in order to help you use a given engine (missing features, simplification,...) and join the effort to improve one of the existing engines. Thanks -- Best regards, Adammailto:[EMAIL PROTECTED] ___ Zope3-users mailing list Zope3-users@zope.org http://mail.zope.org/mailman/listinfo/zope3-users
Re[2]: [Zope3-Users] Design question (object or interface for category implementation?)
Hello, directlyProvides is surely persistent. Make a site works like this. zope.interface.directlyProvides( self, interfaces.ISite, zope.interface.directlyProvidedBy(self)) Friday, March 9, 2007, 3:30:46 PM, you wrote: GM Christophe Combelles wrote: Christophe Combelles a écrit : Hi, I'm playing again with the notion of categories of objects. I have two main goals: - 1) I must let the user choose the category of an object added to the zodb. For this, I must be able to retrieve the list of categories and present them in a form field managed by a vocabulary (or in a different manner). 2) I must have different behaviours for categorized objects: objects of different categories would have different views, different addMenuItems (if they are containers), etc. the first requirement would tell me to define categories as objects, while the second one would tell me to define them as interfaces. The possible solutions I see: 1) The simplest solution is to store the categories as text strings into the annotations of the object. So categories actually are just tags. 2) The second solution is to do the same, but replace text strings with category objects, that implement ICategory. And categories can be stored separately in a category container, or in a registered utility that gives the list of available categories. This is a bit better, but this way I don't know how to easily let my categorized objects behave differently according to their categories. 3) The third solution is to define categories as interfaces extending ICategory. I can retrieve the list of categories with ICategory.dependents But to present them in a form, I must have a pretty name for each interface. Should I store them in a Tagged Value? 4) The fourth solution I see, is to define an interface type, ICategoryType, extending IInterface just like IContentType. Then my categories would be interfaces whose type is ICategoryType. But with IContentType, is there a way to retrieve the list of all available content types? I've finally mixed 3) and 4) : I have defined ICompany(Interface), IClient(ICompany), IProvider(ICompany) And I have an ICompanyType(IInterface) interface type I've set the type of IClient and IProvider as ICompanyType in zcml. ICompany has a types attribute, for which I've redefined __getattr__ and __setattr_: __getattr__ retrieve the ICompanyType interfaces from the object __setattr__ calls noLongerProvides then alsoProvides to change the interfaces. GM I think that it's not work: alsoProvides and directlyProvides change GM interfaces only in memory, it's not persistent changes (after restart GM Zope yours object will be only basic interface) . GM (sorry my honor english). GM ___ GM Zope3-users mailing list GM Zope3-users@zope.org GM http://mail.zope.org/mailman/listinfo/zope3-users -- Best regards, Groszer Adam -- Quote of the day: Never does the human soul appear so strong and noble as when it forgoes revenge and dares to forgive an injury. - Edwin Hubbell Chapin ___ Zope3-users mailing list Zope3-users@zope.org http://mail.zope.org/mailman/listinfo/zope3-users
Re: [Zope3-Users] Configure.zcml In Hello World Video On WorldCookery.Com Doesn't Work
Hello Jonathan, A quick guess: for=zope.app.container.interfaces.Icontainer is for=zope.app.container.interfaces.IContainer Friday, February 16, 2007, 5:24:22 PM, you wrote: Here is my configure.zcml file, which is identical to the one Paul Everitt says to write: configure xmlns=http://namespaces.zope.org/browser; page name=hello template=helloworld.html for=zope.app.container.interfaces.Icontainer permission=zope.Public / /configure and here is the error message that I get when I reboot the Zope 3.3 server on Windows XP: ConfigurationError: ('Invalid value for', 'for', 'ImportError: Module zope.app.container.interfaces has no global Icontainer') Everything I did was identical to the training video. What went wrong? ___ Zope3-users mailing list Zope3-users@zope.org http://mail.zope.org/mailman/listinfo/zope3-users -- Best regards, Adammailto:[EMAIL PROTECTED] -- Quote of the day: Going with the flow is smoothing but risky ___ Zope3-users mailing list Zope3-users@zope.org http://mail.zope.org/mailman/listinfo/zope3-users
Re: [Zope3-Users] 'exceptions.TypeError: can't pickle Checker objects' in zope.scheduler task in transaction.commit()
Hello Alek, 'can't pickle Checker objects' happened to me, when I tried to write a security proxied object to the ZODB. Monday, February 12, 2007, 4:49:01 PM, you wrote: AK Hello, AK I finally managed to access local components from zope.scheduler, but I felt to AK another, even worse trouble. AK In the zope.scheduler task I create and/or update some local objects, but then I AK fall into the following exception: AK 'exceptions.TypeError: can't pickle Checker objects' in zope.scheduler task in AK transaction.commit()' AK I scanned through web but got no clue, except that this may be something with AK Security Proxies. Anyway, I have no clue how to deal with that issue. AK The full stack trace, starting from commit() call is attached. AK File , line 31, in myZopeScehdulerTask AK transaction.commit() AK File C:\Python24\Lib\site-packages\transaction\_manager.py, line 96, in commit AK return self.get().commit(sub, deprecation_wng=False) AK File AK C:\Python24\Lib\site-packages\transaction\_transaction.py, line 395, in AK commit AK self._commitResources() AK File AK C:\Python24\Lib\site-packages\transaction\_transaction.py, line 495, in AK _commitResources AK rm.commit(self) AK File C:\Python24\Lib\site-packages\ZODB\Connection.py, line 498, in commit AK self._commit(transaction) AK File C:\Python24\Lib\site-packages\ZODB\Connection.py, line 543, in _commit AK self._store_objects(ObjectWriter(obj), transaction) AK File C:\Python24\Lib\site-packages\ZODB\Connection.py, line 570, in AK _store_objects AK p = writer.serialize(obj) # This calls __getstate__ of obj AK File C:\Python24\Lib\site-packages\ZODB\serialize.py, line 407, in serialize AK return self._dump(meta, obj.__getstate__()) AK File C:\Python24\Lib\site-packages\ZODB\serialize.py, line 416, in _dump AK self._p.dump(state) AK File C:\Python24\Lib\copy_reg.py, line 69, in _reduce_ex AK raise TypeError, can't pickle %s objects % base.__name__ AK exceptions.TypeError: can't pickle Checker objects AK ___ AK Zope3-users mailing list AK Zope3-users@zope.org AK http://mail.zope.org/mailman/listinfo/zope3-users -- Best regards, Groszer Adam -- Quote of the day: The difference between a hero and a coward is one step sideways. - Gene Hackman ___ Zope3-users mailing list Zope3-users@zope.org http://mail.zope.org/mailman/listinfo/zope3-users
Re[2]: [Zope3-Users] Custom Image Widget
Hi Adam, I would try to figure out how the data gets extracted when it gets displayed. Something like _getCurrentValue. Or better, have a look at hurry.file. It uses a session variable or hidden input to solve your problem. And well, thinking further, hurry.file might be _the_ solution for you. cheers, Thursday, December 14, 2006, 4:47:51 PM, you wrote: AS AS Hi Tom Widget Afficionados. AS AS Thanks for the help so far. AS AS My problem is now this: AS AS From this code (which Tom supplied), how do I code the logic (in bold) AS AS def _toFieldValue(self, input): AS data = super(ImageWidget, self)._toFieldValue(input) AS if data is not None: AS img = Image(data) AS notify(ObjectCreatedEvent(img)) AS return imgelse: #data is None, ie. the File input AS field was left blank and we don't want to AS #replace the current value of the Image Widget with an empty value. AS currentImg = the Image object which the field is being rendered for AS return currentImg AS I can't rely on AS AS AS AS field = self.context AS AS image = field.get(field.context) AS AS AS logic to find the data, because my schema can contain: AS AS AS class Iclaim(IContained): AS AS Claim AS AS supDoc = List(title=_(uSupporting Docs List), AS value_type=Object(IImage, __name__='ImgItem', title=_(uImage))) AS AS img = Object(IImage, title=_(uSingle img), required=False) AS AS And hence, the self.context.context points to the claim AS object, not the list inside when rendering supDoc AS Again, any help is much appreciated. AS Regards, AS Adam AS AS Tom Dossis wrote: AS AS Adam Summers wrote: AS AS AS Hi, AS I have the following widgets. AS class MyImageDisplayWidget(DisplayWidget): ASclass_ = Image ASdef __call__(self): ASmycontent = uoops! no img ASif self._renderedValueSet(): ASmycontent = img src=\data:image/gif;base64, + AS b64encode(self._data.data) + \ / ASreturn mycontent AS MyImageListDisplayWidget = CustomWidgetFactory(SequenceDisplayWidget, AS subwidget = MyImageDisplayWidget) AS class MyImageWidget(FileWidget): ASclass_ = Image ASdef _toFieldValue(self, input): ASvalue = super(MyImageWidget, self)._toFieldValue(input) ASreturn self.class_(value) AS MyImageListWidget = CustomWidgetFactory(ListSequenceWidget, subwidget = AS MyImageWidget) AS I want to build a better input widget (MyImageWidget), so that we can do AS the following: AS* If the field has no data, display a file input. AS* If the field has data, display the image. AS I know that there are design shortcomings in this, but I need a simple AS example (and I only use the files in lists anyway, so I can delete images). AS Any pointers on how to go about this would be much appreciated; as always AS AS AS Hi Adam, AS I'm not exactly sure of your use case, but I've included a widget AS implementation (see below) which you may find useful. I've used this AS widget for an attribute which is an IImage, e.g. AS AS AS snip AS AS AS class ImageInputWidget(FileWidget): AS def _toFieldValue(self, input): AS data = super(ImageWidget, self)._toFieldValue(input) AS if data is not None: AS img = Image(data) AS notify(ObjectCreatedEvent(img)) AS return img AS def __call__(self): AS input_widget = super(ImageWidget, self).__call__() AS try: AS image = ImageDisplayWidget(self.context, self.request)() AS info = self.info() AS return u'br /'.join([image, info, input_widget]) AS except AttributeError: AS # This happens because the context is IAdding AS return input_widge AS AS /snippet AS AS -- Best regards, Adam -- Quote of the day: Education helps earning capacity. Ask any college professor. ___ Zope3-users mailing list Zope3-users@zope.org http://mail.zope.org/mailman/listinfo/zope3-users
Re[2]: [Zope3-Users] Re: UnicodeEncodeErrors from zope/app/maildir.py
Hello Rupert, I'm not a mail+RFC expert, but I would try to pass the content encoded as UTF-8 and set the headers accordingly. Wednesday, November 29, 2006, 1:28:41 PM, you wrote: RR Raphael Ritz wrote: Well, there are the officials like: http://unicode.org http://en.wikipedia.org/wiki/Unicode but you want probably something more like http://www.joelonsoftware.com/articles/Unicode.html and for Python in particular I found http://www.amk.ca/python/howto/unicode RR Those are great pointers, thanks, but I still can't understand why RR zope.app.mail's MailDir functions want to encode the message using the RR 'ascii' encoding, nor does there seem to be any way to suggest a RR different encoding to the mail system. RR How is it possible to send emails containing non-ascii encodings from RR zope? Is there a problem with the python smtplib which is forcing this RR behaviour? (Or do I still not get it...?) RR Thanks for your help, RR Rupert RR R RR ___ RR Zope3-users mailing list RR Zope3-users@zope.org RR http://mail.zope.org/mailman/listinfo/zope3-users -- Best regards, Groszer Adam -- Quote of the day: It is no great thing to be humble when you are brought low; but to be humble when you are praised is a great and rare attainment. - Bernard of Clairvaux ___ Zope3-users mailing list Zope3-users@zope.org http://mail.zope.org/mailman/listinfo/zope3-users
Re: [Zope3-Users] zope 3.3 on windows can't create pages
Hello Anton, That's a small incompatibility between python 2.4.4 and Zope 3.3. You can use python 2.4.3 to work around that. The fix for Zope is there but only in the svn yet. Monday, November 27, 2006, 10:51:48 PM, you wrote: Hi, I have a win2k sp4 PC. I installed: - python 2.4.4 - pythonwin 2.10 - zope 3.3 (the installer from zope.org) I created a zope-instance can start zope, all is fine. I create a new folder it works :-) I try to create a new ZPT Page .. it fails :-( Here is the log with the error message:- 2006-11-24T22:59:00 ERROR SiteError http://localhost:8080 Traceback (most recent call last): File C \Programme\util\Python24\Lib\site-packages\zope\publisher\publish.py, line 126, in publish request.processInputs() File C \Programme\util\Python24\Lib\site-packages\zope\publisher\browser.py, line 263, in processInputs fs = FieldStorage(fp=fp, environ=self._environ, keep_blank_values=1) File C:\Programme\util\Python24\lib\cgi.py, line 530, in __init__ self.read_multi(environ, keep_blank_values, strict_parsing) File C:\Programme\util\Python24\lib\cgi.py, line 650, in read_multi environ, keep_blank_values, strict_parsing) File C:\Programme\util\Python24\lib\cgi.py, line 532, in __init__ self.read_single() File C:\Programme\util\Python24\lib\cgi.py, line 665, in read_single self.read_lines() File C:\Programme\util\Python24\lib\cgi.py, line 687, in read_lines self.read_lines_to_outerboundary() File C:\Programme\util\Python24\lib\cgi.py, line 715, in read_lines_to_outerboundary line = self.fp.readline(116) TypeError: readline() takes exactly 1 argument (2 given) - Is the windows version of zope 3.3 still beta/experimantal or is it suitable for prodution use? Do you have any workaround/ patch?? Bye Anton ___ Zope3-users mailing list Zope3-users@zope.org http://mail.zope.org/mailman/listinfo/zope3-users -- Best regards, Adammailto:[EMAIL PROTECTED] -- Quote of the day: Upgrade (UHP-grayde), n. - Take old bugs out, put new ones in. ___ Zope3-users mailing list Zope3-users@zope.org http://mail.zope.org/mailman/listinfo/zope3-users
Re: [Zope3-Users] Needed help with zc.table selection column
Hello Thierry, Use something like this: sels = self.columns[0].getSelected(self.list_data, self.request) Then sels will contain your objects as a list. Wednesday, November 15, 2006, 12:17:46 PM, you wrote: TF Hi, TF I'm using zc.table to handle simple lists of items to replace the TF standard contents.html container view. TF I use a SelectionColumn and a set of sortable columns, to display a TF checkbox in front of every item, and a set of custom actions to handle TF my selections. TF My question is trivial : as items names are base64 encoded into form TF widgets and form data, is there an already defined way to easilly get TF the list of selected keys, without decoding base64 input fields ? TF Thanks for any help, TF Thierry Florac -- Best regards, Groszer Adam -- Quote of the day: Sterilization is often justified ___ Zope3-users mailing list Zope3-users@zope.org http://mail.zope.org/mailman/listinfo/zope3-users
Re: [Zope3-Users] svn.zope.org and www.zope.org not online
Hello Roger, u, yes squid/2.5.STABLE6 says: While trying to retrieve the URL: http://www.zope.org/ The following error was encountered: Connection Failed The system returned: (111) Connection refused Tuesday, October 10, 2006, 3:35:34 PM, you wrote: RI Hi RI Can somebody confirm that the www.zope.org site and RI the svn is not reachable? RI I can only access the apache test page at: RI http://download.zope.org/ RI Thanks RI Rgards RI Roger Ineichen RI _ RI Projekt01 GmbH RI www.projekt01.ch RI Boesch 65 RI 6331 Hünenberg RI phone +41 (0)41 781 01 78 RI mobile+41 (0)79 340 52 32 RI fax +41 (0)41 781 00 78 RI email [EMAIL PROTECTED] RI _ RI END OF MESSAGE RI ___ RI Zope3-users mailing list RI Zope3-users@zope.org RI http://mail.zope.org/mailman/listinfo/zope3-users -- Best regards, Groszer Adam -- Quote of the day: We believe no evil till the evil's done. - Jean de La Fontaine ___ Zope3-users mailing list Zope3-users@zope.org http://mail.zope.org/mailman/listinfo/zope3-users
Re[2]: [Zope3-Users] svn.zope.org and www.zope.org not online
Hello Benji, www.zope.org works again. :-) But FYI It's the following: l:~ # dig www.zope.org ; DiG 9.2.4 www.zope.org ;; global options: printcmd ;; Got answer: ;; -HEADER- opcode: QUERY, status: NOERROR, id: 42272 ;; flags: qr rd ra; QUERY: 1, ANSWER: 1, AUTHORITY: 2, ADDITIONAL: 2 ;; QUESTION SECTION: ;www.zope.org. IN A ;; ANSWER SECTION: www.zope.org. 300 IN A 63.240.213.171 ;; AUTHORITY SECTION: zope.org. 300 IN NS ns2.zope.com. zope.org. 300 IN NS ns3.zope.com. ;; ADDITIONAL SECTION: ns2.zope.com. 153300 IN A 63.240.213.250 ns3.zope.com. 153300 IN A 70.168.181.3 ;; Query time: 162 msec ;; SERVER: 172.16.144.33#53(172.16.144.33) ;; WHEN: Tue Oct 10 16:16:46 2006 ;; MSG SIZE rcvd: 122 Tuesday, October 10, 2006, 3:58:56 PM, you wrote: BY Adam Groszer wrote: squid/2.5.STABLE6 says: While trying to retrieve the URL: http://www.zope.org/ The following error was encountered: Connection Failed The system returned: (111) Connection refused BY There appear to be some issues with the zope.org DNS as it is BY transitioned to third-party hosting, but the servers themselves are up. BY What IP does www.zope.org resolve to for you? BY -- BY Benji York BY Senior Software Engineer BY Zope Corporation -- Best regards, Groszer Adam -- Quote of the day: Nor peace nor ease the heart can know; Which, like the needle true, Turns at the touch of joy or woe, But turning, trembles too. - Lady Greville ___ Zope3-users mailing list Zope3-users@zope.org http://mail.zope.org/mailman/listinfo/zope3-users
Re: [Zope3-Users] Installing Zope3 on Windows
Hello Catonano, Just uploaded a win32 installer and the pyds. Friday, August 25, 2006, 5:01:37 PM, you wrote: c Hello people, c I downloaded the 3.2.1 version from http://zope.org/Products/Zope3 c but it has no windows installer. c the previous 3.2.o has it. c That is, the last version marked as stable has no windows installer, c while the versions marked as developement and the previous stable c versions do have it. c The download page says: c The version Trunk contains the pyd files necessary to get the trunk c working on win32 without a C compiler. The ZIP files will get marked c with SVN revision number (Unzip into the root of a Zope3 trunk checkout). c So I suspect that the versions with no windows installer can work on c windows BUT the readme file explicitly says to use a windows c installer to install Zope, otherwise you must have a supported C c compiler (it's not my case). c In a few words: what should I do to make the 3.2.1 version I downloaded work ? c I've been playing with Zope 2 and I also made a small job with that c and I liked it. c Now I want to see wether I can reach a reasonable setup also with Zope3. c Thanks SO much for any help ! c Bye c Catonano c ___ c Zope3-users mailing list c Zope3-users@zope.org c http://mail.zope.org/mailman/listinfo/zope3-users -- Best regards, Groszer Adam -- Quote of the day: Dig the well before you are thirsty. - Chinese Proverb ___ Zope3-users mailing list Zope3-users@zope.org http://mail.zope.org/mailman/listinfo/zope3-users
Re[2]: [Zope3-Users] zalchemy integration
Hello Stephan, Monday, August 14, 2006, 12:08:27 PM, you wrote: SR We were on schedule and delivered an application above expectations. SR BTW, I hope I will get a case study out in the next few weeks. Great, I'd love to read that. -- Best regards, Groszer Adam -- Quote of the day: Ah, but a man's reach should exceed his grasp, Or what's a Heaven for? - Robert Browning ___ Zope3-users mailing list Zope3-users@zope.org http://mail.zope.org/mailman/listinfo/zope3-users
Re: [Zope3-Users] Zope3 workflow ?
Hello Thierry, http://svn.zope.org/Zope3/trunk/src/zope/wfmc/ and http://svn.z3lab.org/trac/z3lab/browser/z3ecm/trunk/src/ecm/workflow Monday, July 17, 2006, 5:25:07 PM, you wrote: Hi, I'm looking for components to support workflows in Zope3. I've read into Zope3 Developer's Handbook a whole chapter about Zope3 workflow components and utilities, but these classes don't seem to be part of my current Zope3 release (3.3.0b1) anymore... Any link ? Thierry Florac -- Chef de projet intranet/internet Office National des For�ts - D�partement Informatique 2, Avenue de Saint-Mand� 75570 PARIS Cedex 12 M�l : [EMAIL PROTECTED] T�l. : +33 01.40.19.59.64 Fax. : +33 01.40.19.59.85 -- Best regards, Groszer Adam -- Quote of the day: A student who changes the course of history is probably taking an exam. ___ Zope3-users mailing list Zope3-users@zope.org http://mail.zope.org/mailman/listinfo/zope3-users
[Zope3-Users] Re[2]: [Zope3-dev] [ANN] win32-trunk-pyds
Hi Tim, Sorry for this small confusion. If you don't mind, I'll do it. (The thing started as I became the compiler of the win32 release and the pyd's are just a by-product of the release.) I'll do my best to keep it up to date, but if I should miss something, please drop a mail. Friday, May 19, 2006, 9:11:35 PM, you wrote: [Stephan Richter] Tim has not been updating them recently. After Jim updated the C code in the adapter lookup code, they were invalid. Adam has picked up Tim's work there. [Benji York] As of 5/1 Tim was still willing to build them (as stated in a message to zope3-dev). I don't think that's changed. If he happened to miss a change requiring a recompile, just drop him a line and I'm sure he'll update them. I'm no longer routinely building, or running, Zope3 on Windows, so I'll indeed only update Zope3 .pyds if/when someone emails me saying that's needed. And right, I'm happy to do so. If Adam is paying more attention to Zope3, and especially if has an automated way to keep his Windows Trunk zipfile release up to date, that's probably better all around. If that is the case, then I should remove the old pyd .zip files from my member page, and plant a link there to Adam's gimmick instead. Adam, do you intend to keep Trunk up to date now? -- Best regards, Adammailto:[EMAIL PROTECTED] -- Quote of the day: Mistakes are a fact of life. It is the response to the error that counts. - Nikki Giovanni ___ Zope3-users mailing list Zope3-users@zope.org http://mail.zope.org/mailman/listinfo/zope3-users
[Zope3-Users] [ANN] win32-trunk-pyds
Hello *, I just put the compiled pyd's for win32 users to http://www.zope.org/Products/Zope3/, into a relase called 'Trunk'. -- Best regards, Adam mailto:[EMAIL PROTECTED] -- Quote of the day: I pronounce it as certain that there was never a truly great man that was not at the same time truly virtuous. - Benjamin Franklin ___ Zope3-users mailing list Zope3-users@zope.org http://mail.zope.org/mailman/listinfo/zope3-users
Re[2]: [Zope3-Users] Debugger for Zope 3
Hi, If we are coming to commercial IDEs then Komodo is also a good choice for debugging. You just have to put it's dbgp module on the PYTHONPATH and use the below small script to avoid some irritating deprecation mesages. After this, you put brk() in you code and it will stop there. After it was stopped for the first with brk() the debugger will obey all 'normal' breakpoints. I think it supports threading also but never tried it. import zope.deprecation from dbgp.client import brk as dbgpbrk def brk(): zope.deprecation.__show__.off() dbgpbrk() Wednesday, April 26, 2006, 9:58:52 AM, you wrote: On Tuesday 25 April 2006 08:27, Achim Domma wrote: I would like to start Zope 3 with the debugger, set some breakpoints in my modules and step through the code to learn more about Zope. WingIDE's debugger is superb. Once you set the thread count to 1 it should work. At some point we'll have to write a small package that installs the debugger hook automatically. For now duplicating the Zope 2 steps and the Zope 2 product is the way to go. Regards, Stephan -- Best regards, Adammailto:[EMAIL PROTECTED] -- Quote of the day: Oh, Aunty Em, it's so good to be home! ___ Zope3-users mailing list Zope3-users@zope.org http://mail.zope.org/mailman/listinfo/zope3-users
[Zope3-Users] Z3 widgets overview
Hello, I had some time to finalize the widgets overview. You can download it from here in various formats: http://www.zope.org/Members/adamg/widget -- Best regards, Adam mailto:[EMAIL PROTECTED] -- Quote of the day: A journey of a thousand miles begins with a cash advance. ___ Zope3-users mailing list Zope3-users@zope.org http://mail.zope.org/mailman/listinfo/zope3-users
Re: [Zope3-Users] Convert from string to class
Hello Florian, There is a full-blow method for that in src\zope\configuration\config.py in the class ConfigurationContext called resolve. Tuesday, January 17, 2006, 11:10:12 PM, you wrote: Hello, I've a string like zope.app.folder.Folder and I want to get the class zope.app.folder.Folder from this string. How can I do that? It's probably more a python problem that Zope... but I hope you excuse. Thanks, Florian ___ Zope3-users mailing list Zope3-users@zope.org http://mail.zope.org/mailman/listinfo/zope3-users -- Best regards, Adammailto:[EMAIL PROTECTED] -- Quote of the day: Only a Christ could have conceived a Christ. - Joseph Parker ___ Zope3-users mailing list Zope3-users@zope.org http://mail.zope.org/mailman/listinfo/zope3-users
Re: [Zope3-Users] SQLObject and SQLOS question
Hello Roman, Have a look at http://codespeak.net/svn/z3/sqlos/trunk/doc/examples/sqlos_sample/ Tuesday, January 3, 2006, 11:45:57 AM, you wrote: Hi! I am new both to Zope3 and SQLObject, but they seem (from the descriptions) to be natural fit. My problem is getting them work together. My goal: - seamlessly use sqlobjects for business logic in Zope3 (that is, part of the persistancy will be in MySQL db, part in ZODB). I want nice abstraction of relational DB in the form of sqlobject python objects. I have already installed: Python2.4.2 MySQLdb (to be sure) Zope3 (Zope 3.2b3 ) MySQLda addon SQLObject (to the proper Python2.4.2 of course) Now it looks like I need SQLOS (do I need it to my goal???)... And I am at loss how to install in. Yes, I have read http://codespeak.net/z3/sqlos/ but it was not useful, because it doesn have INSTALL instructions. The tgz doesnt have neither setup.py nor configure! Maybe I have not found proper manual... Can anybody help me please? One more question: is the above mentioned approach STABLE at all compared to totally ZODB or conventional usage of relational DB in Zope? Version 0.1 of sqlos is not reassuring... Thanks! Regards, Roman Suzi ___ Zope3-users mailing list Zope3-users@zope.org http://mail.zope.org/mailman/listinfo/zope3-users -- Best regards, Adammailto:[EMAIL PROTECTED] -- Quote of the day: The universe is full of magical things patiently waiting for our wits to grow sharper. - Eden Phillpotts ___ Zope3-users mailing list Zope3-users@zope.org http://mail.zope.org/mailman/listinfo/zope3-users
Re: [Zope3-Users] Re: index.html
Hello Jeff, Strange, now it's working, but I think I did not modify anything. Maybe I missed a restart... Friday, December 9, 2005, 12:21:47 PM, you wrote: JR Adam Groszer wrote: I register a page with the following zcml: browser:page name=index.html for=..interfaces.IPerson template=person_view.pt permission=dkr.ListContent menu=zmi_views title=View /browser:page I can access it only through .../person01/@@index.html. What am I missing? What do I have to do to access it as .../person01/index.html? JR Now that's odd! Here I can use @@index.html or index.html, @@contents.html JR or contents.html and view my own pages. The @@ seems to make no difference, JR in the cases I'm trying. JR And sometimes when type in a URL to reference an object, say JR http://localhost/myobject JR it add a /index.html suffix and displays in the browser URL widget as: JR http://localhost/myobject/index.html JR and other times it doesn't. Using firefox here. JR -Jeff JR ___ JR Zope3-users mailing list JR Zope3-users@zope.org JR http://mail.zope.org/mailman/listinfo/zope3-users -- Best regards, Groszer Adammailto:[EMAIL PROTECTED] -- Quote of the day: The great successful men of the world have used their imagination...they think ahead and create their mental picture in all its details, filling in here, adding a little there, altering this a bit and that a bit, but steadily building-steadily buildings. (Robert Collier) ___ Zope3-users mailing list Zope3-users@zope.org http://mail.zope.org/mailman/listinfo/zope3-users
Re: [Zope3-Users] Problem importing zope modules from /usr/local/zope3Instance/lib/python/productname folder
Hello Ronald, I would say that either you have to put your zope source in the PYTHONPATH or copy/link the same into the site-packages folder. Friday, October 7, 2005, 7:28:08 PM, you wrote: In chapter 4 of Philipp's book, he runs the python interpreter from the command line and imports several zope modules. I tried doing that from /usr/local/zope3Instance/lib/python/productX but python said the zope modules were unavailable. Is there some trick to this? Did I miss a configuration? Note, the instance of Zope3 was/is running properly. -- Best regards, Adammailto:[EMAIL PROTECTED] -- Quote of the day: If Presidents don't do it to their wives, they do it to the country. - Mel Brooks ___ Zope3-users mailing list Zope3-users@zope.org http://mail.zope.org/mailman/listinfo/zope3-users
Re[2]: [Zope3-Users] Calling createAndAdd with different object id
Hello Florian, No clue. Next hint is to override the add method of AddView. The default is: return self.context.add(content) Try something like this: self.context[my_id]=content Another hint: self.context.contentName = my_id return self.context.add(content) Have a look at \src\zope\app\container\browser\adding.py and \src\zope\app\container\interfaces.py, IAdding interface. The above are not tested, so... Sunday, September 11, 2005, 11:01:05 AM, you wrote: Am Samstag, 10. September 2005 18:53 schrieb Adam Groszer: Hello Florian, I suggest you download the examples for Philipp's book from http://worldcookery.com/files/examples-1.0.tgz Have a look at \examples-1.0\14containers\folder.py. A INameChooser adapter would really be perfect for me. But I need access to the form data of the add form. And AFAIK I don't have this using the NameChooser. You now a way to get the form data in the NameChooser? Thanks, Florian Saturday, September 10, 2005, 5:05:26 PM, you wrote: Hello, I want to override the createAndAdd method mothed in a view class. Since I don't want to do all the work I want to derive my class from the AddView class from /home/florian/Zope3/src/zope/app/form/browser/add.py. The only thing I do in my class is to change the name (object id) of the object to be created. In the arguments of the createAndAdd method I have not found any information about the id. How can I alter the name? Thanks, Florian ___ Zope3-users mailing list Zope3-users@zope.org http://mail.zope.org/mailman/listinfo/zope3-users -- Best regards, Adammailto:[EMAIL PROTECTED] -- Quote of the day: To be intoxicated is to feel sophisticated but not be able to say it. ___ Zope3-users mailing list Zope3-users@zope.org http://mail.zope.org/mailman/listinfo/zope3-users
Re: [Zope3-Users] stuck with zope.schema.List and subwidget
Hello Christian, I'm having almost the same problems with a 'simple' OrderedMultiSelectWidget. Look for the subject problems with browser:widget on the list [Zope3-dev]. Saturday, August 27, 2005, 1:01:04 AM, you wrote: Hi! Did anyone ever test or succeed using the subwidget-directive of zope.app.form.browser.sequencewidget.SequenceWidget? Following the lines of zope/app/form/browser/widgets.txt a widget for a list of objects would be defined by something like this: author_w = CustomWidgetFactory(ObjectWidget, Person) class ArticleEditView(EditView): authors_widget = CustomWidgetFactory(SequenceWidget, subwidget=author_w) Instead of SequenceWidget I tried ListSequenceWidget, too. But I allways get the error-message: __init__() takes at least 4 arguments (3 given) I'm really stuck. Which further argument should I pass to CustomWidgetFactory? CustomWidgetFactory--if I get it right--calls the constructur of SequenceWidget that complains about the missing argument. (self, context, field, request, subwidget=None) is the list of arguments of __init__ Especially: What should I pass as 'field'-argument? I played around with the source code and changed the list to (self, context, request, subwidget=None) and--WOW-- it presents a form yust as I want it. [Now I allways get a new (schema-)error, which I can't track: Es gab *1* Eingabefehler.] The constructor of SequenceWidget reads like this: def __init__(self, context, field, request, subwidget=None): super(SequenceWidget, self).__init__(context, request) self.subwidget = subwidget I really don't understand what is done with 'field'. Where is it passed to? Can someone give me a hint? Kind regards, Christian PS. I found a way to define a widget for objects of objects yesterday, see zope3-users. The example above is taken from there. ___ Zope3-users mailing list Zope3-users@zope.org http://mail.zope.org/mailman/listinfo/zope3-users -- Best regards, Adammailto:[EMAIL PROTECTED] -- Quote of the day: Birth: The first and direst of all disasters. ___ Zope3-users mailing list Zope3-users@zope.org http://mail.zope.org/mailman/listinfo/zope3-users
[Zope3-Users] How to resolve bi-directionally navigable association?
As the subject sais, how can I resolve bi-directionally navigable association in Z3? Both objects have to have references of each other, that means that also the schemas have to have references. class IItem(interface): unit = Object( title=uUnit, description=uUnit, required = False, schema=IUnit) class IUnit(interface): item = Object( title=uItem, description=uItem, required = False, schema=IItem) but obviously that does not work, I cannot define one before the other. The only way I found is defining a dummy interface before the other: class IUnit(interface): pass class IItem(interface): unit = Object( title=uUnit, description=uUnit, required = False, schema=IUnit) class IUnit(interface): item = Object( title=uItem, description=uItem, required = False, schema=IItem) Is there any better solution? -- Best regards, Adam mailto:[EMAIL PROTECTED] ___ Zope3-users mailing list Zope3-users@zope.org http://mail.zope.org/mailman/listinfo/zope3-users
Re: [Zope3-Users] How to resolve bi-directionally navigable association? (Corrections)
Corrections: Monday, August 8, 2005, 11:45:56 AM, I wrote: The only way I found is defining a dummy interface before the other: Actually that does not work, because the dummy IUnit and the real IUnit is not the same and IItem stores the wrong one. This failes on validations. Now I don't have any more ideas, please help. -- Best regards, Adammailto:[EMAIL PROTECTED] ___ Zope3-users mailing list Zope3-users@zope.org http://mail.zope.org/mailman/listinfo/zope3-users
[Zope3-Users] checking zope3book examples
Dear All, I just checked through the messageboard sample of Stephan's book. I used win2k with python 2.3.5, Zope3 trunk version 0. checking with the tests, step10 failes with: from zope.app.file.interfaces import IFile, IFileContent ImportError: cannot import name IFileContent checking with a browser, when adding a message, step8 failes with: File Y:\zope\svn_zope3\src\zope\app\workflow\stateful\contentworkflow.py, line 48, in NewObjectProcessInstanceCreator for pd_name in cwf.getProcessDefinitionNamesForObject(obj): AttributeError: 'object' object has no attribute 'getProcessDefinitionNamesForObject' I would say, that step7 is working without problems. -- Best regards, Adam mailto:[EMAIL PROTECTED] -- ___ Zope3-users mailing list Zope3-users@zope.org http://mail.zope.org/mailman/listinfo/zope3-users
Re[2]: [Zope3-Users] can't get files using tortoiseSVN client
Hello aaron, You will have to enter the URL svn://svn.zope.org/repos/main/book/trunk into TortoiseSVN. That works for me. Sunday, July 17, 2005, 5:50:16 AM, you wrote: Dear all, I get answer from this link, http://subversion.tigris.org/faq.html#http-301-error so could anyone please send me the messageboardbuddydemo files to me. thanks From: aaron wang [EMAIL PROTECTED] To: zope3-users@zope.org Subject: [Zope3-Users] can't get files using tortoiseSVN client Date: Sun, 17 Jul 2005 02:54:24 + Hello all, Following the ZOPE3BOOK, 13.1 Step I: Preparation (page 108) I download the TortoiseSVN 12.1 and installed in my PC/winXP. Restarted and create a dir as d:\repo, open the folder and right click mouse, chose SVNcheckout... from the context menu. with the dialog field URL of repository set to http://svn.zope.org/book/trunk; and the Check out directory set to d:\repo click OK button the result always comes out as : Error: PROPFIND request failed on '/book/trunk' Error: PROPFIND of '/book/trunk': 301 Moved (http://svn.zope.org) but with browser the http://svn.zope.org/book/trunk/messageboard is reachable. What's wrong with my operations? If I have not access to that, should I set to anonymous mode? how? Thank you _ Don't just search. Find. Check out the new MSN Search! http://search.msn.com/ ___ Zope3-users mailing list Zope3-users@zope.org http://mail.zope.org/mailman/listinfo/zope3-users _ Express yourself instantly with MSN Messenger! Download today it's FREE! http://messenger.msn.click-url.com/go/onm00200471ave/direct/01/ ___ Zope3-users mailing list Zope3-users@zope.org http://mail.zope.org/mailman/listinfo/zope3-users -- Best regards, Adammailto:[EMAIL PROTECTED] ___ Zope3-users mailing list Zope3-users@zope.org http://mail.zope.org/mailman/listinfo/zope3-users
Re: [Zope3-Users] Zope3 Product directory Problem
Hello Shariq, Plone is a product for Zope 2.xx. Monday, July 11, 2005, 1:07:12 PM, you wrote: ss ss Hi, ss I have download Zope3 by using Python 2.3 but i didn't find ss any Product directory where I can install Plone. ss How to install Plone. ss Kindly help me, ss Thanks in advance ss Shariq br, Adam ___ Zope3-users mailing list Zope3-users@zope.org http://mail.zope.org/mailman/listinfo/zope3-users
[Zope3-Users] fighting with Pluggable Authentication Utility
Now I have a problem with the Pluggable Authentication Utility. (win32/Zope3/trunk/30009) I have a folder(hu03), which a made a Site. In the default Site-Management Folder I created a Pluggable Authentication Utility (pauloc). Which has a SessionCredentialsPlugin (s2), a PrincipalFolder (usrloc) and a HTTP Basic-Auth Plugin (http2). There is one user in the PrincipalFolder (jani). For Credentials Plugins http2 and s2 is selected. For Authenticator Plugins usrloc is selected. Every plugin is active. Just for fun with (http://localhost:8080/hu03/++etc++site/default/pauloc/usrloc/@@grant.html) I granted _every_ role and permission to jani, including Site Manager, Site Member, ... Now jani is able to login, but objects requiring zope.ManageContent permission just return Unathorized. There is a method, zope.app.securitypolicy.zopepolicy.settingsForObject which I tried to use to check permissions with. But it returns: hu03 {'principalPermissions': [], 'rolePermissions': [], 'principalRoles': []} {'principalPermissions': [], 'rolePermissions': [], 'principalRoles': []} global settings {'principalPermissions': [], 'rolePermissions': [{'setting': PermissionSetting: Allow, 'role': 'bugtracker.User', 'permission': 'bugtracker.AddBug'}, {'setting': PermissionSetting: Allow, 'role': 'zope.Manager', 'permission': 'bugtracker.AddBug'}, {'setting': PermissionSetting: Allow, 'role': 'zope.Manager', 'permission': ... I guess that means that jani does not have the roles/permissions. Please help -- Best regards, Adam mailto:[EMAIL PROTECTED] ___ Zope3-users mailing list Zope3-users@zope.org http://mail.zope.org/mailman/listinfo/zope3-users