Skip to content

Argument Order Matters #5

Description

@nicksloan

The Advanced Usage section of the documentation includes an example for running some sample code that states that the argument order does not matter, however, in practice init arguments must appear before the action name, and arguments for the action must appear after the action name. As such, the following simple class throws an error when run with $ python script.py test --daemon

class Dispatcher(object):

    def __init__(self, daemon=False):
        print daemon

    def test(self):
        print 'test'

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions