| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
|
@dhermes the general idea here LGTM. |
Sorry, something went wrong.
|
@tseaver PTAL. I'd really like to get the list_foo() migration done |
Sorry, something went wrong.
Instead require `Iterator` takes: - a well-formed path for the request - a callable to convert a JSON item to native obj. - (optional) the key in a response holding all items - (optional) a `page_start` (acts as proxy for `Page.__init__`)
There was a problem hiding this comment.
Except for the odd bit of having item_to_value be optional, this looks right to me.
Sorry, something went wrong.
| :param item_to_value: (Optional) Callable to convert an item from JSON | ||
| into the native object. Assumed signature | ||
| takes an :class:`Iterator` and a dictionary | ||
| holding a single item. |
|
|
||
| :type items_key: str | ||
| :param items_key: The key used to grab retrieved items from an API | ||
| response. Defaults to :data:`DEFAULT_ITEMS_KEY`. |
|
@tseaver So I'll add "(Optional)" to the docstring and make item_to_value a positional / required argument. (UPDATE: And fix the lint error. Wrong PR.) Good to merge after those changes are in? |
Sorry, something went wrong.
Yup. |
Sorry, something went wrong.
Also adding "(Optional)" to items_key docstring.
|
OK, waited an hour for Travis. Merging. (There is a lot to do after.) |
Sorry, something went wrong.
…lasses Removing Iterator and Page subclasses.
Removing Iterator and Page subclasses.
…](GoogleCloudPlatform/python-docs-samples#2558) * fix: Use different versions of pytest for python 2 and python3 * fix: delete extra pytest dep * fix: update pytest dependencies in requirements.txt
Removing Iterator and Page subclasses.
Removing Iterator and Page subclasses.
| Back | FazBrowse Home | New Git URL |
Instead require Iterator takes: