TPT-4324: Allow dict passthrough for config_create 'devices' field; update repo to reflect 3.9 EOL#673
Conversation
04d5132 to
d89e53c
Compare
There was a problem hiding this comment.
Pull request overview
Adds backwards-compatible support for passing a raw device mapping dict into Instance.config_create(..., devices=...), enabling explicit sdX key selection during config creation (needed for ansible_linode workflows around expanded volume limits).
Changes:
- Update
Instance.config_createto accept a raw device-map dict and to normalize/serialize device inputs more flexibly. - Add a unit test to ensure device-map dicts are passed through unchanged.
- Add an integration test validating config creation using an explicit device-map key.
Reviewed changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated 3 comments.
| File | Description |
|---|---|
linode_api4/objects/linode.py |
Extends config_create input handling/typing to support device-map dict passthrough; also adjusts clone defaults/normalization. |
test/unit/objects/linode_test.py |
Adds unit coverage asserting raw device-map dict passthrough in config_create. |
test/integration/models/volume/test_blockstorage.py |
Adds integration coverage for creating a config using an explicit device-map key. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| @@ -25,10 +25,11 @@ classifiers = [ | |||
| "License :: OSI Approved :: BSD License", | |||
| "Programming Language :: Python", | |||
| "Programming Language :: Python :: 3", | |||
| "Programming Language :: Python :: 3.9", | |||
| "Programming Language :: Python :: 3.10", | |||
| "Programming Language :: Python :: 3.11", | |||
| "Programming Language :: Python :: 3.12", | |||
| "Programming Language :: Python :: 3.13", | |||
| "Programming Language :: Python :: 3.14", | |||
| ] | |||
| dependencies = ["requests", "polling", "deprecated"] | |||
There was a problem hiding this comment.
Per our support policy, we stop supporting Python versions as soon as they EOL.
I can split this out into a separate PR if needed. Just wanted to use the fancy new type hint syntax.
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 7 out of 7 changed files in this pull request and generated 3 comments.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
11bf63a to
c62fefb
Compare
c62fefb to
b406990
Compare
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 8 out of 8 changed files in this pull request and generated 1 comment.
Comments suppressed due to low confidence (1)
pyproject.toml:15
- This PR also raises the minimum supported Python version to 3.10 and updates the supported-version classifiers. That’s a user-facing breaking change but isn’t mentioned in the PR description; please confirm it’s intended and update the PR description/release notes accordingly (or split this into a separate PR if unrelated).
readme = "README.rst"
requires-python = ">=3.10"
keywords = [
"akamai",
"Akamai Connected Cloud",
"linode",
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 8 out of 8 changed files in this pull request and generated 3 comments.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 8 out of 8 changed files in this pull request and generated 2 comments.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
ad0b65c to
4a678b3
Compare
📝 Description
Adds backwards-compatible support for passing a raw device mapping dict to the devices parameter of
Instance.config_create(...), allowing callers to explicitly specify thesdXkey for a device during config creation.This resolves an issue in ansible_linode that is currently blocking the release of Block Storage Volume Limits Increase.
✔️ How to Test
Unit Testing
Integration Testing