Comments (7)
@hansbonini I'll take a look tonight. It looks like they just need to be added to https://github.com/yfilali/graphql-pynamodb/blob/master/graphene_pynamodb/converter.py
from graphql-pynamodb.
Thx, this attribute is very important.
from graphql-pynamodb.
@hansbonini Any chance you can give the change a try? I added a few tests, but I need to add more before I publish the package. It would be helpful to have someone else try it especially if you have an existing schema with List and Map attributes.
from graphql-pynamodb.
Pypi package pushed, let me know if you see any issues with the new attributes
from graphql-pynamodb.
I'll take a look! Thanks
from graphql-pynamodb.
Would you be able to add examples (in the folder) on how to create query on Map/List Attributes.
ex:
class ReceiptItem(MapAttribute):
name = UnicodeAttribute()
quantity = NumberAttribute()
price = NumberAttribute()
class Receipt(Model):
...
id = UnicodeAttribute(hash_key = True)
items = ListAttribute(null = False, of = ReceiptItem)
class User(Model):
...
name = UnicodeAttribute(null = False)
receipts = OneToMany(Receipt)
class Query(graphene.ObjectType):
node = relay.Node.Field()
all_users = PynamoConnectionField(User)
# ???
schema = graphene.Schema(query = Query, types = [User, Receipt])
not sure how to properly get the query for this. In the GraphiQL i get the memory address from the local DynamoDB as a string. I've been learning graphene-pynamodb but kind of got stuck here when trying to create this example.
...
receipts {
edges {
node {
items
}
}
}
...
in the Graphiql docs it shows up as items: [String]
<model.Receipt.ReceiptItem object at 0x10cb66550>
Any help is appreciated. Awesome Python module. :)
from graphql-pynamodb.
Same issue here, i haven't understand if is an issue of this module or if is a graphene issue, @daksharma did you solve it?
from graphql-pynamodb.
Related Issues (18)
- Handle relationships HOT 1
- Model object has no attribute 'scan' HOT 3
- Supporting Model Subclasses HOT 2
- NumberAttribute converted to INT HOT 4
- Documentation support with GraphiQL HOT 2
- Support for pynamodb 3.0.1 HOT 3
- Add some support to composite field!?
- OneToMany issue HOT 1
- Add tests for the set and json attributes
- Update code for latest PynamoDB 4.x? HOT 3
- DateTime format not ISO 8601
- Travis CI access to a dynamodb database
- Scan vs Query based on params HOT 1
- Add support for range keys in relationships
- Circular Dependencies HOT 1
- examples are not working HOT 2
- Support for graphene >= 2.0? HOT 5
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from graphql-pynamodb.