Skip to content

Migrate plugin tables - #11648

Merged
SchrodingersGat merged 35 commits into
inventree:masterfrom
SchrodingersGat:plugin-migrate
Apr 2, 2026
Merged

SchrodingersGat merged 35 commits into
inventree:masterfrom
SchrodingersGat:plugin-migrate

Conversation

@SchrodingersGat

@SchrodingersGat SchrodingersGat commented Mar 31, 2026 •

Copy link
Copy Markdown
Member

Updates the import_records task to allow clean importing of data defined in a plugin.

References

Tasks

  • Unit tests
  • Documentation updates
  • Add a dummy plugin which can be used to generate extra table content

@SchrodingersGat SchrodingersGat added this to the 1.3.0 milestone Mar 31, 2026
@SchrodingersGat SchrodingersGat added enhancement This is an suggested enhancement or new feature setup Relates to the InvenTree setup / installation process refactor labels Mar 31, 2026
@netlify

netlify Bot commented Mar 31, 2026 •

Copy link
Copy Markdown

✅ Deploy Preview for inventree-web-pui-preview ready!

Name Link
🔨 Latest commit 377a58f
🔍 Latest deploy log https://app.netlify.com/projects/inventree-web-pui-preview/deploys/69ce396b9f84050008b3c704
😎 Deploy Preview https://deploy-preview-11648--inventree-web-pui-preview.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.
Lighthouse
Lighthouse
1 paths audited
Performance: 93 (no change from production)
Accessibility: 81 (no change from production)
Best Practices: 100 (no change from production)
SEO: 78 (no change from production)
PWA: -
View the detailed breakdown and full score reports

To edit notification comments on pull requests, go to your Netlify project configuration.

@matmair matmair left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

looks good; should we create a more formal and versioned schema for the export / import data to make future changes easier?

@codecov

codecov Bot commented Apr 1, 2026 •

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 85.71429% with 2 lines in your changes missing coverage. Please review.
✅ Project coverage is 91.37%. Comparing base (9aa2308) to head (377a58f).
⚠️ Report is 385 commits behind head on master.

Additional details and impacted files
@@            Coverage Diff             @@
##           master   #11648      +/-   ##
==========================================
- Coverage   91.44%   91.37%   -0.08%     
==========================================
  Files         963      963              
  Lines       49841    49893      +52     
==========================================
+ Hits        45578    45588      +10     
- Misses       4263     4305      +42     
Flag Coverage Δ
backend 89.25% <85.71%> (-0.01%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

Components Coverage Δ
Backend Apps 91.71% <83.33%> (ø)
Backend General 93.41% <ø> (ø)
Frontend ∅ <ø> (∅)
🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@SchrodingersGat

Copy link
Copy Markdown
Member Author

@matmair any suggestions for what such a schema might contain?

@SchrodingersGat
SchrodingersGat merged commit 5c55f4f into inventree:master Apr 2, 2026
38 checks passed
@SchrodingersGat
SchrodingersGat deleted the plugin-migrate branch April 2, 2026 10:26
@matmair matmair added the breaking Indicates a major update or change which breaks compatibility label Apr 2, 2026
@matmair

matmair commented Apr 2, 2026

Copy link
Copy Markdown
Member

@SchrodingersGat great effort! This probably needs a changelog entry and I have marked it breaking because it removes some (seldom used) arguments on tasks

SchrodingersGat added a commit to SchrodingersGat/InvenTree that referenced this pull request Apr 3, 2026
SchrodingersGat added a commit that referenced this pull request Apr 3, 2026
martonmiklos pushed a commit to martonmiklos/InvenTree that referenced this pull request Jun 30, 2026
* Prevent creation of PluginConfig during migrations

* Refactor data import process

- Split into multiple separate steps

* Load plugins during data load / dump

- Required, otherwise we cannot dump the data

* Refactor export_records

- Use temporary file
- Cleanup docstring

* Force apps check on second validation step

* Improve import sequencing

* Update CI script

* Update migration docs

* CI pipeline for running import/export test

* Fix workflow naming

* Fix env vars

* Add placeholder script

* Fix matrix env vars

* Fix missing env var

* Install required packages

* Fix typo

* Tweak tasks.py

* Install dummy plugin as part of the

* Updated CI workflow

* Validate exported data

* Additional CI process

* Log mandatory plugins to INFO

* Force global setting

* Refactor CI pipeline

* Tweak file test

* Workflow updates

* Enable auto-update

* Test if import/export test should run

* Trigger if tasks.py changes
martonmiklos pushed a commit to martonmiklos/InvenTree that referenced this pull request Jun 30, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

breaking Indicates a major update or change which breaks compatibility enhancement This is an suggested enhancement or new feature refactor setup Relates to the InvenTree setup / installation process

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[BUG] Fix restore of backups when plugins with modesl are used

2 participants