microsoftgraph / microsoftgraph/entra-powershell

🪲 Move from RequiredVersion to ModuleVersion in module manifests

Open
#1,449 10 comments 1 reaction 1 assignee View on GitHub

@KenitoInc is already working on this.

Since May 2, 2025.

Graph PowerShell Dependency Triaged
Dominant language
PowerShell
Stars
213
Forks
46
PR merge metrics
No merged PRs in 30d

Description

Describe the bug

Install-Module Microsoft.Entra
Install-Module Microsoft.Graph

The above fails, and the -AllowClobber parameter only postpones the installation error until module load-time or execution time. If any other modules/cmdlets depend on a different version of Microsoft.Graph, any Entra modules simply won't load (assembly conflicts).

The issue is caused by the Entra modules having an explicit dependency on Microsoft.Graph's corresponding modules' 2.25.0 (as of Microsoft.Entra 1.0.6), and Microsoft.Graph already has newer versions available (with bug fixes and new features).

These issues cannot be resolved by the consumer unless manually editing the installed modules' manifests to allow other versions.

Resolution:

The module declarations have to move from RequiredVersion to ModuleVersion

# Microsoft.Entra.*.psd1:

# These are currently the relevant parts in the declarations:
# Modules that must be imported into the global environment prior to importing this module
RequiredModules = @(@{ModuleName = 'Microsoft.Graph.{*ModuleName*}'; RequiredVersion = '2.25.0'; })

# Instead, it should be:
RequiredModules = @(@{ModuleName = 'Microsoft.Graph.{*ModuleName*}'; ModuleVersion  = '2.25.0'; MaximumVersion = '2.99.99'; })

See about_Module_Manifests - RequiredModules | Microsoft Learn.

This should be a simple fix.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.