Skip to content

Usefullness of begin.start as a boolean function #63

Open

Description

@Lapin0t

Hi, this is a really great library, the first high level command-line app library I actually like (but as we all have our quirky ways of doing scripts I will be making some pull requests for side features like completion or no double flags)! There is just something that bugs me: what is the benefit of using if begin.start() over the more conventional if __name__ == '__main__' as it seems to be strictly equivalent (but more complicated since you can't just check the globals and have to fiddle with the global stackframe)?

Activity

  1. changed the title [-]Usefullness of `begin.start` as a boolean function[/-] [+]Usefullness of begin.start as a boolean function[/+] on Dec 7, 2016
  2. evanunderscore commented on Dec 13, 2016

    @evanunderscore

    The only real difference is cosmetic - they do the same thing.

  3. Lapin0t commented on Dec 13, 2016

    @Lapin0t
    Author

    That's what I was thinking. So I am going to argue in favor of deprecating this (and later dropping this feature) because begin.start is just a big overloaded mess that can either be a decorator or a decorator factory or a boolean function and because this is a duplicate that will only confuse python users (there should be only one obvious way to do it).

  4. evanunderscore commented on Dec 13, 2016

    @evanunderscore

    Though he doesn't specifically mention the boolean part, here's what Aaron had to say about this. For what it's worth, I agree with you.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions