Skip to content
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

refactor: enhance readability of output logs and errors #1528

Merged
merged 1 commit into from
Nov 7, 2023

Conversation

yangby-cryptape
Copy link
Collaborator

@yangby-cryptape yangby-cryptape commented Nov 6, 2023

What this PR does / why we need it?

This PR enhances readability of output logs and errors.

Before this PR, there are many formats:

  • ethereum_types::H64
    • Format with {} is 01ff....04ff.
    • Format with {:#x} is 0x01ff02ff03ff04ff.
  • bytes::Bytes
    • Format with {:?} is b"\xad@\xe1\xab\xcb\xa9F{6\x01\xa8".
    • Format with {:#x} is 01ff02ff03ff04ff.
      Difference with ethereum_types::Hxxx, there is no 0x-prefix.
  • Vec<u8>
    • Format with {:?} is [1, 255, 2, 255, 3, 255, 4, 255].

The following changes are applied:

  • Format b"\xad@\xe1\xab\xcb\xa9F{6\x01\xa8" to 0x01ff02ff03ff04ff.
  • Format [1, 255, 2, 255, 3, 255, 4, 255] to 0x01ff02ff03ff04ff.
  • Format 01ff....04ff to 0x01ff02ff03ff04ff.

What is the impact of this PR?

No Breaking Change

CI Settings

CI Usage

Tip: Check the CI you want to run below, and then comment /run-ci.

CI Switch

  • Web3 Compatible Tests
  • OCT 1-5 And 12-15
  • OCT 6-10
  • OCT 11
  • OCT 16-19
  • v3 Core Tests

CI Description

CI Name Description
Web3 Compatible Test Test the Web3 compatibility of Axon
v3 Core Test Run the compatibility tests provided by Uniswap V3
OCT 1-5 | 6-10 | 11 | 12-15 | 16-19 Run the compatibility tests provided by OpenZeppelin

@yangby-cryptape yangby-cryptape marked this pull request as ready for review November 6, 2023 18:28
@yangby-cryptape yangby-cryptape requested a review from a team as a code owner November 6, 2023 18:28
@yangby-cryptape yangby-cryptape requested review from jjyr and blckngm and removed request for jjyr and blckngm November 6, 2023 18:28
@Flouse Flouse requested a review from driftluo November 7, 2023 01:57
@KaoImin KaoImin added this pull request to the merge queue Nov 7, 2023
Merged via the queue into main with commit dfee005 Nov 7, 2023
22 of 23 checks passed
@KaoImin KaoImin deleted the yangby/refactor/enhance-readability branch November 7, 2023 03:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants