fix(publish): keep the order of existing include_entities #4
Loading…
Reference in a new issue
No description provided.
Delete branch "fix/keep-include-entities-order"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Description
Fixes the publish preview showing entries as removed and added again when only their position in
include_entitieschanged. Entries that are already in the file keep their position, switched-off entries drop out and new ones are appended at the end. The preview no longer shows moved entries as removed and added.Before, the list was rebuilt in the order of the UI (the Home Assistant entity order) instead of the order in the file. In a real
alexa.yaml, this madebutton.011030425365001108_start_pauseappear as removed in one place and added in another, although it stayed in the file.Type of Change
Changes Made
planAlexaUpdateinha-config.util.tsnow keeps the existing order ofinclude_entities: entries that are still wanted stay in place, switched-off entries drop out, new entries are appended in the order of the UIentity_confighandling are unchangedRelated Issues
Closes #
Testing
The new test sends the entities in a different order than the file and checks that the file order is kept and the new entry comes last. Checked manually with a real
alexa.yaml: the preview shows only the four new entries instead of the moved one.Checklist
Screenshots (if applicable)
Additional Notes
After the merge, tag
v1.0.33onmain.