Fixes some PEP8 and minor stuff

This commit is contained in:
Frederic Guillot 2016-03-25 11:52:20 -04:00
parent 27abb148bd
commit b817a17aa6
12 changed files with 20 additions and 12 deletions

1
.gitignore vendored
View File

@ -4,7 +4,6 @@
*.pyc
*.coverage
*.egg*
.vagrant
.DS_Store
AUTHORS
ChangeLog

View File

@ -15,3 +15,8 @@ Almanach is composed of two parts:
- **Collector**: listen for OpenStack events and store the relevant information in the database.
- **REST API**: Expose the information collected to external systems.
License
-------
Almanach is distributed under Apache 2.0 LICENSE.

View File

@ -13,7 +13,6 @@
# limitations under the License.
import logging
import pymongo
from pymongo.errors import ConfigurationError

View File

@ -14,6 +14,7 @@
import json
import logging
from kombu import Exchange, Queue, Producer
from almanach import config

View File

@ -13,6 +13,7 @@
# limitations under the License.
import logging
from flask import Flask
from gunicorn.app.base import Application

View File

@ -14,6 +14,7 @@
import logging
import sys
from kombu import Connection
from almanach import log_bootstrap

View File

@ -18,12 +18,13 @@ import mongomock
from datetime import datetime
from flexmock import flexmock, flexmock_teardown
from hamcrest import assert_that, contains_inanyorder
from pymongo import MongoClient
from almanach.adapters.database_adapter import DatabaseAdapter
from almanach.common.VolumeTypeNotFoundException import VolumeTypeNotFoundException
from almanach.common.AlmanachException import AlmanachException
from almanach import config
from almanach.core.model import todict
from pymongo import MongoClient
from tests.builder import a, instance, volume, volume_type

View File

@ -13,13 +13,14 @@
# limitations under the License.
import unittest
from kombu import Connection
from kombu.tests import mocks
from kombu.transport import pyamqp
from flexmock import flexmock, flexmock_teardown
from almanach import config
from almanach.adapters.retry_adapter import RetryAdapter
from kombu.tests import mocks
from kombu.transport import pyamqp
class BusAdapterTest(unittest.TestCase):

View File

@ -13,10 +13,9 @@
# limitations under the License.
import json
from uuid import uuid4
import flask
from uuid import uuid4
from unittest import TestCase
from datetime import datetime
from flexmock import flexmock, flexmock_teardown

View File

@ -12,13 +12,13 @@
# See the License for the specific language governing permissions and
# limitations under the License.
from copy import copy
import pytz
from copy import copy
from datetime import datetime
from uuid import uuid4
from almanach.core.model import build_entity_from_dict, Instance, Volume, VolumeType
import pytz
class Builder(object):

View File

@ -13,9 +13,9 @@
# limitations under the License.
import unittest
from datetime import datetime, timedelta
import pytz
from datetime import datetime, timedelta
from dateutil import parser as date_parser
from flexmock import flexmock, flexmock_teardown
from nose.tools import assert_raises

View File

@ -12,10 +12,11 @@
# See the License for the specific language governing permissions and
# limitations under the License.
from datetime import datetime, timedelta
import dateutil.parser
import pytz
from datetime import datetime, timedelta
DEFAULT_VOLUME_TYPE = "5dadd67f-e21e-4c13-b278-c07b73b21250"