Skip to content

Commit

Permalink
bump: v0.4.4
Browse files Browse the repository at this point in the history
Added support for new graphene-federation
Drop support for python 3.8
  • Loading branch information
mak626 committed Jun 4, 2024
1 parent 8fd26f2 commit accd421
Show file tree
Hide file tree
Showing 4 changed files with 208 additions and 199 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ jobs:
strategy:
matrix:
os: [ubuntu-latest, macos-latest, windows-latest]
python: ["3.8", "3.9", "3.10", "3.11", "3.12"]
python: ["3.9", "3.10", "3.11", "3.12"]
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v3
Expand Down
9 changes: 3 additions & 6 deletions graphene_mongo/advanced_types.py
Original file line number Diff line number Diff line change
@@ -1,18 +1,17 @@
import base64

import graphene
from graphene_federation import shareable


@shareable # Support Graphene Federation v2
class FileFieldType(graphene.ObjectType):
content_type = graphene.String()
md5 = graphene.String()
chunk_size = graphene.Int()
length = graphene.Int()
data = graphene.String()

# Support Graphene Federation v2
_shareable = True

@classmethod
def _resolve_fs_field(cls, field, name, default_value=None):
v = getattr(field.instance, field.key)
Expand All @@ -38,12 +37,10 @@ def resolve_data(self, info):
return None


@shareable # Support Graphene Federation v2
class _CoordinatesTypeField(graphene.ObjectType):
type = graphene.String()

# Support Graphene Federation v2
_shareable = True

def resolve_type(self, info):
return self["type"]

Expand Down
Loading

0 comments on commit accd421

Please sign in to comment.