Closed SteveMcGrath closed 4 years ago
some more significant rework being done for a v2.
@SteveMcGrath super sorry to bother, but i thought there was a v2
branch in the repo but can't find it. is there anything publically available yet?
great work on this by the way, it's been a great lib to work with (plus the availability of the cassettes have allowed to move functionality over to some other languages easily as well!)
The initial v2 work that was being done was already merged in as part of 1.2. If you look at the Tenable.ot object you can get a good glimpse of the pathway forward. The main changes revolve around moving a lot of the underlying connection code to the RESTfly library and instead focusing here on more manageable method declarations. Another focus is to move away from the constructor private methods and instead leverage tooling like Marshmallow for validation of the inputs and transformation of the information into what the APIs expect. This method makes the code significantly more testable.
As you mentioned testing, the usage of VCRpy was an early win to try to get testing simple and repeatable, however the current cassettes are highly inefficient and managing them is a massive pain. For OT I experimented with using responses instead and am open to input:
https://github.com/tenable/pyTenable/blob/master/tests/ot/test_assets.py
@SteveMcGrath thanks for being so responsive. I'm going to move this out into a different thread under a properly named issue to continue the discussion
👋 has this been decided to be not implemented?