department-of-veterans-affairs / notification-api

Notification API
MIT License
15 stars 9 forks source link

Upgrade AWS Lambda Python Version to 3.10 - API #1839

Closed EvanParish closed 5 days ago

EvanParish commented 3 weeks ago

User Story - Business Need

Upgrade the Python runtime version for AWS Lambda functions from 3.8 to 3.10 before the end of support in October 2024.

User Story(ies)

As a backend engineer I want to upgrade the Python runtime version for our AWS Lambda functions to 3.10 So that we can take advantage of the latest features, improvements, and security patches in Python 3.10

Additional Info and Resources

The current AWS Lambda functions are using Python 3.8, as specified in our GitHub Actions workflow. Python 3.10 offers several new features and optimizations that could benefit our Lambdas.

Acceptance Criteria

See the comments for explanations of the strikes.

QA Considerations

Potential Dependencies

The API, Kafka and Infra tickets likely all need to be worked at the same time. (see Dependencies below)

mjones-oddball commented 3 weeks ago

Hey team! Please add your planning poker estimate with Zenhub @cris-oddball @EvanParish @k-macmillan @kalbfled @MackHalliday @mchlwellman

kalbfled commented 5 days ago

This ticket doesn't make sense to me. Updating the Python version in the workflow step that uses the setup-python action has no effect on the Python version the lambdas actually execute, which is controlled in infra.

I think having the Python version in the workflow is a legacy of when we had the workflow bundle Python dependencies with the lambda code, but now we use layers. Achieving the intent of this ticket should involve updating the infrastructure, removing the Python action from the workflow, updating the layers, and testing.

kalbfled commented 5 days ago

I discussed this with @EvanParish. He is working on infra 842, which handles the necessary infrastructure changes. I am going to remove the set-python action for this ticket, and we will test the lambdas still function before closing it.

kalbfled commented 5 days ago

I removed the QA label after discussing it with QA.