Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
openSUSE:Backports:SLE-15-SP6:Update
python-netmiko
netmiko-testing-textfsm-installed-as-module.patch
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File netmiko-testing-textfsm-installed-as-module.patch of Package python-netmiko
From ef77e21e0b52317ccce66c2d4a707d0890ff05ae Mon Sep 17 00:00:00 2001 From: Carl Montanari <carlniger@users.noreply.github.com> Date: Fri, 19 Jul 2019 14:02:55 -0700 Subject: [PATCH] testing textfsm installed as module (#1292) --- netmiko/_textfsm/_clitable.py | 8 +++++++- netmiko/utilities.py | 2 +- 2 files changed, 8 insertions(+), 2 deletions(-) Index: b/netmiko/_textfsm/_clitable.py =================================================================== --- a/netmiko/_textfsm/_clitable.py +++ b/netmiko/_textfsm/_clitable.py @@ -31,7 +31,13 @@ import copy import os import re import threading -import copyable_regex_object + +try: + # TextFSM >= 1.0 (new package structure) + from textfsm import copyable_regex_object +except ImportError: + # TextFSM <= 0.4.1 + import copyable_regex_object import textfsm from netmiko._textfsm import _texttable as texttable Index: b/netmiko/utilities.py =================================================================== --- a/netmiko/utilities.py +++ b/netmiko/utilities.py @@ -6,9 +6,9 @@ import sys import io import os import serial.tools.list_ports +from netmiko.py23_compat import text_type from netmiko._textfsm import _clitable as clitable from netmiko._textfsm._clitable import CliTableError -from netmiko.py23_compat import text_type # Dictionary mapping 'show run' for vendors with different command
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor