You're on your way to the next level! Join the Kudos program to earn points and save your progress.
Level 1: Seed
25 / 150 points
1 badge earned
Challenges come and go, but your rewards stay with you. Do more to earn more!
What goes around comes around! Share the love by gifting kudos to your peers.
Keep earning points to reach the top of the leaderboard. It resets every quarter so you always have a chance!
Join now to unlock these features and more
I am currently trying to use MSBuild to build out a test project. For some reason it keeps giving me errors:
Class name : error CS0246: The type or namespace name 'ClosedXML' could not be found (are you missing a using directive or an assembly reference?)
But all the references are there within the project. I even uninstalled\reinstalled the NuGet packages and pushed the changes to my branch and it still will not build. I am new to Bamboo and have tried looking at the documentation and tried to find videos on this, and I haven't found anything.
Usually Bamboo tasks are just wrappers for external commands and should give you the same results you get from the terminal, this is why I'm asking you to check this from your terminal first.
You may try navigating to the build working directory right after the failed build and try to run the MSBuild from there.
Hi, @Daniel Santos
Sorry for the late reply, So I was able to get somewhat of the project to build now, found out I had to reload the nuget packages before the build. Also had to install frameworks for it to build projects. Still, on that part, the build keeps erroring out on errors like this:
C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\MSBuild\15.0\Bin\amd64\Microsoft.Common.CurrentVersion.targets(1179,5): error MSB3644: The reference assemblies for framework ".NETFramework,Version=v4.6.2" were not found. To resolve this, install the SDK or Targeting Pack for this framework version or retarget your application to a version of the framework for which you have the SDK or Targeting Pack installed.
So the main question is for Bamboo to actually build the project with no issues, would I need VS installed on the same server, manually build it on the server to make sure it works and then hook up bamboo to build the project? Currently, I can build the solution perfectly fine on my dev machine
Let me highlight 2 points that in my opinion usually need more attention:
Please check if the variables that you have in your terminal are the same ones you have when running the build. If the build is running on terminal it should also run in Bamboo, it just need small adjustments.
Not a 100% sure what you mean by Windows environment variables. I don't know if I explained the issue correctly. The problem we're currently running into is that the build keeps failing on Bamboo because of Assembly references for .NetFramework versions. Off our Bamboo server and on my local machine I am able to check out our Git repository and have no issues building the entire solution. I build it through VS17, but some projects are still targetted for VS15. The difference on the Bamboo server is that we do not have VS installed, so I am wondering if that's what we would need to do, because when you install VS you select multiple frameworks that you need and would get installed. As of right now, we have been having to individually install the frameworks, because of each error we're receiving. Ideally, we don't want to install VS on the server because of space and integrity of the server. I'm not sure to resolve this type of issue if there are any other ways to resolve this, with having to install VS