Skip to content

Add location attributes field to backup model #45

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jan 28, 2025

Conversation

agners
Copy link
Collaborator

@agners agners commented Jan 28, 2025

Proposed Changes

The new location attributes field exposes attributes which can be different per location. This is mainly to enable encrypted/unencrypted backups per location, but we also expose size as an encrypted backup can be slightly different (a couple of bytes larger) in size.

As per home-assistant/supervisor#5581

@agners agners added the new-feature New features or options. label Jan 28, 2025
The new location attributes field exposes attributes which can be
different per location. This is mainly to enable encrypted/unencrypted
backups per location, but we also expose size as an encrypted backup
can be slightly different (a couple of bytes larger) in size.
@agners agners force-pushed the add-location-attributes branch from 90a094f to ea986b3 Compare January 28, 2025 11:11
Copy link
Contributor

@emontnemery emontnemery left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

protected: bool
size_bytes: int


@dataclass(frozen=True)
class BackupBaseFields(ABC):
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In a follow-up PR, I think we should remove the deprecated fields from this and other backup related types.
We can't easily change the supervisor HTTP API, but we don't need to include the extra data here.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Right, we can remove it in the client library.

@agners agners merged commit 69ed57e into main Jan 28, 2025
7 checks passed
@agners agners deleted the add-location-attributes branch January 28, 2025 12:56
@github-actions github-actions bot locked and limited conversation to collaborators Jan 30, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
new-feature New features or options.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy