Skip to content

AssetModel latest only feature is incomplete

Summary

The "latest only" property implement of AssetModel is currently incomplete and does not work for all asset types.

Steps to reproduce

model = AssetModel()
model.prefix_path = "path/to/prefix"
model.asset_type = "AssetType.DATAFORMAT"
asset_list = model.stringList()
model.setLatestOnlyEnabled(False)
full_asset_list = model.stringList()
assert asset_list != full_asset_list
assert len(asset_list) < len(full_asset_list)

What is the current bug behavior?

The same list of assets is returned for types that are neither database nor protocol templates.

What is the expected correct behavior?

The two lists should be different if the prefix contains several versions of these assets

Possible fixes

Implement the same "un-filtering" for all assets where it make sense.

The fix will require beat.core!76 (merged)

Edited by Samuel GAIST
To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information