Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Revise section "Zope Security" #546

Merged
merged 3 commits into from
Apr 14, 2019
Merged

Revise section "Zope Security" #546

merged 3 commits into from
Apr 14, 2019

Conversation

jugmac00
Copy link
Member

  • improve formatting
  • add links for further information about Acquisition
  • fix references to other chapters

modified: docs/zdgbook/ObjectPublishing.rst

- improve formatting
- add links for further information about Acquisition
- fix references to other chapters

modified:   docs/zdgbook/ObjectPublishing.rst
@jugmac00
Copy link
Member Author

jugmac00 commented Apr 11, 2019

I have to admit, this is one of the first section which I revise, which I am not able to follow / understand completely. Especially the first half sentence. Like, of course we use Zope - its the application server. I do not get the difference between "using Zope" vs "own module".

Also, I am unsure whether the "Explicit or Implicit" is necessary is correct.

For example, in the legacy code base, which I maintain, I got a class, which only inherits from "OFS.Folder.Folder".

Having a look at the mro:

 <class 'OFS.ObjectManager.ObjectManager'>,
 <class 'OFS.CopySupport.CopyContainer'>,
 <class 'App.Management.Navigation'>,
 <class 'App.Management.Tabs'>,
 <type 'Acquirer'>,
 <type 'Persistence.Persistent'>,
 <type 'persistent.Persistent'>,
 <class 'webdav.Collection.Collection'>,
 <class 'webdav.Resource.Resource'>,
 <class webdav.Lockable.LockableItem at 0x7f61135d7a78>,
 <class webdav.EtagSupport.EtagSupport at 0x7f61135d79a8>,
 <class OFS.Traversable.Traversable at 0x7f6112bd1ae0>,
 <class 'OFS.PropertyManager.PropertyManager'>,
 <class OFS.ZDOM.ElementWithAttributes at 0x7f6112bf6b48>,
 <class OFS.ZDOM.Element at 0x7f6112bf6ae0>,
 <class OFS.ZDOM.Node at 0x7f6112bf6a10>,
 <class 'OFS.role.RoleManager'>,
 <class 'AccessControl.rolemanager.RoleManager'>,
 <class AccessControl.PermissionMapping.RoleManager at 0x7f6112f07808>,
 <class 'OFS.SimpleItem.Item'>,
 <class 'OFS.CopySupport.CopySource'>,
 <class 'OFS.owner.Owned'>,
 <class 'AccessControl.owner.Owned'>,
 <class 'App.Undo.UndoSupport'>,
 <class 'OFS.FindSupport.FindSupport'>,
 <type 'ExtensionClass.Base'>,
 <type 'object'>)```

It neither inherits from Explicit nor Implicit, but still gets published.

Any suggestions on this?

@hannosch hannosch removed their request for review April 11, 2019 18:32
@dataflake
Copy link
Member

dataflake commented Apr 13, 2019

Like, of course we use Zope - its the application server. I do not get the difference between "using Zope" vs "own module".

Originally the ZPublisher was thought of as a generic publisher that could publish not just Zope, but other modules as well. IMHO that whole half sentence can go away. Instead of When using Zope rather than publishing your own modules, the replace it with The.

Having a look at the mro:

I have never used the mro to determine subclasses/mixins, so I can't say whether that is a suitable approach at all. Instead, look at the source, Luke! OFS.Folder.Folder derives from OFS.ObjectManager.ObjectManager, which mixes in Acquisition.Implicit.

Copy link
Member

@dataflake dataflake left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

After that one replacement it's ready for merging.

docs/zdgbook/ObjectPublishing.rst Outdated Show resolved Hide resolved
The maybe once true distinction between using Zope vs publishing "own
modules" with ZPublisher no longer is valid.

Removed it.

modified:   docs/zdgbook/ObjectPublishing.rst
@jugmac00 jugmac00 requested a review from dataflake April 13, 2019 23:15
@jugmac00
Copy link
Member Author

Once again, thanks a lot for taking your time to review my changes and the hint about OFS.ObjectManager.ObjectManager!

“I’m just a simple man trying to make my way in the universe.” — Jango Fett

@dataflake
Copy link
Member

@jugmac00 I'm really happy you are taking this time to rework the docs. You know best how short-staffed we are. @icemac will agree that any help is highly appreciated.

@jugmac00
Copy link
Member Author

@dataflake Would you mind to approving the pull request? :-)

@dataflake dataflake merged commit 77d2b99 into master Apr 14, 2019
@dataflake dataflake deleted the zope-security branch April 14, 2019 04:15
@dataflake
Copy link
Member

Oops, had not seen the last commit

jugmac00 added a commit that referenced this pull request Apr 14, 2019
The introductory sentence says it all: "If you are using the Zope
framework, this section will be irrelevant to you."

Also see discussion about "ZPublisher for Zope vs own module", see
#546 (comment)

modified:   docs/zdgbook/ObjectPublishing.rst
dataflake pushed a commit that referenced this pull request Apr 14, 2019
* Drop subsection testing.

As there is no information about the mentioned "builtin support" for
testing.

A link to the testing section is already in the table of contents.

modified:   docs/zdgbook/ObjectPublishing.rst

* Drop subsection "Publishable Module".

The introductory sentence says it all: "If you are using the Zope
framework, this section will be irrelevant to you."

Also see discussion about "ZPublisher for Zope vs own module", see
#546 (comment)

modified:   docs/zdgbook/ObjectPublishing.rst

* Delete introductionary paragraph.

As it relates to the now deleted previous subsection.

modified:   docs/zdgbook/ObjectPublishing.rst
@icemac
Copy link
Member

icemac commented Apr 15, 2019

Help is highly appreciated especially on the documentation which was not updated in years.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants