Hacktoberfest 2026: những issue maintainer đã đánh dấu cho tháng Mười, đang mở và phù hợp người mới. Xem issue Hacktoberfest

Get-AzContext error when running WorkspaceConfigToDCRMigrationTool.ps1 script

Đang mở
#173 0 bình luận 0 reaction 0 người được giao Xem trên GitHub

Chưa có ai nhận issue này.

Đánh giá

Độ khó
3/5
Thời gian dự kiến
1-2 ngày
Mức phù hợp với người mới
35/100
Loại issue
Lỗi
Độ rõ ràng
Khá rõ ràng
Mức độ hoạt động
Đình trệ
Công nghệ
powershell
Lĩnh vực
tooling

Hướng nghiên cứu

Bắt đầu với WorkspaceConfigToDCRMigrationTool.ps1 tại dòng 664 và tái hiện lỗi command-not-found trong PowerShell 7.3.4 khi đã cài đặt Az.Accounts 2.12.3. Kiểm tra cách script kỳ vọng cmdlet của Az.Accounts khả dụng; issue được hoàn tất khi script migration đi đến lệnh gọi này mà không gặp lỗi Get-AzContext.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Mô tả

Hi,

I get the following error when I run the script on Powershell 7.3.4:

Get-AzContext : The term 'Get-AzContext' is not recognized as the name of a cmdlet, function, script file, or operable
program. Check the spelling of the name, or if a path was included, verify that the path is correct and try again.
At C:\Temp\WorkspaceConfigToDCRMigrationTool.ps1:664 char:18

  • $azContext = Get-AzContext
    
  •              ~~~~~~~~~~~~~
    
    • CategoryInfo : ObjectNotFound: (Get-AzContext:String) [], CommandNotFoundException
    • FullyQualifiedErrorId : CommandNotFoundException

Module Az.Accounts is installed on version 2.12.3 and I run powershell as administrator.

Any ideas?

Best regards,

DJITS

Ngôn ngữ chính
PowerShell
Star
1.2k
Fork
493
Chỉ số merge pull request
Không có pull request nào được merge trong 30 ngày

Hướng dẫn đóng góp

Mở hướng dẫn đóng góp

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của microsoft/AzureMonitorCommunity

Tất cả issue của microsoft/AzureMonitorCommunity

Issue tương tự

Thêm issue về DevTools

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.