这是indexloc提供的服务,不要输入任何密码
Skip to content

Conversation

@mknichel
Copy link
Member

Description

This PR writes the team ID to the repository configuration file when a user links the repository to a Space so that that team ID will be used in future requests.

Testing Instructions

npx turbo login
npx turbo link --target=spaces
less .turbo/config.json

@vercel
Copy link
Contributor

vercel bot commented Jul 19, 2023

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
turbo-site ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jul 19, 2023 1:40am
10 Ignored Deployments
Name Status Preview Comments Updated (UTC)
examples-basic-web ⬜️ Ignored (Inspect) Jul 19, 2023 1:40am
examples-cra-web ⬜️ Ignored (Inspect) Jul 19, 2023 1:40am
examples-designsystem-docs ⬜️ Ignored (Inspect) Jul 19, 2023 1:40am
examples-gatsby-web ⬜️ Ignored (Inspect) Jul 19, 2023 1:40am
examples-kitchensink-blog ⬜️ Ignored (Inspect) Jul 19, 2023 1:40am
examples-native-web ⬜️ Ignored (Inspect) Jul 19, 2023 1:40am
examples-nonmonorepo ⬜️ Ignored (Inspect) Jul 19, 2023 1:40am
examples-svelte-web ⬜️ Ignored (Inspect) Jul 19, 2023 1:40am
examples-tailwind-web ⬜️ Ignored (Inspect) Jul 19, 2023 1:40am
examples-vite-web ⬜️ Ignored (Inspect) Jul 19, 2023 1:40am

)
})?;

fs::create_dir_all(base.repo_root.join_component(".turbo"))
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@nathanhammond @gsoltis While testing, I discovered that link --target=spaces wasn't writing the selected team ID to .turbo/config.json. I ran into a situation where I had linked the repo for Remote Caching to another team and when I tried to enable Spaces, it wasn't generating any Runs data because it was trying to use the wrong team ID on subsequent requests.

I'm wondering what you recommend to do. We could ask the user if they want to override the team ID if the user tries to select a team that is different than the one that is already configured for the repository, we could show an error if the team ID that is already configured is different than the selected one, or we could store the team IDs for remote cache and spaces in separate fields. Thoughts?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@github-actions
Copy link
Contributor

github-actions bot commented Jul 19, 2023

🟢 CI successful 🟢

Thanks

kodiakhq bot pushed a commit that referenced this pull request Aug 21, 2023
Supersedes #5561 

Write and use a configuration for a Spaces API client. It's not
graceful, but allows for isolated configuration.

Review ignoring whitespace:
https://github.com/vercel/turbo/pull/5674/files?w=1

---------

Co-authored-by: Nathan Hammond <Nathan Hammond>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants