Skip to content

Conversation

@JasonXuDeveloper
Copy link
Owner

Summary

  • Fixes false positive error detection in BuildManager during step 4/4 (GeneratePolymorphicCodes)
  • Resets _errorCountAtStart after step 3/4 filters out known YooAsset catalog errors
  • Prevents the build from incorrectly failing due to errors that were already handled

Problem

The YooAsset PreprocessBuildCatalog throws "Object reference not set to an instance of an object" when CatalogTools.CreateCatalogFile is called with null decryption services during HybridCLR's GenerateAll step. While step 3/4 correctly uses CheckForErrorsExcluding to filter this known error, the error count baseline was never reset, causing step 4/4's CheckForErrors to still see the elevated error count and throw a false positive failure.

Test plan

  • Run "Build All" or "Code Only" from JEngine Panel
  • Verify build completes successfully without false positive errors
  • Confirm YooAsset catalog errors are logged as warnings but don't fail the build

🤖 Generated with Claude Code

BuildManager was incorrectly detecting false positive errors during
step 4/4 (GeneratePolymorphicCodes) because the error count baseline
was not reset after step 3/4 filtered out known YooAsset catalog errors.

The YooAsset PreprocessBuildCatalog throws "Object reference not set"
when CatalogTools.CreateCatalogFile is called with null decryption
services during HybridCLR's GenerateAll step. This error is correctly
filtered by CheckForErrorsExcluding, but subsequent steps still saw
the elevated error count.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Signed-off-by: JasonXuDeveloper - 傑 <jason@xgamedev.net>
Copilot AI review requested due to automatic review settings January 30, 2026 22:11
@JasonXuDeveloper JasonXuDeveloper enabled auto-merge (squash) January 30, 2026 22:12
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR fixes a false positive error detection bug in the BuildManager where step 4/4 (GeneratePolymorphicCodes) incorrectly fails due to known YooAsset catalog errors from step 3/4 that were already filtered and handled.

Changes:

  • Resets the error count baseline (_errorCountAtStart) after step 3/4 filters out known YooAsset catalog errors
  • Prevents subsequent build steps from seeing filtered errors as new failures

github-actions[bot]
github-actions bot previously approved these changes Jan 30, 2026
Copy link

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

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

Auto-approved: Copilot review found no issues and Unity Tests passed (or were skipped for non-code changes).

@github-actions
Copy link

github-actions bot commented Jan 30, 2026

Unity Test Results

EditMode: All tests passed
PlayMode: All tests passed

Unity Version: 2022.3.55f1
Project Path: UnityProject

✅ All tests passed! The PR is ready for review.

View workflow run

Click here to view the full workflow run

The Settings.json for Unity Code Coverage is only used for local
development. CI uses its own coverageOptions in the workflow file,
so this file doesn't need to be tracked.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Signed-off-by: JasonXuDeveloper - 傑 <jason@xgamedev.net>
Copy link

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

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

Auto-approved: Copilot review found no issues and Unity Tests passed (or were skipped for non-code changes).

@codecov
Copy link

codecov bot commented Jan 30, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 85.02%. Comparing base (bc82092) to head (1bca1ea).
⚠️ Report is 3 commits behind head on master.

Additional details and impacted files

Impacted file tree graph

@@             Coverage Diff             @@
##           master     #610       +/-   ##
===========================================
+ Coverage   42.84%   85.02%   +42.17%     
===========================================
  Files          38       60       +22     
  Lines        4250     7684     +3434     
===========================================
+ Hits         1821     6533     +4712     
+ Misses       2429     1151     -1278     
Flag Coverage Δ
ui 83.60% <ø> (+69.73%) ⬆️
util 90.37% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@JasonXuDeveloper JasonXuDeveloper merged commit 9ecdfb8 into master Jan 30, 2026
20 checks passed
@JasonXuDeveloper JasonXuDeveloper deleted the fix/build-false-positive-error-detection branch January 30, 2026 22:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants