-
Notifications
You must be signed in to change notification settings - Fork 359
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
Potential Contribution for Issue #496 #1158
Conversation
…e tag to match target replacement filename.
Hi @AustinHull, I'm your friendly neighborhood Microsoft Pull Request Bot (You can call me MSBOT). Thanks for your contribution! TTYL, MSBOT; |
Thanks for the contribution! However it looks like you forked the Instead, create a new branch off # Create new branch from master
git checkout -b fix-for-496 master
# Apply your change to the new branch
git cherry-pick 3f03b1d Regarding getting a build for testing, were you following our build instructions. Was anything unclear in these instructions or could they be improved? What are the errors you are currently seeing? If you need to, you can always grab a build from AppVeyor as well under the Being able to test locally would be much faster however, so let's see if we can get you started with that. |
Hello mjbvz, thank you for all the helpful advice and feedback, I really appreciate it! I'm working on porting my commit to a new branch now, just as you've said, but I do seem to still be rather confused on how the testing of this project works, considering it's a VS extension. I downloaded the AppVeyor build, but I'm not too sure where I'm supposed to put it in order to test my results. I've managed to startup the Experimental Instance of VS via the dev console, but that's about as far as I could get from the documentation provided. As for getting the build to run locally, I have tried my best to follow the build instructions posted, but I'm wondering if my issues may be stemming from Part 2 of that process. No matter what I do to try and elevate cmd.exe to admin access, I can never seem to execute the *.ps1 file for environment setup (the prompt keeps telling me - despite my admin privileges. that I do not have permission to access the file), so I attempted to follow the manual alternative, running the registry file to enable the verification skip, and placing the .target file in the specified VS folders (I seem to have three different version folders within my VisualStudio directory). Thank you again! |
Using the appveyor build, you should just be able to run the installer msi. Again, this is an unsigned build and installing this way is not recommended, but it should work. Can you also copy paste the error you are seeing to provide some more context so we can diagnose the problem. Thanks. |
Oh, of course, thank you! The errors I seem to be getting while building NodejsTools.sln are: 3>CSC : error CS0006: Metadata file 'C:\Users\austi_000\Documents\nodejstools\BuildOutput\Debug14.0\Tests\TestUtilities.UI.dll' could not be found 3>CSC : error CS0006: Metadata file 'C:\Users\austi_000\Documents\nodejstools\BuildOutput\Debug14.0\Tests\TestUtilities.UI.dll' could not be found 5>CSC : error CS0006: Metadata file 'C:\Users\austi_000\Documents\nodejstools\BuildOutput\Debug14.0\Tests\TestUtilities.UI.dll' could not be found 11>CSC : error CS0006: Metadata file 'C:\Users\austi_000\Documents\nodejstools\BuildOutput\Debug14.0\Tests\TestUtilities.UI.dll' could not be found 11>CSC : error CS0006: Metadata file 'C:\Users\austi_000\Documents\nodejstools\BuildOutput\Debug14.0\Tests\TestUtilities.UI.Nodejs.dll' could not be found 8>CSC : error CS0006: Metadata file 'C:\Users\austi_000\Documents\nodejstools\BuildOutput\Debug14.0\Tests\TestUtilities.UI.Nodejs.dll' could not be found 9>CSC : error CS0006: Metadata file 'C:\Users\austi_000\Documents\nodejstools\BuildOutput\Debug14.0\Tests\TestUtilities.UI.dll' could not be found 9>CSC : error CS0006: Metadata file 'C:\Users\austi_000\Documents\nodejstools\BuildOutput\Debug14.0\Tests\TestUtilities.UI.Nodejs.dll' could not be found 14>CSC : error CS0006: Metadata file 'C:\Users\austi_000\Documents\nodejstools\BuildOutput\Debug14.0\Tests\TestUtilities.UI.dll' could not be found 14>CSC : error CS0006: Metadata file 'C:\Users\austi_000\Documents\nodejstools\BuildOutput\Debug14.0\Tests\TestUtilities.UI.Nodejs.dll' could not be found I haven't deleted any files from the project, so I'm not sure why these files aren't being found, but I don't have as much experience with DLLs as I would prefer to have, so maybe I made a simple setup mistake? Thank you again for all your help! |
On installing the AppVeyor build, I've noticed that my change hasn't solved the problem, BUT I have noticed that properly functioning project templates seem to each create a folder dedicated to each project within VS's Projects folder, whereas the FromExistingCode project template does not. Perhaps I can look into this as a possible cause. |
@AustinHull For the build, are you running the commands from a vs developer command prompt? Can you share the output from running these commands:
and
Do any of the referenced files from the error exist? It may be helpful if you could share the entire output from running msbuild, starting with the msbuild command itself. As for the fix, I'm actually not sure of what the root cause of the problem is, so identifying what is different between this template and the other templates sounds like a great starting point. Keep in mind that Vs does cache templates, which can cause problems while testing, so make sure you run It'd be best if you can get building NTVS in VS directly since that allows testing changes much more quickly. What errors were you seeing that prevented that from working? |
@mjbvz Alright, heres the output from the command prompt:
Additionally, the entire Build Log is comprised of the following:
When checking for the files being referenced in the errors, I seem to find almost-matching files, except for some reason they seem to be missing the .UI. portion of their file names. I'll instead find a file named "TestUtilities.Nodejs.dll", for example. Thanks! |
The initial error seems to be: 2>C:\Program Files (x86)\MSBuild\14.0\bin\Microsoft.Common.CurrentVersion.targets(1820,5): warning MSB3245: Could not resolve this reference. Could not locate the assembly "Microsoft.VisualStudioTools.VSTestHost.14.0, Version=14.0.1.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL". Check to make sure the assembly exists on disk. If this reference is required by your code, you may get compilation errors. Did you run the Those errors are in the test projects thought and shouldn't prevent you from building and running NTVS itself through visual studio. Is anything blocking you from doing that currently? |
Ah, looks like executing the VSTestHost.msi installer did the trick! My builds are now yielding 27 successes with 0 failures. Thank you again for taking the time to walk me through that, I greatly appreciate it! Now I'm presuming I can run this build by switching the solution to Release mode, building that, and then running a sort of installer just like I did through the build yielded by AppVeyor? |
Good to hear that worked. You should be able to build, launch, and debug NTVS all from within Visual Studio itself. In the nodejstools solution, make sure to set NodeJs as your startup project in VS ( https://msdn.microsoft.com/en-us/library/a1awth7y.aspx?f=255&MSPPError=-2147217396 ) by right clocking on the NodeJs project node and selecting "set as startup project". Then simply hit debug and VS will build NTVS and install in in an experimental Visual Studio Instance that you can debug. Let me know if that works. |
Yes, it seems to be working for me now, thank you! I've also managed to determine, by manually creating a "FromExistingCode1" folder in the Projects directory, the wizard will then appropriately set the default name for the subsequent project as "FromExistingCode2". Unfortunately, even setting the "CreateNewFolder" tag of the FromExistingCode.vstemplate file doesn't seem to automatically create the project folder as I was hoping, so I'm going to have to look into that further. Thank you again for all the help! I suppose you could close this PR if you'd like, since I'm still in the process of looking for a solution. |
Ok, I'm going to close this issue since, as I mentioned, you should start working off of the I recommend started with at |
Issue #496
Hello everyone!
Full Disclosure: I'm a second-year CS undergrad who is extremely new to open-source software development, but I've really been wanting to get involved with it for some time, so being a fan of MS, I hoped I might be found to be of even a little use here.
Looking in the issues list, I noticed one (#496) mentioning a problem with the project template not generating a proper, unique default project name for each subsequent project creation of the type "From Existing Code".
My experience with this software's code is extremely limited, but looking through MSDN's documentation for *.vstemplate files, as well as comparing the template code for the aforementioned type with that of other types - such as NodeJS WebApp - I've noticed that the tag used in the bugged project type differs from the name of the target file checked within the tags, unlike with other project types. In an effort to possibly fix this, I've changed the tag to "FromExistingCode" to match the name of the target file ("FromExistingCode.njsproj").
While I'm aware that I should be testing this on my end, I'm afraid that even after pulling an all-nighter trying to get the cloned builds working on my system, I still seem to be getting about 9 build errors out of 27 total builds, mostly because of some "TestUtilities.UI.dll" files it appears. If anyone could try to splice the content of this commit into their own working build to possibly test at their convenience, I would be extremely appreciative to hear of their results and feedback. Again, I do apologize if I'm coming off as rude, burdensome, or hindering with regards to this project's workflow - I'm just trying to dip my toes into open-source contributing in any way I can, and your time and feedback is greatly appreciated in helping me become a better software developer for the future!
Best Regards,
Austin Hull, Drexel University, Philadelphia