How to upgrade a Python 2 Environment and create a ‘migration to Python 3’ target
As open source supply chain attacks increase, the risk of running Python 2 code is quickly becoming unmanageable. Learn more about ActiveState’s extended support for Python 2 here
Simply follow the video step by step. Here’s the link to the Python 2 GitHub project we use in this demo. We show you how to create a new Python environment, import your requirements from your existing Python 2 project and then find and fix CVEs. Within a few minutes, the Platform resolves dependencies for you and you go from a vulnerable Python 2 environment to a command line snippet that can be used to migrate your environment to Python 3.
You see how Python developers can use the ActiveState Platform to remediate vulnerable Python runtime environments, version 2 or 3, by selecting non-vulnerable package versions, and automatically rebuilding their environments.
Keeping in mind the increase in supply chain attacks however, it is not enough to simply maintain or migrate your Python 2 production environments. it is also critical to consider maintaining the Python 2 code involved in your build process, as well as how it may be used/running in your development and test environments.
An ActiveState extended support subscription helps you better manage your risks and secure your Python supply chain from end to end. You get Python 2 Support for Windows, Linux, macOS, AIX, Solaris and legacy operating systems. We provide patches, security updates and new versions of Python 2 third-party packages. If you decide to migrate your old applications to Python 3, we can make the process easier.
Ready to give it a try? Building with Python 2.7.18 is available on the Platform for all users. If you have a free ActiveState Platform account, you can create your own Python project and use it to scan your Python 2 codebase using your project’s requirements.txt file.
If you have an enterprise user account, you can do what we have demonstrated in this video.
Essentially if you have any Python 2 apps, we can help you move them to the latest version of Python 2.7. We will maintain them and update to ensure you can run your Python 2 apps securely. If you’re looking to migrate to Python 3, we can also help with creating a target environment that is compatible with your existing configuration to help simplify your migration efforts.
Read more about the Python 2 migration conundrum here.
Watch Next: How to Install a Runtime Environment
At ActiveState, we use the Platform to build not only our popular open source language distributions, but also custom runtimes for our enterprise clients (i.e. builds containing just the language and packages their project requires). Try it out yourself or get a personalized demo and understand how it can support your enterprise’s open source needs.
Use our Platform to build a custom environment for your next project, including just the language and packages your project needs.
- Choose a language (Python, Perl or Tcl right now)
- Select your operating system (Linux or Windows, plus Mac for Python)
- Add the packages your project requires
ActiveState regularly pulls packages from each language’s standard open source repository (CPAN, PyPI, etc) to ensure that your open source language and components are up to date, can be compiled from source, and are then verified to work together in a distribution that is packaged for most major operating systems. Go ahead and try our beta today! We are hanging out at our Community Forum to provide support as you explore.