Skip to content
This repository was archived by the owner on Dec 24, 2024. It is now read-only.
This repository was archived by the owner on Dec 24, 2024. It is now read-only.

InProcessParamStore does not parse dot-notation keys #209

@urig

Description

@urig

The ParamStore API currently supports both specifying keys as dictionary keys:

param_store['key'] = value

and as attributes:

param_store.key = value

However, this key/attribute equivalence does not extended to parsing dot notation into full blown nested dictionary hierarchy. More formally:

Steps to reproduce:

param_store= InProcessParamStore()
param_store["qubit1.flux_capacitor.freq"] = 8.0

Expected result:

param_store.qubit1.flux_capacitor.freq == 8.0 # should be True

Actual result:

AttributeError is raised complaining about qubit1 not being an attribute.

We should consider augmenting the InProcessParamStore implementation so that it fulfills the above expectation.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions