Skip to content
This repository was archived by the owner on Aug 26, 2024. It is now read-only.

improve docs for fuzzywuzzy.process#68

Merged
acslater00 merged 1 commit into
seatgeek:masterfrom
nathantypanski:process-doc-cleanup
Feb 19, 2015
Merged

improve docs for fuzzywuzzy.process#68
acslater00 merged 1 commit into
seatgeek:masterfrom
nathantypanski:process-doc-cleanup

Conversation

@nathantypanski

Copy link
Copy Markdown
Contributor

The documentation for this module was dated and sometimes inaccurate.

This overhauls the docs to accurately describe the current module,
including detailing optional arguments that were not previously
explained - e.g., the limit argument to extract().

This change follows the Google Python Style Guide for comments.

The documentation for this module was dated and sometimes inaccurate.
This overhauls the docs to accurately describe the current module,
including detailing optional arguments that were not previously
explained - e.g., limit argument to extract().

This change follows the Google Python Style Guide, which may be found
at:

<https://google-styleguide.googlecode.com/svn/trunk/pyguide.html?showone=Comments#Comments>
nathantypanski added a commit to nathantypanski/fuzzywuzzy that referenced this pull request Nov 30, 2014
Previously, process.extract expected lists or dictionaries, and tested
this with isinstance() calls. In keeping with the spirit of Python (duck
typing and all that), this change enables one to use extract() on any
dict-like object for dict-like results, or any list-like object for
list-like results.

So now we can (and, indeed, I've added tests for these uses) call
extract() on things like:

- a generator of strings ("any iterable")
- a UserDict
- custom user-made classes that "look like" dicts
  (or, really, anything with a .items() method that behaves like a dict)
- plain old lists and dicts

The behavior is exactly the same for previous use cases of
lists-and-dicts.

This change goes along nicely with PR seatgeek#68, since those docs suggest
dict-like behavior is valid, and this change makes that true.
nathantypanski added a commit to nathantypanski/fuzzywuzzy that referenced this pull request Nov 30, 2014
Previously, process.extract expected lists or dictionaries, and tested
this with isinstance() calls. In keeping with the spirit of Python (duck
typing and all that), this change enables one to use extract() on any
dict-like object for dict-like results, or any list-like object for
list-like results.

So now we can (and, indeed, I've added tests for these uses) call
extract() on things like:

- a generator of strings ("any iterable")
- a UserDict
- custom user-made classes that "look like" dicts
  (or, really, anything with a .items() method that behaves like a dict)
- plain old lists and dicts

The behavior is exactly the same for previous use cases of
lists-and-dicts.

This change goes along nicely with PR seatgeek#68, since those docs suggest
dict-like behavior is valid, and this change makes that true.
@erwaller

erwaller commented Jan 5, 2015

Copy link
Copy Markdown
Member

@acslater00 does this look good to you?

@acslater00 acslater00 merged commit bc436d7 into seatgeek:master Feb 19, 2015
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants