11-28-2022 02:12 AM
After 20 years break I created my first app in python. There is many such as, but this is mine!
App is graphical tool working as below:
Take list of devices, list of commands, user and password, connect to each device via ssh with credentials, execute command, repeat.
I find it really useful when I do lot of shows command on list of routers/switches, but it can be used to many tasks. Because limitation of paramiko library- configuration mode is not supported, but can be fix in future- if I decided so. I used it mostly to catch BGP tables from routers, if you are interested how big is internet BGP table- so, in Nov 2022, it is 444226 KB of text, and you need to wait ~45 min to catch it ( I used public access route server rviews.kanren.net).
Source file in python and .exe for win10 you can download from :
https://github.com/bartoszgagat/CSA/tree/beta1
Because it is my first python app - I think it can be better- some constructive criticism is needed.
11-30-2022 07:04 AM
Hi @gagat.b,
This is a very good script, especially for your first one!
I found these were excellent:
- detailed commenting
- variable names match purpose
-function names match purpose
- good exception handling
If I had to pick one thing to improve, it would be to eliminate some of the empty lines, for example:
Personally, I don't mind it, but some people want the fewest lines possible (while still maintaining readability). They like to see just one empty line between functions.
12-02-2022 07:31 AM
Hi @Alex . Thank you for review. I created some apps when I was young ,mostly in C and dialects, so it was funny to try Python and re-enable all "programmer" cells in my brain. Good to know this still is working
Discover and save your favorite ideas. Come back to expert answers, step-by-step guides, recent topics, and more.
New here? Get started with these tips. How to use Community New member guide