Skip to content

Project Won't Validate #363

@shazaman23

Description

@shazaman23

In an org that has more than 100 projects, if your project doesn't show up in the first 100 results of Get-VsTeamProject, commands that use a project parameter fail with the error Cannot validate argument on parameter 'Project'. 'myproject' is invalid

Steps to reproduce

# Use an AZDO account with more than 100 projects in it
# Pick a project (myproject in this example) that doesn't show up when running Get-VsTeamProject
Set-VsTeamDefaultProject 'myproject' -Verbose

Expected behavior

VERBOSE: Performing the operation "Set-VSTeamDefaultProject" on target "myproject".

Actual behavior

Set-VSTeamDefaultProject: Cannot validate argument on parameter 'Project'. 'myproject' is invalid

Environment data

OS

  • macOS
  • Windows
  • Linux

Server

  • TFS 2017
  • TFS 2018
  • Azure DevOps Server
  • Azure DevOps Service
> Get-VSTeamAPIVersion
Name                           Value
----                           -----
ExtensionsManagement           6.0-preview
Version                        VSTS
Release                        5.1
Graph                          6.0-preview
DistributedTaskReleased        5.1
Pipelines                      5.1-preview
Policy                         5.1
Core                           5.1
ServiceEndpoints               5.0-preview
Tfvc                           5.1
DistributedTask                6.0-preview
Git                            5.1
MemberEntitlementManagement    6.0-preview
TaskGroups                     6.0-preview
Build                          5.1
HierarchyQuery                 5.1-preview
Packaging                      6.0-preview
VariableGroups                 5.1-preview.1
Processes                      6.0-preview
> $PSVersionTable
Name                           Value
----                           -----
PSVersion                      7.0.3
PSEdition                      Core
GitCommitId                    7.0.3
OS                             Darwin 19.6.0 Darwin Kernel Version 19.6.0: Thu Jun 18 20:49:00 PDT 2020; root:xnu-6153.141.1~1/RELEASE_X86_64
Platform                       Unix
PSCompatibleVersions           {1.0, 2.0, 3.0, 4.0…}
PSRemotingProtocolVersion      2.3
SerializationVersion           1.1.0.1
WSManStackVersion              3.0

Metadata

Metadata

Assignees

No one assigned

    Labels

    Investigatingwhen an issue needs further investigation by a maintainer. Used only by maintainer.bugwhen a bug has been identified or filed

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions