Cannot install the PackageManagement module in Powershell 7.4.4. (The version ‘1.4.8.1’ of module ‘PackageManagement’ is currently in use)

I am trying to install PackageManagement in Powershell 7.4.4.

I’ve enabled Tls2, Set PSGallery to trusted, and set my execution policy to RemoteSigned (Scope: LocalMachine)

Set-ExecutionPolicy -ExecutionPolicy RemoteSigned -Scope LocalMachine
Set-PSReposiotory -Name PSGallery -InstallationPolicy Trusted
[System.Net.ServicePointManager]::SecurityProtocol = [System.Net.ServicePointManager]::SecurityProtocol -bor [System.Net.SecurityProtocolType]::Tls12

I’m now trying to install PackageManagement and PowerShellGet with the following:

Install-Module -Name PackageManagement -Repository PSGallery -Force
Install-Module -Name PowerShellGet -Repository PSGallery -Force -AllowClobber

But when I run the PackageManagement install, I get an error:

WARNING: The version '1.4.8.1' of module 'PackageManagement' is currently in use. Retry the operation after closing the applications.

Get-Module packagemanagement -ListAvailable returns this:

Directory: C:program filespowershell7Modules

ModuleType Version    PreRelease Name                                PSEdition ExportedCommands
---------- -------    ---------- ----                                --------- ----------------
Script     1.4.8.1               PackageManagement                   Desk      {Find-Package, Get-Package, Get-PackageProv…

So Pwsh is using the PackageManagement 1.4.8.1 script located in C:program filespowershell7Modules.

But when I run Get-InstalledModule, only PowerShellGet (v2.2.5) shows up, without PackageManagement. At least I got the required PowerShellGet version installed, but unfortunately the way PackageManagement is being loaded seems to be defective. Currently Install-Module is broken.

Example: When I run Install-Module [AnyModuleName], the module doesn’t install. I have to add the -Force switch for the module to actually install.

I have a feeling that I need to remove or sidestep the PackageManagement version located in C:program filespowershell7Modules, and actually INSTALL the PackageManagement module. It should appear when I run Get-InstalledModule.

Regarding the NuGet provider, the correct assemblies are located at C:Program FilesPackageManagementProviderAssembliesnuget2.8.5.208Microsoft.PackageManagement.NuGetProvider.dll

Powershell also states:

You can also install the NuGet provider by running ‘Install-PackageProvider -Name NuGet -MinimumVersion 2.8.5.201 -Force’.

So I tried that command: Install-PackageProvider -Name NuGet -MinimumVersion 2.8.5.201 -Force

But Pwsh spits out this error:

Install-PackageProvider: No match was found for the specified search criteria for the provider 'NuGet'. The package provider requires 'PackageManagement' and 'Provider' tags. Please check if the specified package has the tags.

Lastly, here is my PSModulePath environment variable:

I am at my wits end here. I’ve been trying to solve this problem for the last four hours with no success.

I would REALLY appreciate any help getting this issue resolved.

Thanks for any assistance.

Trang chủ Giới thiệu Sinh nhật bé trai Sinh nhật bé gái Tổ chức sự kiện Biểu diễn giải trí Dịch vụ khác Trang trí tiệc cưới Tổ chức khai trương Tư vấn dịch vụ Thư viện ảnh Tin tức - sự kiện Liên hệ Chú hề sinh nhật Trang trí YEAR END PARTY công ty Trang trí tất niên cuối năm Trang trí tất niên xu hướng mới nhất Trang trí sinh nhật bé trai Hải Đăng Trang trí sinh nhật bé Khánh Vân Trang trí sinh nhật Bích Ngân Trang trí sinh nhật bé Thanh Trang Thuê ông già Noel phát quà Biểu diễn xiếc khỉ Xiếc quay đĩa Dịch vụ tổ chức sự kiện 5 sao Thông tin về chúng tôi Dịch vụ sinh nhật bé trai Dịch vụ sinh nhật bé gái Sự kiện trọn gói Các tiết mục giải trí Dịch vụ bổ trợ Tiệc cưới sang trọng Dịch vụ khai trương Tư vấn tổ chức sự kiện Hình ảnh sự kiện Cập nhật tin tức Liên hệ ngay Thuê chú hề chuyên nghiệp Tiệc tất niên cho công ty Trang trí tiệc cuối năm Tiệc tất niên độc đáo Sinh nhật bé Hải Đăng Sinh nhật đáng yêu bé Khánh Vân Sinh nhật sang trọng Bích Ngân Tiệc sinh nhật bé Thanh Trang Dịch vụ ông già Noel Xiếc thú vui nhộn Biểu diễn xiếc quay đĩa Dịch vụ tổ chức tiệc uy tín Khám phá dịch vụ của chúng tôi Tiệc sinh nhật cho bé trai Trang trí tiệc cho bé gái Gói sự kiện chuyên nghiệp Chương trình giải trí hấp dẫn Dịch vụ hỗ trợ sự kiện Trang trí tiệc cưới đẹp Khởi đầu thành công với khai trương Chuyên gia tư vấn sự kiện Xem ảnh các sự kiện đẹp Tin mới về sự kiện Kết nối với đội ngũ chuyên gia Chú hề vui nhộn cho tiệc sinh nhật Ý tưởng tiệc cuối năm Tất niên độc đáo Trang trí tiệc hiện đại Tổ chức sinh nhật cho Hải Đăng Sinh nhật độc quyền Khánh Vân Phong cách tiệc Bích Ngân Trang trí tiệc bé Thanh Trang Thuê dịch vụ ông già Noel chuyên nghiệp Xem xiếc khỉ đặc sắc Xiếc quay đĩa thú vị
Trang chủ Giới thiệu Sinh nhật bé trai Sinh nhật bé gái Tổ chức sự kiện Biểu diễn giải trí Dịch vụ khác Trang trí tiệc cưới Tổ chức khai trương Tư vấn dịch vụ Thư viện ảnh Tin tức - sự kiện Liên hệ Chú hề sinh nhật Trang trí YEAR END PARTY công ty Trang trí tất niên cuối năm Trang trí tất niên xu hướng mới nhất Trang trí sinh nhật bé trai Hải Đăng Trang trí sinh nhật bé Khánh Vân Trang trí sinh nhật Bích Ngân Trang trí sinh nhật bé Thanh Trang Thuê ông già Noel phát quà Biểu diễn xiếc khỉ Xiếc quay đĩa
Thiết kế website Thiết kế website Thiết kế website Cách kháng tài khoản quảng cáo Mua bán Fanpage Facebook Dịch vụ SEO Tổ chức sinh nhật