Skip to content
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

Add CoreProfile to database #5170

Merged
merged 1 commit into from
Dec 10, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 0 additions & 5 deletions backend/infrahub/core/schema/manager.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,6 @@
from typing import TYPE_CHECKING, Any, Optional, Union

from infrahub import lock
from infrahub.core.constants import (
InfrahubKind,
)
from infrahub.core.manager import NodeManager
from infrahub.core.models import (
HashableModelDiff,
Expand Down Expand Up @@ -234,8 +231,6 @@ async def load_schema_to_db(
branch = await registry.get_branch(branch=branch, db=db)

for item_kind in schema.node_names + schema.generic_names:
if item_kind == InfrahubKind.PROFILE:
continue
if limit and item_kind not in limit:
continue
item = schema.get(name=item_kind, duplicate=False)
Expand Down
1 change: 1 addition & 0 deletions changelog/+f91354a0.fixed.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Store CoreProfile in database to ensure consistent initial schema hash. Prior to this the schema was reported as being out of sync when starting the application for the first time. This error wouldn't have hade any impact but was confusing. The workaround would be to load a schema or restart the application at least once after first time initialization.
Loading