Skip to content

Conversation

lsytj0413
Copy link
Contributor

Ref: #3036

Before this pr:

error: cannot find attribute `serde` in this scope
  --> crates/wal-protocol/src/lib.rs:88:11
   |
88 |         #[serde(default)]
   |           ^^^^^
   |
   = note: `serde` is in scope, but it is a crate, not an attribute

@lsytj0413 lsytj0413 force-pushed the fix-wal-protocol-compile-with-options-schema branch from 09417f4 to d7144eb Compare April 1, 2025 10:48
@tillrohrmann tillrohrmann self-requested a review April 10, 2025 13:24
Copy link
Contributor

@tillrohrmann tillrohrmann left a comment

Choose a reason for hiding this comment

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

Thanks for tackling this problem @lsytj0413. I think we can clean up a bit to get rid of the options_schema.

@@ -10,7 +10,7 @@ publish = false
[features]
default = ["serde"]
serde = ["dep:serde", "enum-map/serde", "bytestring/serde", "restate-invoker-api/serde"]
options_schema = ["dep:schemars"]
Copy link
Contributor

Choose a reason for hiding this comment

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

I think that we might actually be able to remove this feature.

Copy link
Contributor

Choose a reason for hiding this comment

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

Additionally, we should change

#[serde(default)]
to #[cfg_attr(feature = "serde", serde(default))].

Copy link
Contributor Author

Choose a reason for hiding this comment

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

fixed, PTAL

@lsytj0413 lsytj0413 force-pushed the fix-wal-protocol-compile-with-options-schema branch from d7144eb to f4d8cf4 Compare April 11, 2025 01:24
@lsytj0413 lsytj0413 force-pushed the fix-wal-protocol-compile-with-options-schema branch from f4d8cf4 to 2eac717 Compare April 11, 2025 01:35
Copy link
Contributor

@tillrohrmann tillrohrmann left a comment

Choose a reason for hiding this comment

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

Thanks a lot for the clean up @lsytj0413. LGTM. Merging it now :-)

@tillrohrmann tillrohrmann merged commit 1b27233 into restatedev:main Apr 11, 2025
25 checks passed
@github-actions github-actions bot locked and limited conversation to collaborators Apr 11, 2025
@lsytj0413 lsytj0413 deleted the fix-wal-protocol-compile-with-options-schema branch April 11, 2025 08:00
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants