Matthew Stidham
12f4263843
lfcli_base: Fix whitespace
...
Signed-off-by: Matthew Stidham <stidmatt@gmail.com >
2021-12-06 11:24:32 -08:00
Matthew Stidham
f9b3347138
LFRequest: Fix whitespace
...
Signed-off-by: Matthew Stidham <stidmatt@gmail.com >
2021-12-06 11:24:18 -08:00
Matthew Stidham
8dcde027f8
lfcli_base: set type of num_stations to always be an integer. Dot not ever, ever, ever set a flag as default=False. Use action='store_true', and do not ever ever ever use both at the same time.
...
Signed-off-by: Matthew Stidham <stidmatt@gmail.com >
2021-11-23 10:01:00 -08:00
Matthew Stidham
78d712e03e
lfcli_base: Mutable defaults at the root of our code are a wonderful way to create unexpected problems.
...
Signed-off-by: Matthew Stidham <stidmatt@gmail.com >
2021-11-19 09:36:18 -08:00
Matthew Stidham
ad0d80dab1
lfcli_base.json_get: Improve json_get debugging
...
Signed-off-by: Matthew Stidham <stidmatt@gmail.com >
2021-11-16 18:46:35 -08:00
Matthew Stidham
3a9a0b5de1
pandas_extensions: Remove invalid comparisons
...
Signed-off-by: Matthew Stidham <stidmatt@gmail.com >
2021-11-16 11:06:48 -08:00
Matthew Stidham
bd760c7552
lfcli_base.py: Remove invalid comparisons
...
Signed-off-by: Matthew Stidham <stidmatt@gmail.com >
2021-11-16 11:06:34 -08:00
Matthew Stidham
8a2a466edf
LFRequest: Remove invalid comparisons
...
Signed-off-by: Matthew Stidham <stidmatt@gmail.com >
2021-11-16 11:06:19 -08:00
Matthew Stidham
be740527bf
lfcli_base: Create report-data folder in home directory if it doesn't exist
...
Signed-off-by: Matthew Stidham <stidmatt@gmail.com >
2021-11-15 15:56:31 -08:00
Matthew Stidham
d0c40cb4b2
lfcli_base fix if os.path.isdir command
...
Signed-off-by: Matthew Stidham <stidmatt@gmail.com >
2021-11-15 15:35:11 -08:00
Matthew Stidham
12da46d6fb
Remove == True error in LFRequest
...
Signed-off-by: Matthew Stidham <stidmatt@gmail.com >
2021-11-15 13:36:27 -08:00
Matthew Stidham
3c1858a609
Remove == True errors in lfcli_base
...
Signed-off-by: Matthew Stidham <stidmatt@gmail.com >
2021-11-15 13:36:05 -08:00
Matthew Stidham
f2b4628a81
We cannot use default paramters in our code!
...
Signed-off-by: Matthew Stidham <stidmatt@gmail.com >
2021-11-15 11:39:38 -08:00
Matthew Stidham
7ff62b9fd6
Fix improper equalities in LFUtils.py
...
Signed-off-by: Matthew Stidham <stidmatt@gmail.com >
2021-11-12 14:42:29 -08:00
Jed Reynolds
ec76d13ba5
LFRequest.py: json_post debug message more readable
...
Signed-off-by: Jed Reynolds <jed@bitratchet.com >
2021-11-08 22:28:54 -08:00
Matthew Stidham
c4511ad39a
Fix LFRequest.get so it inherits debug commands from the class
...
Signed-off-by: Matthew Stidham <stidmatt@gmail.com >
2021-11-08 18:52:26 -08:00
Jed Reynolds
8a0b5c22f0
LFRequest.py: converting if(debug):print() to self.logger.debug() statements
...
This change hooks into the global python logging instance and exercises level based logging
without more advanced logic like "digest/json/http/gui" as documented elsewhere. Need to
establish the correctness of this usage before moving forward.
Signed-off-by: Jed Reynolds <jed@bitratchet.com >
2021-11-03 19:53:30 -07:00
Jed Reynolds
2f7baf2987
lfcli_base.py: can now import lanforge_client.logg
...
Adds notes on where present logg() function is being used
Signed-off-by: Jed Reynolds <jed@bitratchet.com >
2021-11-03 19:53:30 -07:00
Jed Reynolds
3a17f699cc
LFUtils.py can now import Logg
...
Signed-off-by: Jed Reynolds <jed@bitratchet.com >
2021-11-03 19:53:30 -07:00
Jed Reynolds
be4c47295f
lfcli_base.py: adds logging logic that is distinct from lanforge_api.py but similar in function
...
this was checked with lf_help_check.bash and check_argparse.py.
Signed-off-by: Jed Reynolds <jreynolds@candelatech.com >
2021-11-02 16:45:28 -07:00
Jed Reynolds
8118406f7d
lfcli_base.py: whitespace, renamed variable x to argument
2021-11-02 16:45:28 -07:00
Jed Reynolds
45ae840e2a
lf_json_autogen.py removed, replaced by lanforge_api.py
...
Signed-off-by: Jed Reynolds <jed@bitratchet.com >
2021-10-29 09:58:16 -07:00
Jed Reynolds
bcbc3bf7a2
JSON: py-json/LANforge/set_port.py adjusted to lanforge_client/lanforge_api.py
2021-10-11 16:15:53 -07:00
Matthew Stidham
8f2fa4bf8c
* We don't need to import LFUtils in lfcli_base
...
* local_realm in lf_attenmod is unused.
* local_realm in attenuator_profile is unused, because I'm switching to inheritance as part of my work eliminating redundancy.
Signed-off-by: Matthew Stidham <stidmatt@gmail.com >
2021-10-04 11:51:37 -07:00
Chuck SmileyRekiere
4744bc488a
lfcli_base.py : changed from pprint import pprint to import pprint
...
Signed-off-by: Chuck SmileyRekiere <chuck.smileyrekiere@candelatech.com >
2021-09-30 13:25:07 -06:00
Jed Reynolds
f4e45aadeb
set_port.py: corrects updated LFJsonCommand references that have changed
...
Signed-off-by: Jed Reynolds <jed@bitratchet.com >
2021-09-28 09:11:24 -07:00
Jed Reynolds
7bfc9ee7e0
lf_json_autogen.py: significant updates from the jag-2021-09-27 branch
...
- parameter types
- stand-alone request management
- session token
- expanded class hierarchy:
BaseSession <- LFSession,
LFBaseRequest <- JsonQuery <- LFJsonQuery
LFBaseRequest <- JsonCommand <- LFJsonCommand
Signed-off-by: Jed Reynolds <jed@bitratchet.com >
2021-09-28 01:14:15 -07:00
Jed Reynolds
e446aaed39
LFRequest.py: error message prints out called URL
...
Signed-off-by: Jed Reynolds <jed@candelatech.com >
2021-09-28 01:14:15 -07:00
Matthew Stidham
65808d21fa
1. Fix circular import error in LFRequest
...
2. add import re to lfcli_base
3. add debug output to l3_cxprofile, so it is how it used to be
4. add help options to regression_test so we can test how the help flags are working
5. Make test_ip_variable_time work better when it is imported directly by moving most of the logic to a function under IPVariableTime
6. Add init.py file to the LANforge directory and fix archiving in the to_pip.py script
Signed-off-by: Matthew Stidham <stidmatt@gmail.com >
2021-09-23 14:37:53 -07:00
Matthew Stidham
e6cf6b9337
1. Create pandas_extensions.py
...
2. Remove unused imports
Signed-off-by: Matthew Stidham <stidmatt@gmail.com >
2021-09-21 11:11:04 -07:00
Matthew Stidham
36400e003d
Making it so that lanforge-scripts can work if the repository isn't named exactly the same way
...
Signed-off-by: Matthew Stidham <stidmatt@gmail.com >
2021-09-17 15:29:15 -07:00
erinnerim
1d7578251c
Updates to import statements:
...
- Import importlib, os, and sys to each python script.
- Append "lanforge-scripts" root directory to the system path, allowing each script to be called from an antecedent directory. e.g.
if 'lanforge-scripts' not in sys.path:
sys.path.append(os.path.join(os.path.abspath(__file__ + "../../../../../")))
- All statements of the form 'from <module> import <class>' replace with:
<module> = importlib.import_module("lanforge-scripts.<directory>.<module>")
<class> = <module>.<class>
2021-09-15 16:17:16 -07:00
Jed Reynolds
ca63796db5
lf_json_autogen.py: adds column name help for many columns
...
Signed-off-by: Jed Reynolds <jed@candelatech.com >
2021-09-13 15:38:14 -07:00
erinnerim
136cd01fa0
Revert "importlib refactor LFRequest.py"
...
This reverts commit 0642ea475d .
2021-09-10 17:57:08 -07:00
erinnerim
c373891f9d
Revert "importlib refactor LFUtils.py"
...
This reverts commit 343d5f7b31 .
2021-09-10 17:56:55 -07:00
erinnerim
60e9853bb6
Revert "importlib refactor lfcli_base.py"
...
This reverts commit 787edf2d51 .
2021-09-10 17:56:41 -07:00
erinnerim
787edf2d51
importlib refactor lfcli_base.py
2021-09-10 17:09:13 -07:00
erinnerim
343d5f7b31
importlib refactor LFUtils.py
2021-09-10 17:07:20 -07:00
erinnerim
0642ea475d
importlib refactor LFRequest.py
2021-09-10 17:05:58 -07:00
Jed Reynolds
652735990b
lf_json_autogen.py: now has help text for port section
...
Signed-off-by: Jed Reynolds <jed@candelatech.com >
2021-09-10 16:56:31 -07:00
Jed Reynolds
ff6d19fe8f
lf_json_autogen.py: fixes warning about possibly undeclared variable
...
Signed-off-by: Jed Reynolds <jed@candelatech.com >
2021-09-10 16:56:31 -07:00
Jed Reynolds
9f74fec635
lf_json_autogen.py: now has /probe url functionality
...
Signed-off-by: Jed Reynolds <jed@candelatech.com >
2021-09-10 14:36:51 -07:00
Jed Reynolds
9e116bd950
LFRequest.py: adds todo comments
...
Signed-off-by: Jed Reynolds <jed@candelatech.com >
2021-09-09 15:47:46 -07:00
Chuck SmileyRekiere
2efbc62842
Revert "Update py_json files to be compatible with pip standards"
...
This reverts commit 0be47c82de .
2021-09-09 05:32:31 -06:00
Chuck SmileyRekiere
8e9909f2d0
Revert "Revert "Update py_json files to be compatible with pip standards""
...
This reverts commit 6b0322cafa .
2021-09-09 05:28:17 -06:00
Chuck SmileyRekiere
6b0322cafa
Revert "Update py_json files to be compatible with pip standards"
...
This reverts commit 0be47c82de .
2021-09-09 05:24:20 -06:00
Matthew Stidham
0be47c82de
Update py_json files to be compatible with pip standards
...
Signed-off-by: Matthew Stidham <stidmatt@gmail.com >
2021-09-08 16:54:45 -07:00
Jed Reynolds
5ba8a5bfcf
lf_json_autogen: adds help test, WIP
...
Signed-off-by: Jed Reynolds <jed@candelatech.com >
2021-09-07 15:55:48 -07:00
Chuck SmileyRekiere
b6e1f30afb
LFUtiles.py : added back in from LANforge import LFRequest
...
This was needed for the check tests
Signed-off-by: Chuck SmileyRekiere <chuck.smileyrekiere@candelatech.com >
2021-09-06 21:54:28 -06:00
Jed Reynolds
a2e02a6707
LFUtils.py: Improves wait_until_ports_disappear error message; Fixes many linter warnings.
...
Signed-off-by: Jed Reynolds <jed@candelatech.com >
2021-09-06 09:48:52 -07:00