Merge "Removed all __init__ files from pep8 ignore"
This commit is contained in:
commit
a303646625
@ -1 +1,14 @@
|
|||||||
from solar.dblayer import standalone_session_wrapper
|
# -*- coding: utf-8 -*-
|
||||||
|
# Copyright 2015 Mirantis, Inc.
|
||||||
|
#
|
||||||
|
# Licensed under the Apache License, Version 2.0 (the "License"); you may
|
||||||
|
# not use this file except in compliance with the License. You may obtain
|
||||||
|
# a copy of the License at
|
||||||
|
#
|
||||||
|
# http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
#
|
||||||
|
# Unless required by applicable law or agreed to in writing, software
|
||||||
|
# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
|
||||||
|
# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
|
||||||
|
# License for the specific language governing permissions and limitations
|
||||||
|
# under the License.
|
||||||
|
@ -12,4 +12,20 @@
|
|||||||
# License for the specific language governing permissions and limitations
|
# License for the specific language governing permissions and limitations
|
||||||
# under the License.
|
# under the License.
|
||||||
|
|
||||||
from .resource import Resource, load, load_all, validate_resources, load_by_tags, load_updated, RESOURCE_STATE
|
from solar.core.resource.resource import load
|
||||||
|
from solar.core.resource.resource import load_all
|
||||||
|
from solar.core.resource.resource import load_by_tags
|
||||||
|
from solar.core.resource.resource import load_updated
|
||||||
|
from solar.core.resource.resource import Resource
|
||||||
|
from solar.core.resource.resource import RESOURCE_STATE
|
||||||
|
from solar.core.resource.resource import validate_resources
|
||||||
|
|
||||||
|
__all__ = [
|
||||||
|
'RESOURCE_STATE',
|
||||||
|
'Resource',
|
||||||
|
'load',
|
||||||
|
'load_all',
|
||||||
|
'load_by_tags',
|
||||||
|
'load_updated',
|
||||||
|
'validate_resources'
|
||||||
|
]
|
||||||
|
@ -0,0 +1,14 @@
|
|||||||
|
# -*- coding: utf-8 -*-
|
||||||
|
# Copyright 2015 Mirantis, Inc.
|
||||||
|
#
|
||||||
|
# Licensed under the Apache License, Version 2.0 (the "License"); you may
|
||||||
|
# not use this file except in compliance with the License. You may obtain
|
||||||
|
# a copy of the License at
|
||||||
|
#
|
||||||
|
# http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
#
|
||||||
|
# Unless required by applicable law or agreed to in writing, software
|
||||||
|
# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
|
||||||
|
# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
|
||||||
|
# License for the specific language governing permissions and limitations
|
||||||
|
# under the License.
|
@ -1 +1,13 @@
|
|||||||
|
# Copyright 2015 Mirantis, Inc.
|
||||||
|
#
|
||||||
|
# Licensed under the Apache License, Version 2.0 (the "License"); you may
|
||||||
|
# not use this file except in compliance with the License. You may obtain
|
||||||
|
# a copy of the License at
|
||||||
|
#
|
||||||
|
# http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
#
|
||||||
|
# Unless required by applicable law or agreed to in writing, software
|
||||||
|
# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
|
||||||
|
# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
|
||||||
|
# License for the specific language governing permissions and limitations
|
||||||
|
# under the License.
|
||||||
|
@ -1,13 +1,29 @@
|
|||||||
|
# -*- coding: utf-8 -*-
|
||||||
|
# Copyright 2015 Mirantis, Inc.
|
||||||
|
#
|
||||||
|
# Licensed under the Apache License, Version 2.0 (the "License"); you may
|
||||||
|
# not use this file except in compliance with the License. You may obtain
|
||||||
|
# a copy of the License at
|
||||||
|
#
|
||||||
|
# http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
#
|
||||||
|
# Unless required by applicable law or agreed to in writing, software
|
||||||
|
# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
|
||||||
|
# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
|
||||||
|
# License for the specific language governing permissions and limitations
|
||||||
|
# under the License.
|
||||||
|
|
||||||
|
|
||||||
try:
|
try:
|
||||||
from gevent import monkey
|
from gevent import monkey # NOQA
|
||||||
except ImportError:
|
except ImportError:
|
||||||
pass
|
pass
|
||||||
else:
|
else:
|
||||||
from solar.dblayer.gevent_patches import patch_all
|
from solar.dblayer.gevent_patches import patch_all
|
||||||
patch_all()
|
patch_all()
|
||||||
|
|
||||||
from solar.dblayer.model import ModelMeta
|
|
||||||
from solar.config import C
|
from solar.config import C
|
||||||
|
from solar.dblayer.model import ModelMeta
|
||||||
from solar.utils import parse_database_conn
|
from solar.utils import parse_database_conn
|
||||||
|
|
||||||
_connection, _connection_details = parse_database_conn(C.solar_db)
|
_connection, _connection_details = parse_database_conn(C.solar_db)
|
||||||
|
@ -12,4 +12,11 @@
|
|||||||
# License for the specific language governing permissions and limitations
|
# License for the specific language governing permissions and limitations
|
||||||
# under the License.
|
# under the License.
|
||||||
|
|
||||||
from .api import *
|
from solar.events.api import add_dep
|
||||||
|
from solar.events.api import add_event
|
||||||
|
from solar.events.api import add_react
|
||||||
|
from solar.events.api import Dep
|
||||||
|
from solar.events.api import React
|
||||||
|
|
||||||
|
|
||||||
|
__all__ = ['add_dep', 'add_react', 'Dep', 'React', 'add_event']
|
||||||
|
@ -15,8 +15,8 @@
|
|||||||
from solar.config import C
|
from solar.config import C
|
||||||
from solar.core.log import log
|
from solar.core.log import log
|
||||||
from solar.dblayer import ModelMeta
|
from solar.dblayer import ModelMeta
|
||||||
from solar.orchestration import extensions as loader
|
|
||||||
from solar.orchestration.executors import Executor
|
from solar.orchestration.executors import Executor
|
||||||
|
from solar.orchestration import extensions as loader
|
||||||
|
|
||||||
|
|
||||||
SCHEDULER_CLIENT = loader.get_client('scheduler')
|
SCHEDULER_CLIENT = loader.get_client('scheduler')
|
||||||
|
@ -19,10 +19,10 @@ from solar.config import C
|
|||||||
|
|
||||||
|
|
||||||
mgr = driver.DriverManager(
|
mgr = driver.DriverManager(
|
||||||
namespace='solar.orchestration.executors',
|
namespace='solar.orchestration.executors',
|
||||||
name=C.executor,
|
name=C.executor,
|
||||||
invoke_on_load=False,
|
invoke_on_load=False,
|
||||||
)
|
)
|
||||||
|
|
||||||
Client = mgr.driver.Client
|
Client = mgr.driver.Client
|
||||||
Executor = mgr.driver.Executor
|
Executor = mgr.driver.Executor
|
||||||
|
@ -12,6 +12,6 @@
|
|||||||
# License for the specific language governing permissions and limitations
|
# License for the specific language governing permissions and limitations
|
||||||
# under the License.
|
# under the License.
|
||||||
|
|
||||||
import solar.orchestration.workers.scheduler
|
import solar.orchestration.workers.scheduler # NOQA
|
||||||
import solar.orchestration.workers.system_log
|
import solar.orchestration.workers.system_log # NOQA
|
||||||
import solar.orchestration.workers.tasks
|
import solar.orchestration.workers.tasks # NOQA
|
||||||
|
4
tox.ini
4
tox.ini
@ -72,8 +72,8 @@ envdir = devenv
|
|||||||
usedevelop = True
|
usedevelop = True
|
||||||
|
|
||||||
[flake8]
|
[flake8]
|
||||||
ignore = H101,H236,E731,H405
|
ignore = H101,H236,E731,H405,H104
|
||||||
exclude = .venv,.git,.tox,dist,doc,*lib/python*,*egg,build,tools,__init__.py,docs,solar/ansible_library
|
exclude = .venv,.git,.tox,dist,doc,*lib/python*,*egg,build,tools,docs,solar/ansible_library
|
||||||
show-pep8 = True
|
show-pep8 = True
|
||||||
show-source = True
|
show-source = True
|
||||||
count = True
|
count = True
|
||||||
|
Loading…
x
Reference in New Issue
Block a user