Add utility functions for getting an app's name and label.
Review Request #8633 — Created Jan. 19, 2017 and submitted
The django-evolution codebase is littered with snippets of code for calculating the label and name for an app. This is kind of annoying and not very future-proof. This change replaces all those with calls to new utility functions designed to return that information.
Tested listing evolutions, generating evolution hints, and applying
evolutions. All continued to work.
Description | From | Last Updated |
---|---|---|
Use b'.' for extra clarity? Same below. Not sure if this is merited since this doesn't use unicode_literals. |
brennie |
-
-
django_evolution/utils.py (Diff revision 1) Use
b'.'
for extra clarity? Same below.Not sure if this is merited since this doesn't use
unicode_literals
.
Change Summary:
Switched to explicitly using bytestrings.
Commit: |
|
||||
---|---|---|---|---|---|
Diff: |
Revision 2 (+41 -11) |
-
Tool: Pyflakes Processed Files: django_evolution/management/commands/evolve.py django_evolution/utils.py django_evolution/management/commands/list-evolutions.py django_evolution/evolve.py django_evolution/management/__init__.py django_evolution/signature.py Tool: PEP8 Style Checker Processed Files: django_evolution/management/commands/evolve.py django_evolution/utils.py django_evolution/management/commands/list-evolutions.py django_evolution/evolve.py django_evolution/management/__init__.py django_evolution/signature.py