| Age | Commit message (Collapse) | Author | |
|---|---|---|---|
| 2012-12-10 | prep for 1.4b2 | Chris McDonough | |
| 2012-12-10 | Merge branch 'master' of github.com:Pylons/pyramid | Chris McDonough | |
| 2012-12-10 | Merge pull request #736 from msabramo/docs-tutorials-wiki2-tweaks | Chris McDonough | |
| A bunch of minor tweaks to the wiki2 tutorial in docs/tutorials/wiki2 | |||
| 2012-12-10 | Merge pull request #738 from ppaez/pep8_scaffolds | Chris McDonough | |
| Improve pep8 compliance of scaffolds | |||
| 2012-12-06 | add changenote | Chris McDonough | |
| 2012-12-06 | make _backframes work like _depth (but still leave undocumented) | Chris McDonough | |
| 2012-12-06 | note custom_predicates deprecation | Chris McDonough | |
| 2012-12-06 | Merge branch '1.4-branch' | Chris McDonough | |
| 2012-12-06 | Merge branch '1.4-branch' of github.com:Pylons/pyramid into 1.4-branch | Chris McDonough | |
| 2012-12-06 | Merge pull request #739 from mmerickel/fix.view-config-depth | Chris McDonough | |
| _depth argument to view_config is now relative to view_config | |||
| 2012-12-06 | _depth argument to view_config is now relative to view_config | Michael Merickel | |
| This hides an implementation detail that view_config is at least 1 level away from user code. | |||
| 2012-12-02 | Sync tests.py and views.py in SQL wiki tutorial | Patricio Paez | |
| - No line references to update | |||
| 2012-12-02 | Sync initializedb.py in SQL wiki tutorial | Patricio Paez | |
| 2012-12-01 | Sync models.py in SQL wiki tutorial | Patricio Paez | |
| - Update lines and emphasized-lines - No line numbers if only a single line | |||
| 2012-12-01 | Sync __init__.py in SQL wiki tutorial | Patricio Paez | |
| - Update lines and emphasized-lines - No line numbers if only a single line | |||
| 2012-12-01 | unused import | Chris McDonough | |
| 2012-12-01 | Merge branch 'master' of github.com:Pylons/pyramid | Chris McDonough | |
| 2012-12-01 | Sync setup.py in SQL wiki tutorial | Patricio Paez | |
| 2012-12-01 | Update line references | Patricio Paez | |
| - In the Basic Layout and Authorization chapters of the ZODB wiki tutorial | |||
| 2012-12-01 | Sync ZODB tutorial source files with the scaffold | Patricio Paez | |
| 2012-11-30 | tutorials/wiki2/definingviews.rst: Change example error page from | Marc Abramowitz | |
| http://localhost:6543/add_page to http://localhost:6543/foobar/edit_page For me, the former generates "404 Not Found" (probably because it doesn't match a route) while the latter gives "sqlalchemy.orm.exc.NoResultFound" and the nice traceback from Werkzeug. | |||
| 2012-11-30 | A bunch of minor tweaks to the wiki2 tutorial in docs/tutorials/wiki2 | Marc Abramowitz | |
| 2012-11-29 | Sync MyProject files with the starter scaffold | Patricio Paez | |
| - Line numbers are mentioned only in the Creating a Pyramid Project chapter; those that are affected were updated. | |||
| 2012-11-29 | make scaffolds pep8 compliant | Gael Pasgrimaud | |
| Conflicts: pyramid/scaffolds/alchemy/+package+/views.py_tmpl pyramid/scaffolds/alchemy/setup.py_tmpl Solved the two conflicts | |||
| 2012-11-29 | Merge pull request #734 from slinkp/master | Chris McDonough | |
| Fix broken link to contributor docs on front page | |||
| 2012-11-29 | Fix broken link to contributor docs | Paul Winkler | |
| 2012-11-27 | Merge pull request #716 from ericrasmussen/scaffolds.requiresfix | Chris McDonough | |
| add transaction dependency to zodb scaffold | |||
| 2012-11-27 | Merge pull request #732 from ppaez/transaction-dependency | Chris McDonough | |
| Transaction dependency in ZODB tutorial | |||
| 2012-11-22 | typos | Chris McDonough | |
| 2012-11-22 | Sync the tutorial docs for the transaction dependency | Patricio Paez | |
| 2012-11-22 | more appeasement | Chris McDonough | |
| 2012-11-22 | appeasement | Chris McDonough | |
| 2012-11-21 | prep for 1.4b1 | Chris McDonough | |
| 2012-11-21 | prep for release | Chris McDonough | |
| 2012-11-21 | document new introspectable attrs | Chris McDonough | |
| 2012-11-21 | missed adding this file | Chris McDonough | |
| 2012-11-21 | Merge branch 'feature.eventonly' | Chris McDonough | |
| 2012-11-21 | fix for py3 | Chris McDonough | |
| 2012-11-21 | add an integration test for the eventonly behavior | Chris McDonough | |
| 2012-11-21 | garden | Chris McDonough | |
| 2012-11-21 | garden | Chris McDonough | |
| 2012-11-21 | - In order to normalize the relationship between event subscribers and | Chris McDonough | |
| subscriber predicates, we now allow both subscribers and subscriber predicates to accept only a single ``event`` argument even if they've been subscribed for notifications that involve multiple interfaces. Subscribers and subscriber predicates that accept only one argument will receive the first object passed to ``notify``; this is typically (but not always) the event object. The other objects involved in the subscription lookup will be discarded. For instance, if an event is sent by code like this:: registry.notify(event, context) In the past, in order to catch such an event, you were obligated to write and register an event subscriber that mentioned both the event and the context in its argument list:: @subscriber([SomeEvent, SomeContextType]) def subscriber(event, context): pass With the event-only feature you can now write an event subscriber that accepts only ``event`` even if it subscribes to multiple interfaces:: @subscriber([SomeEvent, SomeContextType]) def subscriber(event): # this will work! Note, however, that if the event object is not the first object in the call to ``notify``, you'll run into trouble. For example, if notify is called with the context argument first:: registry.notify(context, event) You won't be able to take advantage of the feature. It will "work", but the object received by your event handler won't be the event object, it will be the context object, which won't be very useful:: @subscriber([SomeContextType, SomeEvent]) def subscriber(event): # bzzt! you'll be getting the context here as ``event``, and it'll # be useless Existing multiple-argument subscribers continue to work without issue, so you should continue use those if your system notifies using multiple interfaces and the first interface is not the event interface. For example:: @subscriber([SomeContextType, SomeEvent]) def subscriber(context, event): # this will still work! The event-only feature makes it possible to use a subscriber predicate that accepts only a request argument within both multiple-interface subscriber registrations and single-interface subscriber registrations. In the past, if you had a subscriber predicate like this:: class RequestPathStartsWith(object): def __init__(self, val, config): self.val = val def text(self): return 'path_startswith = %s' % (self.val,) phash = text def __call__(self, event): return event.request.path.startswith(self.val) If you attempted to use the above predicate to condition a subscription that involved multiple interfaces, it would not work. You had to change it to accept the same arguments as the subscription itself. For example, you might have had to change its ``__call__`` method like so, adding a ``context`` argument:: def __call__(self, event, context): return event.request.path.startswith(self.val) With the event-only feature, you needn't make the change. Instead, you can write all predicates so they only accept ``event`` in their ``__call__`` and they'll be useful across all registrations for subscriptions that use an event as their first argument, even ones which accept more than just ``event``. However, the same caveat applies to predicates as to subscriptions: if you're subscribing to a multi-interface event, and the first interface is not the event interface, the predicate won't work properly. In such a case, you'll need to match the predicate ``__call__`` argument ordering and composition to the ordering of the interfaces. For example:: def __call__(self, context, event): return event.request.path.startswith(self.val) tl;dr: 1) Always use the event as the first argument to a multi-interface subscription and 2) Use only ``event`` in your subscriber and subscriber predicate parameter lists, no matter how many interfaces the subscriber is notified with, as long as the event object is the first argument passed to ``registry.notify``. This will result in the maximum amount of reusability of subscriber predicates. | |||
| 2012-11-20 | adding transaction module requirement to zodb wiki docs | ericrasmussen | |
| 2012-11-20 | add transaction dependency to zodb scaffold | ericrasmussen | |
| 2012-11-20 | garden | Chris McDonough | |
| 2012-11-20 | Merge branch 'sontek-fix_commands' | Chris McDonough | |
| 2012-11-20 | garden | Chris McDonough | |
| 2012-11-20 | garden | Chris McDonough | |
| 2012-11-20 | Merge branch 'master' into sontek-fix_commands | Chris McDonough | |
| 2012-11-20 | coverage | Chris McDonough | |
