Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix fj serialization #682

Merged
merged 2 commits into from
Jun 12, 2022
Merged

Conversation

kamirr
Copy link
Contributor

@kamirr kamirr commented Jun 11, 2022

Fixes #681.

Two things I'm unsure about:

  1. just build doesn't run the tests I've added to fj, despite them running fine via cargo test. Am I missing something?
  2. Should I commit changes to Cargo.lock?

@kamirr kamirr requested a review from hannobraun as a code owner June 11, 2022 15:27
kamirr added 2 commits June 11, 2022 17:28
This required 3 changes:
1. Import serde::{Serialize, Deserialize}.
2. Implement {Serialize, Deserialize} for Sketch.
3. Enable the "derive" feature for serde.
@kamirr kamirr force-pushed the fix_fj_serialization branch from 21f87a1 to 50238b3 Compare June 11, 2022 15:30
Copy link
Owner

@hannobraun hannobraun left a comment

Choose a reason for hiding this comment

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

Thank you for this pull request, @kamirr!

I totally missed that the feature wasn't enabled in the CI build when merging this. This shouldn't have slipped through.

just build doesn't run the tests I've added to fj, despite them running fine via cargo test. Am I missing something?

It looks like the fj crate is missing from default-members in the top-level Cargo.lock file. I'd say that is the reason.

Should I commit changes to Cargo.lock?

Yes, definitely! I've recently added a section on this to CONTRIBUTING.md.


I've left one comment, but that's just a minor nitpick. Feel free to address that in a follow-up PR, if you're up for it, or don't, if you're not 😄

I've opened the following issues in response to the shortcomings that your work here uncovered:

Comment on lines +21 to +22
[dev-dependencies]
serde_json = "1.0.81"
Copy link
Owner

Choose a reason for hiding this comment

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

Minor nitpick: I think it would be a bit more clear to move this to the end of the file. Otherwise we have dependencies inter-mixed with dev-dependencies.

@hannobraun hannobraun merged commit 07405b6 into hannobraun:main Jun 12, 2022
@kamirr kamirr deleted the fix_fj_serialization branch June 12, 2022 07:54
hannobraun added a commit that referenced this pull request Jun 13, 2022
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.

fj doesn't build with the serialization feature
2 participants