Skip to content

Restore mixed deserialization of dicts #13696

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 16 commits into from
Feb 15, 2024

Conversation

mattpap
Copy link
Contributor

@mattpap mattpap commented Feb 14, 2024

This PR restores deserialization of Python dict as either a plain object for string keys or a Map for other kinds of keys. This allows to maintain compatibility, especially for panel and other extensions. All other changes introduced in PR #13618 were kept, allowing for seamless operation on plain objects (as pseudo dicts) and Map at the same time.

This PR also adds settings.serialize_include_defaults for testing/debugging, which is used in this PR in new cross integration tests for issue #13637.

fixes #13637
addresses #13055

Copy link

codecov bot commented Feb 14, 2024

Codecov Report

Attention: 1 lines in your changes are missing coverage. Please review.

Comparison is base (b627a15) 92.59% compared to head (bb0a79c) 92.59%.

Additional details and impacted files
@@             Coverage Diff             @@
##           branch-3.4   #13696   +/-   ##
===========================================
  Coverage       92.59%   92.59%           
===========================================
  Files             323      323           
  Lines           20575    20590   +15     
===========================================
+ Hits            19051    19066   +15     
  Misses           1524     1524           

@mattpap mattpap force-pushed the mattpap/13637_restore_map_deserialization branch from cda38f4 to bb0a79c Compare February 15, 2024 10:50
@mattpap mattpap merged commit b46bf47 into branch-3.4 Feb 15, 2024
@mattpap mattpap deleted the mattpap/13637_restore_map_deserialization branch February 15, 2024 11:54
Chiemezuo pushed a commit to Chiemezuo/bokeh that referenced this pull request Aug 27, 2024
* Rename kinds.{Map->Mapping} to avoid confusion

* Rename kinds to avoid confusion with builtins

* Introduce a common type for major_label_overrides

* Deserialize {type: "map"} as a Map or PlainObject

* Remove special handling from TapToolView

* Update bokehjs' unit tests

* Don't propagate PlainObjectProxy to properties

* Unify border_radius types between bokeh and bokehjs

* Add a cross integration test for issue bokeh#13637

* Better handling of number | string -> V mapping

* Add rudimentary struct support and finish testing

* Rename other colliding kinds and add tests

* Fix type of Selection.multiline_indices in Python

* Allow to {} in Mapping from deserialization

* Allow to configure serialization of defaults

* Add cross integration tests for empty Map case
Copy link

This pull request has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Oct 25, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[BUG] Regression handling glyph border_radius that is a dict
2 participants