Skip to content

Conversation

@SchrodingersGat
Copy link
Member

  • The prefetch_related call is not required as we do not process the parameter fields in python
  • Performing the prefetch adds overhead (up to a few hundred ms in some cases)

- Not required as we do not process the parameter fields in python
@SchrodingersGat SchrodingersGat added this to the 1.2.0 milestone Dec 14, 2025
@SchrodingersGat SchrodingersGat added api Relates to the API refactor labels Dec 14, 2025
@netlify
Copy link

netlify bot commented Dec 14, 2025

Deploy Preview for inventree-web-pui-preview canceled.

Name Link
🔨 Latest commit aab78eb
🔍 Latest deploy log https://app.netlify.com/projects/inventree-web-pui-preview/deploys/693e603ef95ea500083e38ea

@codecov
Copy link

codecov bot commented Dec 14, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 88.16%. Comparing base (2600690) to head (aab78eb).
⚠️ Report is 5 commits behind head on master.

Additional details and impacted files
@@            Coverage Diff             @@
##           master   #11007      +/-   ##
==========================================
- Coverage   88.16%   88.16%   -0.01%     
==========================================
  Files        1290     1290              
  Lines       58044    58043       -1     
  Branches     1970     1970              
==========================================
- Hits        51175    51173       -2     
- Misses       6378     6379       +1     
  Partials      491      491              
Flag Coverage Δ
backend 89.46% <ø> (-0.01%) ⬇️

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

Components Coverage Δ
Backend Apps 92.03% <ø> (ø)
Backend General 93.47% <ø> (-0.01%) ⬇️
Frontend 70.86% <ø> (ø)
🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@SchrodingersGat SchrodingersGat merged commit 2a20eeb into inventree:master Dec 14, 2025
33 checks passed
@SchrodingersGat SchrodingersGat deleted the parameter-api-filtering branch December 14, 2025 08:08
matmair added a commit to matmair/InvenTree that referenced this pull request Dec 14, 2025
* chore(deps): bump the dependencies group across 1 directory with 2 updates (inventree#11003)

* chore(deps): bump the dependencies group across 1 directory with 2 updates

Bumps the dependencies group with 2 updates in the /src/backend directory: [django-q2](https://github.com/GDay/django-q2) and [sentry-sdk](https://github.com/getsentry/sentry-python).


Updates `django-q2` from 1.8.0 to 1.9.0
- [Release notes](https://github.com/GDay/django-q2/releases)
- [Changelog](https://github.com/django-q2/django-q2/blob/master/CHANGELOG.md)
- [Commits](django-q2/django-q2@v1.8.0...v1.9.0)

Updates `sentry-sdk` from 2.46.0 to 2.47.0
- [Release notes](https://github.com/getsentry/sentry-python/releases)
- [Changelog](https://github.com/getsentry/sentry-python/blob/master/CHANGELOG.md)
- [Commits](getsentry/sentry-python@2.46.0...2.47.0)

---
updated-dependencies:
- dependency-name: django-q2
  dependency-version: 1.9.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: dependencies
- dependency-name: sentry-sdk
  dependency-version: 2.47.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: dependencies
...

Signed-off-by: dependabot[bot] <support@github.com>

* fix style

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Matthias Mair <code@mjmair.com>

* Rearrange python package installs in are metal setup  (inventree#11005)

* Reorder pip installation steps in bare metal setup

* Reorder pip installation steps in bare metal setup

* remove unused lines

* Fix docs formatting (inventree#11008)

* Remove prefetch_related from parametric data filter (inventree#11007)

- Not required as we do not process the parameter fields in python

* [refactor] Generic status API (inventree#11009)

* Fix docs formatting

* [refactor] cache custom states

- Generic state API endpoint executed  query for each state type
- We can run a single database query and cache these in memory
- Reduces query time by ~50%

* [refactor] Build list (inventree#11010)

- Prefetch project_code
- Annotate parameter data

* Improve the documentation installation instructions. (inventree#11011)

Co-authored-by: Mitch Davis <mjd@afork.com>

* [refactor] Improve primary_address annotation for Company API (inventree#11006)

* Refactor primary_address annotation

- Remove SerializerMethodField
- Better cache introspection

* Allow address detail to be optional

* Refactor address caching

* Fix primary_address annotation

* Remove "address_count" field

- Pointless annotation which is not used anywhere

* Update API version

* Tweak docs page

* Tweak unit tests

* feat(backend): add performance test

ref inventree#11002

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Michael <michael@buchmann.ruhr>
Co-authored-by: Oliver <oliver.henry.walters@gmail.com>
Co-authored-by: Mitch Davis <mjd+github@afork.com>
Co-authored-by: Mitch Davis <mjd@afork.com>
SchrodingersGat added a commit that referenced this pull request Dec 18, 2025
* feat(backend): add performance test

ref #11002

* feat(backend): add performance test (#486)

* chore(deps): bump the dependencies group across 1 directory with 2 updates (#11003)

* chore(deps): bump the dependencies group across 1 directory with 2 updates

Bumps the dependencies group with 2 updates in the /src/backend directory: [django-q2](https://github.com/GDay/django-q2) and [sentry-sdk](https://github.com/getsentry/sentry-python).


Updates `django-q2` from 1.8.0 to 1.9.0
- [Release notes](https://github.com/GDay/django-q2/releases)
- [Changelog](https://github.com/django-q2/django-q2/blob/master/CHANGELOG.md)
- [Commits](django-q2/django-q2@v1.8.0...v1.9.0)

Updates `sentry-sdk` from 2.46.0 to 2.47.0
- [Release notes](https://github.com/getsentry/sentry-python/releases)
- [Changelog](https://github.com/getsentry/sentry-python/blob/master/CHANGELOG.md)
- [Commits](getsentry/sentry-python@2.46.0...2.47.0)

---
updated-dependencies:
- dependency-name: django-q2
  dependency-version: 1.9.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: dependencies
- dependency-name: sentry-sdk
  dependency-version: 2.47.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: dependencies
...

Signed-off-by: dependabot[bot] <support@github.com>

* fix style

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Matthias Mair <code@mjmair.com>

* Rearrange python package installs in are metal setup  (#11005)

* Reorder pip installation steps in bare metal setup

* Reorder pip installation steps in bare metal setup

* remove unused lines

* Fix docs formatting (#11008)

* Remove prefetch_related from parametric data filter (#11007)

- Not required as we do not process the parameter fields in python

* [refactor] Generic status API (#11009)

* Fix docs formatting

* [refactor] cache custom states

- Generic state API endpoint executed  query for each state type
- We can run a single database query and cache these in memory
- Reduces query time by ~50%

* [refactor] Build list (#11010)

- Prefetch project_code
- Annotate parameter data

* Improve the documentation installation instructions. (#11011)

Co-authored-by: Mitch Davis <mjd@afork.com>

* [refactor] Improve primary_address annotation for Company API (#11006)

* Refactor primary_address annotation

- Remove SerializerMethodField
- Better cache introspection

* Allow address detail to be optional

* Refactor address caching

* Fix primary_address annotation

* Remove "address_count" field

- Pointless annotation which is not used anywhere

* Update API version

* Tweak docs page

* Tweak unit tests

* feat(backend): add performance test

ref #11002

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Michael <michael@buchmann.ruhr>
Co-authored-by: Oliver <oliver.henry.walters@gmail.com>
Co-authored-by: Mitch Davis <mjd+github@afork.com>
Co-authored-by: Mitch Davis <mjd@afork.com>

* add oidc perm

* fix run setup

* add gitignore

* pin action

* enable DB for test

* patch test detection

* move test argument into tasks

* seperate performance testing into own step

* add automigration

* update test

* Increase MAX_QUERY_TIME to 60 seconds

* use newer python for better prerformance / measurement options

* skip plugin install step

* add debug step

* add debug stmt

* make version import safe

* fix command

* more debugging

* move import

* rollback changes

* do full install

* rollback skip_plugins too

* hide version

* new debug try

* add more debug

* try 3.13

* try reinstalling the cffi

* reinstall cffi?

* reset debug

* rollback debug steos

* add initial tests

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Michael <michael@buchmann.ruhr>
Co-authored-by: Oliver <oliver.henry.walters@gmail.com>
Co-authored-by: Mitch Davis <mjd+github@afork.com>
Co-authored-by: Mitch Davis <mjd@afork.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

api Relates to the API refactor

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant