Skip to content

fix: Enum and Fixed would put default in custom_attributes - #460

Merged
Kriskras99 merged 3 commits into
mainfrom
feat/default_in_custom_attributes
Feb 16, 2026
Merged

Kriskras99 merged 3 commits into
mainfrom
feat/default_in_custom_attributes

Conversation

@Kriskras99

Copy link
Copy Markdown
Contributor

No description provided.

@Kriskras99
Kriskras99 force-pushed the feat/default_in_custom_attributes branch 2 times, most recently from 1878dc4 to d7c1d43 Compare February 11, 2026 14:15

@martin-g martin-g left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Comment thread avro/src/schema/mod.rs Resolved
Comment thread avro/src/schema/mod.rs Resolved
@Kriskras99

Copy link
Copy Markdown
Contributor Author

FixedSchema does have the default field, so I think we should either remove it or properly support it.

@martin-g

martin-g commented Feb 11, 2026 •

Copy link
Copy Markdown
Member

/// An optional default symbol used for compatibility
- looks like a copy/paste from EnumSchema (
/// An optional default symbol used for compatibility
).

I'd vote to deprecate and remove it.

@Kriskras99

Copy link
Copy Markdown
Contributor Author

I've removed the default field. Deprecating it means users will have to silence the deprecation lint everywhere they construct a Fixed, as there is no way to construct it without the field.

Comment thread avro/src/schema/mod.rs Resolved
@martin-g

Copy link
Copy Markdown
Member

You can ignore the Perl/interop related failure and merge this PR!

@Kriskras99

Copy link
Copy Markdown
Contributor Author

I'll do map and array in a follow up!

Co-authored-by: Martin Grigorov <[email protected]>
@Kriskras99
Kriskras99 merged commit af56163 into main Feb 16, 2026
21 checks passed
@Kriskras99
Kriskras99 deleted the feat/default_in_custom_attributes branch February 16, 2026 13:52
@martin-g martin-g added this to the 0.22.0 milestone Feb 18, 2026
@Kriskras99 Kriskras99 mentioned this pull request Jun 28, 2026
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