Skip to content

fix(backend): resolve dotted backend object paths - #319

Merged
gaborbernat merged 2 commits into
tox-dev:mainfrom
gaborbernat:fix/dotted-backend-objects
Oct 15, 2026
Merged

gaborbernat merged 2 commits into
tox-dev:mainfrom
gaborbernat:fix/dotted-backend-objects

Conversation

@gaborbernat

Copy link
Copy Markdown
Member

Supersedes #318, keeping @repzakske's commit and adding readable ids to the test cases. #318 doesn't allow maintainer edits, so the follow-up commit couldn't go to that branch.

PEP 517 allows dotted object paths such as build-backend = "build.api:holder.backend". The backend called getattr once with the whole path, so startup failed with AttributeError: module 'build.api' has no attribute 'holder.backend'. It now resolves one attribute at a time.

test_backend_obj covers a plain attribute, a trailing colon, and one and two levels of nesting. Both nested cases fail without the fix.

@gaborbernat
gaborbernat enabled auto-merge (squash) October 15, 2026 21:54
@gaborbernat
gaborbernat merged commit a8953a4 into tox-dev:main Oct 15, 2026
26 checks passed
@gaborbernat
gaborbernat deleted the fix/dotted-backend-objects branch October 15, 2026 21:58
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.

2 participants