Skip to content
This repository has been archived by the owner on Nov 6, 2020. It is now read-only.

Non-English version of the TF Executable #192

Closed
pwaller24 opened this issue Apr 26, 2017 · 19 comments
Closed

Non-English version of the TF Executable #192

pwaller24 opened this issue Apr 26, 2017 · 19 comments

Comments

@pwaller24
Copy link

I am getting this message when I update the VS Code settings with the full path to the TF executable. I have VS 2015 Enterprise installed. It is the version from my MSDN subscription. Attempting to use the latest version of the TEE tf.cmd does not work as well.

@scaillerie
Copy link

Yes, there is an issue with non-english language, but you can use this workaround or look at this thread in order to solve your issue.

Basically, you have to rename the localization folder for your language in order to force TF.exe to be in english...

@pwaller24
Copy link
Author

Not sure that applies in this case. I don't have anything installed other than English.

@jeffyoung
Copy link
Contributor

HI @pwaller24, thanks for trying out the extension.

I'd be interested in seeing the output (as much as you can show) from this command (from a command prompt): tf.exe workfold {path-to-the-folder-you-opened}. I suspect that it won't display the English version of Workspace :.

Also, I'd be really interested in confirming that you saw the same error with the TEE CLC (tf.cmd). We explicitly set an environment variable to force it to return English strings (something that tf.exe is missing).

@pwaller24
Copy link
Author

Here you go @jeffyoung:

C:>"C:\Program Files (x86)\Microsoft Visual Studio 14.0\Common7\IDE\TF.exe" workfold "C:\TFS\P2 Portfolio\Oil and Gas Accounting\Enterprise Upstream\EU\Main"

=============================================================================================================================================================
Workspace : DPDW0324 (Waller, Pete)
Collection: https://tfsprod.p2energysolutions.com/tfs/safe
$/P2 Portfolio/Oil and Gas Accounting/Enterprise Upstream/EU/Main: C:\TFS\P2 Portfolio\Oil and Gas Accounting\Enterprise Upstream\EU\Main

I ran it with the fully qualified path to TF.exe.

@jeffyoung
Copy link
Contributor

Thanks @pwaller24. I'm glad I'm not a betting man (or I would have lost).

I certainly can't tell why you would get the error about the non-ENU tf.exe. I do see that you're using https and I currently have a bug where the extension cannot connect using NTLM over HTTPS (#59). However, I've added some additional logging to the attached private drop of the extension. I'd appreciate it if you could install it, turn on debug logging and provide the results. Hopefully the log will shed some light on the problem.

So in order to install this private drop, you need to uninstall the current extension and then side-load this VSIX. After downloading the ZIP file, you'll need to rename it by dropping the .ZIP extension. Then, after selecting the Extension viewlet, click the ... menu, choose Install from VSIX... and then select that VSIX file.

team-0.117.0.vsix.zip

But back to the HTTPS issue, what version of TFS are you connecting to?

@pwaller24
Copy link
Author

Here is the log file from making those changes.
We are connecting to an on-prem TFS 2017 instance.
team-extension.log.txt

@jeffyoung
Copy link
Contributor

Thanks for the quick turnaround!

For whatever reason, we're having trouble parsing the results of our "GetVersion" command. All that does is parse the results of tf.exe add -noprompt -?. Could you run that locally using the path to your tf.exe (C:\Program Files (x86)\Microsoft Visual Studio 14.0\Common7\IDE\TF.EXE) and provide the results?

And thanks for confirming your version of TFS.

@pwaller24
Copy link
Author

Happy to help get this sorted out!

Here are the results:

C:\Program Files (x86)\Microsoft Visual Studio 14.0>"C:\Program Files (x86)\Microsoft Visual Studio 14.0\Common7\IDE\TF.EXE" add -noprompt -?
Microsoft (R) TF - Team Foundation Version Control Tool, Version 14.98.25331.0
Copyright (c) Microsoft Corporation. All rights reserved.

Adds new files and folders from a local file system location to Team Foundation
version control.

tf vc add [itemspec] [/lock:(none|checkin|checkout)] [/encoding:filetype]
[/noprompt] [/recursive] [/noignore] [/login:username,[password]]

@jeffyoung
Copy link
Contributor

Thanks. I've attached yet another private build here. The line that contains the version value looks good. The regex we use finds the version in the string that's there just fine at regex101. But we still don't find it. Maybe logs from this particular private build will show the truth.

team-0.117.0.vsix.zip

@pwaller24
Copy link
Author

Ok, gave that a try and here is the log:

team-extension.log.txt

@jeffyoung
Copy link
Contributor

😮 OK. Can you tell me what version of Visual Studio you're using? I see in the command line (which we should be parsing successfully) this version value: Version 14.98.25331.0. But could you open Visual Studio and send a screenshot of the Help | About box? Something like this:

image

I'm going to see if I can find the same version and debug this. (For the record, the reason we error out with that message is because we figured we couldn't parse the version out of that command line. But we figured that would only happen in a couple of cases. Looking at the output you provided, I don't see a reason why it should fail especially since the regex pulls it out just ine.)

@pwaller24
Copy link
Author

Here is the information:

image

@jeffyoung
Copy link
Contributor

Thanks @pwaller24. I added a bit more logging and beefed up the regex a bit (to fix a scenario that could fail it).

Could you try this one and provide the results (please delete the existing team-extension.log before re-running).

team-0.117.0.vsix.zip

(I'm pulling my hair out over this! 😄)

@pwaller24
Copy link
Author

Thanks for looking into it....

team-extension.log.txt

@jeffyoung
Copy link
Contributor

OK. It appears that the version of TF.exe you're using is writing more to stdout than we ever expected. 😄

It took a while but I've now got what I believe to be the changes we need to properly parse the version string out of stdout. (I've also used your output, without any PII, as inputs into a new unit test for our version parsing code.)

Here's what should be the last one (fingers crossed).

team-0.117.0.vsix.zip

@pwaller24
Copy link
Author

I think that's got it! No message this time.

team-extension.log.txt

@jeffyoung
Copy link
Contributor

Great, thanks for confirming! I submitted a PR with the fix.

A couple of other things though. First, your server is configured for HTTPS which I have an issue tracking support for (#59). Since you're using TFS 2017, I may have a different solution there. Also, I see that the version of TF.exe you're using apparently doesn't support the 'xml' value for the format option of the status command (TFVC errors: TF10120: The value xml is not supported for option format.). You've got VS 2015 Update 3 installed (although it shows a version different than mine, shown above). Our TFVC support is predicated on parsing XML output so we're going to have to determine a minimum supported version of tf.exe. I don't think there's a later version than Update 3 but I'm not sure why your version isn't what mine is. 😕

@pwaller24
Copy link
Author

My version of VS is from MSDN. Would that be the difference? Thanks for getting it fixed. I'll look for an update on the HTTPS issue.

@jeffyoung
Copy link
Contributor

Well, after digging through this for most of the day, this is apparently what happened. Our TFVC support requires the ability to output 'xml' from the status command (and likely others) so we can parse it in a consistent way. The initial VS 2015 Update 3 shipped with a version of tf.exe that doesn't have this support. (We developed the feature using a version of tf.exe from VS 2015 that did have the support and went ahead and just assumed all 14.0.0-based versions of tf.exe had that support. That wasn't correct but we didn't know it to be true.)

VS 2015 U3 shipped with a version of tf.exe close to what you have (14.98.25331.0; as shown in the output of your add -noprompt -? command, not the version of Visual Studio). Some time later, we released the version of tf.exe that has that 'xml' support. There have been several updates to Update 3 (called Cumulative Servicing Releases or CSRs) that contain later versions of tf.exe, including the one that has the 'xml' support we rely upon. The latest version of the CSR contains a 14.102 version of tf.exe (that has the 'xml' support).

I've got a PR out (#199) that will detect a version lower than 14.102 and provide a button to click that takes you to that CSR page with download instructions. And even though you might have a version of the CSR already installed (as it looks like you already do), you can re-install it with the download link and get a later version with additional updates to ensure you have the latest fixes.

(And I think @MindGirl may have run into this issue once before in #179).

I'll get this PR into the next release of the extension soon. Thanks again @pwaller24.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants