Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
46 changes: 46 additions & 0 deletions docs/admin/release_notes/version_2.3.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@

# v2.3 Release Notes

This document describes all new features and changes in the release. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/) and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).

## Release Overview

- Added the ability to for remote file copy on Cisco NXOS, Cisco ASA, and Arista EOS operating systems.

## [v2.3.0 (2026-04-14)](https://github.com/networktocode/pyntc/releases/tag/v2.3.0)

### Added

- [#365](https://github.com/networktocode/pyntc/issues/365) - Added the remote file copy feature to Arista EOS devices.
- [#365](https://github.com/networktocode/pyntc/issues/365) - Added unittests for remote file copy on Arista EOS devices.
- [#366](https://github.com/networktocode/pyntc/issues/366) - Added ``remote_file_copy``, ``check_file_exists``, ``get_remote_checksum``, and ``verify_file`` support for ``ASADevice`` (FTP, TFTP, SCP, HTTP, HTTPS).
- [#367](https://github.com/networktocode/pyntc/issues/367) - Added remote file copy feature to Cisco NXOS devices.
- [#367](https://github.com/networktocode/pyntc/issues/367) - Added unittests for remote file copy for Cisco NXOS devices.

### Changed

- [#368](https://github.com/networktocode/pyntc/issues/368) - Improved EOS remote file copy to validate scheme and query strings before connecting, use `clean_url` to prevent credential leakage, and simplify credential routing.
- [#368](https://github.com/networktocode/pyntc/issues/368) - Changed copy command builders to include the source file path in the URL and use `flash:` as the destination, matching EOS CLI conventions.
- [#368](https://github.com/networktocode/pyntc/issues/368) - Fixed `_uptime_to_string` to use integer division, preventing `ValueError` on format specifiers.
- [#368](https://github.com/networktocode/pyntc/issues/368) - Fixed `check_file_exists` and `get_remote_checksum` to open the SSH connection before use, preventing `AttributeError` when called standalone.
- [#368](https://github.com/networktocode/pyntc/issues/368) - Fixed password-prompt handling in `remote_file_copy` to wait for the transfer to complete before proceeding to verification.
- [#368](https://github.com/networktocode/pyntc/issues/368) - Simplified checksum parsing in `get_remote_checksum` to use string splitting instead of regex.
- [#368](https://github.com/networktocode/pyntc/issues/368) - Changed `verify_file` to return early when file does not exist and use case-insensitive checksum comparison.
- [#368](https://github.com/networktocode/pyntc/issues/368) - Removed `include_username` parameter from `remote_file_copy` in favor of automatic credential routing based on scheme and username presence.

### Removed

- [#364](https://github.com/networktocode/pyntc/issues/364) - Removed log.init from iosxewlc device.
- [#364](https://github.com/networktocode/pyntc/issues/364) - Removed warning filter for logging.

### Fixed

- [#366](https://github.com/networktocode/pyntc/issues/366) - Fixed ``ASADevice._get_file_system`` to use ``re.search`` instead of ``re.match`` so the filesystem label is correctly parsed regardless of leading whitespace in ``dir`` output.
- [#366](https://github.com/networktocode/pyntc/issues/366) - Fixed ``ASADevice._send_command`` to anchor the ``%`` error pattern to the start of a line (``^% ``) to prevent false-positive ``CommandError`` raises during file copy operations.
- [#366](https://github.com/networktocode/pyntc/issues/366) - Fixed ``ASADevice.active_redundancy_states`` to include ``"disabled"`` so standalone (non-failover) units are correctly treated as active.

### Housekeeping

- [#368](https://github.com/networktocode/pyntc/issues/368) - Converted EOS remote file copy tests from hypothesis/pytest standalone functions to unittest TestCase with `self.assertRaises` and `subTest` for consistency with the rest of the codebase.
- [#368](https://github.com/networktocode/pyntc/issues/368) - Removed duplicate test class `TestRemoteFileCopyCommandExecution` and consolidated into `TestRemoteFileCopy`.
- [#368](https://github.com/networktocode/pyntc/issues/368) - Added integration tests for EOS device connectivity and remote file copy across FTP, TFTP, SCP, HTTP, HTTPS, and SFTP protocols.
2 changes: 1 addition & 1 deletion docs/user/lib_getting_started.md
Original file line number Diff line number Diff line change
Expand Up @@ -252,7 +252,7 @@ interface GigabitEthernet1

#### Remote File Copy (Download to Device)

Some devices support copying files directly from a URL to the device. This is useful for larger files like OS images. To do this, you need to use the `FileCopyModel` data model to specify the source file information and then pass that to the `remote_file_copy` method. Currently only supported on Cisco IOS and Juniper Junos devices. Tested with ftp, http, https, sftp, and tftp urls.
Some devices support copying files directly from a URL to the device. This is useful for large files like OS images. To do this, you need to use the `FileCopyModel` data model to specify the source file information and then pass that to the `remote_file_copy` method. The model is currently supported on Arista EOS, Cisco ASA, Cisco IOS, Cisco NXOS, and Juniper Junos devices. It has been tested with ftp, http, https, sftp, and tftp urls.

- `remote_file_copy` method

Expand Down
23 changes: 12 additions & 11 deletions mkdocs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -132,18 +132,19 @@ nav:
- Uninstall: "admin/uninstall.md"
- Release Notes:
- "admin/release_notes/index.md"
- v0.0: "admin/release_notes/version_0.0.md"
- v0.14: "admin/release_notes/version_0.14.md"
- v0.15: "admin/release_notes/version_0.15.md"
- v0.16: "admin/release_notes/version_0.16.md"
- v0.17: "admin/release_notes/version_0.17.md"
- v0.18: "admin/release_notes/version_0.18.md"
- v0.19: "admin/release_notes/version_0.19.md"
- v0.20: "admin/release_notes/version_0.20.md"
- v1.0: "admin/release_notes/version_1.0.md"
- v2.0: "admin/release_notes/version_2.0.md"
- v2.1: "admin/release_notes/version_2.1.md"
- v2.3: "admin/release_notes/version_2.3.md"
- v2.2: "admin/release_notes/version_2.2.md"
- v2.1: "admin/release_notes/version_2.1.md"
- v2.0: "admin/release_notes/version_2.0.md"
- v1.0: "admin/release_notes/version_1.0.md"
- v0.20: "admin/release_notes/version_0.20.md"
- v0.19: "admin/release_notes/version_0.19.md"
- v0.18: "admin/release_notes/version_0.18.md"
- v0.17: "admin/release_notes/version_0.17.md"
- v0.16: "admin/release_notes/version_0.16.md"
- v0.15: "admin/release_notes/version_0.15.md"
- v0.14: "admin/release_notes/version_0.14.md"
- v0.0: "admin/release_notes/version_0.0.md"
- Developer Guide:
- Extending the Library: "dev/extending.md"
- Contributing to the Library: "dev/contributing.md"
Expand Down
52 changes: 49 additions & 3 deletions poetry.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 0 additions & 4 deletions pyntc/__init__.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
"""Kickoff functions for getting instance of device objects."""

import os
import warnings
from importlib import metadata

from .devices import supported_devices
Expand All @@ -23,9 +22,6 @@
LIB_PATH_DEFAULT = "~/.ntc.conf"


warnings.simplefilter("default")


def ntc_device(device_type, *args, **kwargs):
"""
Instantiate an instance of a ``pyntc.devices.BaseDevice`` by ``device_type``.
Expand Down
Loading
Loading