Skip to content

Conversation

@kelseymorris95
Copy link
Contributor

No description provided.

@boxcla
Copy link

boxcla commented Aug 18, 2016

Verified that @kelseymorris95 has signed the CLA. Thanks for the pull request!

HISTORY.rst Outdated

**Breaking Changes**

- ``Events.get_events(...)`` now returns a list of ``Event`` instances rather than a list of ``dicts`` s
Copy link
Contributor

Choose a reason for hiding this comment

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

Just dict, not dicts.

HISTORY.rst Outdated

- ``Events.get_events(...)`` now returns a list of ``Event`` instances rather than a list of ``dicts`` s
representing ``Event`` s. ``Event`` inherits from ``Mapping`` but will not have all the same capabilities as
``dict`` .
Copy link
Contributor

Choose a reason for hiding this comment

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

Let's add a sub-bullet about how to migrate. Something like:

  • .
    • Your code is affected if you use Events.get_events(...) and expect a list of dict instead of a list of Mapping. For example, if you use __setitem__ (event['key'] = value), update(), or copy(), or if your code depends on the str or repr of the event. Use of __getitem__ (event['key']), get, and other Mapping methods is unaffected. See https://docs.python.org/2.7/library/collections.html#collections-abstract-base-classes for methods supported on Mapping instances.
    • How to migrate: if you still have the need to treat the events like a dict, then you can get a deepcopy of the original dict with the new attribute response_object.

@jmoldow
Copy link
Contributor

jmoldow commented Aug 19, 2016

👍

@jmoldow jmoldow merged commit 309336d into master Aug 19, 2016
@jmoldow jmoldow deleted the docs_update branch August 19, 2016 17:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants