Add a workflow for generating Hackday Github Discussion threads#914
Add a workflow for generating Hackday Github Discussion threads#914mfisher87 merged 4 commits intonsidc:mainfrom
Conversation
aab593c to
f0baaa6
Compare
mfisher87
left a comment
There was a problem hiding this comment.
Since this isn't a user-facing change to earthaccess, I think we should omit this from the changelog!
|
Looks great, thank you @Sherwin-14 :) |
|
@Sherwin-14 tried to do a test run and got: https://github.com/nsidc/earthaccess/actions/runs/12636855658/job/35209870757 Any ideas? |
|
Looks like the category ID doesn't exactly match. I was able to successfully query from my local machine with: Note the trailing |
|
How about we rely on secrets. this may be more flexible, what do you think?
…On Mon, 6 Jan, 2025, 10:44 pm Matt Fisher, ***@***.***> wrote:
Looks like the category ID doesn't exactly match. I was able to
successfully query from my local machine with:
gh api graphql -f query='
mutation
{createDiscussion
(
input:
{
repositoryId: "MDEwOlJlcG9zaXRvcnkzOTk4Njc1Mjk=",
categoryId: "DIC_kwDOF9V-ic4CdYaN",
body: "Reporting out on earthaccess hack days. Use the comment button at the very bottom to send a message. Additionally, consider sending issues and PRs relevant to your work to help make the job of future readers easier. It is okay to duplicate information here! Use the reply feature to have a discussion under any comment. Enjoy!",
title: "Hackathon 2025/01/06"
}
)
{
discussion {id}
}
}'
Note the trailing ! on categoryId is removed. I also needed to mess with
the quotes a little.
—
Reply to this email directly, view it on GitHub
<#914 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/BBV63P3MRC4VSJHKLS6FE3L2JK2YPAVCNFSM6AAAAABUULGINWVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDKNZTGU2TAMJQGA>
.
You are receiving this because you were mentioned.Message ID:
***@***.***>
|
|
Since these values are publicly accessible, I think it's fine to keep them as in-line envvars in the action :) Did you have another reason I'm missing? Fixed with #917 ! |
|
@mfisher87 @Sherwin-14 This is great, I'll give it a shot tomorrow! |
|
🙌 Thanks Andy! |
|
@ateucher I granted you |
|
Accepted, thanks @mfisher87 ! |
I have replaced the CATEGORY_ID and REPOSITORY_ID, though, it remains untested. (It would be funny if Github allowed me to open a discussions thread in another repository 😆)
📚 Documentation preview 📚: https://earthaccess--914.org.readthedocs.build/en/914/