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

remove nft-utils and move the code into sov-nft-module and demo-rollup #992

Merged
merged 1 commit into from
Oct 6, 2023

Conversation

dubbelosix
Copy link
Contributor

Description

Refactoring the location and structure of the sov-nft-module interaction code.

Context:

Previously, the code to interact with the sov-nft-module was located in a separate top-level project named utils/nft-utils. This arrangement was chosen because this code depended on the Runtime for encoding the enum variant of calls and transaction creation.

Problem:

Having nft-utils at the top level creates a compilation issue if someone decides to remove the sov-nft-module.

Proposed Solution:

This PR proposes a better organized solution:

  • Move the utility functions that construct the enum variant into utils.rs inside the sov-nft-module.
  • Introduce a new binary at demo-rollup/src/bin/sov-nft-script.rs. This binary will leverage the utilities from sov-nft-module and handle transaction construction.
  • The original nft-utils has been completely removed.

@dubbelosix dubbelosix requested a review from bkolad October 6, 2023 11:16
@dubbelosix dubbelosix marked this pull request as ready for review October 6, 2023 11:17
@codecov
Copy link

codecov bot commented Oct 6, 2023

Codecov Report

Merging #992 (3d495d9) into nightly (1a73dae) will increase coverage by 0.7%.
The diff coverage is 0.0%.

Files Coverage Δ
...module-implementations/sov-nft-module/src/utils.rs 18.9% <0.0%> (-81.1%) ⬇️

... and 3 files with indirect coverage changes

@dubbelosix dubbelosix enabled auto-merge October 6, 2023 11:42
@dubbelosix dubbelosix added this pull request to the merge queue Oct 6, 2023
Merged via the queue into nightly with commit 3a2ed4b Oct 6, 2023
@dubbelosix dubbelosix deleted the dub/remove_utils_dep branch October 6, 2023 12:31
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