Skip to content

Conversation

@zkzoomer
Copy link
Member

@zkzoomer zkzoomer commented Dec 5, 2025

What ❔

This is a sister-ish PR to matter-labs/zksync-era#4591

Why ❔

Checklist

  • PR title corresponds to the body of PR (we generate changelog entries from PRs).
  • Tests for the changes have been added / updated.
  • Documentation comments have been added / updated.

@zkzoomer zkzoomer changed the title Sma/fix migrate token balances gw to l1 fix: fix migrate token balances gw to l1 Dec 5, 2025
@zkzoomer zkzoomer changed the title fix: fix migrate token balances gw to l1 [WIP--DON'T MERGE] fix: fix migrate token balances gw to l1 Dec 9, 2025
@zkzoomer zkzoomer marked this pull request as ready for review December 9, 2025 11:28

// We check the assetId to make sure the chain is not lying about it.
DataEncoding.assetIdCheck(data.tokenOriginChainId, data.assetId, data.originToken);
if (data.assetId != BRIDGE_HUB.baseTokenAssetId(data.tokenOriginChainId)) {
Copy link
Contributor

Choose a reason for hiding this comment

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

just leaving this comment here, so we don't forget to remove this check

zkzoomer and others added 5 commits December 18, 2025 11:21
# What ❔

* [x] publish release artifacts only on tag pushes

<!-- What are the changes this PR brings about? -->
<!-- Example: This PR adds a PR template to the repo. -->
<!-- (For bigger PRs adding more context is appreciated) -->

## Why ❔

This was caused by this condition:
```
create:
  tags:
    - "v*" # for main releases
    - "zkos*" # for zk releases
```
There is no `on:create` filter for tags, so are firing the release
generation each time a new branch is created.

The proper fix is:
```
push:
  tags:
    - "v*" # for main releases
    - "zkos*" # for zk releases
```

<!-- Why are these changes done? What goal do they contribute to? What
are the principles behind them? -->
<!-- Example: PR templates ensure PR reviewers, observers, and future
iterators are in context about the evolution of repos. -->

## Checklist

<!-- Check your PR fulfills the following items. --> <!-- For draft PRs
check the boxes as you complete them. -->

- [x] PR title corresponds to the body of PR (we generate changelog
entries from PRs).
- [x] Tests for the changes have been added / updated.
- [x] Documentation comments have been added / updated.

# What ❔

<!-- What are the changes this PR brings about? -->
<!-- Example: This PR adds a PR template to the repo. -->
<!-- (For bigger PRs adding more context is appreciated) -->

## Why ❔

<!-- Why are these changes done? What goal do they contribute to? What
are the principles behind them? -->
<!-- Example: PR templates ensure PR reviewers, observers, and future
iterators are in context about the evolution of repos. -->

## Checklist

<!-- Check your PR fulfills the following items. -->
<!-- For draft PRs check the boxes as you complete them. -->

- [ ] PR title corresponds to the body of PR (we generate changelog
entries from PRs).
- [ ] Tests for the changes have been added / updated.
- [ ] Documentation comments have been added / updated.
@zkzoomer zkzoomer changed the title [WIP--DON'T MERGE] fix: fix migrate token balances gw to l1 fix: fix migrate token balances gw to l1 Dec 18, 2025
@github-actions
Copy link

Coverage after merging sma/fix-migrate-token-balances-gw-to-l1 into kl/medium-interop will be

84.91%

Coverage Report
FileStmtsBranchesFuncsLinesUncovered Lines
contracts/bridge
   BridgeHelper.sol100%100%100%100%
   BridgedStandardERC20.sol96.25%100%92.31%97.01%231–232
   L1ERC20Bridge.sol97.78%100%100%97.30%261
   L1Nullifier.sol88.44%100%87.10%88.69%129–130, 182, 191, 432–433, 436, 462, 647, 649, 698, 710, 713, 715, 731, 745–746, 750–751
   UpgradeableBeaconDeployer.sol0%100%0%0%15–16, 18, 20–21
contracts/bridge/asset-router
   AssetRouterBase.sol85.90%100%70.59%90.16%128, 200, 310, 49, 58, 81
   L1AssetRouter.sol91.62%100%86.67%92.70%104, 319, 330, 412–413, 432, 590, 601, 615, 620
contracts/bridge/asset-tracker
   AssetTrackerBase.sol78.38%100%66.67%84%113, 142, 59, 84
   GWAssetTracker.sol80.45%100%77.14%80.95%101–103, 109, 113, 116–117, 124–125, 136–137, 223, 233, 240, 242, 244, 246–248, 264, 318, 322, 354, 477–478, 487–488, 490, 496, 500, 510, 516–517, 521, 540–543, 630–631, 78, 97–99
   L1AssetTracker.sol97.90%100%100%97.54%227, 409, 61
   LegacySharedBridgeAddresses.sol0%100%0%0%23, 26, 29, 32, 36–41, 43
contracts/bridge/interfaces
   AssetHandlerModifiers.sol75%100%100%66.67%13
contracts/bridge/ntv
   L1NativeTokenVault.sol73.83%100%77.27%72.94%102–104, 151, 155–157, 180–186, 188, 257–258, 260, 271, 273, 279, 93–94
   NativeTokenVaultBase.sol82.08%100%66.67%85.88%136–139, 141–142, 144, 219, 310, 46, 48, 494, 496, 50, 52, 564, 601, 611–612, 616–617, 88, 93, 98
contracts/common
   MessageVerification.sol83.33%100%77.78%85.19%34, 41–42, 88
   ReentrancyGuard.sol95%100%100%94.12%79
contracts/common/l2-helpers
   L2ContractHelper.sol94.34%100%100%93.33%102, 108, 112
   SystemContractsCaller.sol52.50%100%60%51.43%44–45, 47, 49, 51, 53, 66, 69, 72, 75, 78, 83, 89, 91, 93, 96, 98
contracts/common/libraries
   DataEncoding.sol82.14%100%78.26%83.15%129–130, 137–138, 183, 197, 225, 233–234, 245, 259, 270, 288, 294, 50
   DynamicIncrementalMerkle.sol81.03%100%85.71%80.39%143–146, 148–151, 153–154
   DynamicIncrementalMerkleMemory.sol98.96%100%100%98.84%196
   FullMerkle.sol100%100%100%100%
   FullMerkleMemory.sol93.81%100%100%93.33%114, 131, 149, 163, 194, 90
   Merkle.sol98.15%100%100%97.96%83
   MessageHashing.sol96%100%100%95.38%118, 135, 154
   SemVer.sol100%100%100%100%
   UncheckedMath.sol100%100%100%100%
   UnsafeBytes.sol100%100%100%100%
   ZKSyncOSBytecodeInfo.sol0%100%0%0%17, 22, 30, 33
contracts/common/libraries/TransientPrimitives
   TransientPrimitives.sol100%100%100%100%
contracts/core/bridgehub
   BridgehubBase.sol88.83%100%88.89%88.82%134, 141, 159, 189, 207, 261, 264, 283, 299, 330, 38, 40, 42, 490, 493, 552, 556, 559
   L1Bridgehub.sol90%100%91.67%89.77%207, 282, 286–287, 290, 300, 66–67, 90
   L2Bridgehub.sol48.89%100%40%51.43%103–104, 112, 114–115, 124, 129–130, 132–133, 45, 48–50, 76, 89–90
contracts/core/chain-asset-handler
   ChainAssetHandlerBase.sol79.12%100%75%80%129–130, 180, 183, 195–196, 250, 267, 44, 46, 48, 50, 89, 96–97
   L1ChainAssetHandler.sol92.68%100%88.89%93.75%68–69
   L2ChainAssetHandler.sol88.24%100%87.50%88.46%121, 70, 94
contracts/core/chain-registration
   ChainRegistrationSender.sol88.24%100%100%85.19%41, 85, 89, 95
contracts/core/ctm-deployment
   CTMDeploymentTracker.sol73.47%100%81.82%71.05%108, 112, 116, 141, 145–146, 34, 42, 67, 80–81
contracts/core/message-root
   L1MessageRoot.sol67.44%100%75%65.71%104, 108–109, 65–66, 72–73, 81, 85, 89, 91–92
   L2MessageRoot.sol60%100%44.44%64.52%39–40, 45–46, 50, 57, 62–63, 68–70
   MessageRootBase.sol82.30%100%76.19%83.70%113, 117, 123–125, 131–133, 196, 212, 285, 314, 35, 38, 40
contracts/governance
   AccessControlRestriction.sol100%100%100%100%
   ChainAdmin.sol97.87%100%100%97.30%39
   ChainAdminOwnable.sol44.83%100%40%45.83%28, 38–40, 46–48, 57, 66, 77–79, 81
   Governance.sol100%100%100%100%
   L2ProxyAdminDeployer.sol0%100%0%0%16–18, 20
   PermanentRestriction.sol88.80%100%100%87.39%104, 111–112, 200–201, 204–205, 208, 210–211, 240, 288, 310, 341
   ServerNotifier.sol93.10%100%100%90.91%55, 65
   TransitionaryOwner.sol0%100%0%0%16–17, 21–23
contracts/governance/restriction
   Restriction.sol60%100%50%66.67%21
   RestrictionValidator.sol100%100%100%100%
contracts/interop
   AttributesDecoder.sol100%100%100%100%
   InteropCenter.sol93.25%100%89.47%93.75%114, 202, 427, 501, 54–55, 59–60, 72
   InteropDataEncoding.sol100%100%100%100%
   InteropHandler.sol91.07%100%81.82%92.08%33–35, 379, 401, 406, 41–42
   L2MessageVerification.sol90%100%100%88.89%35
contracts/l2-upgrades
   L2ComplexUpgrader.sol0%100%0%0%23–25, 39, 44, 46, 56,

@zkzoomer zkzoomer merged commit c45d4b7 into kl/medium-interop Dec 18, 2025
19 of 22 checks passed
@zkzoomer zkzoomer deleted the sma/fix-migrate-token-balances-gw-to-l1 branch December 18, 2025 15:45
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.

3 participants