Skip to content
Tutorials Center
My learning

Topics

Lesson 34 of 38 ยท Governance and Performance

Monitor, Testing and Troubleshooting

Debug and test Power Apps: the Monitor tool, Test Studio and Power Apps Test Engine, app checker, analytics and a checklist for common errors in canvas and model-driven apps.

Apps break in ways you do not see at your desk: a slow network call, a user without a permission, a formula that fails on empty data. Power Apps has built-in tools to watch what an app does, test it automatically and find common mistakes before users do.

The Monitor tool

Monitor shows a live stream of events as someone uses the app: every network call, every formula evaluation of OnSelect, navigation, errors and their timings. Open it:

  • In Power Apps Studio: Advanced tools (the icon in the left rail), then Open monitor.
  • From the maker portal: Apps, select the app, then Monitor in the toolbar, then Play published app (to watch the published version, even on another person's session when they share the session link).
  • For model-driven apps: add &monitor=true to the app URL, or choose Monitor in the app list; it supports form, command and network events.

Columns include Category (Network, Control, Function, Navigation...), Operation, Duration and Status. Click a row for details: request URL, response size, error text. Useful moves:

  • Sort by Duration to find the slowest call.
  • Filter by Category = Network to see data source traffic and spot repeated calls.
  • Search for a status like 401 (not signed in), 403 (no permission) or 429 (throttled).
  • Download the session and share it with a colleague to reproduce the problem.

Debugging toolbox

Monitor Live event stream
App checker Finds formula and accessibility issues
Analytics Usage and errors over time
1 / 2

App checker

In Power Apps Studio, the App checker (the stethoscope icon) lists Formulas, Runtime, Accessibility and Performance findings with severity. Fix the red items first. A common finding is a control with no AccessibleLabel, which hurts screen reader users, and another is a formula with a delegation warning (Delegation and Performance).

Writing defensive formulas

Many runtime errors come from empty values and failed calls. Handle them in the formula:

TEXT
IfError(
    Patch(Requests, Defaults(Requests), { Title: txtTitle.Text }),
    Notify("Save failed: " & FirstError.Message, NotificationType.Error)
)

FirstError is available inside the IfError fallback. Also use IsBlank/Coalesce to guard empty values, and set App.OnError to log unexpected errors in one central place.

Test Studio and Test Engine

Test Studio is part of canvas app editing: Settings, Upcoming features (older UI) or Advanced tools then Tests. You create a test suite with test cases; each case is a list of steps written as Power Fx, such as SetProperty(txtTitle.Text, "Laptop"), Select(btnSubmit) and Assert(lblMessage.Text = "Saved", "Message shown"). You can record steps by playing the app, then edit them. Tests can be run in the browser and results are listed as passed or failed.

Power Apps Test Engine is an open-source tool by Microsoft that runs similar YAML-based test plans from the command line, so you can run them in a pipeline before each deployment. Its features and commands are changing; check its repository for the current syntax.

What to test:

  • Each main path: create, edit, submit, approve.
  • Edge cases: empty required values, very long text, no rows in the data source.
  • Roles: test as every security role (Security Roles, Sharing and Row Access).
  • Devices: phone, tablet, browser.

A tiny test harness: a stand-in

A test case is a set of steps and assertions. This stand-in mimics Test Studio's idea with a miniature app. It is our own illustration and not Test Studio.

JS Stand-in: a test case with assertions

Press Run (or Ctrl + Enter) to see the console output here.

No output.

Reading a request log: a stand-in

Monitor's value is spotting patterns. This stand-in analyzes a list of network events like those you would see in a Monitor session, finding the slowest call and repeated requests.

JS Stand-in: analyze a Monitor-like log

Press Run (or Ctrl + Enter) to see the console output here.

No output.

A troubleshooting checklist

  1. Reproduce it and note the user, role, device and time.
  2. Open Monitor and look for errors, long durations and 4xx statuses.
  3. 403: check security roles and sharing. 401: check connections. 429: throttling; reduce calls.
  4. Run App checker and fix formula warnings.
  5. Check the flow run history in Power Automate for called flows.
  6. Check environment differences: missing environment variable values, unmapped connection references, flows turned off.
  7. Check the published version, not only the saved one: unpublished changes are invisible to users.
  8. Check Service health in the Microsoft 365 or Power Platform admin center for outages.

Check your understanding

Quick check ยท 4 questions

of 4 answered You scored / 4 ยท perfect!

  1. 1. What does the Monitor tool show?

    Monitor records events from a running session so you can see what happened and how long it took.
  2. 2. A call in Monitor returns status 403. What is the likely cause?

    403 means forbidden: check security roles, sharing and data source permissions.
  3. 3. What is Power Apps Test Engine suited for?

    It is an open-source tool that runs tests from the command line, so pipelines can run them.
  4. 4. Which function gives the error message inside an IfError fallback?

    FirstError is available inside the fallback formula.

Summary

  • Monitor shows live events; sort by duration and filter by status to find problems.
  • App checker finds formula, runtime, accessibility and performance issues.
  • Test Studio and Test Engine automate tests; test every role, edge case and device.
  • Use IfError and App.OnError for graceful failures and follow a fixed troubleshooting checklist.

Next: Project: Expense Approval App