Skip to content

fix(examples): Instantiate Session before reading account/region in optimize-example#6038

Open
Hannah14295 wants to merge 3 commits into
aws:masterfrom
Hannah14295:fix/optimize-example-session
Open

fix(examples): Instantiate Session before reading account/region in optimize-example#6038
Hannah14295 wants to merge 3 commits into
aws:masterfrom
Hannah14295:fix/optimize-example-session

Conversation

@Hannah14295

Copy link
Copy Markdown

optimize-example.ipynb called Session.account_id() and Session.boto_region_name on the Session class, raising 'TypeError: account_id() missing 1 required positional argument: self'. Create a Session instance first and read the values from it.

Issue #, if available:
N/A

Description of changes:
optimize-example.ipynb called Session.account_id() and Session.boto_region_name
on the Session class instead of an instance, so the first Configuration cell
failed with:

TypeError: account_id() missing 1 required positional argument: 'self'

This creates a Session() instance first and reads account_id() / boto_region_name
from it. No functional change beyond fixing the crash.

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

hrehard and others added 2 commits July 16, 2026 14:07
optimize-example.ipynb called Session.account_id() and Session.boto_region_name on the Session class, raising 'TypeError: account_id() missing 1 required positional argument: self'. Create a Session instance first and read the values from it.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant