diff options
| author | Chris McDonough <chrism@plope.com> | 2011-08-24 13:00:40 -0400 |
|---|---|---|
| committer | Chris McDonough <chrism@plope.com> | 2011-08-24 13:00:40 -0400 |
| commit | 0ded4eb250519abdc01bdf0dc0493f83cb0620a6 (patch) | |
| tree | 57b6fda140b713aa931a6357df48e150d706abe4 | |
| parent | b93af955803b3ae9dec72d6e3b0d3d3014e58b3f (diff) | |
| download | pyramid-0ded4eb250519abdc01bdf0dc0493f83cb0620a6.tar.gz pyramid-0ded4eb250519abdc01bdf0dc0493f83cb0620a6.tar.bz2 pyramid-0ded4eb250519abdc01bdf0dc0493f83cb0620a6.zip | |
explain better
| -rw-r--r-- | pyramid/config/__init__.py | 21 |
1 files changed, 13 insertions, 8 deletions
diff --git a/pyramid/config/__init__.py b/pyramid/config/__init__.py index baae824ac..80fd51d69 100644 --- a/pyramid/config/__init__.py +++ b/pyramid/config/__init__.py @@ -303,17 +303,22 @@ class Configurator( self.add_view(exceptionresponse_view, context=IExceptionResponse) self.add_view(exceptionresponse_view,context=WebobWSGIHTTPException) - # commit before adding default_view_mapper, as the - # exceptionresponse_view above requires the superdefault view - # mapper + # commit below because: + # + # - the default exceptionresponse_view requires the superdefault view + # mapper, so we need to configure it before adding default_view_mapper + # + # - provided default renderers should be overrideable without requiring + # the user to commit before calling config.add_renderer self.commit() - # The following registrations should be treated as if the methods had - # been called after configurator construction (commit should not be - # called after this). Rationale: user-supplied implementations - # should be preferred rather than add-on author implementations (as - # per automatic conflict resolution). + # self.commit() should not be called after this point because the + # following registrations should be treated as analogues of methods + # called by the user after configurator construction. Rationale: + # user-supplied implementations should be preferred rather than + # add-on author implementations with the help of automatic conflict + # resolution. if authentication_policy and not authorization_policy: authorization_policy = ACLAuthorizationPolicy() # default |
