Skip to content

[FR] ensure restore of backups only works in correct enviroments #11214

Description

@matmair

Please verify that this feature request has NOT been suggested before.

  • I checked and didn't find a similar feature request

Problem statement

User might restore backups in too old environments. This can cause unreliability and data loss

Suggested solution

Use Archmonger/django-dbbackup#663 once it is merged and released to enrich backup metadata with data around api and software version as well as plugin state

Describe alternatives you've considered

Write docs

Examples of other systems

No response

Do you want to develop this?

  • I want to develop this.

Activity

  1. added
    enhancement
    triage:not-checked
    setup
    and removed
    triage:not-checked
    on Jan 27, 2026
  2. self-assigned this
    on Jan 27, 2026
  3. modified the milestones: horizon, 2.0.0 on Jan 27, 2026
  4. SchrodingersGat commented on Jan 29, 2026

    @SchrodingersGat
    Member

    Is there scope here for performing backup / restore of plugin tables? This is a current blocker for extracting data from setups with custom DB tables

  5. matmair commented on Jan 30, 2026

    @matmair
    MemberAuthor

    @SchrodingersGat not really with this mechanism but we can certainly look into it.

    Have you ever checked if the plugin model data is included in backups? Maybe it is just a question of ensuring plugins are loaded during backup/restore - which would be nice and easy to do, compared to anything else that I can imagine being the issue.

  6. SchrodingersGat commented on Feb 1, 2026

    @SchrodingersGat
    Member

    I think we just have to ensure that the correct plugins are enabled before updating.

    So we may need to ensure that the data is re-imported in a correct sequence:

    1. Run InvenTree table migrations
    2. Import core InvenTree data
    3. Load plugin configs (to ensure the plugins are enabled to allow generation of tables)
    4. Re-run migrations (to create the plugin tables)
    5. Import plugin data from the backup
  7. matmair commented on Feb 1, 2026

    @matmair
    MemberAuthor

    sounds reasonable; can we shift that to another issue?

  8. SchrodingersGat commented on Feb 1, 2026

    @SchrodingersGat
    Member

    If you would like to scope it do a different issue, that's fine :)

  9. changed the title [-][FR] ensure restore of plugins only works in correct enviroments[/-] [+][FR] ensure restore of backups only works in correct enviroments[/+] on Feb 1, 2026
  10. matmair commented on Feb 1, 2026

    @matmair
    MemberAuthor

    I opened #11235 to track that issue

  11. modified the milestones: 2.0.0, 1.3.0 on Feb 18, 2026
  12. matmair commented on Feb 18, 2026

    @matmair
    MemberAuthor

    working on this now

  13. added a commit that references this issue on Feb 18, 2026
    f4dfe45
  14. added a commit that references this issue on Feb 24, 2026
    ac9a1f2
  15. added a commit that references this issue on Feb 25, 2026
    29c70ef
  16. added a commit that references this issue on Feb 27, 2026
    3d9104e
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

enhancementsetup

Projects

No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions