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

Option class should have all methods of Full and Empty #38

Closed
joshalbrecht opened this issue Nov 8, 2013 · 1 comment
Closed

Option class should have all methods of Full and Empty #38

joshalbrecht opened this issue Nov 8, 2013 · 1 comment
Assignees

Comments

@joshalbrecht
Copy link

Otherwise pylint complains (fairly) that Option does not have, for example, "map".

Just add these lines at monad.py:72

    def map(self, callback):
        raise NotImplementedError()

    def filter(self, callback):
        raise NotImplementedError()

    def get_or(self, default):
        raise NotImplementedError()

    def get_or_call(self, callback, *args, **kwargs):
        raise NotImplementedError()

    def or_else(self, default):
        raise NotImplementedError()

    def or_call(self, callback, *args, **kwargs):
        raise NotImplementedError()

This is a pretty minor issue and somewhat stylistic, so feel free to ignore :) Thanks for the nice library!

@ghost ghost assigned kachayev Nov 9, 2013
@kachayev
Copy link
Owner

Fixed 6aad4d2
Thanks for reporting!

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

2 participants