Releases: pcdshub/happi
v3.0.1 (2025-11-24)
No functional changes were made in this release
Maintenance
- Adjusted test suite to work with pytest 9.0.0
Full Changelog: v3.0.0...v3.0.1
v3.0.0 (2025-08-04)
API Breaks
-
Client search methods will now return an
InvalidResultif a container (e.g.
HappiItem) cannot be created. Previously, client search methods would raise a
KeyError from the inciting exception. This KeyError will no longer be raised,
and the inciting exception will be included as a data member in the
InvalidResult object. This means downstream code that iterates over many happi
entries doesn't need special error handling on big searches unless specifically
the specific search item it needs is invalid.-
Similarities (between SearchResult and InvalidResult):
- You can still check metadata with key-based access (if it is present)
- Basic operations such as iteration, length checks still work (and will skip any of the missing data members)
-
Differences:
- There is no expectation that an InvalidResult will have well-formed data, some of it may be well-formed but data types are not guaranteed and some required data may be missing.
- You can't meaningfully compare two InvalidResult objects with equality checks.
InvalidResultobjects can't find the item that generated them via an item property (SearchResultsupports this)InvalidResultobjects don't have a get function and cannot be used to instantiate real devices
-
Bugfixes
- Handle invalid entries gathered in cli search method.
- Filter for SearchResults in
HappiViewMixin.
Maintenance
- Touch up some type hints in the qt model file.
Contributors
v2.6.2 (2025-05-13)
Maintenance
- Fixes a variety of typing mistakes
- Fixes
happi transferto use the publichappi.containers.registryAPI rather than internals - Use
line_profilerin pip dev_requirements instead ofline-profilerto avoid confusion - Splits happi pip package into subpackages (
gui,mongo) for more precise dependency specification.
The default dependency set has can be installed viapip install happi[all], and includes
theguiandmongooptional dependencies. - Update test suite to handle no-arg case in cli for click>=8.2.0
Contributors
- tangkong
- jwlodek
New Contributors
Full Changelog: v2.6.1...v2.6.2
v2.6.1
v2.6.0 (2024-12-19)
Features
- Updated
happi loadto support searching and loading in one user-friendly expression. The load function now gathers the results of each search term individually and loads the union of the results.
Maintenance
- Make running happi repair only saves an item if it actually got changed during the repair process
- Fixes issue in test suite, making tst_base_pim2 a loadable SimpleNamespacce
- Add example .cfg and some more instructions on using happi cli
- Make pre-release notes script default to just using vi if EDITOR env var is not set.
- Fix a few dead links in the docs, add to contributing doc to make 1st time dev instructions bit more clear
Contributors
- janeliu-slac
- nstelter-slac
- tangkong
Full Changelog: v2.5.0...v2.6.0
v2.5.0 (2023-12-19)
v2.4.0 (2023-09-27)
Features
- Added
happi.audit.audit()which can be used to programmatically audit
happi items.
Bugfixes
- Fixes bug where
happi transferwas not filling default values properly - Fixes conftest.trim_split_output, which was effectively a no-op. Touches up affected tests
- Issue 302: Add functionality to happi 'repair' that ensures that the name and id fields of a device are the same.
- Removes an extra pcdsutils import from test_cli.py that is not properly caught by error handling
Maintenance
- Adds error handling for the temporary file created when initializing a json backend object.
- Changes format of temporary file name generation to contain only a unique hash.
- Tests modified to no longer assert stdout matches expected strings. Rather the effect of the
command being tested is verified independently. Theassert_match_expectedhelper is still
used, but will now print mismatches instead of asserting them. - Allows
happi updateto handle json-backend-type payloads - Adds pcdsutils and pcdsdevices to environment requirements in conda recipe and dev requirements
- Removes pcdsutils and pcdsdevices from extra testing requirements in github workflow
- The
happi auditCLI entrypoint has been modified to use
happi.audit.audit(). - Updates mongo backend to handle authSource, require connection information (host, user, etc)
- Documents bson dependency. Bson is vendored by pymongo, which instructs
users to not install bson from pypi (pymongo readme <https://github.com/mongodb/mongo-python-driver/tree/master#installation>)
Contributors
v2.3.0 (2023-06-30)
Features
-
CLI command
happi config edit- open config file in$EDITOR -
CLI command
happi config init- create new config file with default options -
CLI command
happi config show- show location & contents of config file -
Extend the config searching mechanism to check the platformdirs config directory. The happi config file path is taken from the
HAPPI_CFGenvironment variable, but if the variable is not set then the following locations are searched in order for files named.happi.cfgorhappi.cfg:- The location specified by the
XDG_CONFIG_HOMEenvironment variable ~/.config- (new) The location specified by
platformdirs.user_config_dir("happi")
- The location specified by the
Maintenance
- Add dependency on
platformdirshttps://pypi.org/project/platformdirs/ - Update build requirements to use pip-provided extras for documentation and test builds
Contributors
v2.2.0 (2023-05-08)
Features
- Adds a hook in
happi.loader.from_containerthat runs the methodpost_happi_mdon an instantiated object after the metadata container has been attached. This allows a clear method for objects to interact with happi metadata if desired.
Maintenance
- Makes
HappiDeviceTreeViewmore tolerant of items with missing metadata keys. Items missing the key used to group the tree view will be organized into a catch-all "[KEY NOT FOUND]" group.