Skip to content

Conversation

Copy link
Contributor

Copilot AI commented Jul 11, 2025

The BCP081 warning about missing resource types was not providing clear enough information about why the warning occurs and what the specific impacts are for users. The original message was too generic and left users confused about whether deployment would work and what functionality they would lose.

Problem

Users seeing the BCP081 warning were asking:

  • Why does this happen?
  • What are the actual impacts?
  • Can I still deploy my template?
  • Where can I get help or workarounds?

The previous message was:

Resource type "Microsoft.Web/serverfarms/firstPartyApps/settings@2019-08-01" does not have types available. Bicep is unable to validate resource properties prior to deployment, but this will not block the resource from being deployed.

Solution

Updated the diagnostic message to be more explicit and helpful:

Resource type "Microsoft.Web/serverfarms/firstPartyApps/settings@2019-08-01" does not have types available. Either the type or version does not exist, or Bicep does not yet know about it. This does not prevent attempting deployment, but does mean Bicep may not be able to provide IntelliSense or detect potential errors.

Key Improvements

  1. Clear explanation of why this happens: "Either the type or version does not exist, or Bicep does not yet know about it"
  2. Explicit impact statements: "may not be able to provide IntelliSense or detect potential errors"
  3. Deployment reassurance: "does not prevent attempting deployment"
  4. Help availability: Users can get help via the auto-generated URI: https://aka.ms/bicep/core-diagnostics#BCP081

Changes Made

  • Updated BCP081 diagnostic in DiagnosticBuilder.cs
  • Updated related BCP230 diagnostic for consistency in module scenarios
  • Updated all 28 test expectations across 11 test files to match the new message format
  • Maintained the same diagnostic code (BCP081) and warning level

The improved message now clearly explains the cause, specific impacts, and provides reassurance about deployment capabilities while directing users to help resources.

Fixes #13287.


💬 Share your feedback on Copilot coding agent for the chance to win a $200 gift card! Click here to start the survey.

Copilot AI and others added 2 commits July 11, 2025 00:20
Copilot AI changed the title [WIP] Warning about missing resource types should be more explicit about impact (and where is the link to the help page?) Improve BCP081 diagnostic message to be more explicit about impact and provide clearer explanation Jul 11, 2025
Copilot AI requested a review from anthony-c-martin July 11, 2025 00:28
Copilot finished work on behalf of anthony-c-martin July 11, 2025 00:28
@anthony-c-martin
Copy link
Member

Rebase

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Warning about missing resource types should be more explicit about impact (and where is the link to the help page?)

2 participants