Skip to content

Latest commit

 

History

History
1462 lines (1024 loc) · 86.8 KB

File metadata and controls

1462 lines (1024 loc) · 86.8 KB

CHANGELOG

0.84.0 - 2026-05-03

Propagate child-type only= hints through method resolvers that declare the relation via select_related. Previously they were silently dropped, causing deferred loads or KeyErrors on descriptors without a deferred-load fallback (e.g. djmoney.MoneyField) once the parent's select_related reached past a single hop.

@strawberry_django.type(Child)
class ChildType:
    @strawberry_django.field(only=["extra_data"])
    def extra(self) -> str:
        return self.extra_data


@strawberry_django.type(Parent)
class ParentType:
    @strawberry_django.field(select_related=["child", "child__site"])
    def child(self) -> ChildType | None:
        return self.child

child.extra_data is now included in the parent's first SELECT.

This release was contributed by @bellini666 in #905

0.83.0 - 2026-05-03

Drop support for Django 4.2.

  • Django 4.2 will reach end of support on April 30, 2026. check here

Drop support for Django 5.0.

Drop support for Django 5.1.

This release was contributed by @p-r-a-v-i-n in #897

0.82.1 - 2026-03-28

Fix FieldError when using the optimizer with django-polymorphic models.

The optimizer now uses the CamelCase model name for polymorphic optimization hints (e.g., ArtProject___field instead of app_label__artproject___field). This ensures that django-polymorphic correctly handles mismatched optimization hints during the realization of mixed querysets by raising an AssertionError (which it catches) instead of an unhandled FieldError. This change also avoids potential name collisions with lowercase reverse relations in multi-table inheritance.

A polymorphic optional dependency extra has been added, which sets the lower limit version to 4.0.0. Install with pip install strawberry-graphql-django[polymorphic] to pull in django-polymorphic.

This release was contributed by @valkrypton in #894

Additional contributors: @bellini666

0.82.0 - 2026-03-15

Fix FieldExtension arguments being silently lost on StrawberryDjangoField.

When a FieldExtension appended arguments to field.arguments in its apply() method, the arguments worked with strawberry.field but silently disappeared with strawberry_django.field. This was because the mixin chain (Pagination → Ordering → Filters → Base) created a new list on every .arguments access, so .append() mutated a temporary copy.

Added a caching arguments property to StrawberryDjangoField so that the first access computes and caches the full arguments list, and subsequent accesses (including .append() from extensions) operate on the same cached list.

This release was contributed by @bellini666 in #892

0.81.0 - 2026-03-15

Fix StrFilterLookup so it can be used without a type parameter (e.g., name: StrFilterLookup | None). Previously this raised TypeError: "StrFilterLookup" is generic, but no type has been passed at schema build time.

This release was contributed by @bellini666 in #891

0.80.0 - 2026-03-08

Add support for graphql-core 3.3.x alongside existing 3.2.x support.

The minimum supported version of strawberry-graphql has been increased to 0.310.1. When using the graphql-core 3.3.x series, the minimum supported version is 3.3.0a12.

This release was contributed by @bellini666 in #850

0.79.2 - 2026-03-08

Fix docs example for process_filters custom filter method where prefix was missing a trailing __, causing Django FieldError. Also add a UserWarning in process_filters() when a non-empty prefix doesn't end with __ to help users catch this mistake early.

This release was contributed by @Ckk3 in #883

0.79.1 - 2026-03-04

Fix FK _id fields (e.g. color_id: auto) in input types failing with mutations.create(). Previously, prepare_create_update() didn't recognize FK attnames, causing the value to be silently dropped and full_clean() to fail. Now attname fields are mapped and their raw PK values are passed through directly.

This release was contributed by @bellini666 in #880

0.79.0 - 2026-03-01

Pass Info instead of GraphQLResolveInfo to callables provided in prefetch_related and annotate arguments of strawberry_django.field.

This is technically a breaking change because the argument type passed to these callables has changed. However, Info acts as a proxy for GraphQLResolveInfo and is compatible with the utilities typically used within prefetch or annotate functions, such as optimize.

This release was contributed by @rcybulski1122012 in #872

0.78.0 - 2026-02-28

Add skip_queryset_filter parameter to filter_field() for declaring virtual (non-filtering) fields on filter types.

Fields marked with skip_queryset_filter=True appear in the GraphQL input type but are not applied as database filters. They are accessible via self.<field> in custom filter methods, making them useful for passing parameters like thresholds or configuration values.

@strawberry_django.filter_type(models.Fruit)
class FruitFilter:
    min_similarity: float | None = strawberry_django.filter_field(
        default=0.3, skip_queryset_filter=True
    )

    @strawberry_django.filter_field
    def search(
        self, info: Info, queryset: QuerySet[models.Fruit], value: str, prefix: str
    ):
        if self.min_similarity is not None:
            queryset = queryset.annotate(
                similarity=TrigramSimilarity(f"{prefix}name", value)
            ).filter(similarity__gte=self.min_similarity)
        return queryset, Q()

This release was contributed by @bellini666 in #876

0.77.0 - 2026-02-28

Automatically inject FK fields into .only() on user-provided Prefetch querysets when the only optimization is enabled.

This prevents N+1 queries caused by Django re-fetching the FK field needed to match prefetched rows back to parent objects.

The optimizer now correctly resolves reverse relations by related_name and restricts FK injection to ManyToOneRel, OneToOneRel, and GenericRelation.

This release was contributed by @bellini666 in #874

0.76.2 - 2026-02-28

Fix N+1 queries when using optimize() inside a Prefetch object with .only() optimization. The optimizer now correctly auto-adds the FK field needed by Django to match prefetched objects back to their parent.

This release was contributed by @bellini666 in #873

0.76.1 - 2026-02-28

Fix optimizer skipping optimization entirely for aliased fields. When a GraphQL query uses aliases for the same field (e.g., a: milestones { id } and b: milestones { id }), the optimizer now merges them into a single prefetch instead of skipping optimization, preventing N+1 queries.

Aliases with different arguments (e.g., a: issues(filters: {search: "Foo"}) and b: issues(filters: {search: "Bar"})) are still skipped, since a single prefetch cannot satisfy both filter sets and optimizing one would produce wrong results for the other.

This release was contributed by @bellini666 in #871

0.76.0 - 2026-02-28

Add native federation support via strawberry_django.federation module.

New decorators that combine strawberry_django functionality with Apollo Federation:

  • strawberry_django.federation.type - Federation-aware Django type with auto-generated resolve_reference
  • strawberry_django.federation.interface - Federation-aware Django interface
  • strawberry_django.federation.field - Federation-aware Django field with directives like @external, @requires, @provides

Example usage:

import strawberry
import strawberry_django
from strawberry.federation import Schema


@strawberry_django.federation.type(models.Product, keys=["upc"])
class Product:
    upc: strawberry.auto
    name: strawberry.auto
    price: strawberry.auto
    # resolve_reference is automatically generated!


schema = Schema(query=Query)

The auto-generated resolve_reference methods support composite keys and multiple keys, and integrate with the query optimizer.

Note: This release requires strawberry-graphql>=0.303.0.

0.75.3 - 2026-02-26

Add support for strawberry-graphql 0.307.x.

Also, the deprecated asserts_errors parameter has been removed from test client query() methods. Use assert_no_errors instead.

This release was contributed by @bellini666 in #870

Additional contributors: @Copilot

0.75.2 - 2026-02-18

Fixes compatibility with strawberry-graphql>=0.296.0 by ensuring proper Info type resolution.

Info is now imported at runtime and resolver arguments include explicit type annotations. This aligns with the updated behavior where parameter injection is strictly type-hint based rather than name-based.

Before, resolvers relying on implicit name-based injection could fail under newer Strawberry versions.

After this change, resolvers work correctly with the stricter type-based injection system introduced in newer releases.

This release was contributed by @daudln in #866

Additional contributors: @pre-commit-ci[bot]

0.75.1 - 2026-02-15

Fix DuplicatedTypeName errors when using FilterLookup[str] by:

  • Exporting StrFilterLookup from the top-level strawberry_django module
  • Adding a deprecation warning when using FilterLookup[str] or FilterLookup[uuid.UUID]
  • Updating documentation to recommend using specific lookup types

Users should migrate from:

from strawberry_django import FilterLookup


@strawberry_django.filter_type(models.Fruit)
class FruitFilter:
    name: FilterLookup[str] | None

To:

from strawberry_django import StrFilterLookup


@strawberry_django.filter_type(models.Fruit)
class FruitFilter:
    name: StrFilterLookup | None

This release was contributed by @bellini666 in #851

0.75.0 - 2026-01-27

Adds support for Django-style relationship traversal in strawberry_django.field(field_name=...) using LOOKUP_SEP (__). You can now flatten related objects or scalar fields without custom resolvers.

Examples:

@strawberry_django.type(User)
class UserType:
    role: RoleType | None = strawberry_django.field(
        field_name="assigned_role__role",
    )

    role_name: str | None = strawberry_django.field(
        field_name="assigned_role__role__name",
    )

The traversal returns None if an intermediate relationship is None. Documentation and tests cover the new behavior, including optimizer query counts.

This release was contributed by @bellini666 in #852

0.74.2 - 2026-01-27

Fix offset pagination extensions so they receive pagination, order, and filter arguments consistently with connection fields. This allows extensions to inspect filters for permission/validation while keeping resolvers tolerant of missing params.

0.74.1 - 2026-01-18

Pagination pageInfo.limit now returns the actual limit applied (after defaults and max caps), not the raw request value.

For example, with PAGINATION_DEFAULT_LIMIT=20, PAGINATION_MAX_LIMIT=50:

{ fruits(pagination: { limit: null }) { pageInfo { limit } } }

Before:

{
  "data": {
    "fruits": {
      "pageInfo": {
        "limit": null
      }
    }
  }
}

After:

{
  "data": {
    "fruits": {
      "pageInfo": {
        "limit": 20
      }
    }
  }
}

Also fixes limit: null to use PAGINATION_DEFAULT_LIMIT instead of PAGINATION_MAX_LIMIT.

This release was contributed by @bellini666 in #848

0.74.0 - 2026-01-17

Add configurable PAGINATION_MAX_LIMIT setting to cap pagination requests, preventing clients from requesting unlimited data via limit: null or excessive limits.

This addresses security and performance concerns by allowing projects to enforce a maximum number of records that can be requested through pagination.

Configuration:

STRAWBERRY_DJANGO = {
    "PAGINATION_MAX_LIMIT": 1000,  # Cap all requests to 1000 records
}

When set, any client request with limit: null, negative limits, or limits exceeding the configured maximum will be capped to PAGINATION_MAX_LIMIT. Defaults to None (unlimited) for backward compatibility, though setting a limit is recommended for production environments.

Works with both offset-based and window-based pagination.

This release was contributed by @bellini666 in #847

0.73.1 - 2026-01-09

This release fixes a bug, which caused nested prefetch_related hints to get incorrectly merged in certain cases.

This release was contributed by @diesieben07 in #839

0.73.0 - 2026-01-04

Nothing changed, testing the new release process using autopub.

0.72.2 - 2026-01-04

Nothing changed, testing the new release process using autopub.

This release was contributed by @bellini666 in #837

0.72.0 - 2025-12-28

What's Changed

  • feat: use the new type-friendly way to define scalars from Strawberry by @bellini666 in #832

0.71.0 - 2025-12-26

What's Changed

0.70.1 - 2025-12-08

What's Changed

  • fix(input): use None as default for Maybe fields instead of UNSET by @bellini666 in #824

0.70.0 - 2025-12-06

What's Changed

  • feat: add support for strawberry.Maybe type in mutations and filter processing by @deepak-singh in #805

0.69.0 - 2025-12-06

What's changed

0.68.0 - 2025-12-03

What's Changed

  • feat: declare support for django 6.0 by @bellini666 in #821
  • docs: add comprehensive guides for production usage by @bellini666 in #810
  • chore(examples): modernize examples with modular apps and current best practices by @bellini666 in #811
  • docs: fix critical code example errors and typos by @bellini666 in #819

0.67.2 - 2025-11-23

What's changed

  • fix: fix wrong total_count when using distinct on m2m/o2m relationships (ff1f016fbd95ddaa7cd76cd712a58ad460ca87df)

0.67.1 - 2025-11-22

What's Changed

0.67.0 - 2025-10-18

What's Changed

Note: If you have a custom connection that defines a resolve_connection method, ensure that you have **kwargs in case you are not defining all possible keyword parameters.

  • feat: Forward custom kwargs to relay connection resolver by @stygmate in #801

0.66.2 - 2025-10-15

What's changed

0.66.1 - 2025-10-14

What's Changed

  • fix: fix broken future annotations with the new | syntax by @bellini666 in #800

0.66.0 - 2025-10-12

What's Changed

  • feat: support for Python 3.14 and drop 3.9, which has reached EOL by @bellini666 in #795
  • fix: fix debug toolbar integration to work with v6.0 by @bellini666 in #796
  • fix: Fix typo in depecation message for order decorator by @zvyn in #785

0.65.1 - 2025-07-26

What's changed

0.65.0 - 2025-07-20

What's Changed

0.64.0 - 2025-07-19

What's changed

  • feat: bump minimum Strawberry version to 0.276.2

0.63.0 - 2025-07-16

What's Changed

0.62.0 - 2025-06-16

What's Changed

  • delete unused filters for creating mutations by @star2000 in #761
  • fix: fix filters using lazy annotations by @bellini666 in #765
  • Add support for AND/OR filters to be lists by @soby in #762

0.61.0 - 2025-06-08

What's Changed

0.60.0 - 2025-05-24

What's Changed

  • fix(optimizer): Pass accurate "info" parameter to PrefetchCallable and AnnotateCallable by @diesieben07 in #742
  • feat: wrap resolvers in django_resolver(...) to ensure appropriate async/sync context by @axieum in #746

0.59.1 - 2025-05-06

What's Changed

  • fix: Fix "ordering" for connections and offset_paginated by @diesieben07 in #741

0.59.0 - 2025-04-30

Highlights

This release brings some very interesting features, thanks to @diesieben07 🍓

  • A new ordering type is now available, created using ⁠@strawberry_django.order_type. This type uses a list for specifying ordering criteria instead of an object, making it easier and more flexible to apply multiple orderings, ensuring they will keep their order. Check the ordering docs for more info on how to use it
  • Support for "true" cursor-based pagination in connections, using the new DjangoCursorConnection type. Check the relay docs for more info on how to use it

Also, to maintain consistency across the codebase, we have renamed several classes and functions. The old names are still available for import and use, making this a non-breaking change, but they are marked as deprecated and will eventually be removed in the future. The renames are as follows:

  • ListConnectionWithTotalCount got renamed to DjangoListConnection
  • strawberry_django.filter got renamed to strawberry_django.filter_type

What's Changed

  • feat: Add new ordering method allowing ordering by multiple fields by @diesieben07 in #679
  • feat: Add support for "true" cursor based pagination in connections by @diesieben07 in #730
  • refactor: rename ListConnectionWithTotalCount and filter for consistency by @bellini666 in #739
  • fix: Fix duplicate LOOKUP_SEP being used when field hints are used with polymorphic queries by @diesieben07 in #736
  • fix: Fix a minor typing issue by @diesieben07 in #738
  • docs: Fix resolvers.md by @Hermotimos in #735

0.58.0 - 2025-04-04

What's Changed

0.57.1 - 2025-03-22

What's Changed

0.57.0 - 2025-03-02

What's Changed

0.56.0 - 2025-02-16

What's Changed

0.55.2 - 2025-02-12

What's Changed

0.55.1 - 2025-01-26

What's Changed

0.55.0 - 2025-01-12

What's Changed

  • feat: Allow setting max_results for connection fields by @bellini666 in #689

0.54.0 - 2025-01-09

What's Changed

0.53.3 - 2025-01-07

What's changed

0.53.2 - 2025-01-07

What's Changed

  • fix: skip empty choice value when generating enums from choices by @fabien-michel in #687
  • test: Replace django mptt with django tree queries for tests by @kwongtn in #684

0.53.1 - 2025-01-03

What's Changed

  • fix(optimizer): Fix nested pagination optimization for m2m relations by @bellini666 in #681
  • Update test scope to include django 5.1 by @kwongtn in #683

0.53.0 - 2024-12-21

What's Changed

  • Support multi-level nested create/update with model full_clean() by @philipstarkey in #659

0.52.1 - 2024-12-18

What's Changed

  • fix(optimizer): Prevent issuing duplicated queries for certain uses of first() and get() by @diesieben07 in #675

0.52.0 - 2024-12-15

What's Changed

  • fix(pagination)!: Use PAGINATION_DEFAULT_LIMIT when limit is not provided by @bellini666 in #673
  • fix(mutations): Refetch instances to optimize the return value by @bellini666 in #674

0.51.0 - 2024-12-08

What's Changed

0.50.0 - 2024-11-09

What's Changed

0.49.1 - 2024-10-19

What's Changed

  • docs: Remove mention about having to enable subscriptions in the docs by @bellini666 in #645
  • Add unit tests for partial input optional field behaviour in update mutations by @SupImDos in #638
  • fix: Make sure that async fields always return Awaitables by @bellini666 in #646

0.49.0 - 2024-10-17

What's Changed

  • feat: Official support for Python 3.13 and drop support for Python 3.8 which has reached EOL by @bellini666 in #643
  • Changed the recommended library for JWT Authentication in Django to strawberry-django-auth by @pkrakesh in #633

0.48.0 - 2024-09-24

What's Changed

  • Change default Relay input m2m types from ListInput[NodeInputPartial] to ListInput[NodeInput] by @SupImDos in #630
  • refactor: Remove guardian ObjectPermissionChecker monkey patch by @bellini666 in #631

0.47.2 - 2024-09-04

What's Changed

0.47.1 - 2024-07-24

What's Changed

  • fix: Fix debug toolbar upgrade issue by @bellini666 in #600
  • fix: Only set False to clear FileFields when updating an instance by @bellini666 in #601

0.47.0 - 2024-07-18

What's Changed

0.46.2 - 2024-07-14

What's Changed

  • refactor(optimizer): Split optimizer code to make it cleaner and easier to understand/maintain by @bellini666 in #575
  • fix(optimizer): Convert select_related into Prefetch when the type defines a custom get_queryset by @bellini666 in #583
  • fix(optimizer): Avoid extra queries for prefetches with existing prefetch hints by @bellini666 in #582
  • fix: Do not try to call an ordering object's order method if it is not a decorated method by @bellini666 in #584
  • fix: Avoid pagination failures when filtering connection by last without before/after by @bellini666 in #585

0.46.1 - 2024-06-30

What's Changed

  • fix: Fix and test optimizer with polymorphic relay node by @stygmate in #570
  • fix: Fix nested pagination/filtering/ordering not working when "only optimization" is disabled by @aprams in #569

0.46.0 - 2024-06-29

What's Changed

  • feat: Add support for auto mapping of ArrayFields by @bellini666 in #567
  • fix: Set files early on mutations to allow clean methods to validate them by @bellini666 in #566
  • fix: Make sure the optimizer calls the type's get_queryset for nested lists/connections by @bellini666 in #568

0.45.0 - 2024-06-27

What's Changed

0.44.2 - 2024-06-17

What's Changed

  • docs: wrong typo on filter on fruitfilter by @OdysseyJ in #555
  • docs: Remove officially unmaintained project by @Eraldo in #557
  • test: Add some tests to ensure Interfaces can be properly optimized by @bellini666 in #554
  • fix: Extract interface definition in optimizer to fix django-polymorphic by @ManiacMaxo in #556

0.44.1 - 2024-06-12

What's Changed

0.44.0 - 2024-06-10

What's Changed

  • feat: Nested optimization for lists and connections by @bellini666 in #540

This releases finally enables the highly anticipated nested optimization for lists and connections 🚀

What does that mean? Remember that when trying to retrieve a relation list inside another type and also trying to filter/order/paginate, that would cause n+1 issues because it would force the prefetched list to be thrown away? Well, not anymore after this release! 😊

In case you find any issues with this, please let us know by registering an issue with as much information as possible on how to reproduce the issue.

Note that even though this is enabled by default, nested optimizations can be disabled by passing enabled_nested_relations_prefetch=False when initializing the optimizer extensions.

  • Dropped support for Django versions earlier than 4.2

The nested optimization feature required features only available on Django 4.2+.

To be able to implement it, and also considering that django itself recommended dropping support for those versions, from now on this lib requires Django 4.2+

0.43.0 - 2024-06-07

What's Changed

  • Added export-schema command to Docs by @Ckk3 in #546
  • fix: Fix specialized connection aliases missing filters/ordering by @bellini666 in #547

NOTE: Even though this only contains a bug fix, I decided to do a minor release because the fix is bumping the minimum required version of strawberry-graphql itself to 0.234.2.

0.42.0 - 2024-05-30

What's Changed

  • refactor: Use graphql-core's collect_sub_fields instead of our own implementation by @bellini666 in #537

0.41.1 - 2024-05-26

What's changed

0.41.0 - 2024-05-26

What's Changed

0.40.0 - 2024-05-11

What's Changed

0.39.2 - 2024-04-25

What's Changed

  • fix: Delete mutation should not throw error if no objects in filterset by @keithhackbarth in #522

0.39.1 - 2024-04-21

What's changed

  • fix: fix annotations inheritance override for python 3.8/3.9

0.39.0 - 2024-04-21

What's changed

  • feat: support for strawberry 0.227.1+

0.38.0 - 2024-04-20

What's Changed

  • feat: Ability to use custom field_cls for connections and nodes (#517)
  • Fix typos in filtering documentation by @cdroege in #520

0.37.1 - 2024-04-14

What's Changed

  • Fixing Docs Typo by @drewbeno1 in #513
  • fix: fix debug toolbar when used with apollo_sandbox ide (#514)
  • fix: fix debug toolbar running on ASGI and Python 3.12

0.37.0 - 2024-04-01

What's Changed

  • feat: filter_field optional value resolution by @Kitefiko in #510

0.36.0 - 2024-03-30

What's Changed

  • feat: properly resolve _id fields to ID (#506)

0.35.1 - 2024-03-19

What's Changed

  • fix: async with new filter API (assert queryset is wrong) by @devkral in #504

0.35.0 - 2024-03-18

🚀 Highlights (contains BREAKING CHANGES)

This release contains a major refactor of how filters and ordering works with this library (#478).

Thank you very much for this excellent work @Kitefiko 😊

Some distinctions between the new API and the old API:

Filtering

IMPORTANT NOTE: If you find any issues and/or can't migrate your codebase yet, the old behaviour can still be achieved by setting USE_DEPRECATED_FILTERS=True in your django settings: https://strawberry-graphql.github.io/strawberry-django/guide/filters/#legacy-filtering

Also, make sure to report any issues you find with the new API.

Ordering

There are no breaking changes in the new ordering API, but please report any issues you find when using it.

0.34.0 - 2024-03-16

What's Changed

  • Fix _perm_cache processing by @vecchp in #498
  • feat: Add support for generated enums in mutation input by @cngai in #497

0.33.0 - 2024-03-05

What's Changed

0.32.2 - 2024-02-27

What's Changed

0.32.0 - 2024-02-19

What's Changed

0.31.0 - 2024-02-07

What's Changed

  • chore: Rename all links to the new repository name by @bellini666 in #477
  • fix: cache definitions in optimizer by @yergom in #474

0.30.1 - 2024-02-05

What's Changed

0.30.0 - 2024-01-27

What's Changed

  • fix: fix files not being saved on create mutation by @bellini666 in #464
  • feat(optimizer): Do not defer select_related fields if no only was specified by @bellini666 in #465
  • fix: Return null on empty files/images by @bellini666 in #466

0.29.0 - 2024-01-23

What's Changed

0.28.3 - 2023-12-23

What's Changed

  • fix(docs): Standardising the use of strawberry_django throughout the documentation. by @ArcD7 in #440
  • Fix code example on updating field_type_map. by @alimony in #441
  • fix: support for fields using async only extensions by @bellini666 in #444

0.28.2 - 2023-12-08

What's Changed

  • fix: HasPerm on async fields, fix missing query in another test by @devkral in #437
  • fix(docs): resolvers.md strawberry_django import by @hkfi in #436

0.28.1 - 2023-12-06

What's Changed

  • fix: really push OR, AND and NOT to the end by @devkral in #435

0.28.0 - 2023-12-06

What's changed

  • Official support for Django 5.0

0.27.0 - 2023-12-04

What's Changed

  • Fix: ordering when dealing with camelCased field by @he0119 in #430
  • Guarantee 'AND', 'OR', and 'NOT' filter fields get evaluated last by … by @TWeidi in #424

0.26.0 - 2023-11-29

What's Changed

0.25.0 - 2023-11-18

What's Changed

0.24.4 - 2023-11-17

What's Changed

0.24.3 - 2023-11-15

What's Changed

0.24.2 - 2023-11-13

What's Changed

  • fix: make sure custom fields are kept during inheritance by @bellini666 in #415

0.24.1 - 2023-11-07

What's Changed

  • fix: Use _RESOLVER_TYPE as the type for the resolver on field, so the… by @guizesilva in #412

0.24.0 - 2023-11-07

What's Changed

0.23.0 - 2023-11-05

What's Changed

0.22.0 - 2023-10-30

What's Changed

  • Fixed Documentation issue #390: added explanation of the error and PYTHON_CONFIGURE_OPTS: a little bit verbose, but maybe will save someone time and possibly add contributors to the project by @thepapermen in #392
  • docs: Added strawberry-django-extras to community-projects.md by @m4riok in #395
  • [pre-commit.ci] pre-commit autoupdate by @pre-commit-ci in #400
  • chore: migrate from black to ruff-formatter by @bellini666 in #403
  • compatibility ASGI/websockets get_request, login and logout by @sdobbelaere in #393

0.21.0 - 2023-10-11

What's Changed

  • chore: Update docs to include changes to partial behavior by @whardeman in #385
  • Docs improvement Subscriptions by @sdobbelaere in #376
  • New Feature: Optional custom key_attr to that can be used instead of id (pk) in to access model in Django UD mutations (Issue #348) by @thepapermen in #387

0.20.3 - 2023-10-09

What's changed

  • fix: fix a regression when checking permissions for an async resolver

0.20.2 - 2023-10-09

What's changed

  • fix: ensure permissions' resolve_for_user get safely resolved inside async contexts

0.20.1 - 2023-10-06

What's Changed

0.20.0 - 2023-10-02

What's Changed

0.19.0 - 2023-10-01

What's Changed

  • feat: deprecate nSomething in favor of using NOT by @bellini666 in #381
  • Fix: DjangoOptimizerExtension corrupts nested objects' fields' prefetch objects by @aprams in #380

0.18.0 - 2023-09-28

What's Changed

  • Support annotate parameter in field to allow ORM annotations by @fjsj in #377

0.17.4 - 2023-09-25

What's Changed

  • Exclude id from model fields to avoid overriding the id: type by @sdobbelaere in #373

0.17.3 - 2023-09-21

What's Changed

0.17.2 - 2023-09-15

What's Changed

0.17.1 - 2023-09-12

What's Changed

  • fix: Update related objects with unique_together by @zvyn in #362

0.17.0 - 2023-09-11

What's Changed

  • feat: Add ValidationError code to OperationMessage by @zvyn in #358
  • Docs on Mutations: Fixed issue with relay.NodeInput not existing, imported NodeInput from strawberry_django instead by @thepapermen in #353
  • [pre-commit.ci] pre-commit autoupdate by @pre-commit-ci in #355
  • docs: fix sample code on 'Serving the API' by @miyashiiii in #357

0.16.1 - 2023-08-31

What's Changed

0.16.0 - 2023-08-02

What's Changed

0.15.0 - 2023-07-31

What's changed

  • feat: drop python 3.7 support, which EOLed on June 2023, following strawberry's 0.198.0 release
  • refactor: make sure to not insert duplicate permission directives to the field

0.14.1 - 2023-07-29

What's Changed

  • refactor: make sure to also call the type's get_queryset when retrieving nodes for connection or a list of nodes
  • Update mutations.md by @baseplate-admin in #319
  • [pre-commit.ci] pre-commit autoupdate by @pre-commit-ci in #321

0.14.0 - 2023-07-19

What's Changed

  • filters support 'NOT' 'AND' 'OR' by @star2000 in #313
  • feat: make sure to run the type's get_queryset when one is defined on resolve_model_node (#316)

0.13.1 - 2023-07-19

What's Changed

  • Fix TypeError with IntegerChoices and Add Tests for Enum Conversion without django_choices_field by @miyashiiii in #314

0.13.0 - 2023-07-17

What's Changed

  • docs: change one occurence of select_related to prefetch_related by @Wartijn in #306
  • fix: fix an issue where non dataclass annotations where being injected as fields on input types by @bellini666 in #310
  • Add new keywords "fields" and "exclude" to type decorator for auto-population of Django model fields by @coleshaw in #293
  • fix: fix resolving optional fields based on reverse one-to-one relations by @bellini666 in #309
  • fix: default pagination/filters/order to UNSET for fields (#257)

0.12.0 - 2023-07-13

What's Changed

  • refactor!: use a setting to decide if we should map fields to relay types or not by @bellini666 in #302

NOTE: If you are using relay integration in all your types, you probably will want to set MAP_AUTO_ID_AS_GLOBAL_ID=True in your strawberry django settings to make sure auto gets mapped properly to GlobalID on types and filters.

0.11.0 - 2023-07-12

What's Changed

0.10.7 - 2023-07-12

What's Changed

0.10.6 - 2023-07-10

What's Changed

0.10.5 - 2023-07-08

What's Changed

  • Handle Django GENERATE_ENUMS_FROM_CHOICES with strawberry.auto by @pcraciunoiu in #286

0.10.4 - 2023-07-08

What's Changed

0.10.3 - 2023-07-06

What's changed

  • fix: make sure field_name overriding is not ignored when querying data (#282)
  • fix: the type's queryset doesn't receive **kwarg
  • fix: make sure the type's get_queryset gets called for resolved coroutines (#281)
  • chore: expose missing input_mutation in init file
  • docs: fix some documentation examples

0.10.2 - 2023-07-05

What's Changed

  • fix: reset annotation cache to fix some inheritance issues when using strawberry>=0.192.2 by @bellini666 in #278

0.10.1 - 2023-07-05

What's Changed

  • fix: do not import anything from strawberry.django that is not in this lib by @bellini666 in #277

0.10.0 - 2023-07-05

Highlights

This release is a major milestone for strawberry-django. Here are some of its highlights:

  • The strawberry-django-plus lib was finally merged into this lib, meaning all the extra features it provides are available directly in here. strawberry-django-plus is being deprecated and the development of its features is going to continue here. Here is a quick summary of all the features ported from it:
    • The query optimizer extension
    • The relay integration (based on the new official relay support from strawberry)
    • Enum integration with django-choices-field and auto generation from fields with choices
    • Lots of improvements to mutations, allowing CUD mutations to handle nested creation/updating/etc
    • The permissioned resolvers, designed as field extensions now instead of the custom schema directives it used
  • All the API has been properly typed, meaning that type checkers should be able to properly validate calls to strawberry_django.type(...)/strawberry_django.field(...)/etc
  • The docs have been updated with all the new features
  • A major performance improvement: Due to all the refactoring and improvements, some personal benchmarks show a performance improvement of around 10x when comparing the v0.9.5 and 8x when comparing to strawberry-django-plus

Changes

0.9.5 - 2023-06-15

What's Changed

0.9.4 - 2023-04-03

What's changed

  • refactor: replace Extension by SchemaExtension as required by strawberry 0.160.0+
  • fix: do not add filters to non list fields (thanks @g-as for reporting this regression)

0.9.3 - 2023-04-02

What's Changed

  • Update test django version from 4.2a1 to 4.2b1 by @kwongtn in #241
  • feature: backporting django-debug-toolbar from strawberry-django-plus by @frleb in #239
  • refactor: do not insert pk arguments inside non root fields by @bellini666 in #246

0.9.2 - 2023-02-04

What's changed

  • chore: do not limit django/strawberry upper bound versions

0.9.1 - 2023-02-03

What's Changed

  • Add django 4.0,4.2 to tests & updated minor versions by @kwongtn in #228
  • Fix private field handling by @devkral in #231

0.9 - 2023-01-14

What's Changed

0.8.2 - 2022-11-16

What's Changed

  • make pk argument required when querying single object by @stygmate in #214

0.8.1 - 2022-11-10

What's Changed

0.8 - 2022-11-06

What's Changed

0.7.1 - 2022-10-28

What's Changed


What's Changed

0.6 - 2022-10-11

What's Changed

0.5.4 - 2022-10-10

What's Changed

0.5.3 - 2022-10-01

What's Changed

  • [pre-commit.ci] pre-commit autoupdate by @pre-commit-ci in #178
  • Fix mutations and filtering for when using strawberry-graphql >=0.132.1 by @jkimbo in #183
  • Broaden is_strawberry_django_field to support custom field classes by @benhowes in #185

0.5.2 - 2022-09-28

What's Changed

  • Pin strawberry-graphql to <0.132.1 by @jkimbo in #184

0.5.1 - 2022-09-12

What's changed


What's Changed


What's Changed

0.3.1 - 2022-06-29

What's Changed


What's Changed

  • Feature: Register mutation by @NeoLight1010 in #45
  • Fix filtering in get_queryset of types with enabled pagination by @illia-v in #60
  • Add permissions to django mutations by @wellzenon in #53
  • Fix a bug related to creating users with unhashed passwords by @illia-v in #62
  • pre-commit config file and fixes by @la4de in #68
  • Clean deprecated API by @la4de in #69
  • updated the way event loop is detected in 'is_async' by @g-as in #72
  • Fix detecting auto annotations when postponed evaluation is used by @illia-v in #73
  • Updated docs by @ccsv in #78
  • Fix incompatibility with Strawberry >= 0.92.0 related to interfaces by @illia-v in #76
  • Fixed issue with generating order args by @jaydensmith in #90
  • Update .gitignore to the python standard by @hiporox in #97
  • feat: add Enum support to filtering by @hiporox in #100
  • build: update packages by @hiporox in #94
  • Caching Extensions using Django Cache by @hiporox in #93
  • docs: filled in some missing info in the docs by @hiporox in #98
  • Fix ordering with custom filters by @hiporox in #108
  • bugfix: ignore filters argument if it is an arbitary argument by @devkral in #115
  • Fixing Quick Start by @akkim2 in #114
  • Fix #110 - Add **kwargs passthrough on CUD mutations, enables "description" annotation from Strawberry. by @JoeWHoward in #111
  • Use auto from strawberry instead of define our own by @bellini666 in #101
  • Fix filtering cannot use relational reflection fields by @star2000 in #109
  • refactor: Change the use of "is_unset" to "is UNSET" by @bellini666 in #117