-
Notifications
You must be signed in to change notification settings - Fork 7
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Arihan/mar 31 summarize and upsert code snippets from reposplitter #57
Arihan/mar 31 summarize and upsert code snippets from reposplitter #57
Conversation
arihanv
commented
Dec 6, 2023
- Automatically write and upsert short summaries of code chunks
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
maige could you review this? |
maige test |
maige comment |
lib/utils/embeddings/embed.ts
Outdated
@@ -42,16 +43,17 @@ export default async function addRepo( | |||
process.env.GITHUB_ACCESS_TOKEN || '' | |||
) | |||
|
|||
const docs = repo.map(doc => { | |||
const docs = Promise.all(repo.map(async doc => { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
.map(async () => { await someFunc() }
might not actually wait
I believe the only JS for loop that respects async-await is for (const doc or repo) { await someFunc() }
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
.map(async () => { await someFunc() } -> Why does it not?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM 🚢
after the map(async...
issue is resolved we're good to go
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM