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

Wrap sync peewee calls in batch loaders #1222

Draft
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

pylipp
Copy link
Collaborator

@pylipp pylipp commented Feb 7, 2024

fragment ProductBasicFields on Product {
  id
  name
  gender
  deletedOn
  __typename
}

fragment SizeBasicFields on Size {
  id
  label
  __typename
}

fragment TagBasicFields on Tag {
  id
  name
  color
  description
  type
  __typename
}

query BoxesForBoxesView($baseId: ID!, $filterInput: FilterBoxInput) {
  boxes(
    baseId: $baseId
    filterInput: $filterInput
    paginationInput: {first: 100000}
  ) {
    totalCount
    pageInfo {
      hasNextPage
      __typename
    }
    elements {
      labelIdentifier
      product {
        ...ProductBasicFields
        __typename
      }
      numberOfItems
      size {
        ...SizeBasicFields
        __typename
      }
      state
      location {
        id
        name
        __typename
      }
      tags {
        ...TagBasicFields
        __typename
      }
      shipmentDetail {
        id
        shipment {
          id
          __typename
        }
        __typename
      }
      comment
      createdOn
      lastModifiedOn
      __typename
    }
    __typename
  }
}

@pylipp pylipp force-pushed the poc-batch-loaders-with-sync-wrapper branch from 26bc28c to da59dfb Compare March 11, 2024 11:27
Copy link

codecov bot commented Mar 11, 2024

Codecov Report

Attention: Patch coverage is 90.90909% with 2 lines in your changes are missing coverage. Please review.

Project coverage is 84.67%. Comparing base (4150560) to head (da59dfb).

Files Patch % Lines
back/boxtribute_server/graph_ql/loaders.py 89.47% 1 Missing and 1 partial ⚠️
Additional details and impacted files
@@             Coverage Diff             @@
##           master    #1222       +/-   ##
===========================================
- Coverage   96.68%   84.67%   -12.02%     
===========================================
  Files         109      231      +122     
  Lines        3497    20869    +17372     
  Branches      343     1569     +1226     
===========================================
+ Hits         3381    17670    +14289     
- Misses         97     3179     +3082     
- Partials       19       20        +1     
Flag Coverage Δ
backend 96.64% <90.90%> (-0.05%) ⬇️
frontend 82.24% <ø> (?)

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

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant