From bb800f2cd7424c6280a7346303963d0f0daed935 Mon Sep 17 00:00:00 2001 From: Julien MIOTTE Date: Fri, 3 Jun 2016 09:20:14 +0200 Subject: Adding a warning discouraging use of __acl__ properties attributes --- docs/narr/security.rst | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'docs') diff --git a/docs/narr/security.rst b/docs/narr/security.rst index 7cbea113c..842aad23f 100644 --- a/docs/narr/security.rst +++ b/docs/narr/security.rst @@ -290,6 +290,13 @@ properties of the instance. def __init__(self, owner): self.owner = owner +.. warning:: + + Writing ``__acl__`` as properties is discouraged, as AttributeErrors + occuring in ``fget`` or ``fset`` will be silently dismissed (this is consistent + with Python ``getattr`` and ``hasattr`` behaviors). For dynamic ACLs, simply use + callables, as documented above. + .. index:: single: ACE single: access control entry -- cgit v1.2.3