networka 0.1.12__tar.gz → 0.2.0__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (205) hide show
  1. {networka-0.1.12 → networka-0.2.0}/.gitignore +6 -0
  2. {networka-0.1.12 → networka-0.2.0}/PKG-INFO +50 -73
  3. {networka-0.1.12 → networka-0.2.0}/README.md +40 -61
  4. networka-0.2.0/docs/LLM_TASK_NOTES.md +37 -0
  5. networka-0.2.0/docs/adding-platforms.md +799 -0
  6. {networka-0.1.12 → networka-0.2.0}/docs/backups.md +6 -0
  7. {networka-0.1.12 → networka-0.2.0}/docs/configuration.md +25 -0
  8. networka-0.2.0/docs/development/networka-release-qualification.md +53 -0
  9. networka-0.2.0/docs/development/networka-upgrade-plan.md +45 -0
  10. networka-0.2.0/docs/development/networka-upgrade-report-2026-11-24.md +81 -0
  11. networka-0.2.0/docs/development/platform-registry-explanations.md +400 -0
  12. networka-0.2.0/docs/development/platform-registry-implementation-plan.md +867 -0
  13. networka-0.2.0/docs/development/platform-registry-summary.md +186 -0
  14. {networka-0.1.12 → networka-0.2.0}/docs/development.md +21 -4
  15. {networka-0.1.12 → networka-0.2.0}/docs/environment-variables.md +4 -3
  16. {networka-0.1.12 → networka-0.2.0}/docs/file_upload.md +6 -0
  17. {networka-0.1.12 → networka-0.2.0}/docs/getting-started.md +9 -4
  18. {networka-0.1.12 → networka-0.2.0}/docs/index.md +15 -2
  19. {networka-0.1.12 → networka-0.2.0}/docs/ip-address-support.md +4 -0
  20. networka-0.2.0/docs/library/adhoc-targets.md +120 -0
  21. networka-0.2.0/docs/library/index.md +88 -0
  22. networka-0.2.0/docs/library/quickstart.md +92 -0
  23. networka-0.2.0/docs/library/recipes.md +307 -0
  24. networka-0.2.0/docs/library/sessions.md +171 -0
  25. {networka-0.1.12 → networka-0.2.0}/docs/multi-vendor-support.md +30 -6
  26. networka-0.2.0/docs/nornir-inventory.md +82 -0
  27. {networka-0.1.12 → networka-0.2.0}/docs/overrides/home.html +2 -2
  28. networka-0.2.0/docs/platform-compatibility.md +12 -0
  29. networka-0.2.0/docs/pypi-setup.md +117 -0
  30. networka-0.2.0/docs/reference/api.md +198 -0
  31. {networka-0.1.12 → networka-0.2.0}/docs/reference/cli.md +136 -87
  32. networka-0.2.0/docs/reference/introspection.md +141 -0
  33. networka-0.2.0/docs/scrapli-platform-expansion-plan.md +772 -0
  34. networka-0.2.0/docs/ssh-config-sync.md +235 -0
  35. networka-0.2.0/docs/transport.md +18 -0
  36. {networka-0.1.12 → networka-0.2.0}/docs/vendors/cisco/index.md +16 -10
  37. {networka-0.1.12 → networka-0.2.0}/docs/vendors/index.md +14 -4
  38. {networka-0.1.12 → networka-0.2.0}/docs/vendors/mikrotik/index.md +17 -11
  39. networka-0.2.0/docs/vendors/nokia/index.md +31 -0
  40. {networka-0.1.12 → networka-0.2.0}/pyproject.toml +24 -13
  41. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/__about__.py +1 -1
  42. networka-0.2.0/src/network_toolkit/__init__.py +28 -0
  43. networka-0.2.0/src/network_toolkit/api/__init__.py +140 -0
  44. networka-0.2.0/src/network_toolkit/api/backup.py +307 -0
  45. networka-0.2.0/src/network_toolkit/api/diff.py +514 -0
  46. networka-0.2.0/src/network_toolkit/api/download.py +243 -0
  47. networka-0.2.0/src/network_toolkit/api/execution.py +51 -0
  48. networka-0.2.0/src/network_toolkit/api/firmware.py +200 -0
  49. networka-0.2.0/src/network_toolkit/api/info.py +80 -0
  50. networka-0.2.0/src/network_toolkit/api/list.py +246 -0
  51. networka-0.2.0/src/network_toolkit/api/platforms.py +174 -0
  52. networka-0.2.0/src/network_toolkit/api/routerboard_upgrade.py +149 -0
  53. networka-0.2.0/src/network_toolkit/api/run.py +577 -0
  54. networka-0.2.0/src/network_toolkit/api/state_diff.py +294 -0
  55. networka-0.2.0/src/network_toolkit/api/state_diff_patterns.py +130 -0
  56. networka-0.2.0/src/network_toolkit/api/upload.py +224 -0
  57. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/builtin_sequences/mikrotik_routeros/common.yml +1 -1
  58. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/cli.py +39 -13
  59. networka-0.2.0/src/network_toolkit/client.py +297 -0
  60. networka-0.2.0/src/network_toolkit/commands/backup.py +134 -0
  61. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/commands/complete.py +21 -18
  62. networka-0.2.0/src/network_toolkit/commands/diff.py +258 -0
  63. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/commands/download.py +71 -87
  64. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/commands/firmware.py +66 -221
  65. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/commands/info.py +65 -150
  66. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/commands/list.py +24 -61
  67. networka-0.2.0/src/network_toolkit/commands/platforms.py +195 -0
  68. networka-0.2.0/src/network_toolkit/commands/routerboard_upgrade.py +130 -0
  69. networka-0.2.0/src/network_toolkit/commands/run.py +531 -0
  70. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/commands/ssh.py +28 -13
  71. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/commands/ssh_platform.py +6 -0
  72. networka-0.2.0/src/network_toolkit/commands/sync_ssh.py +324 -0
  73. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/commands/upload.py +63 -84
  74. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/commands/vendor_config_backup.py +9 -23
  75. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/common/interactive_confirmation.py +3 -20
  76. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/common/output.py +1 -2
  77. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/common/resolver.py +19 -7
  78. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/common/table_providers.py +246 -209
  79. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/config.py +699 -151
  80. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/credentials.py +208 -42
  81. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/device.py +76 -122
  82. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/device_transfers.py +1 -1
  83. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/exceptions.py +4 -0
  84. networka-0.2.0/src/network_toolkit/introspection.py +208 -0
  85. networka-0.2.0/src/network_toolkit/inventory/__init__.py +1 -0
  86. networka-0.2.0/src/network_toolkit/inventory/catalog.py +307 -0
  87. networka-0.2.0/src/network_toolkit/inventory/nornir_simple.py +584 -0
  88. networka-0.2.0/src/network_toolkit/inventory/resolve.py +250 -0
  89. networka-0.2.0/src/network_toolkit/inventory/ssh_config.py +245 -0
  90. networka-0.2.0/src/network_toolkit/platforms/__init__.py +48 -0
  91. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/platforms/cisco_ios/operations.py +17 -11
  92. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/platforms/cisco_iosxe/operations.py +26 -12
  93. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/platforms/factory.py +53 -57
  94. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/platforms/mikrotik_routeros/operations.py +20 -12
  95. networka-0.2.0/src/network_toolkit/platforms/registry.py +367 -0
  96. networka-0.2.0/src/network_toolkit/py.typed +0 -0
  97. networka-0.2.0/src/network_toolkit/runtime.py +74 -0
  98. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/sequence_manager.py +15 -0
  99. networka-0.2.0/src/network_toolkit/session_pool.py +118 -0
  100. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/shell_completion/bash_completion_nw.sh +8 -2
  101. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/transport/factory.py +2 -27
  102. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/transport/interfaces.py +5 -1
  103. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/transport/nornir_netmiko.py +2 -0
  104. networka-0.2.0/src/network_toolkit/transport/scrapli_sync.py +251 -0
  105. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/tui/prompt.py +1 -1
  106. networka-0.1.12/docs/.generated/platform_capabilities.md +0 -9
  107. networka-0.1.12/docs/.generated/platform_support_table.md +0 -21
  108. networka-0.1.12/docs/.generated/vendor_list.md +0 -72
  109. networka-0.1.12/docs/platform-compatibility.md +0 -154
  110. networka-0.1.12/docs/reference/api.md +0 -19
  111. networka-0.1.12/docs/transport.md +0 -38
  112. networka-0.1.12/src/network_toolkit/__init__.py +0 -8
  113. networka-0.1.12/src/network_toolkit/commands/backup.py +0 -539
  114. networka-0.1.12/src/network_toolkit/commands/diff.py +0 -488
  115. networka-0.1.12/src/network_toolkit/commands/routerboard_upgrade.py +0 -200
  116. networka-0.1.12/src/network_toolkit/commands/run.py +0 -878
  117. networka-0.1.12/src/network_toolkit/platforms/__init__.py +0 -21
  118. networka-0.1.12/src/network_toolkit/platforms/cisco_ios/constants.py +0 -15
  119. networka-0.1.12/src/network_toolkit/platforms/cisco_iosxe/constants.py +0 -15
  120. networka-0.1.12/src/network_toolkit/platforms/mikrotik_routeros/constants.py +0 -31
  121. networka-0.1.12/src/network_toolkit/transport/scrapli_sync.py +0 -36
  122. {networka-0.1.12 → networka-0.2.0}/LICENSE +0 -0
  123. {networka-0.1.12 → networka-0.2.0}/config/examples/README.md +0 -0
  124. {networka-0.1.12 → networka-0.2.0}/docs/adding-gifs-guide.md +0 -0
  125. {networka-0.1.12 → networka-0.2.0}/docs/assets/gifs/networka-setup.gif +0 -0
  126. {networka-0.1.12 → networka-0.2.0}/docs/assets/images/networka.jpg +0 -0
  127. {networka-0.1.12 → networka-0.2.0}/docs/assets/images/networka.png +0 -0
  128. {networka-0.1.12 → networka-0.2.0}/docs/assets/images/networka2.png +0 -0
  129. {networka-0.1.12 → networka-0.2.0}/docs/assets/images/networka_readme.png +0 -0
  130. {networka-0.1.12 → networka-0.2.0}/docs/assets/javascripts/extra.js +0 -0
  131. {networka-0.1.12 → networka-0.2.0}/docs/assets/stylesheets/extra.css +0 -0
  132. {networka-0.1.12 → networka-0.2.0}/docs/backup-filename-normalization.md +0 -0
  133. {networka-0.1.12 → networka-0.2.0}/docs/cisco-ios-platform-mapping.md +0 -0
  134. {networka-0.1.12 → networka-0.2.0}/docs/documentation-guidelines.md +0 -0
  135. {networka-0.1.12 → networka-0.2.0}/docs/examples/recipes.md +0 -0
  136. {networka-0.1.12 → networka-0.2.0}/docs/examples/user_sequences/README.md +0 -0
  137. {networka-0.1.12 → networka-0.2.0}/docs/examples/user_sequences/arista_eos/custom.yml +0 -0
  138. {networka-0.1.12 → networka-0.2.0}/docs/examples/user_sequences/mikrotik_routeros/custom.yml +0 -0
  139. {networka-0.1.12 → networka-0.2.0}/docs/interactive-credentials.md +0 -0
  140. {networka-0.1.12 → networka-0.2.0}/docs/output-modes.md +0 -0
  141. {networka-0.1.12 → networka-0.2.0}/docs/overrides/partials/footer.html +0 -0
  142. {networka-0.1.12 → networka-0.2.0}/docs/overrides/partials/logo.html +0 -0
  143. {networka-0.1.12 → networka-0.2.0}/docs/results.md +0 -0
  144. {networka-0.1.12 → networka-0.2.0}/docs/running-commands.md +0 -0
  145. {networka-0.1.12 → networka-0.2.0}/docs/shell-completion.md +0 -0
  146. {networka-0.1.12 → networka-0.2.0}/docs/tmux-ssh.md +0 -0
  147. {networka-0.1.12 → networka-0.2.0}/docs/troubleshooting.md +0 -0
  148. {networka-0.1.12 → networka-0.2.0}/docs/vendors/arista/index.md +0 -0
  149. {networka-0.1.12 → networka-0.2.0}/docs/vendors/juniper/index.md +0 -0
  150. {networka-0.1.12 → networka-0.2.0}/shell_completion/bash_completion_nw.sh +0 -0
  151. {networka-0.1.12 → networka-0.2.0}/shell_completion/zsh_completion_nw.zsh +0 -0
  152. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/__main__.py +0 -0
  153. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/banner.py +0 -0
  154. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/builtin_sequences/arista_eos/common.yml +0 -0
  155. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/builtin_sequences/cisco_iosxe/common.yml +0 -0
  156. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/builtin_sequences/cisco_nxos/common.yml +0 -0
  157. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/builtin_sequences/juniper_junos/common.yml +0 -0
  158. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/commands/__init__.py +0 -0
  159. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/commands/config.py +0 -0
  160. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/commands/schema.py +0 -0
  161. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/commands/sequence.py +0 -0
  162. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/commands/ssh_engines.py +0 -0
  163. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/commands/ssh_fallback.py +0 -0
  164. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/common/color_magic.py +0 -0
  165. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/common/command.py +0 -0
  166. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/common/command_base.py +0 -0
  167. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/common/command_helpers.py +0 -0
  168. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/common/config_manifest.py +0 -0
  169. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/common/credentials.py +0 -0
  170. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/common/defaults.py +0 -0
  171. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/common/errors.py +0 -0
  172. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/common/file_utils.py +0 -0
  173. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/common/filename_utils.py +0 -0
  174. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/common/logging.py +0 -0
  175. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/common/output_clean.py +0 -0
  176. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/common/paths.py +0 -0
  177. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/common/styles.py +0 -0
  178. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/common/table_generator.py +0 -0
  179. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/ip_device.py +0 -0
  180. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/platforms/base.py +0 -0
  181. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/platforms/cisco_ios/__init__.py +0 -0
  182. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/platforms/cisco_iosxe/__init__.py +0 -0
  183. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/platforms/cisco_shared/__init__.py +0 -0
  184. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/platforms/cisco_shared/operations.py +0 -0
  185. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/platforms/mikrotik_routeros/__init__.py +0 -0
  186. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/platforms/mikrotik_routeros/confirmation_patterns.py +0 -0
  187. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/results_enhanced.py +0 -0
  188. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/schemas/__init__.py +0 -0
  189. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/shell_completion/zsh_completion_nw.zsh +0 -0
  190. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/transport/__init__.py +0 -0
  191. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/transport/nornir_inventory.py +0 -0
  192. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/tui/__init__.py +0 -0
  193. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/tui/app.py +0 -0
  194. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/tui/clipboard.py +0 -0
  195. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/tui/compat.py +0 -0
  196. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/tui/constants.py +0 -0
  197. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/tui/controller.py +0 -0
  198. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/tui/data.py +0 -0
  199. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/tui/dialogs.py +0 -0
  200. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/tui/helpers.py +0 -0
  201. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/tui/keymap.py +0 -0
  202. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/tui/layout.py +0 -0
  203. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/tui/models.py +0 -0
  204. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/tui/output_manager.py +0 -0
  205. {networka-0.1.12 → networka-0.2.0}/src/network_toolkit/tui/services.py +0 -0
@@ -71,6 +71,9 @@ instance/
71
71
  # Sphinx documentation
72
72
  docs/_build/
73
73
 
74
+ # Auto-generated documentation
75
+ docs/.generated/
76
+
74
77
  # PyBuilder
75
78
  .pybuilder/
76
79
  target/
@@ -284,3 +287,6 @@ config/sequences/*
284
287
 
285
288
  # Pre-release check marker
286
289
  .pre-release-passed
290
+
291
+ # LLM working files (plans, notes)
292
+ llm-plans/
@@ -1,6 +1,6 @@
1
- Metadata-Version: 2.4
1
+ Metadata-Version: 2.5
2
2
  Name: networka
3
- Version: 0.1.12
3
+ Version: 0.2.0
4
4
  Summary: Modern Python cli toolkit for network device automation
5
5
  Project-URL: Homepage, https://github.com/narrowin/networka
6
6
  Project-URL: Documentation, https://narrowin.github.io/networka/
@@ -13,7 +13,7 @@ Author-email: narrowin <contact@narrowin.com>
13
13
  Maintainer-email: narrowin <contact@narrowin.com>
14
14
  License: Apache-2.0
15
15
  License-File: LICENSE
16
- Keywords: async,automation,cli,infrastructure,mikrotik,narrowin,network,networking,routeros
16
+ Keywords: async,automation,cli,infrastructure,library,mikrotik,narrowin,network,networking,programmatic,python-api,routeros,sdk
17
17
  Classifier: Development Status :: 4 - Beta
18
18
  Classifier: Environment :: Console
19
19
  Classifier: Intended Audience :: Developers
@@ -21,29 +21,27 @@ Classifier: Intended Audience :: System Administrators
21
21
  Classifier: Intended Audience :: Telecommunications Industry
22
22
  Classifier: License :: OSI Approved :: Apache Software License
23
23
  Classifier: Operating System :: MacOS
24
- Classifier: Operating System :: Microsoft :: Windows
25
- Classifier: Operating System :: OS Independent
26
24
  Classifier: Operating System :: POSIX :: Linux
27
25
  Classifier: Programming Language :: Python :: 3
28
26
  Classifier: Programming Language :: Python :: 3 :: Only
29
27
  Classifier: Programming Language :: Python :: 3.11
30
28
  Classifier: Programming Language :: Python :: 3.12
31
29
  Classifier: Programming Language :: Python :: 3.13
30
+ Classifier: Programming Language :: Python :: 3.14
31
+ Classifier: Programming Language :: Python :: 3.15
32
32
  Classifier: Topic :: Software Development :: Libraries :: Python Modules
33
33
  Classifier: Topic :: System :: Networking
34
34
  Classifier: Topic :: System :: Systems Administration
35
35
  Classifier: Topic :: Utilities
36
36
  Classifier: Typing :: Typed
37
37
  Requires-Python: >=3.11
38
- Requires-Dist: asyncssh>=2.21.0
39
- Requires-Dist: libtmux>=0.46.2
38
+ Requires-Dist: libtmux<0.68,>=0.67.1
39
+ Requires-Dist: paramiko<6,>=5.1.0
40
40
  Requires-Dist: pydantic>=2.5.0
41
41
  Requires-Dist: python-dotenv>=1.0.0
42
42
  Requires-Dist: pyyaml>=6.0
43
43
  Requires-Dist: rich>=13.0.0
44
- Requires-Dist: scrapli-community>=2025.1.30
45
- Requires-Dist: scrapli[community]>=2023.7.30
46
- Requires-Dist: scrapli[paramiko]>=2023.7.30
44
+ Requires-Dist: scrapli==2026.11.12
47
45
  Requires-Dist: textual>=0.58.0
48
46
  Requires-Dist: typer>=0.12.0
49
47
  Provides-Extra: dev
@@ -51,13 +49,13 @@ Requires-Dist: bandit>=1.7.0; extra == 'dev'
51
49
  Requires-Dist: build>=0.10.0; extra == 'dev'
52
50
  Requires-Dist: cffconvert>=2.0.0; extra == 'dev'
53
51
  Requires-Dist: detect-secrets>=1.4.0; extra == 'dev'
54
- Requires-Dist: mypy>=1.7.0; extra == 'dev'
52
+ Requires-Dist: mypy==2.4.1; extra == 'dev'
55
53
  Requires-Dist: pytest-asyncio>=0.21.0; extra == 'dev'
56
54
  Requires-Dist: pytest-cov>=4.1.0; extra == 'dev'
57
55
  Requires-Dist: pytest-mock>=3.14.0; extra == 'dev'
58
56
  Requires-Dist: pytest-xdist>=3.8.0; extra == 'dev'
59
57
  Requires-Dist: pytest>=7.4.0; extra == 'dev'
60
- Requires-Dist: ruff>=0.1.0; extra == 'dev'
58
+ Requires-Dist: ruff==0.17.6; extra == 'dev'
61
59
  Requires-Dist: twine>=4.0.0; extra == 'dev'
62
60
  Requires-Dist: types-paramiko>=3.0.0; extra == 'dev'
63
61
  Requires-Dist: types-pyyaml>=6.0.0; extra == 'dev'
@@ -84,7 +82,7 @@ Originally developed at [narrowin](https://narrowin.ch/en/about.html), now commu
84
82
  **Networka: `Eierlegende Wollmilchsau` of network operations — optimized for your daily workflows.**
85
83
 
86
84
  [![Python 3.11+](https://img.shields.io/badge/python-3.11%2B-blue.svg)](https://www.python.org/downloads/)
87
- [![Platform](https://img.shields.io/badge/platform-Linux%20%7C%20macOS%20%7C%20Windows-lightgrey.svg)](https://github.com/narrowin/networka)
85
+ [![Platform](https://img.shields.io/badge/platform-Linux%20%7C%20macOS%20arm64-lightgrey.svg)](https://github.com/narrowin/networka)
88
86
  [![License: Apache-2.0](https://img.shields.io/badge/License-Apache_2.0-blue.svg)](https://www.apache.org/licenses/LICENSE-2.0)
89
87
  [![Code style: ruff](https://img.shields.io/badge/code%20style-ruff-000000.svg)](https://github.com/astral-sh/ruff)
90
88
  [![Type checked with mypy](https://img.shields.io/badge/mypy-checked-blue.svg)](http://mypy-lang.org/)
@@ -92,8 +90,6 @@ Originally developed at [narrowin](https://narrowin.ch/en/about.html), now commu
92
90
 
93
91
  Networka is a modern CLI tool for automating network devices across multiple vendors. Designed for network engineers who want fast, scalable automation with full cross-platform support.
94
92
 
95
- Built with the help of agentic-AI with humans in the loop, this started as an experiment that turned into something genuinely useful.
96
-
97
93
  ---
98
94
 
99
95
  ## _The Networka Monologue_
@@ -128,13 +124,25 @@ Because a real **Networka** wants the f\*ing lot.”<br><br>
128
124
  <p><em>Networka setup and command execution demo</em></p>
129
125
  </div>
130
126
 
127
+ ## Networka vs the alternatives
128
+
129
+ | | Networka | Ansible | Nornir |
130
+ |---|---|---|---|
131
+ | Primary interface | CLI commands | YAML playbooks | Python scripts |
132
+ | Time to first command | Seconds after install | After writing playbook + inventory | After writing Python script |
133
+ | Learning curve | Familiar CLI patterns | YAML, Jinja2, modules | Python programming |
134
+ | Execution | Concurrent by default | Sequential by default | Depends on implementation |
135
+ | Best for | Daily operations, ad-hoc commands | Infrastructure-as-code, compliance | Custom automation frameworks |
136
+
137
+ Networka is built for network engineers who want to run commands now. Ansible excels at declarative infrastructure-as-code. Nornir shines when you need full Python programmability. Different tools, each great at what they do.
138
+
131
139
  ## Features
132
140
 
133
141
  ### **Core Capabilities**
134
142
 
135
143
  - **Multi-vendor network automation**: Native support for MikroTik RouterOS, Cisco IOS/IOS-XE/NX-OS, Arista EOS, Juniper JunOS, and more
136
144
  - **Scalable device management**: Execute commands across individual devices or groups
137
- - **Cross-platform compatibility**: Full support for Linux, macOS, and Windows environments
145
+ - **Cross-platform compatibility**: Scrapli 2 wheels for Linux and Apple Silicon
138
146
  - **Flexible configuration**: YAML and CSV configuration options with powerful device tagging and grouping
139
147
 
140
148
  ### **Operational Features**
@@ -164,84 +172,53 @@ Because a real **Networka** wants the f\*ing lot.”<br><br>
164
172
 
165
173
  ### System Requirements
166
174
 
167
- - **Operating System**: Linux, macOS, or Windows
168
- - **Python**: 3.11, 3.12, or 3.13
175
+ - **Operating System**: Linux x86-64/arm64 or macOS arm64
169
176
  - **Network Access**: SSH connectivity to target devices
170
177
  - **Package Manager**: uv (recommended) or pip
178
+ - **tmux for `nw cli`**: Install tmux to use the multi-pane CLI command (`brew install tmux` on macOS, `apt install tmux` on Debian/Ubuntu). libtmux is installed automatically with Networka.
171
179
 
172
- ### Quick Install (recommended)
180
+ ### Install from the checkout
173
181
 
174
- Not on PyPI yet — install from GitHub.
182
+ With uv 0.13.9 in this checkout, use a project environment to keep the native driver isolated.
175
183
 
176
184
  ```bash
177
- # Recommended (isolated, user-wide)
178
- uv tool install git+https://github.com/narrowin/networka.git
179
-
180
- # Alternative
181
- pipx install git+https://github.com/narrowin/networka.git
182
-
183
- # Verify installation
184
- nw --help
185
+ uv sync --locked
186
+ uv run nw --version
187
+ uv run nw --help
185
188
  ```
186
189
 
187
- #### If `nw` is not found
190
+ Networka 0.2.0 uses Scrapli 2 via the `scrapli==2026.11.12` distribution. An in-place upgrade replaces legacy Scrapli through pip or uv. Early candidate installations that included `scrapli2==2.0.4` should use a fresh environment. Networka 0.2.0 targets Linux and Apple Silicon macOS. RouterOS restart confirmation and Cisco enable-password escalation passed in disposable labs. WSL2 remains unverified. [Transport selection](docs/transport.md) · [Platform compatibility](docs/platform-compatibility.md)
188
191
 
189
- - Check: `command -v nw` (Linux/macOS) or `where nw` (Windows)
190
- - If using pipx: ensure PATH is set, then reload shell
191
- ```bash
192
- pipx ensurepath
193
- exec $SHELL
194
- ```
195
- - Linux/macOS: add user bin to PATH if needed
196
- ```bash
197
- echo 'export PATH="$HOME/.local/bin:$PATH"' >> ~/.bashrc # or ~/.zshrc
198
- exec $SHELL
199
- ```
200
- - Windows (native, best-effort): prefer WSL2; if native, run `pipx ensurepath` and restart the terminal
201
-
202
- More → PATH troubleshooting: https://narrowin.github.io/networka/troubleshooting/#path-nw-not-found
192
+ ## Quick Start
203
193
 
204
- ### Upgrade & Remove
194
+ Get up and running with config init command:
205
195
 
206
196
  ```bash
207
- # Upgrade to latest version (from GitHub)
208
- uv tool install --force git+https://github.com/narrowin/networka.git
209
- # or
210
- pipx install --force git+https://github.com/narrowin/networka.git
211
-
212
- # Remove installation
213
- uv tool uninstall nw
214
- # or
215
- pipx uninstall networka
197
+ # Initialize in default location with interactive prompts
198
+ nw config init
199
+
216
200
  ```
217
201
 
218
- ### Platform-Specific Notes
202
+ ### Library API
219
203
 
220
- **Linux/macOS**: No additional dependencies required
204
+ Use Networka programmatically in your Python applications:
221
205
 
222
- **Windows**: Scrapli (the default transport) does not officially support native Windows. While it may work with Paramiko or ssh2-python drivers, the recommended approach is to run Networka on WSL2 (Ubuntu) for a fully supported POSIX environment. Native Windows usage is best-effort.
206
+ ```python
207
+ from network_toolkit import NetworkaClient, DeviceSession
223
208
 
224
- WSL2 quickstart (recommended):
209
+ client = NetworkaClient()
225
210
 
226
- ```bash
227
- # In Ubuntu on WSL2
228
- curl -LsSf https://astral.sh/uv/install.sh | sh
229
- exec $SHELL
230
- uv tool install git+https://github.com/narrowin/networka.git
231
- nw --help
211
+ with DeviceSession("router1", client.config) as session:
212
+ output = session.execute_command("show version")
213
+ print(output)
232
214
  ```
233
215
 
234
- Details → https://narrowin.github.io/networka/platform-compatibility/#wsl2-quickstart-recommended
235
-
236
- ## Quick Start
237
-
238
- Get up and running with config init command:
216
+ See the [Library Documentation](https://narrowin.github.io/networka/library/) for:
239
217
 
240
- ```bash
241
- # Initialize in default location with interactive prompts
242
- nw config init
243
-
244
- ```
218
+ - Multi-command workflows with persistent sessions
219
+ - Ad-hoc IP targeting without configuration files
220
+ - Credential handling patterns
221
+ - Integration recipes
245
222
 
246
223
  ### One-liners (no config)
247
224
 
@@ -13,7 +13,7 @@ Originally developed at [narrowin](https://narrowin.ch/en/about.html), now commu
13
13
  **Networka: `Eierlegende Wollmilchsau` of network operations — optimized for your daily workflows.**
14
14
 
15
15
  [![Python 3.11+](https://img.shields.io/badge/python-3.11%2B-blue.svg)](https://www.python.org/downloads/)
16
- [![Platform](https://img.shields.io/badge/platform-Linux%20%7C%20macOS%20%7C%20Windows-lightgrey.svg)](https://github.com/narrowin/networka)
16
+ [![Platform](https://img.shields.io/badge/platform-Linux%20%7C%20macOS%20arm64-lightgrey.svg)](https://github.com/narrowin/networka)
17
17
  [![License: Apache-2.0](https://img.shields.io/badge/License-Apache_2.0-blue.svg)](https://www.apache.org/licenses/LICENSE-2.0)
18
18
  [![Code style: ruff](https://img.shields.io/badge/code%20style-ruff-000000.svg)](https://github.com/astral-sh/ruff)
19
19
  [![Type checked with mypy](https://img.shields.io/badge/mypy-checked-blue.svg)](http://mypy-lang.org/)
@@ -21,8 +21,6 @@ Originally developed at [narrowin](https://narrowin.ch/en/about.html), now commu
21
21
 
22
22
  Networka is a modern CLI tool for automating network devices across multiple vendors. Designed for network engineers who want fast, scalable automation with full cross-platform support.
23
23
 
24
- Built with the help of agentic-AI with humans in the loop, this started as an experiment that turned into something genuinely useful.
25
-
26
24
  ---
27
25
 
28
26
  ## _The Networka Monologue_
@@ -57,13 +55,25 @@ Because a real **Networka** wants the f\*ing lot.”<br><br>
57
55
  <p><em>Networka setup and command execution demo</em></p>
58
56
  </div>
59
57
 
58
+ ## Networka vs the alternatives
59
+
60
+ | | Networka | Ansible | Nornir |
61
+ |---|---|---|---|
62
+ | Primary interface | CLI commands | YAML playbooks | Python scripts |
63
+ | Time to first command | Seconds after install | After writing playbook + inventory | After writing Python script |
64
+ | Learning curve | Familiar CLI patterns | YAML, Jinja2, modules | Python programming |
65
+ | Execution | Concurrent by default | Sequential by default | Depends on implementation |
66
+ | Best for | Daily operations, ad-hoc commands | Infrastructure-as-code, compliance | Custom automation frameworks |
67
+
68
+ Networka is built for network engineers who want to run commands now. Ansible excels at declarative infrastructure-as-code. Nornir shines when you need full Python programmability. Different tools, each great at what they do.
69
+
60
70
  ## Features
61
71
 
62
72
  ### **Core Capabilities**
63
73
 
64
74
  - **Multi-vendor network automation**: Native support for MikroTik RouterOS, Cisco IOS/IOS-XE/NX-OS, Arista EOS, Juniper JunOS, and more
65
75
  - **Scalable device management**: Execute commands across individual devices or groups
66
- - **Cross-platform compatibility**: Full support for Linux, macOS, and Windows environments
76
+ - **Cross-platform compatibility**: Scrapli 2 wheels for Linux and Apple Silicon
67
77
  - **Flexible configuration**: YAML and CSV configuration options with powerful device tagging and grouping
68
78
 
69
79
  ### **Operational Features**
@@ -93,84 +103,53 @@ Because a real **Networka** wants the f\*ing lot.”<br><br>
93
103
 
94
104
  ### System Requirements
95
105
 
96
- - **Operating System**: Linux, macOS, or Windows
97
- - **Python**: 3.11, 3.12, or 3.13
106
+ - **Operating System**: Linux x86-64/arm64 or macOS arm64
98
107
  - **Network Access**: SSH connectivity to target devices
99
108
  - **Package Manager**: uv (recommended) or pip
109
+ - **tmux for `nw cli`**: Install tmux to use the multi-pane CLI command (`brew install tmux` on macOS, `apt install tmux` on Debian/Ubuntu). libtmux is installed automatically with Networka.
100
110
 
101
- ### Quick Install (recommended)
111
+ ### Install from the checkout
102
112
 
103
- Not on PyPI yet — install from GitHub.
113
+ With uv 0.13.9 in this checkout, use a project environment to keep the native driver isolated.
104
114
 
105
115
  ```bash
106
- # Recommended (isolated, user-wide)
107
- uv tool install git+https://github.com/narrowin/networka.git
108
-
109
- # Alternative
110
- pipx install git+https://github.com/narrowin/networka.git
111
-
112
- # Verify installation
113
- nw --help
116
+ uv sync --locked
117
+ uv run nw --version
118
+ uv run nw --help
114
119
  ```
115
120
 
116
- #### If `nw` is not found
121
+ Networka 0.2.0 uses Scrapli 2 via the `scrapli==2026.11.12` distribution. An in-place upgrade replaces legacy Scrapli through pip or uv. Early candidate installations that included `scrapli2==2.0.4` should use a fresh environment. Networka 0.2.0 targets Linux and Apple Silicon macOS. RouterOS restart confirmation and Cisco enable-password escalation passed in disposable labs. WSL2 remains unverified. [Transport selection](docs/transport.md) · [Platform compatibility](docs/platform-compatibility.md)
117
122
 
118
- - Check: `command -v nw` (Linux/macOS) or `where nw` (Windows)
119
- - If using pipx: ensure PATH is set, then reload shell
120
- ```bash
121
- pipx ensurepath
122
- exec $SHELL
123
- ```
124
- - Linux/macOS: add user bin to PATH if needed
125
- ```bash
126
- echo 'export PATH="$HOME/.local/bin:$PATH"' >> ~/.bashrc # or ~/.zshrc
127
- exec $SHELL
128
- ```
129
- - Windows (native, best-effort): prefer WSL2; if native, run `pipx ensurepath` and restart the terminal
130
-
131
- More → PATH troubleshooting: https://narrowin.github.io/networka/troubleshooting/#path-nw-not-found
123
+ ## Quick Start
132
124
 
133
- ### Upgrade & Remove
125
+ Get up and running with config init command:
134
126
 
135
127
  ```bash
136
- # Upgrade to latest version (from GitHub)
137
- uv tool install --force git+https://github.com/narrowin/networka.git
138
- # or
139
- pipx install --force git+https://github.com/narrowin/networka.git
140
-
141
- # Remove installation
142
- uv tool uninstall nw
143
- # or
144
- pipx uninstall networka
128
+ # Initialize in default location with interactive prompts
129
+ nw config init
130
+
145
131
  ```
146
132
 
147
- ### Platform-Specific Notes
133
+ ### Library API
148
134
 
149
- **Linux/macOS**: No additional dependencies required
135
+ Use Networka programmatically in your Python applications:
150
136
 
151
- **Windows**: Scrapli (the default transport) does not officially support native Windows. While it may work with Paramiko or ssh2-python drivers, the recommended approach is to run Networka on WSL2 (Ubuntu) for a fully supported POSIX environment. Native Windows usage is best-effort.
137
+ ```python
138
+ from network_toolkit import NetworkaClient, DeviceSession
152
139
 
153
- WSL2 quickstart (recommended):
140
+ client = NetworkaClient()
154
141
 
155
- ```bash
156
- # In Ubuntu on WSL2
157
- curl -LsSf https://astral.sh/uv/install.sh | sh
158
- exec $SHELL
159
- uv tool install git+https://github.com/narrowin/networka.git
160
- nw --help
142
+ with DeviceSession("router1", client.config) as session:
143
+ output = session.execute_command("show version")
144
+ print(output)
161
145
  ```
162
146
 
163
- Details → https://narrowin.github.io/networka/platform-compatibility/#wsl2-quickstart-recommended
164
-
165
- ## Quick Start
166
-
167
- Get up and running with config init command:
147
+ See the [Library Documentation](https://narrowin.github.io/networka/library/) for:
168
148
 
169
- ```bash
170
- # Initialize in default location with interactive prompts
171
- nw config init
172
-
173
- ```
149
+ - Multi-command workflows with persistent sessions
150
+ - Ad-hoc IP targeting without configuration files
151
+ - Credential handling patterns
152
+ - Integration recipes
174
153
 
175
154
  ### One-liners (no config)
176
155
 
@@ -0,0 +1,37 @@
1
+ # Networka CLI → Library Refactor Notes
2
+
3
+ Purpose: compact context for LLMs continuing the refactor so the Typer CLI (`nw`) becomes a thin layer over an importable library without regressing behavior or tests.
4
+
5
+ ## Current Architecture
6
+ - Package namespace: `network_toolkit` under `src/`.
7
+ - CLI entrypoint: `[project.scripts] nw = "network_toolkit.cli:app"` (unchanged).
8
+ - CLI pattern: Typer commands in `network_toolkit/commands/*` that should only parse args, call library functions, format output, and map exceptions to exit codes.
9
+ - Library pattern: Logic modules under `network_toolkit/api/*` returning typed data structures; no printing, no `sys.exit`/`typer.Exit`.
10
+ - Public surface: `network_toolkit/api/__init__.py` re-exports API types/functions.
11
+ - Example library module implemented: `network_toolkit/api/run.py` (`run_commands`, typed result dataclasses, `TargetResolutionError`).
12
+ - CLI wrapper updated: `network_toolkit/commands/run.py` now delegates to the API and only handles presentation/exit behavior.
13
+ - Helper tool: `scripts/api_test_tool.py` demonstrates calling the API directly via argparse (no Typer).
14
+
15
+ ## Testing Status
16
+ - New API tests: `tests/test_api_run.py` (dummy DeviceSession) cover single-device command, group sequence, and unknown-target error handling with deterministic ordering.
17
+ - Full suite not run in this environment (pytest not available); rerun `pytest` once dependencies are present.
18
+
19
+ ## Goals (keep these invariant)
20
+ - Separate heavy logic into `network_toolkit/api/*`; CLI files stay thin.
21
+ - Functions return typed data (dataclasses or Pydantic models) and raise typed exceptions; no printing/exit in library code.
22
+ - Reuse existing helpers (config/device/transport/sequence/results) instead of duplicating logic.
23
+ - Preserve existing behavior, output modes (including raw/JSON), and tests.
24
+ - Maintain API stability via `network_toolkit/api/__init__.py` exports and versioned result/exception types.
25
+
26
+ ## Outstanding Work
27
+ - Add API-level tests for each migrated command and expand `api/__init__.py` exports.
28
+ - Document programmatic usage and API stability policy once more commands are migrated.
29
+ - Optional: update tooling/docs to encourage direct API use (e.g., enrich `scripts/compliance_report.py` or add examples).
30
+
31
+ ## Quick Usage Examples
32
+ - Programmatic: `from network_toolkit.api.run imuv run nw list devicesport RunOptions, run_commands`
33
+ - CLI remains: `nw run ...` (delegates to API internally)
34
+
35
+ ## Distilled Next-Session Focus (config)
36
+ - There is no need to migragte remaining commands (`config`, `ssh`, `schema`)!
37
+ - **`vendor_config_backup`**: Investigate `commands/vendor_config_backup.py`. It appears to be a command implementation but is not currently registered in `cli.py`. Determine if it should be refactored to `api/vendor_backup.py` or removed if obsolete.