Skip to content

Commit bf5436a

Browse files
flake8 fixes
1 parent ba2e16c commit bf5436a

27 files changed

+67
-45
lines changed

encode/__init__.py

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
1-
# Copyright Collab 2012-2015
1+
# Copyright Collab 2012-2016
2+
# See LICENSE for details.
23

34
"""
45
`django-encode` application.

encode/admin.py

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
1-
# Copyright Collab 2012-2015
1+
# Copyright Collab 2012-2016
2+
# See LICENSE for details.
23

34
"""
45
Admin functionality.

encode/conf.py

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
1-
# Copyright Collab 2013-2015
1+
# Copyright Collab 2013-2016
2+
# See LICENSE for details.
23

34
"""
45
Configuration options.

encode/encoders.py

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
1-
# Copyright Collab 2013-2015
1+
# Copyright Collab 2013-2016
2+
# See LICENSE for details.
23

34
"""
45
Encoders.

encode/forms.py

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
1-
# Copyright Collab 2014-2015
1+
# Copyright Collab 2014-2016
2+
# See LICENSE for details.
23

34
"""
45
Forms.

encode/models.py

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
1-
# Copyright Collab 2012-2015
1+
# Copyright Collab 2012-2016
2+
# See LICENSE for details.
23

34
"""
45
Models.

encode/signals.py

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
1-
# Copyright Collab 2012-2015
1+
# Copyright Collab 2012-2016
2+
# See LICENSE for details.
23

34
"""
45
Signals.

encode/static/encode/js/media.js

+4-3
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
1-
// Copyright Collab 2014-2015
1+
// Copyright Collab 2014-2016
2+
// See LICENSE for details.
23

34
!function ($)
45
{
@@ -57,7 +58,7 @@
5758
}
5859
}
5960
});
60-
61+
6162
// change player background color
6263
player.el().style.backgroundColor = "#BDBBBC";
6364
}
@@ -73,7 +74,7 @@
7374
{
7475
markup = '<video id="myVideo' + index + '" class="video-js vjs-default-skin"></video>';
7576
players.append(markup);
76-
77+
7778
// add video player
7879
var player = videojs("myVideo" + index,
7980
{

encode/storage.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
1-
# Copyright Collab 2015
1+
# Copyright Collab 2015-2016
2+
# See LICENSE for details.
23

34
"""
45
Storage.
@@ -26,4 +27,3 @@ def __init__(self,
2627
remote_options=remote_options,
2728
delayed=delayed,
2829
*args, **kwargs)
29-

encode/tasks.py

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
1-
# Copyright Collab 2012-2015
1+
# Copyright Collab 2012-2016
2+
# See LICENSE for details.
23

34
"""
45
Tasks.

encode/tests/__init__.py

+3-2
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,8 @@
1-
# Copyright Collab 2012-2015
1+
# Copyright Collab 2012-2016
2+
# See LICENSE for details.
23

34
"""
45
Tests for the :py:mod:`encode` project.
56
"""
67

7-
from .celery import app
8+
from .celery import app # flake8: noqa

encode/tests/celery.py

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
1-
# Copyright Collab 2013-2015
1+
# Copyright Collab 2013-2016
2+
# See LICENSE for details.
23

34
"""
45
Celery configuration for the :py:mod:`encode` application.

encode/tests/helpers.py

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
1-
# Copyright Collab 2012-2015
1+
# Copyright Collab 2012-2016
2+
# See LICENSE for details.
23

34
"""
45
Utilities and test data.

encode/tests/runner.py

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
1-
# Copyright Collab 2014-2015
1+
# Copyright Collab 2014-2016
2+
# See LICENSE for details.
23

34
"""
45
Custom test runner.

encode/tests/settings.py

+3-5
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
1-
# Copyright Collab 2013-2015
1+
# Copyright Collab 2013-2016
2+
# See LICENSE for details.
23

34
import os
45

@@ -104,7 +105,7 @@
104105
)
105106

106107
# Logging configuration.
107-
# See http://docs.djangoproject.com/en/dev/topics/logging for
108+
# See https://docs.djangoproject.com/en/dev/topics/logging for
108109
# more details on how to customize your logging configuration.
109110

110111
LOG_HANDLER = 'null'
@@ -118,9 +119,6 @@
118119
}
119120
},
120121
'formatters': {
121-
'verbose': {
122-
'format': '%(asctime)s %(levelname)-6s %(name)-15s - %(process)d %(thread)d %(message)s'
123-
},
124122
'simple': {
125123
'format': '%(asctime)s %(levelname)-6s %(name)-15s - %(message)s'
126124
},

encode/tests/test_admin.py

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
# -*- coding: utf-8 -*-
2-
# Copyright Collab 2014-2015
2+
# Copyright Collab 2014-2016
3+
# See LICENSE for details.
34

45
"""
56
Tests for the :py:mod:`encode.admin` module.

encode/tests/test_encoders.py

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
# -*- coding: utf-8 -*-
2-
# Copyright Collab 2013-2015
2+
# Copyright Collab 2013-2016
3+
# See LICENSE for details.
34

45
"""
56
Tests for the :py:mod:`encode.encoders` module.

encode/tests/test_models.py

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
1-
# Copyright Collab 2014-2015
1+
# Copyright Collab 2014-2016
2+
# See LICENSE for details.
23

34
"""
45
Tests for the :py:mod:`encode.models` module.

encode/tests/test_tasks.py

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
# -*- coding: utf-8 -*-
2-
# Copyright Collab 2013-2015
2+
# Copyright Collab 2013-2016
3+
# See LICENSE for details.
34

45
"""
56
Tests for the :py:mod:`encode.tasks` module.

encode/tests/test_util.py

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
# -*- coding: utf-8 -*-
2-
# Copyright Collab 2013-2015
2+
# Copyright Collab 2013-2016
3+
# See LICENSE for details.
34

45
"""
56
Tests for the :py:mod:`encode.util` module.

encode/tests/test_widgets.py

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
1-
# Copyright Collab 2015
1+
# Copyright Collab 2015-2016
2+
# See LICENSE for details.
23

34
"""
45
Tests for the :py:mod:`encode.widgets` module.

encode/tests/urls.py

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
1-
# Copyright Collab 2014-2015
1+
# Copyright Collab 2014-2016
2+
# See LICENSE for details.
23

34
"""
45
URLConf for :py:mod:`encode` tests.

encode/util.py

+5-4
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
1-
# Copyright Collab 2012-2015
1+
# Copyright Collab 2012-2016
2+
# See LICENSE for details.
23

34
"""
45
Utilities.
@@ -98,14 +99,14 @@ def parseMedia(data):
9899
:type data: str
99100
:rtype: str
100101
"""
101-
#logger.debug("Got frame data: %s" % str(len(data)))
102-
#logger.debug("Data URI header: %s" % data[0:40])
102+
# logger.debug("Got frame data: %s" % str(len(data)))
103+
# logger.debug("Data URI header: %s" % data[0:40])
103104

104105
try:
105106
header_len = data.find(",")
106107
payload = data[header_len + 1:]
107108
binary = b64decode(payload)
108-
#logger.debug("Binary id: %s" % binary[0:4])
109+
# logger.debug("Binary id: %s" % binary[0:4])
109110

110111
return binary
111112

encode/widgets.py

+4-2
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
1-
# Copyright Collab 2014-2015
1+
# Copyright Collab 2014-2016
2+
# See LICENSE for details.
23

34
"""
45
Widgets.
@@ -29,7 +30,8 @@ def render(self, name, value, attrs=None, choices=()):
2930
if option_value in [int(x) for x in value]:
3031
try:
3132
from encode import models
32-
path = models.MediaFile.objects.get(title=option_label).file.url
33+
path = models.MediaFile.objects.get(
34+
title=option_label).file.url
3335
paths.append(path)
3436
except models.MediaFile.DoesNotExist:
3537
pass

runtests.py

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
#!/usr/bin/env python
2-
# Copyright Collab 2014-2015
2+
# Copyright Collab 2014-2016
3+
# See LICENSE for details.
34

45
import os
56
import sys

setup.cfg

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
[flake8]
2-
ignore = E121, E125, E128
3-
exclude = doc/*, encode/migrations/*
2+
ignore = E121, E122, E123, E125, E126, E128
3+
exclude = doc/*, encode/migrations/*, encode/tests/*

setup.py

+6-6
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
#!/usr/bin/env python
2-
# Copyright Collab 2012-2015
2+
# Copyright Collab 2012-2016
3+
# See LICENSE for details.
34

45
import os
56
import sys
@@ -10,16 +11,15 @@
1011
README = open(os.path.join(os.path.dirname(__file__), 'README.rst')).read()
1112

1213
# get version nr
13-
sys.path.insert(0, os.path.abspath(os.path.join(os.path.dirname(__file__), 'encode')))
14-
from encode import version
14+
sys.path.insert(0, os.path.abspath(os.path.join(os.path.dirname(__file__),
15+
'encode')))
16+
from encode import version # flake8: noqa
1517
sys.path.pop(0)
1618

1719

1820
class Tox(TestCommand):
1921
"""
20-
Makes the `python setup.py test` command work.
21-
22-
See http://testrun.org/tox/latest/example/basic.html#integration-with-setuptools-distribute-test-commands
22+
Makes the `python setup.py test` command work with Tox.
2323
"""
2424
def finalize_options(self):
2525
TestCommand.finalize_options(self)

0 commit comments

Comments
 (0)