Skip to content

Recommendation: add SQLAlchemy session object context_value in README #5

Open
@Diggitysc

Description

@Diggitysc

Thank you for creating such a great library. This is a huge benefit to my project.

That being said, I had to jump through a few hoops to figure out how to get querying up and running for the graphiql interface (with SQLalchemy running the backend models and linked into the database session/transaction manager)

I was finally able to get everything wired up by setting the following:
return serve_graphql_request(request, schema, context_value={'session': request.dbsession}, graphiql_enabled=True)

It would be helpful to list for other SQLAlchemy users who want a quick graphql interface via webob instead of flask.

Thank you guys for all your hard work

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions