Team Ai
Datasetpublic

MegaBites-AI/Windows-powershell

sourceHugging Facemitupdated 6mo agoView on Hugging Face
0likes372downloads
troubleshooting-builds.instructions.md101 linesDownload Raw Back to instructions
1---2applyTo:3  - "build.psm1"4  - "tools/ci.psm1"5  - ".github/**/*.yml"6  - ".github/**/*.yaml"7---8 9# Troubleshooting Build Issues10 11## Git Describe Error12 13**Error:**14```15error MSB3073: The command "git describe --abbrev=60 --long" exited with code 128.16```17 18**Cause:** Insufficient git history (shallow clone)19 20**Solution:** Add `fetch-depth: 1000` to checkout step21 22```yaml23- name: Checkout24  uses: actions/checkout@v425  with:26    fetch-depth: 100027```28 29## Version Information Incorrect30 31**Symptom:** Build produces wrong version numbers32 33**Cause:** Git tags not synchronized34 35**Solution:** Run `Sync-PSTags -AddRemoteIfMissing`:36 37```yaml38- name: Bootstrap39  shell: pwsh40  run: |41    Import-Module ./tools/ci.psm142    Invoke-CIInstall -SkipUser43    Sync-PSTags -AddRemoteIfMissing44```45 46## PowerShell Binary Not Built47 48**Error:**49```50Exception: CoreCLR pwsh.exe was not built51```52 53**Causes:**541. Build failed (check logs)552. Wrong configuration used563. Build output location incorrect57 58**Solutions:**591. Check build logs for errors602. Verify correct configuration for use case613. Use default parameters: `Start-PSBuild`62 63## Module Restore Issues64 65**Symptom:** Slow build or module restore failures66 67**Causes:**68- Network issues69- Module cache problems70- Package source unavailable71 72**Solutions:**731. Retry the build742. Check network connectivity753. Use `-NoPSModuleRestore` if modules not needed764. Clear package cache if persistent77 78## .NET SDK Not Found79 80**Symptom:** Build can't find .NET SDK81 82**Solution:** Ensure .NET setup step runs first:83 84```yaml85- name: Setup .NET86  uses: actions/setup-dotnet@v487  with:88    global-json-file: ./global.json89```90 91## Bootstrap Failures92 93**Symptom:** Invoke-CIInstall fails94 95**Causes:**96- Missing dependencies97- Network issues98- Platform-specific requirements not met99 100**Solution:** Check prerequisites for your platform in build system docs101