Re: [Zope] Product refreshing in Zope 2.9
On 1/30/06, Andreas Jung <lists@andreas-jung.com> wrote:
--On 30. Januar 2006 17:39:11 +0000 Peter Bengtsson <peter@fry-it.com> wrote:
It's not a strange product. It's quite simple in fact. Not being able to refresh without restarting means that I can't use Zope 2.9 for python product development.
Why is refresh a requirement for doing Zope development? I am doing Zope development since five or six years and I have never done any development using Refresh...so there must be something very special with your development approach?!
Sorry. It's not a _requirement_. But without it I loose productivity. (see my previous email on this topic with the human benchmark, ValueErrors and lost SESSIONS). I too have several years of zope programming beyond the ZMI and have developed many products and refreshing is the only way I know to quickly test changes. Having to wait a few seconds for each test is not an option. How do you solve this problem without refreshing? Or are you ready to wait for the zope restart and avoid it by writing more unit tests? -- Peter Bengtsson, work www.fry-it.com home www.peterbe.com hobby www.issuetrackerproduct.com
Peter Bengtsson wrote:
On 1/30/06, Andreas Jung wrote:
--On 30. Januar 2006 17:39:11 +0000 Peter Bengtsson wrote:
It's not a strange product. It's quite simple in fact. Not being able to refresh without restarting means that I can't use Zope 2.9 for python product development. Why is refresh a requirement for doing Zope development? I am doing Zope development since five or six years and I have never done any development using Refresh...so there must be something very special with your development approach?!
Sorry. It's not a _requirement_. But without it I loose productivity. (see my previous email on this topic with the human benchmark, ValueErrors and lost SESSIONS).
I too have several years of zope programming beyond the ZMI and have developed many products and refreshing is the only way I know to quickly test changes. Having to wait a few seconds for each test is not an option.
How do you solve this problem without refreshing? Or are you ready to wait for the zope restart and avoid it by writing more unit tests?
Yes most people who are serious about their developments use unit tests and functional tests and non-regression tests. They start by coding tests and doctests about code they've not yet written. In most cases when I develop, I don't go to the ZMI until quite late in the process. Going to the ZMI is not productive. That's why I, like others in this thread, don't care about refresh. Florent -- Florent Guillaume, Nuxeo (Paris, France) CTO, Director of R&D +33 1 40 33 71 59 http://nuxeo.com fg@nuxeo.com
On 1/31/06, Florent Guillaume <fg@nuxeo.com> wrote:
Peter Bengtsson wrote:
On 1/30/06, Andreas Jung wrote:
--On 30. Januar 2006 17:39:11 +0000 Peter Bengtsson wrote:
It's not a strange product. It's quite simple in fact. Not being able to refresh without restarting means that I can't use Zope 2.9 for python product development. Why is refresh a requirement for doing Zope development? I am doing Zope development since five or six years and I have never done any development using Refresh...so there must be something very special with your development approach?!
Sorry. It's not a _requirement_. But without it I loose productivity. (see my previous email on this topic with the human benchmark, ValueErrors and lost SESSIONS).
I too have several years of zope programming beyond the ZMI and have developed many products and refreshing is the only way I know to quickly test changes. Having to wait a few seconds for each test is not an option.
How do you solve this problem without refreshing? Or are you ready to wait for the zope restart and avoid it by writing more unit tests?
Yes most people who are serious about their developments use unit tests and functional tests and non-regression tests. They start by coding tests and doctests about code they've not yet written.
In most cases when I develop, I don't go to the ZMI until quite late in the process. Going to the ZMI is not productive.
I don't go into the ZMI either, I have scripts that call manage_performRefresh() from the commandline. Few of my projects are brain surgery. Often I develop products for clients that don't need a rocket engine, just a neat app to handle their content. It usually doesn't require brains, just time. BUT I don't want to go back to develop this content handling with Script (Python) and ZSQL Methods.
That's why I, like others in this thread, don't care about refresh.
Like I mentioned elsewhere, with my setup, restarting zope is gravely inferior to zope-restart for product development. I'm happy to share my setup to Open Source but it's quite "personal" so I'd have to spend as much time explaining it as I have spent writing it. Hmm... perhaps a screencast? -- Peter Bengtsson, work www.fry-it.com home www.peterbe.com hobby www.issuetrackerproduct.com
On 31 Jan 2006, at 12:02, Peter Bengtsson wrote:
That's why I, like others in this thread, don't care about refresh.
Like I mentioned elsewhere, with my setup, restarting zope is gravely inferior to zope-restart for product development.
I'm happy to share my setup to Open Source but it's quite "personal" so I'd have to spend as much time explaining it as I have spent writing it. Hmm... perhaps a screencast?
I don't think there is any need for that. The situation is pretty simple: You have an itch, but no one cares enough to scratch it for you. The only sane way forward is for you to scratch the itch yourself. jens
On 1/31/06, Jens Vagelpohl <jens@dataflake.org> wrote:
On 31 Jan 2006, at 12:02, Peter Bengtsson wrote:
That's why I, like others in this thread, don't care about refresh.
Like I mentioned elsewhere, with my setup, restarting zope is gravely inferior to zope-restart for product development.
I'm happy to share my setup to Open Source but it's quite "personal" so I'd have to spend as much time explaining it as I have spent writing it. Hmm... perhaps a screencast?
I don't think there is any need for that. The situation is pretty simple: You have an itch, but no one cares enough to scratch it for you. The only sane way forward is for you to scratch the itch yourself.
But that's what I'm doing! Thanks to Dieter I've got som genuine technical help on what it might be instead of just people saying "that's not how I do it, give up" And I don't understand how Zope product refresh doesn't have a higher attention priority when it's so useful. As far as I know, it's the only way to make changes to a zope2 product without having to restart the server causing downtime and lost sessions. -- Peter Bengtsson, work www.fry-it.com home www.peterbe.com hobby www.issuetrackerproduct.com
Peter Bengtsson wrote:
On 1/31/06, Jens Vagelpohl <jens@dataflake.org> wrote:
And I don't understand how Zope product refresh doesn't have a higher attention priority when it's so useful. As far as I know, it's the only way to make changes to a zope2 product without having to restart the server causing downtime and lost sessions.
Oh, but it has. I just haven't moved to 2.9 yet. Not having refresh would be extremely annoying. -- hilsen/regards Max M, Denmark http://www.mxm.dk/ IT's Mad Science
Peter Bengtsson wrote:
On 1/31/06, Jens Vagelpohl <jens-G0EXMjp3EnnNLxjTenLetw@public.gmane.org> wrote:
On 31 Jan 2006, at 12:02, Peter Bengtsson wrote:
That's why I, like others in this thread, don't care about refresh.
Like I mentioned elsewhere, with my setup, restarting zope is gravely inferior to zope-restart for product development.
I'm happy to share my setup to Open Source but it's quite "personal" so I'd have to spend as much time explaining it as I have spent writing it. Hmm... perhaps a screencast? I don't think there is any need for that. The situation is pretty simple: You have an itch, but no one cares enough to scratch it for you. The only sane way forward is for you to scratch the itch yourself.
But that's what I'm doing! Thanks to Dieter I've got som genuine technical help on what it might be instead of just people saying "that's not how I do it, give up"
And I don't understand how Zope product refresh doesn't have a higher attention priority when it's so useful.
Refresh works well in limited situations, but it *cannot work* if you have global registries or many interrelated modules.
As far as I know, it's the only way to make changes to a zope2 product without having to restart the server causing downtime and lost sessions.
Then use ZEO. And on a development server you can have the sessions in a shared ZEO filestorage. Florent -- Florent Guillaume, Nuxeo (Paris, France) Director of R&D +33 1 40 33 71 59 http://nuxeo.com fg@nuxeo.com
On 1/31/06, Florent Guillaume <fg@nuxeo.com> wrote:
Peter Bengtsson wrote:
On 1/31/06, Jens Vagelpohl <jens-G0EXMjp3EnnNLxjTenLetw@public.gmane.org> wrote:
On 31 Jan 2006, at 12:02, Peter Bengtsson wrote:
That's why I, like others in this thread, don't care about refresh.
Like I mentioned elsewhere, with my setup, restarting zope is gravely inferior to zope-restart for product development.
I'm happy to share my setup to Open Source but it's quite "personal" so I'd have to spend as much time explaining it as I have spent writing it. Hmm... perhaps a screencast? I don't think there is any need for that. The situation is pretty simple: You have an itch, but no one cares enough to scratch it for you. The only sane way forward is for you to scratch the itch yourself.
But that's what I'm doing! Thanks to Dieter I've got som genuine technical help on what it might be instead of just people saying "that's not how I do it, give up"
And I don't understand how Zope product refresh doesn't have a higher attention priority when it's so useful.
Refresh works well in limited situations, but it *cannot work* if you have global registries or many interrelated modules.
The setup I use takes care of dependencies in a semi-manual way. In my refresh-config I define which other products depend on the one I'm defining. Problem solved.
As far as I know, it's the only way to make changes to a zope2 product without having to restart the server causing downtime and lost sessions.
Then use ZEO. And on a development server you can have the sessions in a shared ZEO filestorage.
Didn't know that was possible. Would still be nice to have a working product refresh in z2.9 :) -- Peter Bengtsson, work www.fry-it.com home www.peterbe.com hobby www.issuetrackerproduct.com
On 1/31/06, Peter Bengtsson <peter@fry-it.com> wrote:
Refresh works well in limited situations, but it *cannot work* if you have global registries or many interrelated modules.
The setup I use takes care of dependencies in a semi-manual way. In my refresh-config I define which other products depend on the one I'm defining. Problem solved.
Well, if you have actually solved this problem, and therefore made Refresh useful, one question that pops up is why this hasn't been moved into Zope. ;) -- Lennart Regebro, Nuxeo http://www.nuxeo.com/ CPS Content Management http://www.cps-project.org/
On 1/31/06, Lennart Regebro <regebro@gmail.com> wrote:
On 1/31/06, Peter Bengtsson <peter@fry-it.com> wrote:
Refresh works well in limited situations, but it *cannot work* if you have global registries or many interrelated modules.
The setup I use takes care of dependencies in a semi-manual way. In my refresh-config I define which other products depend on the one I'm defining. Problem solved.
Well, if you have actually solved this problem, and therefore made Refresh useful, one question that pops up is why this hasn't been moved into Zope. ;)
The setup is quite personal and ad hoc and probably only works on linux. I'm going to write an article about it some time soon but I've been waiting for finishing my company's website first where I'll publish it together with the code. In all honesty: lazyness :) -- Peter Bengtsson, work www.fry-it.com home www.peterbe.com hobby www.issuetrackerproduct.com
This thread has been interesting. I wish there was even more writing about how people develop with zope. I have "completed" my first zope product and I find that the change in mindset is the biggest challenge. Zope is cool but it is quite different from php or java or cgi. I wish that there was complete basic application that had all the standard features in it so that a new developer could just start with that template and modify. I have downloaded many of the products from zope.org but they really don't tie everything togather. I am looking for something that covers login in users, building tables out of data stored in zodb, getters and setters for objects in the zodb, collecting a variable in one page and passing it on to another page where it modifies the data display, working with Sessions, etc. I guess what I'm looking for is a template for a real application, not for the individual pieces of functionality. And if it it has associated test framework, unit tests, setup scripts etc. that is even better. One application that has it all factored out to the most common way zope is used would be a beautiful thing. Also, more writting on how you guys go about developing zope apps. Do you start from scratch each time or do you have your own templates? Do you use the zmi? Do you mix zpt and dtml? What is the best products? most commonly used products? BTW, I find refresh usefull because my site is hosted in Europe and I'm in Calif.. I can live without refresh but it is one more reason for me to not request a zope upgrade from my hosting service. And if it isn't going to work, shouldn't it be removed? Tim On 1/31/06, Peter Bengtsson <peter@fry-it.com> wrote:
On 1/31/06, Lennart Regebro <regebro@gmail.com> wrote:
On 1/31/06, Peter Bengtsson <peter@fry-it.com> wrote:
Refresh works well in limited situations, but it *cannot work* if you have global registries or many interrelated modules.
The setup I use takes care of dependencies in a semi-manual way. In my refresh-config I define which other products depend on the one I'm defining. Problem solved.
Well, if you have actually solved this problem, and therefore made Refresh useful, one question that pops up is why this hasn't been moved into Zope. ;)
The setup is quite personal and ad hoc and probably only works on linux. I'm going to write an article about it some time soon but I've been waiting for finishing my company's website first where I'll publish it together with the code. In all honesty: lazyness :)
-- Peter Bengtsson, work www.fry-it.com home www.peterbe.com hobby www.issuetrackerproduct.com _______________________________________________ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )
Tim Nash wrote at 2006-1-31 11:48 -0800:
... I have "completed" my first zope product and I find that the change in mindset is the biggest challenge. Zope is cool but it is quite different from php or java or cgi.
Have you read the "Zope Developper Guide"? It is something like a basic guide to product development in Zope 2.
... I have downloaded many of the products from zope.org but they really don't tie everything togather.
"Products" are extensions that try to have very few dependancies. Therefore, they try not to tie other things together but use only services of Zope (which is always available). The things that tie together are Zope itself and larger frameworks on top of it, such as e.g. the CMF or Plone/CPS/Silva.
I am looking for something that covers login in users,
Look for the product "PAS" (PluggableAuthenticationService).
building tables out of data stored in zodb,
There is a product "TinyTables" (or similar) for (as the name tells you) "tiny" tables. Zope does not (yet) support large tables (it is not a relational database). But, you can use the "ZCatalog" to search your objects. Read the "searching" chapter in the Zope Book (Online, 2.7 edition).
... getters and setters for objects in the zodb,
There is no difference in attribute access for persistent objects (those in the ZODB) and standard Python objects. Read the Python tutorial.
collecting a variable in one page and passing it on to another page
You have the standard HTML facility (e.g. query string and hidden variables; function in "ZTUtils.Zope" help you in using them) and you have sessions (explained in the Zope Book; read it!)
where it modifies the data display, working with Sessions, etc. I guess what I'm looking for is a template for a real application, not for the individual pieces of functionality.
I guess, you read the resources mentioned above ("Zope Developper Guide" and "Zope Book, 2.7 edition, online") and then come back with concrete questions. Maybe, you then write the tutorial you are looking for now -- to the profit of future new Zope users... -- Dieter
The things that tie together are Zope itself and larger frameworks on top of it, such as e.g. the CMF or Plone/CPS/Silva. Do you mean that nobody actually writes an application without using CMF or Plone/CPS/Silva? If that is the case then that explains my slow rate of development. But I wonder if I want to continue with zope. It looks like a cool application server, I have written an application (slowly) and I was hoping that I could see better examples of how to write a complete application. There is very little on sourceforge. I have read the "zope bible" cover to cover and I have read most of the zope book, but I admit that I haven't read the developer book. ( hate reading large amounts of text online). I guess that is my future.
As for a specific question. Here goes: Could I please get a Zope application written by someone who has > 2 years of Zope experience that uses several dtml or zpt pages, that 1. registers a user 2. collects data from a user and saves that data to the zodb 3. manages the accumulation of data in the zodb? If it was developed outside the zmi (I hope) can you also send me the associated test framework? Thanks! On 2/1/06, Dieter Maurer <dieter@handshake.de> wrote:
Tim Nash wrote at 2006-1-31 11:48 -0800:
... I have "completed" my first zope product and I find that the change in mindset is the biggest challenge. Zope is cool but it is quite different from php or java or cgi.
Have you read the "Zope Developper Guide"?
It is something like a basic guide to product development in Zope 2.
... I have downloaded many of the products from zope.org but they really don't tie everything togather.
"Products" are extensions that try to have very few dependancies. Therefore, they try not to tie other things together but use only services of Zope (which is always available).
The things that tie together are Zope itself and larger frameworks on top of it, such as e.g. the CMF or Plone/CPS/Silva.
I am looking for something that covers login in users,
Look for the product "PAS" (PluggableAuthenticationService).
building tables out of data stored in zodb,
There is a product "TinyTables" (or similar) for (as the name tells you) "tiny" tables.
Zope does not (yet) support large tables (it is not a relational database). But, you can use the "ZCatalog" to search your objects. Read the "searching" chapter in the Zope Book (Online, 2.7 edition).
... getters and setters for objects in the zodb,
There is no difference in attribute access for persistent objects (those in the ZODB) and standard Python objects.
Read the Python tutorial.
collecting a variable in one page and passing it on to another page
You have the standard HTML facility (e.g. query string and hidden variables; function in "ZTUtils.Zope" help you in using them) and you have sessions (explained in the Zope Book; read it!)
where it modifies the data display, working with Sessions, etc. I guess what I'm looking for is a template for a real application, not for the individual pieces of functionality.
I guess, you read the resources mentioned above ("Zope Developper Guide" and "Zope Book, 2.7 edition, online") and then come back with concrete questions.
Maybe, you then write the tutorial you are looking for now -- to the profit of future new Zope users...
-- Dieter
On 2/2/06, Tim Nash <thedagdae@gmail.com> wrote:
The things that tie together are Zope itself and larger frameworks on top of it, such as e.g. the CMF or Plone/CPS/Silva. Do you mean that nobody actually writes an application without using CMF or Plone/CPS/Silva? If that is the case then that explains my slow rate of development.
Well, the development speed is not higher because you use these frameworks. It's just they they have done a lot of generally useful work, so you don't have to develop it. -- Lennart Regebro, Nuxeo http://www.nuxeo.com/ CPS Content Management http://www.cps-project.org/
maybe you can check iungo at http://iungo.org ? On 2/3/06, Tim Nash <thedagdae@gmail.com> wrote:
The things that tie together are Zope itself and larger frameworks on top of it, such as e.g. the CMF or Plone/CPS/Silva. Do you mean that nobody actually writes an application without using CMF or Plone/CPS/Silva? If that is the case then that explains my slow rate of development. But I wonder if I want to continue with zope. It looks like a cool application server, I have written an application (slowly) and I was hoping that I could see better examples of how to write a complete application. There is very little on sourceforge. I have read the "zope bible" cover to cover and I have read most of the zope book, but I admit that I haven't read the developer book. ( hate reading large amounts of text online). I guess that is my future.
As for a specific question. Here goes: Could I please get a Zope application written by someone who has > 2 years of Zope experience that uses several dtml or zpt pages, that 1. registers a user 2. collects data from a user and saves that data to the zodb 3. manages the accumulation of data in the zodb? If it was developed outside the zmi (I hope) can you also send me the associated test framework?
Thanks!
On 2/1/06, Dieter Maurer <dieter@handshake.de> wrote:
Tim Nash wrote at 2006-1-31 11:48 -0800:
... I have "completed" my first zope product and I find that the change in mindset is the biggest challenge. Zope is cool but it is quite different from php or java or cgi.
Have you read the "Zope Developper Guide"?
It is something like a basic guide to product development in Zope 2.
... I have downloaded many of the products from zope.org but they really don't tie everything togather.
"Products" are extensions that try to have very few dependancies. Therefore, they try not to tie other things together but use only services of Zope (which is always available).
The things that tie together are Zope itself and larger frameworks on top of it, such as e.g. the CMF or Plone/CPS/Silva.
I am looking for something that covers login in users,
Look for the product "PAS" (PluggableAuthenticationService).
building tables out of data stored in zodb,
There is a product "TinyTables" (or similar) for (as the name tells you) "tiny" tables.
Zope does not (yet) support large tables (it is not a relational database). But, you can use the "ZCatalog" to search your objects. Read the "searching" chapter in the Zope Book (Online, 2.7 edition).
... getters and setters for objects in the zodb,
There is no difference in attribute access for persistent objects (those in the ZODB) and standard Python objects.
Read the Python tutorial.
collecting a variable in one page and passing it on to another page
You have the standard HTML facility (e.g. query string and hidden variables; function in "ZTUtils.Zope" help you in using them) and you have sessions (explained in the Zope Book; read it!)
where it modifies the data display, working with Sessions, etc. I guess what I'm looking for is a template for a real application, not for the individual pieces of functionality.
I guess, you read the resources mentioned above ("Zope Developper Guide" and "Zope Book, 2.7 edition, online") and then come back with concrete questions.
Maybe, you then write the tutorial you are looking for now -- to the profit of future new Zope users...
-- Dieter
_______________________________________________ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )
Tim Nash wrote at 2006-2-2 11:50 -0800:
... As for a specific question. Here goes: Could I please get a Zope application written by someone who has > 2 years of Zope experience that uses several dtml or zpt pages, that 1. registers a user 2. collects data from a user and saves that data to the zodb 3. manages the accumulation of data in the zodb? If it was developed outside the zmi (I hope) can you also send me the associated test framework?
Have a look at Plone or Silva or CPS. There, you find complete content management systems on top of Zope doing all of the things you call for (but much more).
Dieter
-- Dieter
This thread has been interesting. I wish there was even more writing about how people develop with zope. I have "completed" my first zope product and I find that the change in mindset is the biggest challenge. Zope is cool but it is quite different from php or java or cgi. I wish that there was complete basic application that had all the standard features in it so that a new developer could just start with that template and modify. I have downloaded many of the products from zope.org but they really don't tie everything togather. I am looking for something that covers login in users, building tables out of data stored in zodb, getters and setters for objects in the zodb, collecting a variable in one page and passing it on to another page where it modifies the data display, working with Sessions, etc. I guess what I'm looking for is a template for a real application, not for the individual pieces of functionality. And if it it has associated test framework, unit tests, setup scripts etc. that is even better. One application that has it all factored out to the most common way zope is used would be a beautiful thing. Also, more writting on how you guys go about developing zope apps. Do you start from scratch each time or do you have your own templates? Do you use the zmi? Do you mix zpt and dtml? What is the best products? most commonly used products? BTW, I find refresh usefull because my site is hosted in Europe and I'm in Calif.. I can live without refresh but it is one more reason for me to not request a zope upgrade from my hosting service. And if it isn't going to work, shouldn't it be removed? Tim On 1/31/06, Peter Bengtsson <peter@fry-it.com> wrote:
On 1/31/06, Lennart Regebro <regebro@gmail.com> wrote:
On 1/31/06, Peter Bengtsson <peter@fry-it.com> wrote:
Refresh works well in limited situations, but it *cannot work* if you have global registries or many interrelated modules.
The setup I use takes care of dependencies in a semi-manual way. In my refresh-config I define which other products depend on the one I'm defining. Problem solved.
Well, if you have actually solved this problem, and therefore made Refresh useful, one question that pops up is why this hasn't been moved into Zope. ;)
The setup is quite personal and ad hoc and probably only works on linux. I'm going to write an article about it some time soon but I've been waiting for finishing my company's website first where I'll publish it together with the code. In all honesty: lazyness :)
-- Peter Bengtsson, work www.fry-it.com home www.peterbe.com hobby www.issuetrackerproduct.com _______________________________________________ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )
On 31 Jan 2006, at 13:05, Peter Bengtsson wrote:
And I don't understand how Zope product refresh doesn't have a higher attention priority when it's so useful. As far as I know, it's the only way to make changes to a zope2 product without having to restart the server causing downtime and lost sessions.
You're assuming because you think something is useful other people must think the same. However, usefulness is in the eye of the beholder. I find it potentially harmful. jens
Peter Bengtsson wrote at 2006-1-31 13:05 +0000:
... But that's what I'm doing! Thanks to Dieter I've got som genuine technical help on what it might be instead of just people saying "that's not how I do it, give up"
I am an enthusiastic "refresh" user and find is *MUCH* more productive than the "zopectl fg" dance favoured by other developpers. However, I will probably never use Zope 2.9 (I would have quite some work but not really gain much from this release). Thus, I can support you only from the distance. But, I *AM* interested that "refresh" keeps working, as I may use Zope 2.10 or 2.11 again -- hopefully with "refresh". -- Dieter
participants (8)
-
ardo -
Dieter Maurer -
Florent Guillaume -
Jens Vagelpohl -
Lennart Regebro -
Max M -
Peter Bengtsson -
Tim Nash