Skip to content

[web] Expose rasterizers in Renderer #174308

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged

Conversation

harryterkelsen
Copy link
Contributor

This is a small tweak to the Renderer API that exposes a Rasterizer and a map of View to ViewRasterizer in the Renderer. The Renderer handles creating and disposing the ViewRasterizers in response to Views being created and disposed.

This is a step towards #172311

Pre-launch Checklist

If you need help, consider asking for advice on the #hackers-new channel on Discord.

Note: The Flutter team is currently trialing the use of Gemini Code Assist for GitHub. Comments from the gemini-code-assist bot should not be taken as authoritative feedback from the Flutter team. If you find its comments useful you can update your code accordingly, but if you are unsure or disagree with the feedback, please feel free to wait for a Flutter team member's review for guidance on which automated comments should be addressed.

@harryterkelsen harryterkelsen requested a review from mdebbar August 22, 2025 19:59
@github-actions github-actions bot added engine flutter/engine repository. See also e: labels. platform-web Web applications specifically labels Aug 22, 2025
Copy link
Contributor

@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request refactors the renderer classes by introducing a base Renderer class to share common logic for managing rasterizers, which is a great step towards unifying the different rendering backends. The changes are well-structured. My review includes several suggestions to improve documentation and code clarity in line with the project's style guide, such as using the correct doc comment syntax and simplifying method calls. I also found a potential regression in the skwasm_stub where removing the initialize override could lead to a less clear runtime error.

@flutter-dashboard
Copy link

CI had a failure that stopped further tests from running. We need to investigate to determine the root cause.

SHA at time of execution: f51a8fd.

Possible causes:

  • Configuration Changes: The .ci.yaml file might have been modified between the creation of this pull request and the start of this test run. This can lead to ci yaml validation errors.
  • Infrastructure Issues: Problems with the CI environment itself (e.g., quota) could have caused the failure.

A blank commit, or merging to head, will be required to resume running CI for this PR.

Error Details:

GitHub Error: You have exceeded a secondary rate limit. Please wait a few minutes before you try again. If you reach out to GitHub Support for help, please include the request ID BC92:1768B5:296C4C6:95C5FAE:68A8D4CD.

Stack trace:

#0      GitHub.handleStatusCode (package:github/src/common/github.dart:486:5)
#1      GitHub.request (package:github/src/common/github.dart:422:7)
<asynchronous suspension>
#2      GitHub.requestJson (package:github/src/common/github.dart:323:22)
<asynchronous suspension>
#3      RetryOptions.retry (package:retry/retry.dart:131:16)
<asynchronous suspension>
#4      LuciBuildService.scheduleTryBuilds (package:cocoon_service/src/service/luci_build_service.dart:246:24)
<asynchronous suspension>
#5      Scheduler._runCiTestingStage (package:cocoon_service/src/service/scheduler.dart:1253:9)
<asynchronous suspension>
#6      Scheduler.proceedToCiTestingStage (package:cocoon_service/src/service/scheduler.dart:1314:7)
<asynchronous suspension>
#7      Scheduler._closeSuccessfulEngineBuildStage (package:cocoon_service/src/service/scheduler.dart:1121:5)
<asynchronous suspension>
#8      Scheduler.processCheckRunCompleted (package:cocoon_service/src/service/scheduler.dart:1054:9)
<asynchronous suspension>
#9      PresubmitLuciSubscription.post (package:cocoon_service/src/request_handlers/presubmit_luci_subscription.dart:135:7)
<asynchronous suspension>
#10     RequestHandler.service (package:cocoon_service/src/request_handling/request_handler.dart:45:20)
<asynchronous suspension>
#11     SubscriptionHandler.service (package:cocoon_service/src/request_handling/subscription_handler.dart:140:5)
<asynchronous suspension>
#12     createServer.<anonymous closure> (package:cocoon_service/server.dart:339:7)
<asynchronous suspension>

@harryterkelsen harryterkelsen added this pull request to the merge queue Aug 22, 2025
Merged via the queue into flutter:master with commit 7d6d410 Aug 23, 2025
182 of 183 checks passed
@harryterkelsen harryterkelsen deleted the expose-rasterizers-in-renderer branch August 23, 2025 00:29
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Aug 23, 2025
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Aug 23, 2025
auto-submit bot pushed a commit to flutter/packages that referenced this pull request Aug 23, 2025
flutter/flutter@26bb33b...edd434a

2025-08-23 engine-flutter-autoroll@skia.org Roll Skia from 6f710e0b38f7 to 61169c1f6f7c (1 revision) (flutter/flutter#174325)
2025-08-23 engine-flutter-autoroll@skia.org Roll Fuchsia Linux SDK from Z-ZaFQ7jAqJ1OrIBf... to XLSNQCsY1VkIthSjt... (flutter/flutter#174318)
2025-08-23 engine-flutter-autoroll@skia.org Roll Skia from ebb6051e8bb1 to 6f710e0b38f7 (1 revision) (flutter/flutter#174317)
2025-08-22 1961493+harryterkelsen@users.noreply.github.com [web] Expose rasterizers in Renderer (flutter/flutter#174308)
2025-08-22 jhy03261997@gmail.com Update some semantics flags updated to use enum (engine, framework, web) (flutter/flutter#170696)
2025-08-22 bkonyi@google.com [ Tool ] Don't emit artifact downloading messages when --machine is provided (flutter/flutter#174301)
2025-08-22 engine-flutter-autoroll@skia.org Roll Skia from cb15e1452399 to ebb6051e8bb1 (5 revisions) (flutter/flutter#174296)
2025-08-22 matanlurey@users.noreply.github.com `_downloadArtifacts` (Web SDK) uses content-aware hashing in post-submit (flutter/flutter#174236)
2025-08-22 jacksongardner@google.com Refactor text and runtime effect to separate skia and impeller implementations. (flutter/flutter#174219)
2025-08-22 engine-flutter-autoroll@skia.org Roll Packages from 58c02e0 to 092d832 (4 revisions) (flutter/flutter#174295)
2025-08-22 bkonyi@google.com [ Widget Preview ] Add support for DevTools configuration (flutter/flutter#174272)
2025-08-22 32538273+ValentinVignal@users.noreply.github.com Migrate more files to `WidgetStateProperty` (flutter/flutter#174268)
2025-08-22 bkonyi@google.com [ Tool ] Ensure `--dds-port=<port>` is respected when targeting web devices (flutter/flutter#174278)
2025-08-22 fluttergithubbot@gmail.com Marks Mac_ios ios_debug_workflow to be unflaky (flutter/flutter#174104)

If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/flutter-packages
Please CC bmparr@google.com,stuartmorgan@google.com on the revert to ensure that a human
is aware of the problem.

To file a bug in Packages: https://github.com/flutter/flutter/issues/new/choose

To report a problem with the AutoRoller itself, please file a bug:
https://issues.skia.org/issues/new?component=1389291&template=1850622

Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
engine flutter/engine repository. See also e: labels. platform-web Web applications specifically
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants