- Fix the `dump_json` method in the `ModelView` class to call `model_dump_json` instead of `model_dump`, ensuring consistency in JSON serialization.
- Added a new test case in `TestListModelView` to verify the functionality of `dump_json` and check for correct IP address serialization.
- Enhanced the `vlans`, `interfaces`, and `system` properties with type hints for better clarity and type checking.
- Added detailed docstrings to each property, describing the return types and structure of the associated configurations.
- Changed the runner from `ubuntu-latest` to `rassbery` for the `ci-success` job.
- Specified a custom container `catthehacker/ubuntu:act-22.04` for the job environment, enhancing compatibility and consistency in the CI process.
- Replaced 'disabled' with 'shutdown' in the Mikrotik template to align with the new interface state management.
- Updated expected configuration JSON to set 'shutdown' to true for accurate testing and validation of interface configurations.
- Included the `shutdown` command in the Huawei interface template to manage interface states.
- Added a new interface configuration in `config.conf` with the `shutdown` command.
- Updated the expected output JSON to reflect the new interface and its shutdown state for accurate testing and validation of configurations.
- Included the `shutdown` command in the Qtech interface template to manage interface states.
- Updated expected output JSON files to set the `shutdown` attribute to true for accurate testing and validation of interface configurations.
- Included the `shutdown` command in the H3C interface template to reflect the new interface state management.
- Updated the `config.conf` file to include the `shutdown` command for the `HundredGigE1/0/3` interface.
- Modified the expected output JSON to set the `shutdown` attribute to true, ensuring accurate testing and validation of interface configurations.
- Incremented the project version in `pyproject.toml` from 0.1.0 to 0.1.1.
- Added `.coverage` to `.gitignore` to prevent tracking of coverage reports.
- Added a `shutdown` boolean attribute to the `Interfaces` class to manage interface states.
- Updated the `eltex.ttp` template to include the `shutdown` command based on the new attribute.
- Modified expected configuration JSON files for various devices to reflect the new `shutdown` attribute, ensuring accurate testing and validation of interface configurations.
- Introduced a new job `ci-success` in both Gitea and GitHub CI workflows to verify that all previous jobs (lint and test) succeeded.
- The job runs on `ubuntu-latest` and exits with a failure status if any prior job has failed or been cancelled, enhancing the reliability of the CI process.
- Added .python-version to .gitignore to prevent tracking of Python version files.
- Deleted the .python-version file as it is no longer needed for the project.
- Created a CI workflow for Gitea with linting and testing jobs using Python versions 3.10 to 3.13.
- Established a CI workflow for GitHub with similar linting and testing jobs, ensuring consistency across platforms.
- Both workflows utilize the `uv` tool for dependency management and testing, enhancing the project's CI/CD capabilities.
- Added `.vscode` to `.gitignore` to exclude Visual Studio Code settings.
- Updated `pyproject.toml` to include `ruff` for linting and configured its settings.
- Modified `uv.lock` to include `ruff` in both optional and development dependencies.
- Refactored type hints in several files to use `str | None` for optional parameters.
- Cleaned up unused imports and whitespace in various modules for improved code clarity.
- Updated `pytest` to version 9.0.3 and `responses` to version 0.26.1 in `pyproject.toml`.
- Removed the main execution block from the Huawei model for cleaner code structure.
- Introduced support for H3C devices by adding a new configuration file `config.conf` containing interface and VLAN settings.
- Created an expected output JSON file `config.expected.json` to validate the parsing of H3C configurations.
- Updated the test model cases to include H3C for comprehensive testing of device parsing functionality.
- Eliminated the main execution block from the Quasar model for cleaner code.
- Introduced new configuration files `config_1.conf` and `config_2.conf` for Quasar devices, detailing interface settings and IP configurations.
- Added expected output JSON files `config_1.expected.json` and `config_2.expected.json` to validate the parsing of Quasar configurations against expected results.
- Introduced a new JSON file `config.expected.json` containing expected system and interface configurations for Mikrotik devices, including model, serial number, IP addresses, and VLAN details.
- This addition facilitates testing and validation of the parsing functionality for Mikrotik configurations.
- Introduced a static method `_as_list` to normalize TTP group results, ensuring consistent list output regardless of input type (dict or list).
- Updated the `_validate_contract` method to utilize `_as_list` for processing interfaces and VLANs, improving code clarity and reliability.
- Removed unused imports and main execution block from the Mikrotik model for cleaner code.
- Updated the Mikrotik TTP template to adjust the order of parameters in the 'add' command, enhancing clarity in the generated configurations.
- Added a new configuration file `config.conf` for Mikrotik devices to facilitate testing and validation of parsing functionality.
- Updated the Eltex TTP template to include 'name' and 'description' fields for interfaces, enhancing clarity and detail in the generated configurations.
- Replaced the internal `_expand_vlan_range` function in the `Qtech` class with the new `expand_vlan_range` utility from `utils.py` for improved code maintainability.
- Added new configuration files `config_1.conf` and `config_2.conf` for Qtech devices to facilitate testing.
- Introduced expected output JSON files `config_1.expected.json` and `config_2.expected.json` to validate the parsing of Qtech configurations against expected results.
- Introduced a new configuration file `config.conf` for Huawei devices, detailing interface settings and VLAN configurations.
- Added an expected output JSON file `config.expected.json` to validate the parsing of Huawei configurations against expected results, including system model, serial number, and interface details.
- Replaced the internal `_expand_vlan_range` function in the `Eltex` class with the new `expand_vlan_range` utility from `utils.py` for improved code maintainability.
- Added a new configuration file `config.conf` for Eltex devices to facilitate testing.
- Introduced an expected output JSON file `config.expected.json` to validate the parsing of Eltex configurations against expected results.
- Removed the internal `_decode_utf` method from the `Keenetic` class and replaced its usage with the new `decode_utf` utility function for decoding interface descriptions.
- Added a new configuration file `config.conf` for Keenetic devices to facilitate testing.
- Introduced an expected output JSON file `config.expected.json` to validate the parsing of Keenetic configurations against expected results.
- Introduced a new test file `test_models.py` to implement unit tests for various device models in the `device_registry`.
- Added parameterized tests to validate the parsing of device configurations against expected JSON outputs and to ensure required sections are present in the parsed models.
- Enhanced test coverage for multiple device types including Mikrotik, Keenetic, Qtech, Huawei, Eltex, and Quasar.
- Introduced a new utility function `decode_utf` in `utils.py` to decode escaped UTF-8 descriptions.
- Updated unit tests in `test_units.py` to include tests for the `decode_utf` function, covering plain text and escaped UTF-8 scenarios.
- Refactored existing tests to streamline the usage of the `expand_vlan_range` function.
- Introduced a new utility function `expand_vlan_range` in `utils.py` to expand VLAN range strings into individual VLAN IDs.
- Created a new test file `test_units.py` with unit tests for the `expand_vlan_range` function, covering various scenarios including simple ranges, reversed ranges, non-numeric inputs, and list inputs.
- Enhanced test coverage for other functionalities in the `device_registry` and template validation classes.
- Modified the Huawei TTP template to append the model identifier to the version string, enhancing the clarity of system information output for diagnostics.
- Introduced a new test file `test_network.py` to implement unit tests for the `OxiAPI` class.
- Added tests for node retrieval, configuration fetching, error handling for missing nodes, and response status checks.
- Utilized the `responses` library to mock API responses for comprehensive testing of various scenarios, including successful retrieval and error cases.
- Added `.DS_Store` to `.gitignore` to prevent macOS system files from being tracked.
- Introduced optional development dependencies in `pyproject.toml`, including `pytest` and `responses`, to facilitate testing and development.
- Updated `uv.lock` with new package dependencies and versions for improved compatibility and functionality.
- Created new test files `conftest.py` and `test_view.py` to establish testing fixtures and implement unit tests for the `ModelView` class.
- Added a repository URL section in `pyproject.toml` to link to the GitHub repository.
- Updated installation instructions in `README.md` to reflect the change from Gitea to GitHub as the source for package installation, removing references to the private Gitea Package Registry.
- Updated the required setuptools version from 61 to 77 to ensure compatibility with the latest features and improvements.
- Changed the license format in `pyproject.toml` to specify "Apache-2.0" directly and added a reference to the license file for clarity.
- Revised the project description in `pyproject.toml` to better reflect the functionality of the `oxipy` client.
- Improved the README.md by adding detailed explanations of the project structure, installation instructions, and usage examples.
- Updated documentation files to enhance clarity and organization, including sections on extending models and writing TTP templates.
- Adjusted various TTP templates to ensure consistency and accuracy in the parsing of device configurations.
- Introduced a new helper function `_expand_vlan_range` to convert VLAN range strings into a list of individual VLAN IDs.
- Enhanced the `vlans` method in the `Qtech` class to utilize the new function, improving the handling of VLAN IDs and ensuring proper processing of both individual and range-based VLAN inputs.
- Modified the Huawei TTP template to enhance the system information output by including the line identifier and slot number alongside the version and serial number. This change aims to provide clearer context for system diagnostics.
- Changed the required Python version in `pyproject.toml` from 3.11 to 3.10 to broaden compatibility.
- Removed an unused import from `oxi/conf.py` to streamline the code and improve readability.
- Updated the `BaseDevice` class constructor to accept an optional `name` parameter for better context in error messages.
- Improved the `_validate_contract` method to raise an `OxiAPIError` with a descriptive message if the node is not found.
- Modified the `_run_ttp` method to include a check for node existence, returning `None` if not found.
- Changed the test file name in the `Eltex` model to reflect a more descriptive context for testing node not found scenarios.
- Added a new helper function `_looks_like_node_not_found_html` to identify NodeNotFound errors based on HTTP response content.
- Updated the `from_http_error` method in the `OxiAPIError` class to convert 500 status codes to 404 when a NodeNotFound error is detected, improving error handling and user feedback.
- Updated the `reload` method in the `OxiAPI` class to catch `HTTPError` exceptions and raise a custom `OxiAPIError` with context.
- Improved the `__call__` method in the `Node` class to handle `HTTPError` exceptions similarly, providing context-specific error messages.
- Introduced a new class method `from_http_error` in `OxiAPIError` for standardized error message generation based on HTTP status codes.