#7205 closed change (fixed)

[python-abp] Change classes that use ALL_CAPS naming to be CamelCase as recommended by PEP8

Reported by: kvas Assignee: rhowell
Priority: P3 Milestone:
Module: Sitescripts Keywords:
Cc: Blocked By:
Blocking: Platform: Unknown / Cross platform
Ready: yes Confidential: no
Tester: Unknown Verified working: no
Review URL(s):



In python-abp we have several classes that are used as namespaces for constants (example). Their names follow ALL_CAPS convention to indicate this special usage and produce ALL_CAPS names of constants like FILTER_OPTION.IMAGE. Naming classes in ALL_CAPS contradicts PEP8 and we have to bypass flake8 checking for those lines.

We have recently created attempted to make ALL_CAPS class names allowed, at least for the cases when the class contains just constants (ticket). However, the maintainers of pep8-naming refused the ticket stating that our usage is not conventional and that, for example, the documentation of Enum class in Python 3, that fulfils a very similar purpose, follows CamelCase for class names (so constant names look like FilterOption.IMAGE).

What to change

Change the names of the constant namespace classes in parser.py to follow CamelCase convention and update the references (export list of that module and any imports and use in other modules).

Change History (3)

comment:1 Changed 21 months ago by rhowell

  • Owner set to rhowell

comment:2 Changed 21 months ago by abpbot

comment:3 Changed 21 months ago by rhowell

  • Resolution set to fixed
  • Status changed from new to closed
Note: See TracTickets for help on using tickets.