tailcallhq / tailcall

High Performance GraphQL Runtime
https://tailcall.run
Apache License 2.0
1.28k stars 248 forks source link

feat: make tailcall "GraphQL over HTTP" compliant #1766

Open tusharmath opened 5 months ago

tusharmath commented 5 months ago

Currently, tailcall doesn't support GraphQL over HTTP Spec

Technical Requirements

Additional Information Use https://graphql-http.com to check for spec compliance.

Related Issues

Use the following configuration for testing.

schema
  @server(
    port: 8000
    graphiql: true
    hostname: "0.0.0.0"
    headers: {cors: {allowOrigins: ["*"], allowHeaders: ["*"], allowMethods: [POST, GET, OPTIONS]}}
  )
  @upstream(baseURL: "http://jsonplaceholder.typicode.com") {
  query: Query
}

type Query {
  posts: [Post] @http(path: "/posts")
}

type Post {
  id: Int!
  userId: Int!
  title: String!
  body: String!
}
tusharmath commented 5 months ago

/bounty 200$

algora-pbc[bot] commented 5 months ago

💎 $200 bounty â€ĸ Tailcall Inc.

Steps to solve:

  1. Start working: Comment /attempt #1766 with your implementation plan
  2. Submit work: Create a pull request including /claim #1766 in the PR body to claim the bounty
  3. Receive payment: 100% of the bounty is received 2-5 days post-reward. Make sure you are eligible for payouts

🙏 Thank you for contributing to tailcallhq/tailcall! 🧐 Checkout our guidelines before you get started. đŸ’ĩ More about our bounty program.

Attempt Started (GMT+0) Solution
🔴 @syedbarimanjan Apr 22, 2024, 6:50:15 AM WIP
🔴 @webbdays Apr 22, 2024, 1:48:23 PM WIP
🔴 @ologbonowiwi Apr 24, 2024, 3:58:41 PM WIP
đŸŸĸ @mogery May 19, 2024, 9:39:15 AM WIP
đŸŸĸ @ssddOnTop Jul 20, 2024, 9:07:26 AM #2480
syedbarimanjan commented 5 months ago

Currently, tailcall doesn't support GraphQL over HTTP Spec

Did you mean to link this back to this issue? @tusharmath

tusharmath commented 5 months ago

@syedbarimanjan Fixed it, thanks!

webbdays commented 5 months ago

/attempt

Algora profile Completed bounties Tech Active attempts Options
@webbdays 1 tailcallhq bounty
Python, Rust,
JavaScript & more
Cancel attempt
webbdays commented 5 months ago

I would like to follow this https://graphql.github.io/graphql-over-http/draft/ . And work on one by one compliance requirement.

webbdays commented 5 months ago

Hi @tusharmath,

But that specification is still in draft. Any other specification to follow?

ologbonowiwi commented 5 months ago

I'd love to work on this. Putting myself on the queue 🤚đŸŊ

tusharmath commented 5 months ago

Hi @tusharmath,

But that specification is still in draft. Any other specification to follow?

It's going to be in the draft state for a while I think. Supporting it however will become a necessity very soon because most tooling will start depending on it.

I think the best way to start is to pick items based on the severity of the issues.

algora-pbc[bot] commented 5 months ago

@webbdays: Reminder that in 1 days the bounty will become up for grabs, so please submit a pull request before then 🙏

ologbonowiwi commented 5 months ago

@tusharmath, our playground is currently /graphql; should we change it to /graphiql so that /graphql is used as described in the spec?

tusharmath commented 5 months ago

@tusharmath, our playground is currently /graphql; should we change it to /graphiql so that /graphql is used as described in the spec?

We can use https://tailcall.run/playground/ instead of the current self hosted one.

algora-pbc[bot] commented 5 months ago

The bounty is up for grabs! Everyone is welcome to /attempt #1766 🙌

ologbonowiwi commented 5 months ago

Ok, now no one else is on the queue I'll /attempt.

Algora profile Completed bounties Tech Active attempts Options
@ologbonowiwi    32 tailcallhq bounties
+ 19 bounties from 5 projects
Rust, TypeScript,
Shell & more
Cancel attempt
webbdays commented 5 months ago

i am in. Currently working on the Accept header spec requirement. You can work parallel on other spec requirements.

webbdays commented 5 months ago

@ologbonowiwi

ologbonowiwi commented 5 months ago

Oh, sorry, @webbdays; as for the comment from the Algora bot, I thought you had dropped your attempt.

I plan to start from GET/POST on the /graphql route.

webbdays commented 5 months ago

ok. POST is must GET is optional according to spec.

webbdays commented 5 months ago

in spec 5.2 and 5.2.1 contradicts, isn't it?

webbdays commented 5 months ago

@ologbonowiwi Let me know which section numbers, you are currently plan to work? so that i can skip.

ologbonowiwi commented 5 months ago

Yeah, sure. For now, my only focus is to change the routing, so at least we can check against the app on https://graphql-http.com/

webbdays commented 5 months ago

I think the best way to start is to pick items based on the severity of the issues @tusharmath Can you mention those here as a priority list.

tusharmath commented 5 months ago

I think the best way to start is to pick items based on the severity of the issues @tusharmath Can you mention those here as a priority list.

Check out the report generated.

algora-pbc[bot] commented 5 months ago

@ologbonowiwi: Reminder that in 1 days the bounty will become up for grabs, so please submit a pull request before then 🙏

algora-pbc[bot] commented 5 months ago

The bounty is up for grabs! Everyone is welcome to /attempt #1766 🙌

mogery commented 4 months ago

/attempt #1766

Algora profile Completed bounties Tech Active attempts Options
@mogery    6 tailcallhq bounties
+ 17 bounties from 6 projects
Rust, TypeScript,
HTML & more
Cancel attempt
ssddOnTop commented 2 months ago

/attempt #1766

(there are some problems with async-graphql, will fix those first)

Algora profile Completed bounties Tech Active attempts Options
@ssddOnTop 59 tailcallhq bounties
Rust, Java,
C & more
īšŸ2389
Cancel attempt
algora-pbc[bot] commented 2 months ago

[!NOTE] The user @mogery is already attempting to complete issue #1766 and claim the bounty. We recommend checking in on @mogery's progress, and potentially collaborating, before starting a new solution.

algora-pbc[bot] commented 2 months ago

💡 @ssddOnTop submitted a pull request that claims the bounty. You can visit your bounty board to reward.

karatakis commented 2 months ago

I made this pull request to async_graphql to dictate that the extensions property is optional according to GraphQL over HTTP spec file.

https://github.com/async-graphql/async-graphql/pull/1569

karatakis commented 2 months ago

They are similar, but different approach. Lets double our chances :smile:. @ssddOnTop lets hope any of them gets accepted. Then we will be a closer step to the compliance thing.

ssddOnTop commented 2 months ago

🤷

github-actions[bot] commented 1 month ago

Action required: Issue inactive for 30 days. Status update or closure in 7 days.

github-actions[bot] commented 1 month ago

Issue closed after 7 days of inactivity.