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(ts): add essential exports by versions (#184) #165

Merged
merged 1 commit into from
May 3, 2024
Merged

feat(ts): add essential exports by versions (#184) #165

merged 1 commit into from
May 3, 2024

Conversation

ygrishajev
Copy link
Contributor

This pull request introduces a more streamlined approach to managing and exporting Akash protobuf files across various projects. By centralizing exports, I aim to reduce code duplication and improve maintainability across the ecosystem.

Key Changes

  1. Centralized Exports: Added necessary exports organized by groups and versions in the akash-api repository. This change allows other projects (like Cloudmos API, Indexer, and Deploy-Web) to utilize a single source of truth instead of maintaining duplicated code across different repositories.

Current Differences and Impact

I've identified slight variations in the proto files used across different projects:

  • Indexer v1beta2: Includes a unique Storage import.
  • Indexer v1beta3: Contains a GPU import not present in other versions.
  • Web v1beta3: Features a DepositDeploymentAuthorization import.

Question for Review

Is the presence of these unique imports intended, or should the proto files be uniform across all versions and projects? Understanding this will guide whether I can safely replace the duplicated files with centralized exports from the akash-api.

Proposal

Assuming these differences are not required for specific functional needs, my proposal is to eliminate all duplicate proto files in favor of those exported from the akash-api. This would simplify the codebase and ensure consistency.

@ygrishajev ygrishajev requested a review from a team as a code owner May 2, 2024 08:37
@ygrishajev ygrishajev requested review from Redm4x and baktun14 May 2, 2024 08:37
@Redm4x
Copy link

Redm4x commented May 2, 2024

Some background for those imports:

  • The GPU & Storage imports in the indexer are only there to type the params of these two functions in akashStatsIndexer.ts.
  • The DepositDeploymentAuthorization import in the web project is because we need it to encode Authz Grant transactions. We are not indexing deployment authorizations currently, that's why it's not imported in indexer/api. If we ever wanted to index them we would need it to decode the MsgGrant authorization.

@troian troian merged commit 43563b8 into main May 3, 2024
8 checks passed
@troian troian deleted the feat/ts branch May 3, 2024 12:33
Copy link

github-actions bot commented May 3, 2024

🎉 This PR is included in version 1.2.0 🎉

The release is available on:

Your semantic-release bot 📦🚀

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