So there I was in this discussion about Zope versioning (again) and there were two features requested that seemed perfectly reasonable at the time,
- to have a list of all the objects changed by a version
Sorry if this is obvious, but at least neither ZopeFind nor locked_in_version() seem to be mentioned anywhere in zope's (2.3.3) online docu, so I thought I might post it: <dtml-in "ZopeFind(PARENTS[-1],search_sub=1,obj_expr='locked_in_version()')"> <LI>found <dtml-var title_or_id html_quote> in Version <dtml-var locked_in_version> </dtml-in>
- to be able to individually commit or discard changes in a version on a per object basis
This is would be extremely useful for those times when you forget to check out of a version and accidentally lock the root folder (This happens quite a bit). Simple I thought, but ugh versions go all the way down to FileStorage and got into ZODB stuff I didnt understand. I would have thought having a little refactoring to give two more methods: getVersionContents and commitObject would be possible, but Im scratching my head at FileStorage now.
Hehe, I feel with you, looking at how versions work takes one straight to Filestorage.commitVersion and some very low level code.
Before I embark down this path is there an easier way?
The question is if this is worth the effort, in the light of the new versioning discussion. The weaknesses of the current implementation of versioning puts some pressure to create something new IMO. cheers, oliver
<dtml-in "ZopeFind(PARENTS[-1],search_sub=1,obj_expr='locked_in_version()')"> <LI>found <dtml-var title_or_id html_quote> in Version <dtml-var locked_in_version> </dtml-in>
Yep I've done that, but looking through every object to see if its in the version rather than examining the versions seems some what icky (and can be expensive with lots of objects).
Hehe, I feel with you, looking at how versions work takes one straight to Filestorage.commitVersion and some very low level code.
Yup. Hence the post.
The question is if this is worth the effort, in the light of the new versioning discussion. The weaknesses of the current implementation of versioning puts some pressure to create something new IMO.
Yup, unfortunately I might be in a battle for Zope where time is of the essence. I was just hoping there was an easy way. Sounds like there isn't. -- Andy McKay
participants (2)
-
Andy McKay -
Oliver Bleutgen