Opened 19 years ago

Closed 19 years ago

Last modified 19 years ago

#1872 closed (invalid)

Documentation: module level methods

Reported by: bnomis@… Owned by: Jacob
Component: Documentation Version:
Severity: normal Keywords:
Cc: Triage Stage: Unreviewed
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no

Description

The documentation on module level methods has disappeared. Pre-MR this was _module_methods. I think post-MR we can used @staticmethod and @classmethod. It would be nice if this was explicity stated in the docs. This is different from Manager table wide methods - I think.

Change History (3)

comment:1 by Luke Plant, 19 years ago

You can use @staticmethod, @classmethod and plain old methods, as well as module level functions. The choice between module level functions and @staticmethods is mainly a matter of style. I personally think it shouldn't be stated anywhere in the documentation -- it works exactly like you would expect it to in Python, and for those who are not aware of the bad old days, this would just be pointing out the obvious. If it's not in the RemovingTheMagic wiki page, maybe you could add it there.

comment:2 by Adrian Holovaty, 19 years ago

Resolution: invalid
Status: newclosed

Closing for the reason outlined by lukeplant in the previous comment.

comment:3 by Main, 19 years ago

Type: defect
Note: See TracTickets for help on using tickets.
Back to Top