Docs on setting the modification date
Nobody has claimed this yet.
- Dominant language
- Makefile
- Stars
- 106
- Forks
- 190
- Avg merge
- 3d 2h
- Merged PRs (30d)
- 1
Description
The documentation
https://5.docs.plone.org/develop/plone/content/timestamps.html#setting-modification-date-explicitly
is in general right but in reality it is wrong.
You usually need to call reindexObject() for object updates. And reindexObject() implicitly triggers an update of the modification_date property with the current timestamp. So it seems to be impossible to explicitly set the modification date.
/home/vmadmin/share-migration/eggs/zope.component-3.12.1-py2.7.egg/zope/component/_api.py(136)subscribers()
-> return sitemanager.subscribers(objects, interface)
/home/vmadmin/share-migration/eggs/zope.interface-4.2.0-py2.7-linux-x86_64.egg/zope/interface/registry.py(328)subscribers()
-> return self.adapters.subscribers(objects, provided)
/home/vmadmin/share-migration/eggs/zope.interface-4.2.0-py2.7-linux-x86_64.egg/zope/interface/adapter.py(596)subscribers()
-> subscription(*objects)
/home/vmadmin/share-migration/eggs/zope.component-3.12.1-py2.7.egg/zope/component/event.py(32)objectEventNotify()
-> zope.component.subscribers((event.object, event), None)
/home/vmadmin/share-migration/eggs/zope.component-3.12.1-py2.7.egg/zope/component/_api.py(136)subscribers()
-> return sitemanager.subscribers(objects, interface)
/home/vmadmin/share-migration/eggs/zope.interface-4.2.0-py2.7-linux-x86_64.egg/zope/interface/registry.py(328)subscribers()
-> return self.adapters.subscribers(objects, provided)
/home/vmadmin/share-migration/eggs/zope.interface-4.2.0-py2.7-linux-x86_64.egg/zope/interface/adapter.py(596)subscribers()
-> subscription(*objects)
/home/vmadmin/share-migration/eggs/plone.dexterity-2.5.1-py2.7.egg/plone/dexterity/content.py(784)reindexOnModify()
-> content.reindexObject()
/home/vmadmin/share-migration/eggs/Products.CMFCore-2.2.11-py2.7.egg/Products/CMFCore/CMFCatalogAware.py(85)reindexObject()
-> self.notifyModified()
/home/vmadmin/share-migration/eggs/plone.dexterity-2.5.1-py2.7.egg/plone/dexterity/content.py(381)notifyModified()
-> self.setModificationDate()
> /home/vmadmin/share-migration/eggs/plone.dexterity-2.5.1-py2.7.egg/plone/dexterity/content.py(405)setModificationDate()
-> self.modification_date = DateTime()
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the linked timestamps documentation and compare its instructions with the reported reindexObject() and setModificationDate() call stack. Verify the documented behavior around explicit modification dates, then update the page so it accurately describes the supported procedure and limitations; the issue is done when the documentation matches the observed Plone behavior.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- documentation
- Issue type
- Documentation
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 38/100