Skip to content

[cli] detect composite block classes in custom_blocks - #15001

Open
yiyixuxu wants to merge 1 commit into
mainfrom
fix-custom-blocks-composite-detection
Open

yiyixuxu wants to merge 1 commit into
mainfrom
fix-custom-blocks-composite-detection

Conversation

@yiyixuxu

@yiyixuxu yiyixuxu commented Oct 9, 2026

Copy link
Copy Markdown
Collaborator

cc @DN6

my agent ran into this issue:

diffusers-cli custom_blocks finds packageable classes by parsing the file with ast and looking at the literal names in each class's bases. so it's not able to detect any subclass of ModularPipelineBlocks, e.g. SequentialPipelineBlocks, AutoPipelineBlocks ... these are actually more common to be published

`diffusers-cli custom_blocks` only recognized classes whose base was spelled
exactly `ModularPipelineBlocks`, so a `SequentialPipelineBlocks` or
`AutoPipelineBlocks` subclass (the usual thing to publish) was reported as
"could not be retrieved". Accept the composite subclasses as well, and match
on the class name so dotted bases like
`diffusers.modular_pipelines.SequentialPipelineBlocks` work too.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
@yiyixuxu
yiyixuxu requested a review from DN6 October 9, 2026 19:49
@github-actions github-actions Bot added documentation Improvements or additions to documentation tests utils size/M PR with diff < 200 LOC labels Oct 9, 2026
@HuggingFaceDocBuilderDev

Copy link
Copy Markdown

The docs for this PR live here. All of your documentation changes will be reflected on that endpoint. The docs are available until 30 days after the last update.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Improvements or additions to documentation size/M PR with diff < 200 LOC tests utils

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants