Python 3 migration with the Splunk platform
On January 1, 2020, Python version 2.x was officially deprecated by the Python Software Foundation. Python packages and tools have ended or are ending support for Python 2, and new Python packages don't support Python 2. To continue to leverage community support and maintain compatibility with the many third-party projects that use Python, Splunk has migrated Splunk Cloud Platform and Splunk Enterprise, supported Premium Solutions, and supported Splunkbase apps and add-ons to be compatible with Python 3.7 and higher. Splunk is prepared and able to provide support for Python 3.7 and higher, including patches for new CVEs identified against Python 3.7 and higher.
Beginning in Splunk Enterprise version 9.3, Splunk supports Python version 3.9 by default. In future versions of Splunk software, Splunk plans to support higher versions of Python. Splunk also plans to deprecate support for Python 3.7, but support for Python 3.7 remains in Splunk Enterprise 9.3. For more information about support for both Python 3.7 and Python 3.9 in Splunk Enterprise 9.3, see Changes to Splunk Enterprise.
This manual helps identify prerequisites, required changes and steps for migrating impacted Splunk products and apps to Python 3.7 and higher. As Splunk makes new tools and advice available, this content will be updated.
All Splunk platform versions 9.0 and higher require at least Python 3.7. In Splunk platform 9.x, Python 2 is no longer an option.
Splunk administrators
Administrators of Splunk Cloud Platform and Splunk Enterprise deployments might need to take steps to prepare for Python 3.7 and higher, as there are prerequisites to these upgrades. See details in Changes to Splunk Enterprise.
Splunk provides the Splunk Platform Upgrade Readiness app for admins to scan deployed apps for any components impacted by migration to Python 3. For more information, see the Splunk Platform Upgrade Readiness App.
Splunk app developers
Splunk app and add-on developers must revise apps and add-ons that use Python 2.7 scripts. Revised Splunkbase apps will need to be resubmitted after validation with version 8.x or 9.x. For details about specific script changes required to support version 8.x or 9.x, see Python Development in Splunk Enterprise. Custom apps for Splunk Cloud Platform will follow the same guidelines as custom apps for Splunk Enterprise, with the added requirement of passing Cloud vetting.
Splunk provides the Splunk Platform Upgrade Readiness app for developers to scan deployed apps for any components impacted by migration to Python 3. For more information, see the Splunk Platform Upgrade Readiness App. Developers should also review all issues covered in this manual and test app and add-on revisions with the Splunk Enterprise version 8.x or 9.x before resubmitting to Splunkbase.
Splunk Cloud Platform customers
Beginning with version 8.0, Splunk Cloud Platform added Python 3 support and updated the out-of-the-box Splunk Cloud Platform capabilities. Regardless of your Splunk Cloud Platform version, any apps or add-ons in your Splunk Cloud Platform instances that are not Python 3 compatible must be upgraded or removed. Splunk Cloud Platform customers should take the following steps:
- Update your private apps to be compatible with Splunk Cloud Platform 8.x and higher, as well as Python 3. You should follow the same process as Splunk app developers to update private apps. However, for Splunk Cloud Platform, you'll update and upload the app as necessary for your Splunk Cloud Platform Experience designation, instead of uploading the app to Splunkbase. See Install private apps on Splunk Cloud Platform.
- Update apps you have installed on your Splunk Cloud Platform deployment from Splunkbase to versions that are compatible with both your current version of Splunk Cloud Platform and Splunk Cloud Platform 8.x and higher. Decide whether to update remaining incompatible apps or to find another solution. Use the Splunk Cloud Monitoring Console, to identify which apps on your Splunk Cloud Platform deployment must be updated.
This Python 3 compatibility requirement applies to all public and private apps in your Splunk Cloud Platform environment. Splunk will continue to work closely with third-party Splunkbase developers to provide updated Python 3-compatible versions of their published apps. You must install the new versions of those Splunkbase apps and upgrade all private apps to ensure Python 3 compatibility.
For more information, see Splunk Cloud Platform.
Splunk solutions customers
Customers of some Splunk solutions must update ML models to support Python 3, as specified in Splunk IT Service Intelligence and Splunk Machine Learning Toolkit.
This information is subject to change at any time, at the sole discretion of Splunk Inc. and without notice. This roadmap information shall not be incorporated into any contract or other commitment. Splunk undertakes no obligation to either develop or deliver any product, features, or functionality described here.
Changes to Splunk Enterprise with Python 3 |
This documentation applies to the following versions of Splunk® Enterprise: 9.1.6, 9.1.7, 9.3.0, 9.3.1, 9.3.2, 9.4.0
Feedback submitted, thanks!