Skip to content

fix: handle NetworkManager Awake being overridden - #4237

Merged
EmandM merged 9 commits into
develop-2.0.0from
fix/override-networkmanager-awake
Nov 6, 2026
Merged

EmandM merged 9 commits into
develop-2.0.0from
fix/override-networkmanager-awake

Conversation

@EmandM

@EmandM EmandM commented Nov 2, 2026 •

Copy link
Copy Markdown
Member

Purpose of this PR

Ensure required NetworkManager methods are protected virtual so the base versions can be called when overridden.

Jira ticket

UUM-159597

Changelog

  • Fixed: Resolves exceptions being thrown when a derived NetworkManager implements their own Awake.

Documentation

  • No documentation changes or additions were necessary.

Testing & QA (How your changes can be verified during release Playtest)

Functional Testing

Manual testing :

  • Manual testing done

Automated tests:

  • Covered by existing automated tests
  • Covered by new automated tests

Does the change require QA team to:

  • Review automated tests?
  • Execute manual tests?
  • Provide feedback about the PR?

If any boxes above are checked the QA team will be automatically added as a PR reviewer.

Up-port

Up-ported by #4244

Backports

n/a

@EmandM
EmandM requested a review from a team as a code owner November 2, 2026 17:34

@u-pr u-pr Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

💡 Harness Review

LGTM

The logger fallbacks consistently cover all three startup modes, and the lifecycle methods now allow derived managers to invoke their base implementations.

Reviewed commit e6693e9

🤖 Helpful? 👍/👎

@NoelStephensUnity NoelStephensUnity left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

LGTM!

@EmandM
EmandM requested a review from a team as a code owner November 5, 2026 15:30
@EmandM
EmandM enabled auto-merge (squash) November 5, 2026 21:33
@codecov-github-com

codecov-github-com Bot commented Nov 5, 2026 •

Copy link
Copy Markdown

Codecov Report

Attention: Patch coverage is 62.96296% with 10 lines in your changes missing coverage. Please review.

Files with missing lines Patch % Lines
...netcode.gameobjects/Runtime/Core/NetworkManager.cs 62.96% 10 Missing ⚠️
@@                Coverage Diff                @@
##           develop-2.0.0    #4237      +/-   ##
=================================================
+ Coverage          74.36%   74.77%   +0.40%     
=================================================
  Files                172      172              
  Lines              28291    28400     +109     
=================================================
+ Hits               21039    21236     +197     
+ Misses              7252     7164      -88     
Flag Coverage Δ
NGOv2_project_testproject_ubuntu 74.42% <62.96%> (+0.38%) ⬆️

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

Files with missing lines Coverage Δ
...netcode.gameobjects/Runtime/Core/NetworkManager.cs 79.23% <62.96%> (-0.39%) ⬇️

... and 3 files with indirect coverage changes

Components Coverage Δ
com.unity.netcode.gameobjects 74.77% <86.36%> (+0.40%) ⬆️

ℹ️ Need help interpreting these results?

@EmandM
EmandM merged commit 3d90e55 into develop-2.0.0 Nov 6, 2026
26 checks passed
@EmandM
EmandM deleted the fix/override-networkmanager-awake branch November 6, 2026 01:37
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.

2 participants