Add utility functions for working with nested dictionary keys.

Review Request #13993 — Created June 23, 2024 and submitted — Latest diff uploaded

Information

Djblets
release-5.x

Reviewers

A pattern that crops up from time to time is the need to work with
nested dictionary keys, setting or retrieving something deep in a
dictionary while handling type conflicts and avoiding unwanted
alteration of data.

This introduces two dict_get_path_value() and dict_set_path_value()
for working with this pattern. These standard methods can be used to
more easily work with path-based key management in dictionaries.

Unit tests pass.

Commits

Files