Strawberry-graphql

Latest version: v0.229.1

Safety actively analyzes 629765 Python packages for vulnerabilities to keep your Python projects secure.

Scan your dependencies

Page 48 of 119

0.125.0

Not secure
--------------------

This release adds an integration with Django Channels. The integration will
allow you to use GraphQL subscriptions via Django Channels.

Contributed by [Dan Sloan](https://github.com/LucidDan) via [PR #1407](https://github.com/strawberry-graphql/strawberry/pull/1407/)

0.124.0

Not secure
--------------------

This release adds full support for Apollo Federation 2.0. To opt-in you need to
pass `enable_federation_2=True` to `strawberry.federation.Schema`, like in the
following example:

python
strawberry.federation.type(keys=["id"])
class User:
id: strawberry.ID


strawberry.type
class Query:
user: User


schema = strawberry.federation.Schema(query=Query, enable_federation_2=True)


This release also improves type checker support for the federation.

Contributed by [Patrick Arminio](https://github.com/patrick91) via [PR #2047](https://github.com/strawberry-graphql/strawberry/pull/2047/)

0.123.3

Not secure
--------------------

This release fixes a regression introduced in version 0.118.2 which was
preventing using circular dependencies in Strawberry django and Strawberry
django plus.

Contributed by [Thiago Bellini Ribeiro](https://github.com/bellini666) via [PR #2062](https://github.com/strawberry-graphql/strawberry/pull/2062/)

0.123.2

Not secure
--------------------

This release adds support for priting custom enums used only on
schema directives, for example the following schema:

python
strawberry.enum
class Reason(str, Enum):
EXAMPLE = "example"


strawberry.schema_directive(locations=[Location.FIELD_DEFINITION])
class Sensitive:
reason: Reason


strawberry.type
class Query:
first_name: str = strawberry.field(directives=[Sensitive(reason=Reason.EXAMPLE)])


prints the following:

graphql
directive sensitive(reason: Reason!) on FIELD_DEFINITION

type Query {
firstName: String! sensitive(reason: EXAMPLE)
}

enum Reason {
EXAMPLE
}


while previously it would omit the definition of the enum.

Contributed by [Patrick Arminio](https://github.com/patrick91) via [PR #2059](https://github.com/strawberry-graphql/strawberry/pull/2059/)

0.123.1

Not secure
--------------------

This release adds support for priting custom scalar used only on
schema directives, for example the following schema:

python
SensitiveConfiguration = strawberry.scalar(str, name="SensitiveConfiguration")


strawberry.schema_directive(locations=[Location.FIELD_DEFINITION])
class Sensitive:
config: SensitiveConfiguration


strawberry.type
class Query:
first_name: str = strawberry.field(directives=[Sensitive(config="Some config")])


prints the following:

graphql
directive sensitive(config: SensitiveConfiguration!) on FIELD_DEFINITION

type Query {
firstName: String! sensitive(config: "Some config")
}

scalar SensitiveConfiguration


while previously it would omit the definition of the scalar.

Contributed by [Patrick Arminio](https://github.com/patrick91) via [PR #2058](https://github.com/strawberry-graphql/strawberry/pull/2058/)

0.123.0

Not secure
--------------------

This PR adds support for adding schema directives to the schema of
your GraphQL API. For printing the following schema:

python
strawberry.schema_directive(locations=[Location.SCHEMA])
class Tag:
name: str


strawberry.type
class Query:
first_name: str = strawberry.field(directives=[Tag(name="team-1")])


schema = strawberry.Schema(query=Query, schema_directives=[Tag(name="team-1")])


will print the following:

graphql
directive tag(name: String!) on SCHEMA

schema tag(name: "team-1") {
query: Query
}

type Query {
firstName: String!
}
"""


Contributed by [Patrick Arminio](https://github.com/patrick91) via [PR #2054](https://github.com/strawberry-graphql/strawberry/pull/2054/)

Page 48 of 119

Links

Releases

Has known vulnerabilities

© 2024 Safety CLI Cybersecurity Inc. All Rights Reserved.