Hello! New to the forum and to Stackstorm, so please forgive any faux pas. I appreciate any guidance about etiquette and rules, as appropriate.
I’m using the ServiceNow pack from Stackstorm Exchange with version 3.2.0 of Stackstorm and whenever I run most any action, the PySnow library that it’s based on returns a deprecation warning:
"stderr": "/opt/stackstorm/virtualenvs/servicenow/lib/python2.7/site-packages/pysnow/client.py:120: DeprecationWarning: `query` is deprecated and will be removed in a future release. Please use `resource()` instead.
\"Please use `resource()` instead.\" % inspect.stack()[1][3], DeprecationWarning)
/opt/stackstorm/virtualenvs/servicenow/lib/python2.7/site-packages/pysnow/legacy_request.py:99: DeprecationWarning: get_all() is deprecated, please use get_multiple() instead
warnings.warn(\"get_all() is deprecated, please use get_multiple() instead\", DeprecationWarning)
",
"exit_code": 0
I was considering forking the pack and adding a configuration parameter for the /api/now/
“version” for the ServiceNow API and then updating the pack action Python methods to call the “newer”
methods based on the configuration parameter (i.e., “strategy” pattern). Would that be the appropriate
approach? (Of course, I would submit a pull request for the updated code to share with community. I just
wasn’t sure of philosophy.)
Thanks!
Tim Jones