Re: CamelCase vs. all-lowercase package names

Discussion in 'Python' started by Terry Reedy, Feb 2, 2013.

  1. Terry Reedy

    Terry Reedy Guest

    On 2/2/2013 3:03 AM, dieter wrote:
    > Rhubarb Sin <> writes:
    >
    >> PEP-8 calls for "short, all-lowercase names" for packages:
    >>
    >> http://www.python.org/dev/peps/pep-0008/#package-and-module-names

    >
    > This is mainly to support case insensitive file systems (and
    > file systems with quite limited path length).


    It also serves to differentiate a module from the main class it defines.
    If file Module defines class Module, then the two possible imports
    import Module
    from Module import Module
    make 'Module' later in the file ambiguous without referring to the top
    of the file for the import. But now, 'decimal' is the module and
    'Decimal' is the class (absent stupid renaming designed to confuse).

    > With mixed case, some packages/modules may not conflict on
    > a case sensitive file system but happen to conflict on a
    > case insensitive file system.


    --
    Terry Jan Reedy
    Terry Reedy, Feb 2, 2013
    #1
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Replies:
    23
    Views:
    1,186
  2. Glen
    Replies:
    2
    Views:
    248
  3. stef mientki
    Replies:
    2
    Views:
    428
    Rob Wolfe
    Sep 14, 2007
  4. Guest
    Replies:
    0
    Views:
    742
    Guest
    Sep 18, 2007
  5. dieter
    Replies:
    0
    Views:
    102
    dieter
    Feb 2, 2013
Loading...

Share This Page