Splunk Dev

saved_search.py both python 2 and 3?

davop
New Member

try:
import utils
....

opts = utils.parse(argv, RULES, ".splunkrc", usage=usage)

I am confused as both python3 and python2 does not seem to have an utils module with a parse method? Could someone explain?

Labels (1)
0 Karma

richgalloway
SplunkTrust
SplunkTrust

Please put this question in context. What are you trying to do? Where did you get this code?

---
If this reply helps you, Karma would be appreciated.
0 Karma

davop
New Member

I was just attempting to run the example code from the sdk for python. One of the files called saved_search.py. I tried running it with both python 3 and/or python 2 but both times in the code saved_search.py it says there is no methods in utils....

0 Karma
Get Updates on the Splunk Community!

Extending Observability Content to Splunk Cloud

Watch Now!   In this Extending Observability Content to Splunk Cloud Tech Talk, you'll see how to leverage ...

More Control Over Your Monitoring Costs with Archived Metrics!

What if there was a way you could keep all the metrics data you need while saving on storage costs?This is now ...

New in Observability Cloud - Explicit Bucket Histograms

Splunk introduces native support for histograms as a metric data type within Observability Cloud with Explicit ...