fixed linting
continuous-integration/drone/push Build is failing
Details
continuous-integration/drone/push Build is failing
Details
This commit is contained in:
parent
b9cd468827
commit
5607ec6012
|
@ -17,7 +17,7 @@ steps:
|
||||||
- coverage run --source='.' manage.py test --noinput --parallel
|
- coverage run --source='.' manage.py test --noinput --parallel
|
||||||
- name: run flake8
|
- name: run flake8
|
||||||
commands:
|
commands:
|
||||||
- flake8
|
- flake8 --max-line-length=120
|
||||||
- name: run pylint
|
- name: run pylint
|
||||||
commands:
|
commands:
|
||||||
- pylint --rcfile=.pylintrc -- **/*.py
|
- pylint --rcfile=.pylintrc -- **/*.py
|
||||||
|
|
|
@ -0,0 +1,15 @@
|
||||||
|
[MASTER]
|
||||||
|
load-plugins=pylint_django
|
||||||
|
django-settings-module=im.settings
|
||||||
|
|
||||||
|
[FORMAT]
|
||||||
|
max-line-length=120
|
||||||
|
|
||||||
|
[MESSAGES CONTROL]
|
||||||
|
disable=missing-docstring,unnecessary-pass
|
||||||
|
|
||||||
|
[DESIGN]
|
||||||
|
max-parents=13
|
||||||
|
|
||||||
|
[TYPECHECK]
|
||||||
|
generated-members=REQUEST,acl_users,aq_parent,"[a-zA-Z]+_set{1,2}",save,delete
|
|
@ -4,10 +4,9 @@ from django.contrib.auth.models import User
|
||||||
|
|
||||||
class Events(models.Model):
|
class Events(models.Model):
|
||||||
id = models.AutoField(primary_key=True)
|
id = models.AutoField(primary_key=True)
|
||||||
start = models.DateTimeField(null=True,blank=True)
|
start = models.DateTimeField(null=True, blank=True)
|
||||||
end = models.DateTimeField(null=True,blank=True)
|
end = models.DateTimeField(null=True, blank=True)
|
||||||
user = models.ForeignKey(User, on_delete=models.CASCADE)
|
user = models.ForeignKey(User, on_delete=models.CASCADE)
|
||||||
|
|
||||||
def __str__(self):
|
def __str__(self):
|
||||||
return self.name
|
return self.name
|
||||||
|
|
||||||
|
|
|
@ -115,8 +115,8 @@ USE_I18N = True
|
||||||
|
|
||||||
USE_L10N = True
|
USE_L10N = True
|
||||||
|
|
||||||
#USE_TZ = True
|
# USE_TZ = True
|
||||||
#TURNED off for simplicity
|
# TURNED off for simplicity
|
||||||
USE_TZ = False
|
USE_TZ = False
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -1,5 +1,6 @@
|
||||||
from django.contrib.auth.forms import UserCreationForm
|
from django.contrib.auth.forms import UserCreationForm
|
||||||
|
|
||||||
|
|
||||||
class CustomUserCreationForm(UserCreationForm):
|
class CustomUserCreationForm(UserCreationForm):
|
||||||
class Meta(UserCreationForm.Meta):
|
class Meta(UserCreationForm.Meta):
|
||||||
fields = UserCreationForm.Meta.fields + ("email",)
|
fields = UserCreationForm.Meta.fields + ("email",)
|
||||||
|
|
|
@ -1,5 +1,3 @@
|
||||||
from django.contrib.auth import login
|
|
||||||
|
|
||||||
from django.shortcuts import redirect, render
|
from django.shortcuts import redirect, render
|
||||||
|
|
||||||
from django.urls import reverse
|
from django.urls import reverse
|
||||||
|
|
Loading…
Reference in New Issue