tailcall icon indicating copy to clipboard operation
tailcall copied to clipboard

refactor: re-write `gen_gql_schema.rs`

Open tusharmath opened this issue 11 months ago • 9 comments

Current implementation takes a schemars and directly writes a .graphql file. The expectation is to create a async_graphql::ServiceDocument and then leverage the crate::document::print to print it.

Expectations

  • Rewrite the module to create a ServiceDocument and use document::print to print it.
  • Drop all the write! calls from gen_gql_schema.rs
  • Split the large file into smaller logical files that's easy to understand.
  • Write documentation for different files and modules created.
  • Make sure the final generated file doesn't change.

tusharmath avatar Mar 19 '24 14:03 tusharmath

/bounty 250$

tusharmath avatar Mar 19 '24 14:03 tusharmath

💎 $250 bounty • Tailcall Inc.

Steps to solve:

  1. Start working: Comment /attempt #1510 with your implementation plan
  2. Submit work: Create a pull request including /claim #1510 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
🟢 @harshbisle Mar 19, 2024, 3:34:45 PM WIP
🔴 @benya9 May 15, 2024, 8:36:04 AM WIP
🔴 @Sambit003 May 18, 2024, 8:16:25 AM WIP
🔴 @snigdha510 May 22, 2024, 5:02:36 AM WIP
🔴 @asr2003 May 22, 2024, 6:34:39 AM WIP
🟢 @bnchi #2297

algora-pbc[bot] avatar Mar 19 '24 14:03 algora-pbc[bot]

/attempt #1510

Algora profile Completed bounties Tech Active attempts Options
@harshbisle 5 bounties from 2 projects
TypeScript, HTML,
JavaScript & more
Cancel attempt

harshbisle avatar Mar 19 '24 15:03 harshbisle

@harshbisle Go for it.

tusharmath avatar Mar 20 '24 05:03 tusharmath

@harshbisle Go for it.

On it!

harshbisle avatar Mar 20 '24 05:03 harshbisle

@tusharmath, we have a limitation, though: our From<Config> for ServiceDocument accounts only for filled fields.

I see two ways we can go for this:

  1. Write a new version accounting for the empty fields to generate the .graphql based on the ServiceDocument
  2. Fill all the fields so we have the filled version and can quickly run .to_sdl()

The second option looks the worst to me as every new field would require changing the "mock" values, which is sort of what we do today (when adding directives). Let me know if 1. makes sense or if you have any other ideas to accomplish this.

ologbonowiwi avatar Apr 23 '24 17:04 ologbonowiwi

No one assigned. Can i work on it?

VasuDevrani avatar May 03 '24 03:05 VasuDevrani

/attempt #1510

Options

ghost avatar May 15 '24 08:05 ghost

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

algora-pbc[bot] avatar May 15 '24 08:05 algora-pbc[bot]

/attempt #1510

Options

Sambit003 avatar May 18 '24 08:05 Sambit003

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

algora-pbc[bot] avatar May 18 '24 08:05 algora-pbc[bot]

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

algora-pbc[bot] avatar May 19 '24 08:05 algora-pbc[bot]

/attempt #1510

Algora profile Completed bounties Tech Active attempts Options
@snigdha510
Jupyter Notebook, JavaScript,
CSS & more
Cancel attempt

snigdha510 avatar May 22 '24 05:05 snigdha510

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

algora-pbc[bot] avatar May 22 '24 05:05 algora-pbc[bot]

/attempt #1510

Options

asr2003 avatar May 22 '24 06:05 asr2003

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

algora-pbc[bot] avatar May 23 '24 05:05 algora-pbc[bot]

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

algora-pbc[bot] avatar May 23 '24 06:05 algora-pbc[bot]

@harshbisle I'm interested in this project and I see that it hasn't been completed yet. Let me know if you're open to collaboration. Otherwise, as there's nobody assigned to this, I'd like to just get started. Thanks

nickelulz avatar May 27 '24 19:05 nickelulz

Is this resolved ?

Subh231004 avatar Jun 09 '24 12:06 Subh231004

I am interested in doing this. Please confirm whether this is still up for grabs or not (given it has been 3 months this issue was opened and a month since a PR was created)

0xa48rx394r83e9 avatar Jun 23 '24 22:06 0xa48rx394r83e9

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

algora-pbc[bot] avatar Jun 27 '24 12:06 algora-pbc[bot]

@bnchi: You've been awarded a $250 bounty by tailcallhq! 👉 Complete your Algora onboarding to collect the bounty.

algora-pbc[bot] avatar Jul 08 '24 14:07 algora-pbc[bot]

🎉🎈 @bnchi has been awarded $250! 🎈🎊

algora-pbc[bot] avatar Aug 08 '24 07:08 algora-pbc[bot]