Skip to content

Commit

Permalink
Develop (#55)
Browse files Browse the repository at this point in the history
- Improve logging in helper functions - especially around resolving ssh config/known hosts
- Add `ttp_parse_output` method to Response object; add `ttp_parse` function in helper
- Load requirements from requirements files and parse them for setup.py -- stop me from forgetting to update in one place or another!
- Slacken the IOSXE configuration prompt pattern -- `hostname(ipsec-profile)` was not being caught by the pattern as it was expecting the part in parenthesis to start with "conf" - thank you Talha Javaid for bringing this up on ntc slack, and Alex Lardschneider for confirming the "fix" should be good to go!
- Add `community` pip extra to install scrapli community
- Minor README house keeping!
- Made transport `set_timeout` saner -- I genuinely don't know what I was doing with that before... this included the base class as well as updating telnet and systemssh... in theory this could be a breaking change if you were just calling `set_timeout` for some reason without passing an argument... you probably weren't doing that... because why would you? There was *some* precedent for doing it like this before but it isn't worth caring about now :)
- Did smarter things with imports in helper, added tests to make sure the warnings are correct
- Dramatically simplified session locking... this had just gotten out of hand over time... now only the channel locks. This means that basically all inputs/outputs should go through the channel and/or you should acquire the lock yourself if you wish to read/write directly to the transport. Critically this means that all the external transport plugins AND scrapli-netconf need to be updated as well -- this means that you *must* update all of these if you are using this release! (requirements are of course pinned to make sure this is the case)
- **BREAKING CHANGE:** removed **ALL** keepalive stuff... for now. This will probably get added back, but AFAIK nobody uses it right now and the implementation of it is frankly not very good... keeping it around right now added complexity for little gain. Keepalives will be back and improved hopefully in the next release. If you need them, please just pin to 2020.09.26!
  • Loading branch information
carlmontanari authored Oct 10, 2020
1 parent 5c7c3a1 commit b42a5f8
Show file tree
Hide file tree
Showing 48 changed files with 985 additions and 848 deletions.
10 changes: 5 additions & 5 deletions .github/workflows/commit.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ jobs:
max-parallel: 1
matrix:
os: [ubuntu-latest]
version: [3.8]
version: [3.9]
steps:
- uses: actions/checkout@v2
- name: set up python ${{ matrix.version }}
Expand All @@ -30,7 +30,7 @@ jobs:
max-parallel: 9
matrix:
os: [ubuntu-latest, macos-latest]
version: [3.6, 3.7, 3.8, 3.9-dev]
version: [3.6, 3.7, 3.8, 3.9]
steps:
- uses: actions/checkout@v2
- name: set up python ${{ matrix.version }}
Expand All @@ -41,9 +41,9 @@ jobs:
# not super friendly looking, but easy way to get major.minor version so we can easily exec only the specific
# version we are targeting with nox, while still having versions like 3.9.0a4
run: |
echo "::set-env name=FRIENDLY_PYTHON_VERSION::$(python -c "import sys; print(f'{sys.version_info.major}.{sys.version_info.minor}')")"
- name: install libxml2 and libxslt seems to only be needed for 3.9 dev image for some reason
if: matrix.os == 'ubuntu-latest' && matrix.version == '3.9-dev'
echo "FRIENDLY_PYTHON_VERSION=$(python -c "import sys; print(f'{sys.version_info.major}.{sys.version_info.minor}')")" >> $GITHUB_ENV
- name: install libxml2 and libxslt seems to only be needed for 3.9 image for some reason
if: matrix.os == 'ubuntu-latest' && matrix.version == '3.9'
run: |
sudo apt install libxml2-dev
sudo apt install libxslt-dev
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/publish.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,10 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: set up python 3.8
- name: set up python 3.9
uses: actions/setup-python@v2
with:
python-version: 3.8
python-version: 3.9
- name: setup publish env
run: |
python -m pip install --upgrade pip
Expand Down
10 changes: 5 additions & 5 deletions .github/workflows/weekly.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ jobs:
max-parallel: 1
matrix:
os: [ubuntu-latest]
version: [3.8]
version: [3.9]
steps:
- uses: actions/checkout@v2
- name: set up python ${{ matrix.version }}
Expand All @@ -35,7 +35,7 @@ jobs:
max-parallel: 9
matrix:
os: [ubuntu-latest, macos-latest]
version: [3.6, 3.7, 3.8, 3.9-dev]
version: [3.6, 3.7, 3.8, 3.9]
steps:
- uses: actions/checkout@v2
- name: set up python ${{ matrix.version }}
Expand All @@ -46,9 +46,9 @@ jobs:
# not super friendly looking, but easy way to get major.minor version so we can easily exec only the specific
# version we are targeting with nox, while still having versions like 3.9.0a4
run: |
echo "::set-env name=FRIENDLY_PYTHON_VERSION::$(python -c "import sys; print(f'{sys.version_info.major}.{sys.version_info.minor}')")"
- name: install libxml2 and libxslt seems to only be needed for 3.9 dev image for some reason
if: matrix.os == 'ubuntu-latest' && matrix.version == '3.9-dev'
echo "FRIENDLY_PYTHON_VERSION=$(python -c "import sys; print(f'{sys.version_info.major}.{sys.version_info.minor}')")" >> $GITHUB_ENV
- name: install libxml2 and libxslt seems to only be needed for 3.9 image for some reason
if: matrix.os == 'ubuntu-latest' && matrix.version == '3.9'
run: |
sudo apt install libxml2-dev
sudo apt install libxslt-dev
Expand Down
28 changes: 28 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,32 @@
CHANGELOG
=======

# 2020.10.10
- Improve logging in helper functions - especially around resolving ssh config/known hosts
- Add `ttp_parse_output` method to Response object; add `ttp_parse` function in helper
- Load requirements from requirements files and parse them for setup.py -- stop me from forgetting to update in one
place or another!
- Slacken the IOSXE configuration prompt pattern -- `hostname(ipsec-profile)` was not being caught by the pattern as
it was expecting the part in parenthesis to start with "conf" - thank you Talha Javaid for bringing this up on ntc
slack, and Alex Lardschneider for confirming the "fix" should be good to go!
- Add `community` pip extra to install scrapli community
- Minor README house keeping!
- Made transport `set_timeout` saner -- I genuinely don't know what I was doing with that before... this included the
base class as well as updating telnet and systemssh... in theory this could be a breaking change if you were just
calling `set_timeout` for some reason without passing an argument... you probably weren't doing that... because why
would you? There was *some* precedent for doing it like this before but it isn't worth caring about now :)
- Did smarter things with imports in helper, added tests to make sure the warnings are correct
- Dramatically simplified session locking... this had just gotten out of hand over time... now only the channel locks
. This means that basically all inputs/outputs should go through the channel and/or you should acquire the lock
yourself if you wish to read/write directly to the transport. Critically this means that all the external transport
plugins AND scrapli-netconf need to be updated as well -- this means that you *must* update all of these if you are
using this release! (requirements are of course pinned to make sure this is the case)
- **BREAKING CHANGE:** removed **ALL** keepalive stuff... for now. This will probably get added back, but AFAIK nobody
uses it right now and the implementation of it is frankly not very good... keeping it around right now added complexity
for little gain. Keepalives will be back and improved hopefully in the next release. If you need them, please just
pin to 2020.09.26!


# 2020.09.26
- Improved error handling/exceptions for scrapli `Factory`
- Fixed issue where `system` transport did not properly close/kill SSH connections
Expand All @@ -19,6 +45,8 @@ CHANGELOG
- Fully give into the warm embrace of dependabot and pin all the dev requirements to specific versions... dependabot
can keep us up to date and this lets us not worry about builds failing because of dev requirements getting changed
around
- Fix ptyprocess file object closing issue


# 2020.08.28
- Added Packet Pushers scrapli episode to the README!!
Expand Down
Loading

0 comments on commit b42a5f8

Please sign in to comment.