问题
I've recently had a TFS 2015 to 2017 upgrade, and now I have this error whenever I try to do a Source Control->Annotate from the Visual Studio Solution Explorer:
Annotation Error
m_itempath or m_versionControl not set
If I try to run the annotate from the file editor, I get the different error:
Annotation Error
Unable to determine the workspace for the file C:\...
Using Visual Studio Enterprise 2015. This is a Server workspace, and all other operations seem to work as normal.
回答1:
Most of the solutions in
- Is there workaround for when TFPT is "unable to determine the workspace" and refreshing the cache does not work?
- TFS Error: Unable to determine the workspace for this solution
failed to work for me.
This did work:
- Go to Source Control Explorer
- Right-click on the mapped folder
- Select 'Advanced->Remove Mapping' and follow prompts. Ignore conflict screens.
- Select 'Advanced->Map to Local Folder' and map back to the existing folder.
- Resolve any outstanding conflicts.
After this, the annotations worked again.
来源:https://stackoverflow.com/questions/45688981/tfs-annotation-error