Skip to content

Commit fa5c2d0

Browse files
committed
Release 🍓 0.258.0
1 parent ef27874 commit fa5c2d0

File tree

3 files changed

+33
-28
lines changed

3 files changed

+33
-28
lines changed

CHANGELOG.md

+32
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,38 @@
11
CHANGELOG
22
=========
33

4+
0.258.0 - 2025-01-12
5+
--------------------
6+
7+
Add the ability to override the "max results" a relay's connection can return on
8+
a per-field basis.
9+
10+
The default value for this is defined in the schema's config, and set to `100`
11+
unless modified by the user. Now, that per-field value will take precedence over
12+
it.
13+
14+
For example:
15+
16+
```python
17+
@strawerry.type
18+
class Query:
19+
# This will still use the default value in the schema's config
20+
fruits: ListConnection[Fruit] = relay.connection()
21+
22+
# This will reduce the maximum number of results to 10
23+
limited_fruits: ListConnection[Fruit] = relay.connection(max_results=10)
24+
25+
# This will increase the maximum number of results to 10
26+
higher_limited_fruits: ListConnection[Fruit] = relay.connection(max_results=10_000)
27+
```
28+
29+
Note that this only affects `ListConnection` and subclasses. If you are
30+
implementing your own connection resolver, there's an extra keyword named
31+
`max_results: int | None` that will be passed to it.
32+
33+
Contributed by [Thiago Bellini Ribeiro](https://github.com/bellini666) via [PR #3746](https://github.com/strawberry-graphql/strawberry/pull/3746/)
34+
35+
436
0.257.0 - 2025-01-09
537
--------------------
638

RELEASE.md

-27
This file was deleted.

pyproject.toml

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
[tool.poetry]
22
name = "strawberry-graphql"
33
packages = [ { include = "strawberry" } ]
4-
version = "0.257.0"
4+
version = "0.258.0"
55
description = "A library for creating GraphQL APIs"
66
authors = ["Patrick Arminio <[email protected]>"]
77
license = "MIT"

0 commit comments

Comments
 (0)