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

Feat: Refactor and Enhance Artifact Management Functions #6

Merged
merged 8 commits into from
Aug 15, 2024

Conversation

cristovaoth
Copy link
Collaborator

@cristovaoth cristovaoth commented Aug 14, 2024

Overview:

This PR introduces a comprehensive update to the artifact management functions within the zodiac-core package, with the goal of improving usability, clarity, and maintainability. The changes include renaming, restructuring, and enhancing various artifact-related methods, as well as updating the corresponding documentation to reflect these improvements.

Key Changes:

  1. Function Renaming & Restructuring:

    • writeMastercopyArtifact is now split into two distinct functions:
      • writeMastercopyFromBuild: Collects and stores artifact data from a local contract build.
      • writeMastercopyFromExplorer: Retrieves and stores artifact data from a deployed contract by querying a blockchain explorer.
    • deployMastercopies is now deployAllMastercopies.
    • verifyMastercopies is now verifyAllMastercopies.
    • readMastercopyArtifact is now readMastercopy.
  2. New Functionality:

    • Added getSourceCode utility to fetch contract source code, ABI, and other relevant data from an explorer API.
    • Enhanced artifact verification by integrating the verifySourceCode method, which offers improved source code verification capabilities.
  3. Documentation Updates:

    • Updated README with detailed descriptions and examples for all artifact management functions.
    • Provided a clearer structure for function inputs, outputs, and usage examples.
  4. Codebase Cleanup:

    • Removed redundant code and improved consistency across the artifact management modules.
    • Improved function and variable naming to enhance readability and maintainability.

Impact:

These changes make it easier for developers to manage and verify mastercopy artifacts, whether they are working with locally built contracts or deployed contracts on a blockchain. The updates also align the codebase with best practices, facilitating future enhancements and maintenance.

@juliopavila juliopavila changed the title new API Feat: Refactor and Enhance Artifact Management Functions Aug 14, 2024
@coveralls
Copy link

coveralls commented Aug 14, 2024

Pull Request Test Coverage Report for Build 10403862855

Details

  • 0 of 0 changed or added relevant lines in 0 files are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage remained the same at 99.512%

Totals Coverage Status
Change from base Build 10388472184: 0.0%
Covered Lines: 122
Relevant Lines: 123

💛 - Coveralls

README.md Outdated Show resolved Hide resolved
@cristovaoth cristovaoth merged commit ff5bbd6 into master Aug 15, 2024
1 of 2 checks passed
@github-actions github-actions bot locked and limited conversation to collaborators Aug 15, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants