-
Notifications
You must be signed in to change notification settings - Fork 8
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Bug]: Ciscoconfparse2 doesn't support python pickle #12
Comments
seems like there might be more than i've detailed - when attempting to load a pickled object i hit a i didn't have this problem in ciscoconfparse 1.0 - i'm unsure what specifically changed but will try to look further into it |
looks like it's only an issue when i'm in debugging mode in my IDE and i have a breakout that contains a ciscoconfparse object, likewise if i print it, it also throws an exception but if i don't have breakpoints and just let the code run, no issues - very weird, this is most likely beyond me |
One problem is that @attrs.define(repr=False)
class CiscoConfParse(object):
"""Parse Cisco IOS configurations and answer queries about the configs."""
config: Optional[Union[str,List[str]]] = None There are a number of things that have to be fixed for |
That's fair enough - feel free to close this issue or just keep it open for tracking so others don't re-raise 😄 |
Thank you for your patience. Please test version 0.7.77 and advise whether the issue is fixed. |
thanks for the update, i will test when i get a chance |
Contact Details
No response
What happened?
CiscoConfParse
objects don't support python'spickle
module - this is a very handy module when you're working with 1000s of configs (it takes a long time to call CiscoConfParse() on this many objects)I've had a look at the source code - it looks ike it's trying to save CiscoConfParse.config but it wasn't set during the
__init__
- it looks like you can fix this by just specifyingduring the
__init__
hereit seems like CiscoConfParse.config should be set somewhere? it's entirely unused in this module it seems, perhaps a remnant of CiscoConfParse 1.0?
CiscoConfParse Version
0.7.74
What Operating System are you using?
MacOS
What Python version(s) have this problem?
Python 3.10
Show us how to reproduce the problem. Please tell us if the problem is specific to certain inputs or situations.
Python tracebacks
Relevant log output
No response
Code of Conduct
The text was updated successfully, but these errors were encountered: