Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Docs erroneously say that odict.add() only has two mandatory parameters #554

Closed
alexwlchan opened this issue Mar 9, 2017 · 9 comments
Closed

Comments

@alexwlchan
Copy link
Contributor

Quoting from the Extension API docs (emphasis mine):

The add() method accepts three arguments:

  • key: A string. The key is used for later reference to the item.
  • value: The object instance stored in this item.
  • location: Optional. The items location in relation to other items.

But the source code for the method shows that all three arguments are required:

def add(self, key, value, location):
    """ Insert by key location. """

Either the "Optional" should be removed from the docs, or the parameter should be made optional.

I’d mildly prefer the latter, as I have some cases where the location really doesn’t matter, but it’s not a strong preference.

@waylan
Copy link
Member

waylan commented Mar 9, 2017

Not sure why the docs say "optional". It never has been and doesn't make sense to be. I'll update the docs. Thanks for the report.

@waylan waylan closed this as completed in 03ebc27 Mar 9, 2017
@john-kurkowski
Copy link

john-kurkowski commented Nov 29, 2017

Thanks! Can you publish the doc update? http://pythonhosted.org/Markdown/extensions/api.html#ordereddict still says "Optional."

@waylan
Copy link
Member

waylan commented Nov 30, 2017

The docs are updated on each release.

@waylan
Copy link
Member

waylan commented Nov 30, 2017

Hmm, looks like we didn't update the docs when we released 2.6.9. Opps.

@facelessuser
Copy link
Collaborator

Docs don't auto-deploy on release? I figured they did, but I never really checked.

@waylan
Copy link
Member

waylan commented Nov 30, 2017

No, I never got that automated. The releases are so few and far between and it was never a problem to run make docs and then use the "edit" page on PyPI to upload the zip file. That is, until now. See #601 for the current state and my proposal to address it.

@facelessuser
Copy link
Collaborator

Have you settled on a theme? If you have (and when I have some time), I can probably set it up.

@facelessuser
Copy link
Collaborator

That is of course if you are ready to jump to Mkdocs.

@waylan
Copy link
Member

waylan commented Dec 1, 2017

The switch to MkDocs exists in the md3 branch at 6f87b32. That commit should "cherry-pick" and merge relatively easily. And I just finished and released the MkDocs-Nature theme to use with it (the md3 branch is currently using readthedocs). Whoever gets to it first...

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

No branches or pull requests

4 participants