Skip to content

Conversation

@shawnxie999
Copy link
Collaborator

@shawnxie999 shawnxie999 commented Feb 1, 2024

Spec is here https://github.com/XRPLF/XRPL-Standards/tree/master/XLS-0033d-multi-purpose-tokens

Builds rippled on https://github.com/gregtatcam/rippled/tree/mpt-direct-pay

  • refactor Issue and STAmount related changes (will need to change if rippled has further changes)
  • introduces new table mp_token_holders
  • ETL that extracts holders into mp_token_holders table whenever a new MPTokenAuthorize tx is observed
  • new mpt_holders API
  • inject synthetic mpt_issuance_id field into MPTokenIssuanceCreate transaction metadata for APIs (eg, tx, ledger, subscribe, account_tx)
  • support new MPTokenIssuance and MPToken objects types for ledger_entry
  • inject synthetic mpt_issuance_id field into MPTokenIssuance object for ledger_data and account_objects APIs

@godexsoft godexsoft changed the title mpt Implement MPT holders Feb 1, 2024
@shawnxie999 shawnxie999 changed the title Implement MPT holders Implement MPT changes Feb 1, 2024
@godexsoft
Copy link
Collaborator

godexsoft commented Feb 4, 2024

@shawnxie999 you need to setup clangd locally in your VSCode, or at least some modern version of clang-format via an extension. Let me know if you need help to set that up 👍
Another thing you are probably missing is our githook for checking format on commit. Take a look at our guide.

Copy link
Collaborator

@godexsoft godexsoft left a comment

Choose a reason for hiding this comment

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

Adding a few nits in advance. This is not a real review, just a few things that are immediately visible by glancing thru the code 🔢

@shawnxie999 shawnxie999 marked this pull request as ready for review March 4, 2024 21:55
@cindyyan317
Copy link
Contributor

👍 LGTM. Just a few of small things. The CI seems fail to build xrpl , let's fix it and stamp.

@codecov
Copy link

codecov bot commented Mar 6, 2024

Codecov Report

Attention: Patch coverage is 66.26506% with 56 lines in your changes missing coverage. Please review.

Project coverage is 71.76%. Comparing base (891fd1e) to head (195620c).
Report is 1 commits behind head on develop.

Files with missing lines Patch % Lines
src/rpc/RPCHelpers.cpp 21.73% 16 Missing and 2 partials ⚠️
src/etl/MPTHelpers.cpp 20.00% 15 Missing and 1 partial ⚠️
src/rpc/handlers/LedgerEntry.hpp 50.00% 0 Missing and 7 partials ⚠️
src/etl/impl/LedgerLoader.hpp 0.00% 4 Missing ⚠️
src/rpc/handlers/MPTHolders.hpp 60.00% 2 Missing and 2 partials ⚠️
src/etl/impl/AsyncData.hpp 33.33% 1 Missing and 1 partial ⚠️
src/rpc/handlers/MPTHolders.cpp 96.87% 1 Missing and 1 partial ⚠️
src/etl/impl/Transformer.hpp 0.00% 0 Missing and 1 partial ⚠️
src/rpc/common/impl/HandlerProvider.cpp 0.00% 1 Missing ⚠️
src/rpc/handlers/LedgerEntry.cpp 92.30% 1 Missing ⚠️
Additional details and impacted files
@@             Coverage Diff             @@
##           develop    #1147      +/-   ##
===========================================
- Coverage    71.85%   71.76%   -0.10%     
===========================================
  Files          279      282       +3     
  Lines        11731    11891     +160     
  Branches      5948     6032      +84     
===========================================
+ Hits          8429     8533     +104     
- Misses        1732     1773      +41     
- Partials      1570     1585      +15     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@godexsoft
Copy link
Collaborator

@shawnxie999 please merge develop again when you have a chance. We fixed the detection mechanism for undocumented code and it may show something new

Copy link
Collaborator

@godexsoft godexsoft left a comment

Choose a reason for hiding this comment

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

Found some things to improve 👍
Another thing is that your test coverage is slightly negative - please take a look at codecov for your branch to see where it's lacking tests. Anything with red change% needs a bit more love.

@shawnxie999
Copy link
Collaborator Author

@godexsoft as for test coverage, i believe most of the parts that lack coverage are ETL related

@shawnxie999 shawnxie999 changed the title Implement MPT changes feat: Implement MPT changes Jul 8, 2024
@kennyzlei kennyzlei added this to the 2.3 milestone Oct 22, 2024
cindyyan317
cindyyan317 previously approved these changes Oct 25, 2024
Copy link
Contributor

@cindyyan317 cindyyan317 left a comment

Choose a reason for hiding this comment

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

💯 All comments are addressed. Looks like ready to go. 👍

@shawnxie999
Copy link
Collaborator Author

updated to rippled v2.3.0 in commit 4863a9f

@cindyyan317 @godexsoft current build passes. i think would be ready to merge unless you guys have more feedbacks

Copy link
Collaborator

@godexsoft godexsoft left a comment

Choose a reason for hiding this comment

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

I have not spent too much time reviewing this PR but @cindyyan317 did. Once the new ETL is developed, we will have to move the logic into Extensions anyway and we can improve any nits then. Good job on the implementation @shawnxie999 👍

@godexsoft
Copy link
Collaborator

@shawnxie999 can you squash the above commits and make sure the resulting one is signed by you? then you can force-push the branch.

commit 2b0e504
Merge: d4a72a3 891fd1e
Author: Alex Kremer <[email protected]>
Date:   Mon Nov 11 15:26:30 2024 +0000

    Merge branch 'develop' into mpt-holders

commit d4a72a3
Merge: d801509 de6c177
Author: Shawn Xie <[email protected]>
Date:   Mon Nov 11 10:04:45 2024 -0500

    Merge branch 'develop' into mpt-holders

commit d801509
Merge: 8f6138c c435466
Author: Shawn Xie <[email protected]>
Date:   Thu Nov 7 13:02:00 2024 -0500

    Merge branch 'develop' into mpt-holders

commit 8f6138c
Merge: 4863a9f f8df654
Author: Shawn Xie <[email protected]>
Date:   Thu Nov 7 11:24:30 2024 -0500

    Merge remote-tracking branch 'upstream/develop' into mpt-holders

commit 4863a9f
Author: Shawn Xie <[email protected]>
Date:   Thu Nov 7 11:21:38 2024 -0500

    update artifactory and amendments

commit 2ea0cb8
Merge: 7bd4472 d04331d
Author: Shawn Xie <[email protected]>
Date:   Tue Oct 29 15:14:07 2024 -0400

    Merge branch 'develop' into mpt-holders

commit 7bd4472
Author: Shawn Xie <[email protected]>
Date:   Thu Oct 17 16:48:42 2024 -0400

    ledger entry test

commit a9b1430
Author: Shawn Xie <[email protected]>
Date:   Thu Oct 17 14:05:08 2024 -0400

    fix API response discrepancies

commit cce63dc
Author: Shawn Xie <[email protected]>
Date:   Wed Oct 9 13:48:39 2024 -0400

    comments

commit d877e5d
Author: Shawn Xie <[email protected]>
Date:   Tue Oct 8 11:09:07 2024 -0400

    update clio to compile with latest rippled

commit 2fc2536
Merge: 1c271f4 2c18fd5
Author: Shawn Xie <[email protected]>
Date:   Mon Oct 7 14:36:32 2024 -0400

    Merge remote-tracking branch 'upstream/develop' into mpt-holders

commit 1c271f4
Merge: 1a03ae0 bc9ca41
Author: Shawn Xie <[email protected]>
Date:   Thu Sep 5 16:10:01 2024 -0400

    Merge remote-tracking branch 'upstream/develop' into mpt-holders

commit 1a03ae0
Author: Shawn Xie <[email protected]>
Date:   Thu Sep 5 13:40:58 2024 -0400

    make compile

commit ca079a5
Merge: 8b8cc9b 648cedc
Author: Alex Kremer <[email protected]>
Date:   Thu Jul 18 12:28:48 2024 +0100

    Merge branch 'develop' into mpt-holders

commit 8b8cc9b
Author: Shawn Xie <[email protected]>
Date:   Mon Jul 8 12:15:24 2024 -0400

    add MPT amendment

commit 703500f
Author: Shawn Xie <[email protected]>
Date:   Mon Jul 8 11:32:16 2024 -0400

    clang

commit a464fba
Merge: 5df2068 d536433
Author: Shawn Xie <[email protected]>
Date:   Mon Jul 8 11:31:59 2024 -0400

    Merge remote-tracking branch 'upstream/develop' into mpt-holders

commit 5df2068
Author: Shawn Xie <[email protected]>
Date:   Thu Mar 28 12:03:36 2024 -0400

    predicate const ref

commit e75e2cf
Author: Shawn Xie <[email protected]>
Date:   Tue Mar 26 16:19:06 2024 -0400

    comments

commit 57020c2
Merge: 3defe87 9fa1740
Author: Shawn Xie <[email protected]>
Date:   Wed Mar 13 09:37:12 2024 -0400

    Merge branch 'develop' into mpt-holders

commit 3defe87
Author: Shawn Xie <[email protected]>
Date:   Tue Mar 12 14:52:03 2024 -0400

    add renamed libxrpl

commit a39c90a
Author: Shawn Xie <[email protected]>
Date:   Tue Mar 12 14:50:34 2024 -0400

    Delete CMake/deps/libxrpl.cmake

commit c4dbd11
Author: Shawn Xie <[email protected]>
Date:   Tue Mar 12 14:49:25 2024 -0400

    libxrpl

commit d2f40a9
Author: Shawn Xie <[email protected]>
Date:   Tue Mar 12 14:42:24 2024 -0400

    revert libxrpl

commit 26ca942
Merge: cee9cd5 43ced3b
Author: Shawn Xie <[email protected]>
Date:   Tue Mar 12 14:36:37 2024 -0400

    Merge remote-tracking branch 'upstream/develop' into mpt-holders

commit cee9cd5
Author: Shawn Xie <[email protected]>
Date:   Tue Mar 5 15:11:26 2024 -0500

    change libxrpl

commit 87838f6
Author: Shawn Xie <[email protected]>
Date:   Tue Mar 5 13:57:15 2024 -0500

    clang

commit 01453ee
Author: Shawn Xie <[email protected]>
Date:   Tue Mar 5 13:56:59 2024 -0500

    use toJson

commit 0087ff5
Author: Shawn Xie <[email protected]>
Date:   Tue Mar 5 11:14:02 2024 -0500

    var name

commit 55386e8
Author: Shawn Xie <[email protected]>
Date:   Tue Mar 5 11:13:42 2024 -0500

    change var name

commit 8d798a6
Author: Shawn Xie <[email protected]>
Date:   Tue Mar 5 10:50:32 2024 -0500

    doc

commit d9c54be
Author: Shawn Xie <[email protected]>
Date:   Tue Mar 5 10:48:36 2024 -0500

    comment

commit e7c77d3
Author: Shawn Xie <[email protected]>
Date:   Tue Mar 5 10:45:55 2024 -0500

    doc

commit f4852a8
Author: Shawn Xie <[email protected]>
Date:   Tue Mar 5 10:24:41 2024 -0500

    update libxrpl

commit 19b268f
Merge: 90dc297 c7b637b
Author: Shawn Xie <[email protected]>
Date:   Mon Mar 4 11:45:50 2024 -0500

    Merge branch 'develop' into mpt-holders

commit 90dc297
Author: Shawn Xie <[email protected]>
Date:   Mon Mar 4 11:20:02 2024 -0500

    comment

commit aac1e0c
Author: Shawn Xie <[email protected]>
Date:   Mon Mar 4 11:16:00 2024 -0500

    use getaccountid

commit b988f2d
Author: Shawn Xie <[email protected]>
Date:   Mon Mar 4 11:05:55 2024 -0500

    comment

commit d316375
Author: Shawn Xie <[email protected]>
Date:   Mon Mar 4 10:58:29 2024 -0500

    use copyif

commit 1d166a7
Merge: 5630132 51150d8
Author: Shawn Xie <[email protected]>
Date:   Mon Mar 4 08:45:21 2024 -0500

    Merge remote-tracking branch 'upstream/develop' into mpt-holders

commit 5630132
Author: Shawn Xie <[email protected]>
Date:   Fri Mar 1 17:00:53 2024 -0500

    clang

commit 63b4f7c
Author: Shawn Xie <[email protected]>
Date:   Fri Mar 1 17:00:40 2024 -0500

    remove rvalue ref

commit 66a4fe7
Author: Shawn Xie <[email protected]>
Date:   Fri Mar 1 16:01:49 2024 -0500

    improvements

commit d28b21f
Author: Shawn Xie <[email protected]>
Date:   Thu Feb 29 15:21:46 2024 -0500

    comment

commit f224555
Author: Shawn Xie <[email protected]>
Date:   Thu Feb 29 15:20:40 2024 -0500

    revert

commit 4d85852
Author: Shawn Xie <[email protected]>
Date:   Thu Feb 29 15:11:40 2024 -0500

    update

commit 38804f6
Merge: 9a378b0 b3e63b2
Author: Shawn Xie <[email protected]>
Date:   Thu Feb 29 15:10:43 2024 -0500

    Merge remote-tracking branch 'upstream/develop' into mpt-holders

commit 9a378b0
Author: Shawn Xie <[email protected]>
Date:   Thu Feb 29 13:25:54 2024 -0500

    revert issue changes

commit 494f56f
Author: Shawn Xie <[email protected]>
Date:   Thu Feb 8 14:35:39 2024 -0500

    doxygen and end of file line

commit b368864
Author: Shawn Xie <[email protected]>
Date:   Mon Feb 5 16:33:11 2024 -0500

    clang

commit 203fa8d
Author: Shawn Xie <[email protected]>
Date:   Mon Feb 5 16:32:24 2024 -0500

    clang

commit f3d7f0d
Author: Shawn Xie <[email protected]>
Date:   Mon Feb 5 13:09:26 2024 -0500

    template parameter type checking

commit eb138d2
Merge: 62b01fe a1699d7
Author: Shawn Xie <[email protected]>
Date:   Mon Feb 5 11:58:03 2024 -0500

    Merge remote-tracking branch 'upstream/develop' into mpt-holders-bk

commit 62b01fe
Author: Shawn Xie <[email protected]>
Date:   Mon Feb 5 10:58:17 2024 -0500

    remove comment

commit b6691bd
Author: Shawn Xie <[email protected]>
Date:   Mon Feb 5 10:56:40 2024 -0500

    refactor validators and add tests

commit e6d34fa
Merge: c453391 8f89a59
Author: Shawn Xie <[email protected]>
Date:   Fri Feb 2 11:53:15 2024 -0500

    Merge branch 'develop' into mpt-holders

commit c453391
Merge: 96288d0 ecfe5e8
Author: Shawn Xie <[email protected]>
Date:   Fri Feb 2 09:28:40 2024 -0500

    Merge branch 'develop' into mpt-holders

commit 96288d0
Author: Shawn Xie <[email protected]>
Date:   Thu Feb 1 11:44:04 2024 -0500

    add deletion blocker

commit 5fa9182
Merge: 75eddfd 03c0940
Author: Shawn Xie <[email protected]>
Date:   Thu Feb 1 11:32:20 2024 -0500

    Merge remote-tracking branch 'upstream/develop' into mpt-holders

commit 75eddfd
Author: Shawn Xie <[email protected]>
Date:   Thu Feb 1 10:45:15 2024 -0500

    tests

commit 18a8a4a
Author: Shawn Xie <[email protected]>
Date:   Wed Jan 31 19:59:06 2024 -0500

    improve condition

commit 412fa2e
Author: Shawn Xie <[email protected]>
Date:   Wed Jan 31 16:17:41 2024 -0500

    change order

commit 880d036
Author: Shawn Xie <[email protected]>
Date:   Wed Jan 31 16:12:23 2024 -0500

    clang

commit 2decaa8
Author: Shawn Xie <[email protected]>
Date:   Wed Jan 31 15:55:51 2024 -0500

    ledgerdata test

commit ac5f48e
Author: Shawn Xie <[email protected]>
Date:   Wed Jan 31 14:25:27 2024 -0500

    ledgerdata

commit 7052364
Author: Shawn Xie <[email protected]>
Date:   Wed Jan 31 14:00:04 2024 -0500

    comments

commit a700caa
Author: Shawn Xie <[email protected]>
Date:   Wed Jan 31 13:49:34 2024 -0500

    cmake

commit 1d7e49f
Author: Shawn Xie <[email protected]>
Date:   Wed Jan 31 13:37:14 2024 -0500

    typo

commit 0adc32e
Author: Shawn Xie <[email protected]>
Date:   Wed Jan 31 13:30:33 2024 -0500

    tests

commit f9b494e
Author: Shawn Xie <[email protected]>
Date:   Fri Jan 26 16:41:16 2024 -0500

    working marker

commit 0dae3cb
Author: Shawn Xie <[email protected]>
Date:   Fri Jan 26 14:16:02 2024 -0500

    compile

commit a97d549
Author: Shawn Xie <[email protected]>
Date:   Fri Jan 26 11:52:31 2024 -0500

    initial

commit 9ac779d
Author: Shawn Xie <[email protected]>
Date:   Mon Jan 15 13:46:11 2024 -0500

    account object test

commit 5bbf673
Author: Shawn Xie <[email protected]>
Date:   Mon Jan 15 12:00:44 2024 -0500

    ledger_entry tests

commit 5bc4ca5
Author: Shawn Xie <[email protected]>
Date:   Sat Jan 13 16:32:57 2024 -0500

    use translation

commit efc839c
Author: Shawn Xie <[email protected]>
Date:   Sat Jan 13 15:05:59 2024 -0500

    Working ledger entry

commit 2e297fa
Author: Shawn Xie <[email protected]>
Date:   Thu Jan 11 14:27:35 2024 -0500

    reafactor

commit b908b4e
Author: Shawn Xie <[email protected]>
Date:   Thu Jan 11 14:15:47 2024 -0500

    Synthetic MPT ID

commit f182a1d
Author: Shawn Xie <[email protected]>
Date:   Thu Jan 11 11:35:23 2024 -0500

    Working account_objects and Ledger_entry

commit 59bcb97
Author: Shawn Xie <[email protected]>
Date:   Tue Jan 9 11:51:48 2024 -0500

    wip

commit 924dd72
Author: Shawn Xie <[email protected]>
Date:   Wed Jan 10 16:14:53 2024 -0500

    remove static cast

commit f8bbf0c
Author: Shawn Xie <[email protected]>
Date:   Wed Jan 10 15:57:19 2024 -0500

    compile

commit 3c98a06
Author: Shawn Xie <[email protected]>
Date:   Wed Jan 10 15:20:26 2024 -0500

    Refactoring currency (WIP)
@godexsoft godexsoft merged commit 6b61984 into XRPLF:develop Nov 11, 2024
17 checks passed
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.

5 participants