Search code examples
.net.net-corecontinuous-integrationappveyor

AppVeyor cannot find project or solution file


I am using AppVeyor as CI for an open-source .NET Core project. The appveyor.yml file looks like follows, which was based on the reference example.

# Version format
version: 1.0.{build}

# Build worker image
image: Visual Studio 2017

# Build platform
platform: Any CPU

# Build Configuration
configuration: Debug

# MSBuild settings
build:
  project: src\PROJECT.sln
  verbosity: quiet

# Execute script before build
before_build:
 - nuget restore src\PROJECT.sln

# Omitted the tests, as they are not relevant for the question

While the above configuration worked correctly in the past, I made a few changes to the codebase after a year of "pause" on the project and pushed the new commit to GitHub. Now I get the following error message from AppVeyor, after the nuget restore command is executed:

Specify which project or solution file to use because the folder contains more than one project or solution file.

I don't really get what could be the issue, since the build system of the project did not change at all, and it was working perfectly before. The proper solution file to use is given in the configuration and I verified that the path is correct:

build:
  project: src\PROJECT.sln

I have limited knowledge and experience with AppVeyor, but according to the mentioned example configuration, it should work fine. Thanks for any suggestions or ideas.


Solution

  • It turned out that the OAuth token got "stale". Removing GitHub authorization from AppVeyor, then authorizing GitHub again solved the issue.