Skip to content

Conversation

@homura
Copy link
Collaborator

@homura homura commented Jan 5, 2024

Description

Fixes #594

This PR supports duck typing by switching to codec as validators to check CKB-related objects. It also removes the unnecessary toolkit dep in related modules

Type of change

Please delete options that are not relevant.

  • Refactor (non-breaking change)

How Has This Been Tested?

  • Unit test

@vercel
Copy link

vercel bot commented Jan 5, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Updated (UTC)
lumos-website ✅ Ready (Inspect) Visit Preview Jan 19, 2024 3:15am

@codecov
Copy link

codecov bot commented Jan 5, 2024

Codecov Report

Attention: 3 lines in your changes are missing coverage. Please review.

Comparison is base (b44fb39) 87.29% compared to head (9c21eb4) 87.30%.

Additional details and impacted files

Impacted file tree graph

@@             Coverage Diff             @@
##           develop     #598      +/-   ##
===========================================
+ Coverage    87.29%   87.30%   +0.01%     
===========================================
  Files          118      118              
  Lines        23983    23984       +1     
  Branches      2459     2469      +10     
===========================================
+ Hits         20935    20939       +4     
- Misses        3003     3004       +1     
+ Partials        45       41       -4     
Files Coverage Δ
packages/ckb-indexer/src/collector.ts 76.56% <100.00%> (-0.08%) ⬇️
packages/codec/src/bytes.ts 99.21% <100.00%> (+0.78%) ⬆️
packages/helpers/src/index.ts 91.45% <100.00%> (+0.37%) ⬆️
packages/base/src/indexer.ts 85.71% <80.00%> (-0.07%) ⬇️
packages/ckb-indexer/src/indexer.ts 41.51% <66.66%> (ø)
packages/codec/src/error.ts 90.00% <80.00%> (-1.08%) ⬇️

... and 2 files with indirect coverage changes


Continue to review full report in Codecov by Sentry.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update b44fb39...9c21eb4. Read the comment docs.

@phroi
Copy link
Contributor

phroi commented Jan 5, 2024

Great!! What's the best way to test this PR with my typescript code? 🤔

@homura homura requested a review from zhangyouxin January 5, 2024 12:35
@phroi
Copy link
Contributor

phroi commented Jan 5, 2024

@homura if you want I can open a dedicated question to how to import a Lumos PR and you can reply there, so it's easier to find for future L1 developers, just let me know!!

@homura
Copy link
Collaborator Author

homura commented Jan 5, 2024

Great!! What's the best way to test this PR with my typescript code? 🤔

It will automatically be released as a canary once the PR is reviewed and merged

# Conflicts:
#	packages/base/package.json
#	packages/ckb-indexer/package.json
#	packages/common-scripts/package.json
#	packages/e2e-test/package.json
#	packages/experiment-tx-assembler/package.json
#	packages/helpers/package.json
#	packages/lumos/package.json
#	packages/transaction-manager/package.json
#	pnpm-lock.yaml
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.

[Suggestion] Switch Lumos validation and serialization to Duck Typing

3 participants