contrib: Revert module path to ryu.contrib

Signed-off-by: IWASE Yusuke <iwase.yusuke0@gmail.com>
Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
This commit is contained in:
IWASE Yusuke 2016-11-09 14:17:12 +09:00 committed by FUJITA Tomonori
parent 2dc7d403bb
commit 63ce337e1d
6 changed files with 18 additions and 42 deletions

View File

@ -17,22 +17,20 @@
import inspect
from types import MethodType
import webob.dec
from webob.response import Response
from ryu import cfg
from ryu.lib import hub
from routes import Mapper
from routes.util import URLGenerator
import ryu.contrib
ryu.contrib.update_module_path()
from tinyrpc.server import RPCServer
from tinyrpc.dispatch import RPCDispatcher
from tinyrpc.dispatch import public as rpc_public
from tinyrpc.protocols.jsonrpc import JSONRPCProtocol
from tinyrpc.transports import ServerTransport, ClientTransport
from tinyrpc.client import RPCClient
ryu.contrib.restore_module_path()
import webob.dec
from webob.response import Response
from ryu import cfg
from ryu.lib import hub
from routes import Mapper
from routes.util import URLGenerator
CONF = cfg.CONF
CONF.register_cli_opts([

View File

@ -19,19 +19,9 @@
from ryu.lib import hub
hub.patch(thread=False)
# TODO:
# Right now, we have our own patched copy of ovs python bindings
# Once our modification is upstreamed and widely deployed,
# use it
#
# NOTE: this modifies sys.path and thus affects the following imports.
import ryu.contrib
ryu.contrib.update_module_path()
from ryu import cfg
import logging
import sys
import logging
from ryu import log
log.early_init_log(logging.DEBUG)

View File

@ -25,18 +25,15 @@
from __future__ import print_function
import ryu.contrib
ryu.contrib.update_module_path()
from ryu import cfg
import cmd
import sys
import lxml.etree as ET
import lxml.etree as ET
from ncclient.operations.rpc import RPCError
from ryu import cfg
from ryu.lib import of_config
from ryu.lib.of_config import capable_switch
from ncclient.operations.rpc import RPCError
import ryu.lib.of_config.classes as ofc

View File

@ -31,17 +31,13 @@
from __future__ import print_function
import ryu.contrib
ryu.contrib.update_module_path()
from ryu import cfg
import cmd
import signal
import socket
import sys
import termios
from ryu import cfg
from ryu.lib import rpc

View File

@ -14,15 +14,13 @@
# See the License for the specific language governing permissions and
# limitations under the License.
import ryu.contrib
ryu.contrib.update_module_path()
import argparse
import os.path
import sys
from ryu import cfg
from ryu import utils
from ryu import version
import argparse
import os.path
import sys
subcommands = {

View File

@ -22,9 +22,6 @@ import glob
import os.path
import sys
# we require ncclient
import ryu.contrib
ryu.contrib.update_module_path()
SCHEMA_DIR = os.path.dirname(__file__)
@ -34,7 +31,7 @@ _files = glob.glob(os.path.join(SCHEMA_DIR, 'of-config-*.xsd'))
OF_CONFIG_XSD_FILES = dict(
(os.path.basename(f)[len(_PREFIX):-len(_SUFFIX)], f) for f in _files)
# For convinience
# For convenience
# OF_CONFIG_1_0_XSD = os.path.join(SCHEMA_DIR, 'of-config-1.0.xsd')
# and so on
_this_module = sys.modules[__name__]