Hello,

On Thu, 28 May 2020 16:05:52 -0400
<[email protected]> wrote:

[]

> People write main entry points that are not exactly this?
> 
> If __name__ == '__main__':
>     sys.exit(main(sys.argv[1:]))

Yes, most of the time, I don't emulate C main function, so I write it
as:

if __name__ == "__main__":
    main()

(Mind the double quotes!!)

And one sweet day, I intend to fully convert to write it:

if __name__ == "__main__":
    __main__()


(The morale of the story: you won't get all people agree to your way,
can as well accept that.)


-- 
Best regards,
 Paul                          mailto:[email protected]
_______________________________________________
Python-ideas mailing list -- [email protected]
To unsubscribe send an email to [email protected]
https://mail.python.org/mailman3/lists/python-ideas.python.org/
Message archived at 
https://mail.python.org/archives/list/[email protected]/message/UEZVZO6G256XRZ6AEGUJMUBBEY7QNWFI/
Code of Conduct: http://python.org/psf/codeofconduct/

Reply via email to