Skip to content

Do not skip dataclass fields starting with _ #52

Closed
@junrushao-openai

Description

@junrushao-openai

Currently MLC skips a dataclass field if its name starts with an underscore:

if field_name.startswith("_"):
continue

This could be a pretty surprising footgun given downstream applications may use the underscore _ convention quite a lot.

There's no fundamental reason MLC has to skip _ fields AFAICT, so could you please reconsider this convention? If MLC really wants to support skipped fields, how about naming them as _mlc_* instead?

Metadata

Metadata

Assignees

Labels

Type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions