Skip to content

Reverting back to JSON serialization #587

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

Merged
merged 4 commits into from
May 1, 2025
Merged

Conversation

jatinchowdhury18
Copy link
Contributor

No description provided.

@jatinchowdhury18 jatinchowdhury18 requested a review from Copilot May 1, 2025 03:24
Copy link

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR reverts the serialization mechanism back to JSON by removing binary serialization support from tests and backend modules. The key changes include updating test case tags to include "[serial]", removing binary serialization/deserialization functions, and modifying PluginStateImpl to use JSON serialization exclusively.

Reviewed Changes

Copilot reviewed 12 out of 12 changed files in this pull request and generated no comments.

Show a summary per file
File Description
tests/plugin_tests/chowdsp_plugin_state_test/*.cpp Updated test tags and removed binary serialization tests
modules/plugin/chowdsp_presets_v2/Backend/chowdsp_PresetState.{h,cpp} Removed binary serialization methods
modules/plugin/chowdsp_plugin_state/Backend/chowdsp_StateValue.h Removed binary serialization methods from StateValue
modules/plugin/chowdsp_plugin_state/Backend/chowdsp_PluginStateImpl.cpp Replaced binary branch with JSON serialization in state (de)serialization
modules/plugin/chowdsp_plugin_state/Backend/chowdsp_ParamHolder.{h,cpp} Removed binary serialization functions
modules/plugin/chowdsp_plugin_state/Backend/chowdsp_NonParamState.{h,cpp} Removed binary serialization functions
Comments suppressed due to low confidence (1)

modules/plugin/chowdsp_plugin_state/Backend/chowdsp_PluginStateImpl.cpp:25

  • Since binary serialization is fully removed, consider simplifying the deserialization lambda by removing the conditional check for JSON format detection, and directly calling JSONUtils::fromMemoryBlock to streamline the code.
JSONUtils::toMemoryBlock (serialize (*this), data);

Copy link

codecov bot commented May 1, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 95.13%. Comparing base (c0c292c) to head (bb251ac).

Additional details and impacted files
@@            Coverage Diff             @@
##             next     #587      +/-   ##
==========================================
+ Coverage   95.11%   95.13%   +0.02%     
==========================================
  Files         319      319              
  Lines       12414    12197     -217     
  Branches     1150     1130      -20     
==========================================
- Hits        11807    11604     -203     
+ Misses        606      592      -14     
  Partials        1        1              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@jatinchowdhury18 jatinchowdhury18 merged commit 8bcb369 into next May 1, 2025
@jatinchowdhury18 jatinchowdhury18 deleted the return-to-json-serial branch May 1, 2025 04:12
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.

1 participant