Skip to content

Main sdk next#2114

Merged
ygrishajev merged 20 commits intomainfrom
main-sdk-next
Oct 27, 2025
Merged

Main sdk next#2114
ygrishajev merged 20 commits intomainfrom
main-sdk-next

Conversation

@ygrishajev
Copy link
Contributor

@ygrishajev ygrishajev commented Oct 27, 2025

Summary by CodeRabbit

Release Notes

  • New Features

    • Added support for testnet environment with dedicated configuration and deployment workflows.
    • Introduced local deployment storage for improved manifest and metadata persistence across browser sessions.
  • Bug Fixes

    • Fixed deployment and lease data structure by consolidating escrow account fields into a nested state object with improved data organization.
    • Updated API endpoints to latest versions for deployments, markets, and certificates.
    • Corrected deployment identifier paths and field naming for API consistency.
    • Simplified deposit workflows by removing unnecessary depositor address requirements.
  • Chores

    • Updated Cosmos SDK dependency to version 53 with associated cosmjs and chain-sdk upgrades.
    • Expanded CI/CD workflows to support additional development branches.
    • Added testnet-specific Helm configurations for infrastructure deployment.

@ygrishajev ygrishajev requested a review from a team as a code owner October 27, 2025 13:29
@coderabbitai
Copy link
Contributor

coderabbitai bot commented Oct 27, 2025

Caution

Review failed

Failed to post review comments

Walkthrough

Comprehensive SDK53 upgrade across the Akash console and related services, migrating from Cosmos SDK v1beta3/v1beta4 to v1/v1beta5 message types. Updates include protocol type imports, message-type URLs, data schema refactoring (renaming ID fields, nesting escrow state), dependency upgrades, gRPC client migrations, testnet configuration changes, and new CI/CD workflows for multi-environment deployments.

Changes

Cohort / File(s) Summary
GitHub Actions Workflows - Branch Triggers
.github/workflows/all-trigger-coverage.yml, console-api-validate-n-build.yml, console-web-docker-build.yml, diff-package-lock.yml, github-actions-lint.yml, indexer-docker-build.yml, local-packages-validate.yml, log-collector-validate-n-build.yml, notifications-validate-n-build.yml, provider-console-docker-build.yml, provider-proxy-docker-build.yml, stats-web-docker-build.yml, workspace-ci-unsafe.yml
Updated pull_request trigger branches to include "main-sdk-next" alongside "main"
GitHub Actions Workflows - New Testnet Deployment
.github/workflows/console-api-deploy-testnet.yml, console-web-deploy-testnet.yml, indexer-deploy-testnet.yml, notifications-deploy-testnet.yml
Added new workflows to build and deploy apps (console-api, console-web, indexer, notifications) to testnet environment with beta sandbox deployments
GitHub Actions Reusable Workflows
.github/workflows/reusable-build-image.yml, reusable-deploy-k8s.yml
Added tag-latest and force-build inputs to build workflow; removed release_name export from deploy workflow
Helm Configuration
.helm/console-api-staging-testnet-values.yaml, indexer-staging-testnet-values.yaml
Added new Helm values files for testnet deployments with chain and endpoint configurations
Documentation
apps/api/README.md, apps/deploy-web/README.md, apps/notifications/README.md, apps/indexer/README.md
Added "CosmosSDK" section with "Target version: 53"
Environment Files
apps/api/env/.env.testnet, apps/deploy-web/env/.env.staging-testnet, apps/notifications/env/.env.staging-testnet
Added new testnet/staging-testnet environment configuration files
Package Dependencies
apps/api/package.json, apps/deploy-web/package.json, apps/indexer/package.json, apps/notifications/package.json, apps/provider-proxy/package.json, apps/stats-web/package.json, packages/http-sdk/package.json
Updated chain-sdk from 1.0.0-alpha.9 to 1.0.0-alpha.12; upgraded cosmjs packages from 0.32.4/0.33.x to ~0.36.1; removed cosmjs-types; adjusted cosmos-kit versions
Type Imports Migration
apps/api/src/address/services/address/address.service.ts, apps/api/src/billing/lib/batch-signing-client/batch-signing-client.service.spec.ts, apps/api/src/billing/lib/batch-signing-client/batch-signing-client.service.ts, apps/indexer/src/chain/genesisTypes.ts, apps/indexer/src/indexers/messageAddressesIndexer.ts, apps/indexer/src/indexers/validatorIndexer.ts, apps/indexer/src/shared/utils/coin.ts, packages/database/chainDefinitions.ts
Replaced cosmjs-types imports with @akashnetwork/chain-sdk/private-types paths
Protocol Registry Updates
apps/api/src/billing/providers/type-registry.provider.ts, apps/api/src/utils/protobuf.ts, apps/deploy-web/src/utils/customRegistry.ts, apps/indexer/src/shared/utils/protobuf.ts, apps/notifications/src/modules/chain/providers/registry.provider.ts
Refactored from static registries to dynamic aggregation of protobuf types from multiple versioned namespaces (v1, v1beta4, v1beta5, cosmos versions)
Message Schema Updates
apps/api/src/bid/http-schemas/bid.schema.ts, apps/api/src/billing/http-schemas/tx.schema.ts, apps/api/src/deployment/http-schemas/deployment-rpc.schema.ts, apps/api/src/deployment/http-schemas/deployment.schema.ts, apps/api/src/deployment/http-schemas/lease-rpc.schema.ts
Renamed ID fields (bid_idid, deployment_idid, lease_idid); added bseq field; restructured escrow/account fields into nested state object with transferred/funds arrays and deposits collection
Bid-Related Services
apps/api/src/bid/services/bid/bid.service.ts, apps/api/src/gpu/services/gpu-price.service.ts, apps/api/src/gpu/types/gpu.type.ts, packages/http-sdk/src/bid/bid-http.service.ts
Updated bid ID path from bid_id to id; added support for v1beta4/v1beta5 MsgCreateBid variants; added bseq field
Deployment Reader/Writer Services
apps/api/src/deployment/services/deployment-reader/deployment-reader.service.ts, apps/api/src/deployment/services/deployment-writer/deployment-writer.service.ts, apps/api/src/deployment/repositories/message/message.repository.ts, apps/api/src/deployment/repositories/deployment/deployment.repository.ts
Updated to use id instead of deployment_id; changed version to hash; restructured escrow account access paths; updated message type handling for multiple versions
Fallback Services
apps/api/src/deployment/services/fallback-deployment-reader/fallback-deployment-reader.service.ts, apps/api/src/deployment/services/fallback-lease-reader/fallback-lease-reader.service.ts
Updated response shapes to use id fields and nested state structures; adjusted escrow payment transformation with id and state nesting
API Type Definitions
apps/api/src/types/rest/akashDeploymentListResponse.ts, apps/api/src/types/rest/akashLeaseListResponse.ts, apps/api/src/types/rest/index.ts
Updated deployment/group/escrow field names; restructured escrow state; removed akashLeaseListResponse export
Billing Services
apps/api/src/billing/services/balances/balances.service.ts, apps/api/src/billing/services/managed-user-wallet/managed-user-wallet.service.ts, apps/api/src/billing/services/trial-validation/trial-validation.service.ts, apps/api/src/billing/services/financial-stats/financial-stats.service.ts, apps/api/src/billing/services/chain-error/chain-error.service.ts
Updated message type versions and escrow state access; changed to dynamic $type references; updated typeUrl mappings
RPC Message Service
apps/api/src/billing/services/rpc-message-service/rpc-message.service.ts
Major refactor: replaced v1beta3 types with private-types; changed typeUrl construction to use $type; updated message payloads for deposits with signer/scope/xid; removed depositor field
Deployment Utils
apps/api/src/deployment/services/gpu-bids-creator/gpu-bids-creator.service.ts, apps/api/src/deployment/services/sdl/sdl.service.ts, apps/api/src/deployment/services/top-up-managed-deployments/top-up-managed-deployments.service.ts
Updated message type construction; added method overloads; changed registry injection; updated deposit message structure
Cert & SDK Client
apps/api/src/certificate/services/certificate.service.ts, apps/api/src/billing/lib/sync-signing-stargate-client/sync-signing-stargate-client.ts, apps/api/src/billing/lib/wallet/wallet.ts
Updated certificateManager import; made async generatePEM; changed signature to variadic; updated return types
Constants & Utils
apps/api/src/utils/constants.ts, apps/api/src/billing/config/env.config.ts
Renamed constants (betaTypeVersion→deploymentVersion, etc.); updated GAS_SAFETY_MULTIPLIER; added certVersion/deploymentVersion/marketVersion
API Test Fixtures
apps/api/test/functional/addresses.spec.ts, apps/api/test/functional/balances.spec.ts, apps/api/test/functional/bids.spec.ts, apps/api/test/functional/certificate.spec.ts, apps/api/test/functional/create-deployment.spec.ts, apps/api/test/functional/deployment-*.spec.ts, apps/api/test/functional/gpu.spec.ts, apps/api/test/functional/lease-fallback.spec.ts, apps/api/test/functional/managed-api-deployment-flow.spec.ts, apps/api/test/functional/sign-and-broadcast-tx.spec.ts, apps/api/test/functional/start-trial.spec.ts, apps/api/test/functional/stripe-webhook.spec.ts, apps/api/test/functional/wallets-refill.spec.ts
Updated test fixtures to match new data shapes; renamed fields; updated API endpoints to use version constants; restructured escrow/bid data
Test Seeders
apps/api/test/seeders/akash-message.seeder.ts, apps/api/test/seeders/bid.seeder.ts, apps/api/test/seeders/deployment-grant-response.seeder.ts, apps/api/test/seeders/deployment-grant.seeder.ts, apps/api/test/seeders/deployment-info.seeder.ts, apps/api/test/seeders/fees-authorization.seeder.ts, apps/api/test/seeders/lease-api-response.seeder.ts, apps/api/test/seeders/lease.seeder.ts
Updated seeder functions to generate new data shapes; changed authorization types; restructured escrow/deposit objects; removed deprecated seeders
Deploy Web - Message Handling
apps/deploy-web/src/utils/TransactionMessageData.ts, apps/deploy-web/src/utils/customRegistry.ts, apps/deploy-web/src/utils/apiUtils.ts, apps/deploy-web/src/utils/grants.ts, apps/deploy-web/src/utils/proto/grant.ts, apps/deploy-web/src/utils/proto/index.ts, apps/deploy-web/src/utils/init.ts
Replaced static message type construction with dynamic protobuf-based builders; removed hardcoded type mappings; introduced getRevokeDepositMsg; refactored registry initialization
Deploy Web - Chain/Network
apps/deploy-web/src/chains/akash-testnet.ts, apps/deploy-web/src/config/denom.config.ts, apps/deploy-web/src/context/SettingsProvider/SettingsProviderContext.tsx, apps/deploy-web/src/context/CustomChainProvider/CustomChainProvider.tsx, apps/deploy-web/src/hooks/useProviderWebsocket.ts, apps/deploy-web/src/services/api-url/api-url.service.ts, apps/deploy-web/src/services/app-di-container/app-di-container.ts, apps/deploy-web/src/services/provider-proxy/provider-proxy.service.ts
Updated testnet chain config (testnet-02→testnet-7); added TESTNET_ID to denom config; integrated netConfig for endpoint mapping; updated import sources
Deploy Web - Storage Service
apps/deploy-web/src/services/deployment-storage/deployment-storage.service.ts, apps/deploy-web/src/services/deployment-storage/deployment-storage.service.spec.ts
New service for client-side deployment data persistence with get/set/update/delete operations
Deploy Web - Deposit Flow
apps/deploy-web/src/components/deployments/DeploymentDepositModal.tsx, apps/deploy-web/src/components/deployments/DeploymentDetailTopBar.tsx, apps/deploy-web/src/components/deployments/DeploymentListRow.tsx, apps/deploy-web/src/components/deployments/DeploymentSubHeader.tsx, apps/deploy-web/src/components/shared/PrerequisiteList.tsx, apps/deploy-web/src/components/deployments/DeploymentDetail.tsx, apps/deploy-web/src/components/wallet/ConnectManagedWalletButton.tsx
Removed depositor-address flow; simplified deposit modal; updated escrow account access from balance.denom to state.funds[0]?.denom
Deploy Web - Manifest & Lease
apps/deploy-web/src/components/deployments/ManifestUpdate.tsx, apps/deploy-web/src/components/new-deployment/ManifestEdit.tsx, apps/deploy-web/src/components/new-deployment/CreateLease/CreateLease.tsx, apps/deploy-web/src/components/new-deployment/RentGpusForm.tsx
Updated to use deploymentLocalStorage; removed depositorAddress parameter; integrated local storage for manifest persistence
Deploy Web - Certificate
apps/deploy-web/src/context/CertificateProvider/CertificateProviderContext.tsx
Made async PEM parsing; updated certificateManager import; integrated async/await for certificate generation
Deploy Web - Deployment Data
apps/deploy-web/src/utils/deploymentData/helpers.ts, apps/deploy-web/src/utils/deploymentData/index.ts, apps/deploy-web/src/utils/deploymentData/v1beta2.ts, apps/deploy-web/src/utils/deploymentData/v1beta3.ts
Removed v1beta2 support; narrowed SDL types to string-only; removed depositorAddress parameter; updated API endpoints
Deploy Web - Utility Updates
apps/deploy-web/src/utils/deploymentDetailUtils.ts, apps/deploy-web/src/utils/deploymentLocalDataUtils.ts, apps/deploy-web/src/utils/encoding.ts, apps/deploy-web/src/utils/zod/deploymentRow.ts, apps/deploy-web/src/utils/walletUtils.ts
Restructured escrow balance calculations; created new encoding utilities; removed deployment local data utils (replaced by service); updated schema to nested state
Deploy Web - Hooks & Queries
apps/deploy-web/src/hooks/useAutoTopUpService.ts, apps/deploy-web/src/hooks/useDenom.ts, apps/deploy-web/src/hooks/useDeploymentMetrics.tsx, apps/deploy-web/src/hooks/useWalletBalance.ts, apps/deploy-web/src/queries/useBidQuery.ts, apps/deploy-web/src/queries/useGrantsQuery.spec.tsx, apps/deploy-web/src/queries/useLeaseQuery.spec.tsx
Updated to use new data shapes; added type assertions; changed escrow/bid field access paths; updated grant authorization types
Deploy Web - Providers & Types
apps/deploy-web/src/pages/providers/[owner]/index.tsx, apps/deploy-web/src/types/address.ts, apps/deploy-web/src/types/deployment.ts
Changed network validation from dynamic to hardcoded list; renamed deploymentGrant→deploymentGrants; restructured deployment/lease/group/escrow types with new field names and nesting
Deploy Web - Wallet & Services
apps/deploy-web/src/services/wallet-balances/wallet-balances.service.ts, apps/deploy-web/src/services/wallet-balances/wallet-balances.service.spec.ts, apps/deploy-web/src/context/LocalNoteProvider/DeploymentNameModal.tsx, apps/deploy-web/src/context/LocalNoteProvider/LocalNoteContext.tsx, apps/deploy-web/src/context/WalletProvider/WalletProvider.tsx, apps/deploy-web/src/components/new-deployment/BidGroup.tsx, apps/deploy-web/src/components/new-deployment/CreateLease/CreateLease.spec.tsx, apps/deploy-web/src/components/onboarding/OnboardingContainer/OnboardingContainer.tsx, apps/deploy-web/src/components/onboarding/OnboardingContainer/OnboardingContainer.spec.tsx
Updated balance calculations with array summation; added deploymentGrants array handling; integrated wallet/localStorage dependencies; updated MESSAGE_STATES mapping; added managed wallet integration
Deploy Web - Tests & Scripts
apps/deploy-web/tests/seeders/alert.ts, apps/deploy-web/tests/seeders/bid.ts, apps/deploy-web/tests/seeders/deployment.ts, apps/deploy-web/tests/seeders/deploymentBid.ts, apps/deploy-web/script/closeDeployments.ts, apps/deploy-web/tsconfig.json, apps/deploy-web/src/components/sdl/LogCollectorControl/LogCollectorControl.spec.tsx, apps/deploy-web/src/utils/deploymentDetailUtils.spec.ts
Updated test seeders to new data shapes; migrated script to use chain-sdk registry; adjusted test configurations
Provider Console
apps/provider-console/src/types/deployment.ts
Updated RpcLease type with new id/state nesting for lease and escrow_payment
Indexer
apps/indexer/README.md, apps/indexer/package.json, apps/indexer/src/providers/statusEndpointHandlers/fake-insecure-credentials.ts, apps/indexer/src/providers/statusEndpointHandlers/grpc.ts
Removed FakeInsecureCredentials; migrated from gRPC to chain-sdk provider client; updated package versions
Notifications Module
apps/notifications/README.md, apps/notifications/package.json, apps/notifications/env/.env.staging-testnet, apps/notifications/src/modules/alert/services/deployment/deployment.service.ts, apps/notifications/src/modules/alert/services/deployment/deployment.service.spec.ts, apps/notifications/src/modules/chain/chain.module.ts, apps/notifications/src/modules/chain/providers/comet-client/comet-client.provider.ts, apps/notifications/src/modules/chain/providers/tendermint-client/tendermint-client.provider.ts, apps/notifications/src/modules/chain/providers/registry.provider.ts, apps/notifications/src/modules/chain/services/block-message-parser/block-message-parser.service.ts, apps/notifications/src/modules/chain/services/chain-events-poller/chain-events-poller.service.ts, apps/notifications/src/modules/chain/services/message-decoder/message-decoder.service.ts, apps/notifications/src/modules/chain/services/tx-events-service/tx-events.service.ts, apps/notifications/test/functional/balance-alert.spec.ts, apps/notifications/test/functional/deployment-alert-crud.spec.ts, apps/notifications/test/seeders/deployment-balance-response.seeder.ts, apps/notifications/test/seeders/message.seeder.ts, apps/notifications/tsconfig.json
Updated message type paths; migrated Tendermint34Client→Comet38Client; refactored TxEventsService event processing; updated deployment balance calculation; changed authorization types
Docker & Build
packages/docker/script/build.sh
Added -l/--mark-latest flag to control tagging behavior; conditioned force-build checks
HTTP SDK
packages/http-sdk/package.json, packages/http-sdk/src/authz/authz-http.service.ts, packages/http-sdk/src/bid/bid-http.service.ts, packages/http-sdk/src/block/block-http.service.ts, packages/http-sdk/src/certificates/certificates.service.ts
Moved cosmjs dependencies to peerDependencies; updated authorization type strings; restructured bid escrow and API endpoint versions
Stats Web
apps/stats-web/package.json, apps/stats-web/src/config/denom.config.ts, apps/stats-web/src/services/api-url/api-url.service.ts, apps/stats-web/src/types/deployment.ts
Updated dependencies; extended denom config for testnet; consolidated imports; updated lease type with new id/state nesting
Mock & Config
apps/api/test/mocks/hello-world-sdl.yml, apps/api/test/mocks/hello-world-sdl-update.yml
Removed console/trials attribute from deployment profiles

Estimated code review effort

🎯 5 (Critical) | ⏱️ ~120+ minutes

  • Complexity: Massive coordinated protocol upgrade with breaking changes across multiple versioned APIs (v1beta3→v1beta4/v1beta5/v1)
  • Scope: 100+ files modified spanning API, frontend, indexer, notifications, and supporting packages
  • Heterogeneity: Mixed pattern changes including type migrations, message construction refactors, data shape restructuring, gRPC client swaps, and CI/CD workflow additions
  • Logic Density: High concentration of business logic changes in message builders, data readers/writers, balance calculations, and event processing

Areas requiring extra attention:

  • Escrow/Balance Logic: Restructured from flat fields to nested arrays; validate all balance aggregation paths (apps/api/src/billing/services/balances/balances.service.ts, apps/deploy-web/src/hooks/useWalletBalance.ts)
  • Message Type Routing: Dynamic $type-based typeUrl construction replacing hardcoded strings; ensure all message types are properly registered in new registries (apps/api/src/billing/providers/type-registry.provider.ts, apps/deploy-web/src/utils/customRegistry.ts)
  • Data Migration Paths: ID field renames and escrow state nesting; verify all query paths and data mappers handle the new structure (deployment-reader.service.ts, fallback-*-reader.ts, *-http.service.ts)
  • Deposit Flow Changes: Removed depositor-address parameter; verify signer-based authorization and grant revocation work correctly (RpcMessageService, TransactionMessageData)
  • Client Library Transitions: gRPC→Comet38, TendermintClientProvider removal, registry refactoring; verify connectivity and event parsing (notifications tx-events-service, indexer grpc.ts)
  • Test Coverage: Extensive mock/seeder updates required; cross-verify test fixtures match new API/schema versions

Possibly related issues

Possibly related PRs

Suggested reviewers

  • baktun14

🐰 A whisker-twitching dance of SDK53 delight!
From v1beta3 to v1, the protocol takes flight,
New schemas nested, grants revoked just right,
Testnet deployments glowing in the testnet-7 light,
Storage persists, and balances sum so bright! 🌕

Pre-merge checks and finishing touches

❌ Failed checks (1 warning, 1 inconclusive)
Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 13.04% which is insufficient. The required threshold is 80.00%. You can run @coderabbitai generate docstrings to improve docstring coverage.
Title Check ❓ Inconclusive The PR title "Main sdk next" is vague and lacks meaningful context about the changeset. While the title references the source branch name (main-sdk-next), it does not convey what the actual changes contain. The changeset represents a substantial upgrade including chain-sdk dependency bump (1.0.0-alpha.9 → 1.0.0-alpha.12), CosmJS updates (0.32.x → 0.36.1), protocol buffer type reorganization, message version updates (v1beta3/v1beta4 → v1beta4/v1beta5), and significant API schema restructuring. A more descriptive title would communicate these key changes rather than simply restating the branch name. Consider updating the PR title to be more descriptive of the primary change, such as "Upgrade chain-sdk to 1.0.0-alpha.12 and update message types to v1beta4/v1beta5" or "Update SDK dependencies and restructure API schemas" to clearly communicate the scope and nature of the changes to reviewers scanning the PR history.
✅ Passed checks (1 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
✨ Finishing touches
  • 📝 Generate docstrings
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch main-sdk-next

Comment @coderabbitai help to get the list of available commands and usage tips.

@@ -40,7 +40,7 @@
"dependencies": {
Copy link
Contributor

@github-actions github-actions bot Oct 27, 2025

Choose a reason for hiding this comment

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

🔄 Carefully review the package-lock.json diff

Resolve the comment if everything is ok

* apps/api/node_modules/@cosmjs/crypto                                                     0.32.4 -> 0.36.1
* apps/api/node_modules/@cosmjs/encoding                                                   0.32.4 -> 0.36.1
* apps/api/node_modules/@cosmjs/math                                                       0.32.4 -> 0.36.1
* apps/api/node_modules/@cosmjs/stargate                                                   0.32.4 -> 0.36.1
* apps/deploy-web/node_modules/@cosmjs/encoding                                            0.32.4 -> 0.36.1
* apps/deploy-web/node_modules/@cosmjs/math                                                0.32.4 -> 0.36.1
* apps/deploy-web/node_modules/@cosmjs/stargate                                            0.32.4 -> 0.36.1
* apps/indexer/node_modules/@cosmjs/crypto                                                 0.32.4 -> 0.36.1
* apps/indexer/node_modules/@cosmjs/encoding                                               0.32.4 -> 0.36.1
* apps/indexer/node_modules/@cosmjs/math                                                   0.32.4 -> 0.36.1
* apps/indexer/node_modules/@cosmjs/stargate                                               0.32.4 -> 0.36.1
* apps/notifications/node_modules/@cosmjs/amino                                            0.33.1 -> 0.36.1
* apps/notifications/node_modules/@cosmjs/crypto/node_modules/@cosmjs/math                 0.32.4 -> 0.36.1
* apps/notifications/node_modules/@cosmjs/crypto                                           0.32.4 -> 0.36.1
* apps/notifications/node_modules/@cosmjs/encoding                                         0.32.4 -> 0.36.1
* apps/notifications/node_modules/@cosmjs/json-rpc                                         0.33.1 -> 0.36.1
* apps/notifications/node_modules/@cosmjs/proto-signing                                    0.33.1 -> 0.36.1
* apps/notifications/node_modules/@cosmjs/socket                                           0.33.1 -> 0.36.1
* apps/notifications/node_modules/@cosmjs/stargate                                         0.33.1 -> 0.36.1
* apps/notifications/node_modules/@cosmjs/stream                                           0.33.1 -> 0.36.1
* apps/notifications/node_modules/@cosmjs/tendermint-rpc                                   0.33.1 -> 0.36.1
* apps/notifications/node_modules/@cosmjs/utils                                            0.33.1 -> 0.36.1
* apps/provider-proxy/node_modules/@cosmjs/amino                                           0.33.1 -> 0.36.1
* apps/provider-proxy/node_modules/@cosmjs/crypto                                          0.33.1 -> 0.36.1
* apps/provider-proxy/node_modules/@cosmjs/encoding                                        0.32.4 -> 0.36.1
* apps/provider-proxy/node_modules/@cosmjs/math                                            0.33.1 -> 0.36.1
* apps/provider-proxy/node_modules/@cosmjs/utils                                           0.33.1 -> 0.36.1
* apps/stats-web/node_modules/@cosmjs/encoding                                             0.32.4 -> 0.36.1
* node_modules/@adraffy/ens-normalize                                                      1.11.0 -> 1.11.1
* node_modules/@akashnetwork/chain-sdk/node_modules/@cosmjs/crypto                         0.33.1 -> 0.36.1
* node_modules/@akashnetwork/chain-sdk/node_modules/@cosmjs/encoding                       0.33.1 -> 0.36.1
* node_modules/@akashnetwork/chain-sdk/node_modules/@cosmjs/json-rpc                       0.33.1 -> 0.36.1
* node_modules/@akashnetwork/chain-sdk/node_modules/@cosmjs/math                           0.33.1 -> 0.36.1
* node_modules/@akashnetwork/chain-sdk/node_modules/@cosmjs/proto-signing                  0.33.1 -> 0.36.1
* node_modules/@akashnetwork/chain-sdk/node_modules/@cosmjs/socket                         0.33.1 -> 0.36.1
* node_modules/@akashnetwork/chain-sdk/node_modules/@cosmjs/stargate                       0.33.1 -> 0.36.1
* node_modules/@akashnetwork/chain-sdk/node_modules/@cosmjs/stream                         0.33.1 -> 0.36.1
* node_modules/@akashnetwork/chain-sdk/node_modules/@cosmjs/tendermint-rpc                 0.33.1 -> 0.36.1
* node_modules/@akashnetwork/chain-sdk/node_modules/@cosmjs/utils                          0.33.1 -> 0.36.1
* node_modules/@akashnetwork/chain-sdk                                                     1.0.0-alpha.9 -> 1.0.0-alpha.12
* node_modules/@chain-registry/cosmostation                                                1.66.71 -> 1.72.372
* node_modules/@chain-registry/keplr                                                       1.68.2 -> 1.74.372
* node_modules/@chain-registry/types                                                       0.50.17 -> 0.50.233
* node_modules/@chain-registry/utils                                                       1.51.12 -> 1.51.233
* node_modules/@cosmos-kit/core                                                            2.15.0 -> 2.16.6
* node_modules/@cosmos-kit/cosmos-extension-metamask                                       0.10.0 -> 0.13.3
* node_modules/@cosmos-kit/cosmostation-extension                                          2.13.0 -> 2.16.6
* node_modules/@cosmos-kit/keplr-extension/node_modules/@keplr-wallet/types                0.12.156 -> 0.12.280
* node_modules/@cosmos-kit/keplr-extension                                                 2.14.0 -> 2.15.7
* node_modules/@cosmos-kit/keplr-mobile                                                    2.14.1 -> 2.15.7
* node_modules/@cosmos-kit/keplr                                                           2.14.1 -> 2.15.7
* node_modules/@cosmos-kit/leap-extension                                                  2.14.1 -> 2.15.6
* node_modules/@cosmos-kit/leap-metamask-cosmos-snap                                       0.14.1 -> 0.15.6
* node_modules/@cosmos-kit/leap-mobile                                                     2.13.1 -> 2.14.6
* node_modules/@cosmos-kit/leap                                                            2.14.1 -> 2.15.6
* node_modules/@cosmos-kit/walletconnect                                                   2.12.0 -> 2.13.6
* node_modules/@keplr-wallet/provider-extension/node_modules/@keplr-wallet/types           0.12.156 -> 0.12.280
* node_modules/@keplr-wallet/provider-extension                                            0.12.156 -> 0.12.280
* node_modules/@keplr-wallet/provider/node_modules/@keplr-wallet/types                     0.12.156 -> 0.12.280
* node_modules/@keplr-wallet/provider                                                      0.12.156 -> 0.12.280
* node_modules/@keplr-wallet/router                                                        0.12.156 -> 0.12.280
* node_modules/@keplr-wallet/wc-client/node_modules/@keplr-wallet/types                    0.12.156 -> 0.12.280
* node_modules/@keplr-wallet/wc-client                                                     0.12.156 -> 0.12.280
* node_modules/@scure/base                                                                 1.2.5 -> 1.2.6
* node_modules/@walletconnect/core/node_modules/@walletconnect/types                       2.21.3 -> 2.22.4
* node_modules/@walletconnect/core                                                         2.21.3 -> 2.22.4
* node_modules/@walletconnect/sign-client/node_modules/@walletconnect/types                2.21.3 -> 2.22.4
* node_modules/@walletconnect/sign-client                                                  2.21.3 -> 2.22.4
* node_modules/@walletconnect/utils/node_modules/@noble/curves                             1.9.2 -> 1.9.7
* node_modules/@walletconnect/utils/node_modules/@walletconnect/types                      2.21.3 -> 2.22.4
* node_modules/@walletconnect/utils                                                        2.21.3 -> 2.22.4
* node_modules/abitype                                                                     1.0.8 -> 1.1.1
* node_modules/lossless-json                                                               4.1.0 -> 4.3.0
* node_modules/ox                                                                          0.7.1 -> 0.9.3
* node_modules/starknet-types-07 -> node_modules/                                          starknet-io/starknet-types-07
* node_modules/starknet                                                                    6.24.1 -> 7.6.4
* packages/http-sdk/node_modules/@cosmjs/encoding                                          0.32.4 -> 0.36.1
* packages/http-sdk/node_modules/@cosmjs/math                                              0.32.4 -> 0.36.1
* packages/http-sdk/node_modules/@cosmjs/stargate                                          0.32.4 -> 0.36.1
+ apps/notifications/node_modules/@cosmjs/tendermint-rpc/node_modules/@cosmjs/math         0.36.1  
+ node_modules/@cosmos-kit/core/node_modules/@dao-dao/cosmiframe                           1.0.0   
+ node_modules/@keplr-wallet/provider-extension/node_modules/uuid                          11.1.0  
+ node_modules/@starknet-io/starknet-types-08                                              0.8.4   
+ node_modules/@walletconnect/utils/node_modules/@walletconnect/logger                     3.0.0   
+ node_modules/@walletconnect/utils/node_modules/on-exit-leak-free                         2.1.2   
+ node_modules/@walletconnect/utils/node_modules/pino-abstract-transport                   2.0.0   
+ node_modules/@walletconnect/utils/node_modules/pino-std-serializers                      7.0.0   
+ node_modules/@walletconnect/utils/node_modules/pino                                      10.0.0  
+ node_modules/@walletconnect/utils/node_modules/process-warning                           5.0.0   
+ node_modules/@walletconnect/utils/node_modules/real-require                              0.2.0   
+ node_modules/@walletconnect/utils/node_modules/sonic-boom                                4.2.0   
+ node_modules/@walletconnect/utils/node_modules/thread-stream                             3.1.0   
+ node_modules/hash-wasm                                                                   4.12.0  
+ node_modules/slow-redact                                                                 0.3.2   
+ packages/http-sdk/node_modules/@cosmjs/amino                                             0.36.1  
+ packages/http-sdk/node_modules/@cosmjs/crypto                                            0.36.1  
+ packages/http-sdk/node_modules/@cosmjs/json-rpc                                          0.36.1  
+ packages/http-sdk/node_modules/@cosmjs/proto-signing                                     0.36.1  
+ packages/http-sdk/node_modules/@cosmjs/socket                                            0.36.1  
+ packages/http-sdk/node_modules/@cosmjs/stream                                            0.36.1  
+ packages/http-sdk/node_modules/@cosmjs/tendermint-rpc                                    0.36.1  
+ packages/http-sdk/node_modules/@cosmjs/utils                                             0.36.1  
+ packages/http-sdk/node_modules/@noble/ciphers                                            1.3.0   
+ packages/http-sdk/node_modules/@noble/curves                                             1.9.7   
+ packages/http-sdk/node_modules/cosmjs-types                                              0.10.1  
+ packages/http-sdk/node_modules/ws                                                        7.5.10  
- apps/notifications/node_modules/@cosmjs/crypto/node_modules/@cosmjs/utils                0.32.4  
- apps/notifications/node_modules/@cosmjs/math                                             0.33.1  
- apps/notifications/node_modules/@cosmjs/tendermint-rpc/node_modules/@cosmjs/crypto       0.33.1  
- apps/provider-proxy/node_modules/@cosmjs/crypto/node_modules/@cosmjs/encoding            0.33.1  
- node_modules/@akashnetwork/chain-sdk/node_modules/@cosmjs/stargate/node_modules/@cosmjs/amino 0.33.1  
- node_modules/@chain-registry/cosmostation/node_modules/@chain-registry/types             0.45.57 
- node_modules/@chain-registry/keplr/node_modules/@chain-registry/types                    0.45.55 
- node_modules/@cosmos-kit/core/node_modules/@chain-registry/keplr/node_modules/@chain-registry/types 0.50.12 
- node_modules/@cosmos-kit/leap-mobile/node_modules/@chain-registry/keplr                  1.74.31 
- node_modules/@walletconnect/utils/node_modules/@scure/base                               1.2.6   
- node_modules/fetch-cookie                                                                3.0.1   
- node_modules/filter-obj                                                                  1.1.0   
- node_modules/isomorphic-fetch                                                            3.0.0   
- node_modules/isows                                                                       1.0.7   
- node_modules/json2csv/node_modules/commander                                             6.2.1   
- node_modules/json2csv                                                                    5.0.7   
- node_modules/query-string                                                                7.1.3   
- node_modules/set-cookie-parser                                                           2.7.1   
- node_modules/split-on-first                                                              1.1.0   
- node_modules/strict-uri-encode                                                           2.0.0   
- node_modules/viem                                                                        2.31.0  

ygrishajev and others added 11 commits October 27, 2025 14:30
* feat(network): testnet deposit implementation

* feat(analytics): implement new handlers for indexing

* feat(analytics): add protobuf types from chain sdk for indexer

* fix(analytics): remove test throw

* feat: update chain-sdk indexer

* feat: update net package
* refactor: migrate provider-proxy to next chain sdk (#1980)

* feat(analytics): chain sdk next indexer (#1983)

* feat(network): testnet deposit implementation

* feat(analytics): implement new handlers for indexing

* feat(analytics): add protobuf types from chain sdk for indexer

* fix(analytics): remove test throw

* feat: update chain-sdk indexer

* feat: update net package

* fix: net package testnet (#2016)

fix: net config data

* feat: implement new chain sdk types in api

* fix: replace DepositAuthorization

* fix: update http sdk + functional test envs

* fix: undo frontend code changes

* fix: balance calculation

* fix: pr fixes

* fix: gpu prices test

* fix: tests

* fix: fallback deployment tests

* fix: stripe webhook tests

* fix: balances test

* fix: api structure for leases + tests

* fix: lease fallback tests

* fix: tests

* fix: build fix

* fix: faucet json

* refactor: gets rid of akashjs and akash-api

* fix: pr fixes for tests

* fix: build

* fix: sdl

---------

Co-authored-by: Serhii Stotskyi <sergiy.stotskiy@gmail.com>
@codecov
Copy link

codecov bot commented Oct 27, 2025

Codecov Report

❌ Patch coverage is 61.81818% with 189 lines in your changes missing coverage. Please review.
✅ Project coverage is 46.42%. Comparing base (46841af) to head (bea3e24).
⚠️ Report is 20 commits behind head on main.
✅ All tests successful. No failed tests found.

Files with missing lines Patch % Lines
.../components/deployments/DeploymentDepositModal.tsx 0.00% 17 Missing and 1 partial ⚠️
...CertificateProvider/CertificateProviderContext.tsx 6.25% 14 Missing and 1 partial ⚠️
...pps/deploy-web/src/utils/TransactionMessageData.ts 28.57% 15 Missing ⚠️
...pps/deploy-web/src/components/sdl/RentGpusForm.tsx 0.00% 13 Missing and 1 partial ⚠️
...b/src/components/deployments/DeploymentListRow.tsx 0.00% 13 Missing ⚠️
...web/src/components/new-deployment/ManifestEdit.tsx 0.00% 9 Missing and 2 partials ⚠️
...-web/src/components/deployments/ManifestUpdate.tsx 0.00% 8 Missing and 1 partial ⚠️
...vices/gpu-bids-creator/gpu-bids-creator.service.ts 0.00% 8 Missing ⚠️
.../components/deployments/DeploymentDetailTopBar.tsx 0.00% 7 Missing ⚠️
...in/providers/comet-client/comet-client.provider.ts 0.00% 7 Missing ⚠️
... and 33 more

❌ Your patch status has failed because the patch coverage (46.25%) is below the target coverage (50.00%). You can increase the patch coverage or adjust the target coverage.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #2114      +/-   ##
==========================================
+ Coverage   46.11%   46.42%   +0.31%     
==========================================
  Files        1019     1016       -3     
  Lines       28877    28674     -203     
  Branches     7543     7436     -107     
==========================================
- Hits        13316    13313       -3     
+ Misses      15252    14259     -993     
- Partials      309     1102     +793     
Flag Coverage Δ
api 82.03% <84.73%> (-0.24%) ⬇️
deploy-web 24.63% <46.25%> (+0.33%) ⬆️
log-collector 75.35% <ø> (ø)
notifications 88.11% <84.28%> (-0.05%) ⬇️
provider-console 81.48% <ø> (ø)
provider-proxy 84.61% <ø> (ø)
Files with missing lines Coverage Δ
...pi/src/address/services/address/address.service.ts 69.49% <ø> (ø)
apps/api/src/bid/http-schemas/bid.schema.ts 100.00% <ø> (ø)
apps/api/src/bid/services/bid/bid.service.ts 100.00% <100.00%> (ø)
apps/api/src/billing/config/env.config.ts 100.00% <ø> (ø)
apps/api/src/billing/http-schemas/tx.schema.ts 100.00% <ø> (ø)
...tch-signing-client/batch-signing-client.service.ts 90.37% <100.00%> (ø)
...ng-stargate-client/sync-signing-stargate-client.ts 100.00% <100.00%> (ø)
apps/api/src/billing/lib/wallet/wallet.ts 78.78% <100.00%> (ø)
...pi/src/billing/providers/type-registry.provider.ts 100.00% <100.00%> (ø)
.../src/billing/services/balances/balances.service.ts 96.36% <100.00%> (-0.25%) ⬇️
... and 78 more

... and 181 files with indirect coverage changes

🚀 New features to boost your workflow:
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

baktun14 and others added 9 commits October 27, 2025 14:32
* feat: update proto types to chain-sdk

* feat: implement testnet console-web

* feat: chain-sdk deployments + remove akashjs

* fix: pr fixes

* fix: pr fixes
* fix(deployment): get all deployment grants

* fix: onboarding redirects

* fix: remove log

* fix: functional tests with sandbox

* fix: env var

* fix: remove log

* fix: undo faucet changes

* fix: faucet url

* fix: tests

* fix: remove testnet providers test

* fix: window not defined
Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 50

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (28)
apps/api/test/functional/provider-graph-data.spec.ts (1)

206-206: Avoid using type any.

The code casts the response to any, which violates the coding guideline. Define a proper TypeScript interface for the expected response structure.

As per coding guidelines.

+interface ProviderGraphDataResponse {
+  currentValue: number;
+  compareValue: number;
+  snapshots: Array<{ date: string; value: number }>;
+  now: {
+    count: number;
+    cpu: number;
+    gpu: number;
+    memory: number;
+    storage: number;
+  };
+  compare: {
+    count: number;
+    cpu: number;
+    gpu: number;
+    memory: number;
+    storage: number;
+  };
+}
+
-        const data = (await response.json()) as any;
+        const data = (await response.json()) as ProviderGraphDataResponse;
apps/deploy-web/src/utils/walletUtils.ts (2)

109-109: Type inconsistency: use NetworkId instead of string.

The networkId parameter should be typed as NetworkId | undefined to match the type used consistently throughout the file (lines 35, 79, 86, 97, 114).

Apply this diff:

-export function updateStorageWallets(wallets: LocalWallet[], networkId?: string) {
+export function updateStorageWallets(wallets: LocalWallet[], networkId?: NetworkId) {

114-132: Pass networkId to wallet storage operations.

The function computes selectedNetworkId from the networkId parameter (line 115) but doesn't pass it to getStorageWallets() (line 116) and updateStorageWallets() (line 119). This causes operations to target the default network instead of the specified one, leading to data inconsistency when managing wallets across different networks.

Apply this diff:

 export function deleteWalletFromStorage(address: string, deleteDeployments: boolean, networkId?: NetworkId) {
   const selectedNetworkId = networkId || networkStore.selectedNetworkId;
-  const wallets = getStorageWallets();
+  const wallets = getStorageWallets(networkId);
   const newWallets = wallets.filter(w => w.address !== address).map((w, i) => ({ ...w, selected: i === 0 }));
 
-  updateStorageWallets(newWallets);
+  updateStorageWallets(newWallets, networkId);
apps/notifications/test/seeders/message.seeder.ts (2)

143-143: Incomplete migration: Hardcoded v1beta3 typeUrl.

This function still uses the hardcoded v1beta3 typeUrl while the rest of the file has been migrated to v1beta4 with dynamic type construction. This creates inconsistency in test data where create deployment messages use v1beta4 types but close deployment messages use v1beta3.

Apply this diff to align with the SDK53 migration:

-    typeUrl: "/akash.deployment.v1beta3.MsgCloseDeployment",
+    typeUrl: `/${MsgCloseDeployment.$type}`,

282-290: Incomplete migration: v1beta3 hardcoded throughout.

This entire function still uses hardcoded v1beta3 type strings (lines 282, 283, 289) while the corresponding generateMsgCreateDeployment function was updated to use dynamic types. This creates inconsistent test data mixing v1beta3 and v1beta4 message types.

Apply this diff to align with the SDK53 migration:

   return {
-    type: "akash.deployment.v1beta3.MsgCloseDeployment",
-    typeUrl: "/akash.deployment.v1beta3.MsgCloseDeployment",
+    type: MsgCloseDeployment.$type,
+    typeUrl: `/${MsgCloseDeployment.$type}`,
     value: {
       id: {
         dseq: { low: parseInt(deploymentId.dseq, 10) },
         owner: deploymentId.owner
       },
-      $type: "akash.deployment.v1beta3.MsgCloseDeployment"
+      $type: MsgCloseDeployment.$type
     }
   };
apps/api/src/billing/services/managed-signer/managed-signer.service.spec.ts (2)

34-34: Remove as any type casts.

These type casts violate the coding guidelines which explicitly state: "Never use type any or cast to type any. Always define the proper TypeScript types."

As per coding guidelines.

Apply this diff to use proper types:

-      await expect(service.executeDecodedTxByUserId(null as any, [])).rejects.toThrow("User Not Found");
+      await expect(service.executeDecodedTxByUserId(null!, [])).rejects.toThrow("User Not Found");
-      await expect(service.executeDecodedTxByUserId(undefined as any, [])).rejects.toThrow("User Not Found");
+      await expect(service.executeDecodedTxByUserId(undefined!, [])).rejects.toThrow("User Not Found");

Also applies to: 40-40


143-143: Replace explicit any type with unknown.

The explicit any type annotation violates the coding guidelines. Use unknown instead, which is type-safe and requires proper type narrowing.

As per coding guidelines.

Apply this diff:

-    } catch (error: any) {
+    } catch (error: unknown) {
apps/deploy-web/src/utils/deploymentData/v1beta3.ts (2)

98-98: Critical logic bug when deposit array lacks matching denom.

When deposit is an array but deposit.find() returns undefined (no matching denom), the fallback deposit.toString() is called on the array, producing an invalid string like "[object Object],[object Object]" instead of a valid amount.

Apply this diff to fix the logic:

-    const _deposit = (Array.isArray(deposit) && deposit.find(d => d.denom === denom)) || { denom, amount: deposit.toString() };
+    const _deposit = Array.isArray(deposit) 
+      ? (deposit.find(d => d.denom === denom) || { denom, amount: "0" })
+      : { denom, amount: deposit.toString() };

Alternatively, throw an error if the required denom is not found in the array:

-    const _deposit = (Array.isArray(deposit) && deposit.find(d => d.denom === denom)) || { denom, amount: deposit.toString() };
+    const _deposit = Array.isArray(deposit) 
+      ? deposit.find(d => d.denom === denom) ?? (() => { throw new Error(`Deposit denom ${denom} not found in provided deposits`); })()
+      : { denom, amount: deposit.toString() };

106-118: Breaking change: verify and update all consumers of the return object.

The return object structure in apps/deploy-web/src/utils/deploymentData/v1beta3.ts (lines 106-118) has breaking changes:

  • version field replaced with hash
  • depositor field removed entirely

Found active consumers that require updates:

  • apps/stats-web/src/components/transactions/akash/MsgCreateDeployment.tsx:24 - directly references data?.depositor
  • apps/stats-web/src/components/transactions/akash/MsgDepositDeployment.tsx:17 - directly references message?.data?.depositor

Update these components to remove references to the removed depositor field and ensure they use hash instead of version.

apps/notifications/src/modules/chain/services/tx-events-service/tx-events.service.spec.ts (1)

187-195: Align setup() with test guidelines: accept param, return SUT, and surface mocks.

Per the repo’s spec guidelines, setup should accept a single param (inline typed), create the object under test, and return it (avoid shared state). Update setup to accept overrides and return service and cometClient, then simplify the test body.

Proposed change:

@@
-  async function setup() {
-    const module = await Test.createTestingModule({
-      providers: [TxEventsService, { provide: Comet38Client, useValue: mock<Comet38Client>() }, MockProvider(LoggerService)]
-    }).compile();
-
-    return {
-      module
-    };
-  }
+  async function setup(opts: {
+    cometClient?: DeepPartial<Comet38Client>;
+    logger?: DeepPartial<LoggerService>;
+  } = {}) {
+    const module = await Test.createTestingModule({
+      providers: [
+        TxEventsService,
+        MockProvider(Comet38Client, opts.cometClient),
+        MockProvider(LoggerService, opts.logger),
+      ],
+    }).compile();
+    const service = module.get<TxEventsService>(TxEventsService);
+    const cometClient = module.get<MockProxy<Comet38Client>>(Comet38Client);
+    return { service, cometClient, module };
+  }

And in the test:

-      const { module } = await setup();
-      const service = module.get<TxEventsService>(TxEventsService);
-      const cometClient = module.get<MockProxy<Comet38Client>>(Comet38Client);
+      const { service, cometClient } = await setup();

Based on coding guidelines

Also applies to: 15-17

apps/api/src/billing/services/balances/balances.service.ts (1)

87-92: Add null safety check for escrowAccount.state.funds before calling .reduce().

The review comment is valid. While the DeploymentInfoSchema defines funds as a required array, the codebase uses inconsistent defensive patterns, indicating runtime concerns.

Evidence of inconsistency in the same file (deployment-reader.service.ts):

  • Line 256 uses optional chaining: state.funds[0]?.denom
  • Line 296 directly accesses without checks: state.funds.reduce(...)

Additionally, deploymentDetailUtils.ts (line 19) checks if (d.escrow_account.state.funds.length > 0) before access. This mixed approach suggests state.funds may not always be guaranteed at runtime, even if the schema requires it.

Adding a null check ensures the code won't throw a TypeError if state.funds is undefined:

const deploymentEscrowBalance = activeDeployments.reduce((total: number, deployment: DeploymentInfo) => {
  const escrowAccount = deployment.escrow_account;
  if (!escrowAccount || !escrowAccount.state.funds) return total;

  return total + parseFloat(escrowAccount.state.funds.reduce((sum, { amount }) => sum + parseFloat(amount), 0).toFixed(18));
}, 0);
apps/deploy-web/src/components/new-deployment/CreateLease/CreateLease.spec.tsx (1)

47-56: Use queryBy for expectations in deploy-web specs.*

Per guidelines for apps/deploy-web .spec.tsx, prefer queryBy* in expectations. Replace getBy*/screen.getBy* in asserts within waitFor. Example patch:

-    const { getByRole } = setup({
+    const { queryByRole } = setup({
       BidGroup,
       bids
     });
 ...
-      expect(getByRole("button", { name: /Accept Bid/i })).toBeInTheDocument();
+      expect(queryByRole("button", { name: /Accept Bid/i })).toBeInTheDocument();

Similarly:

-    const { getByRole } = setup({
+    const { queryByRole } = setup({
       BidGroup,
       bids
     });
-      expect(getByRole("button", { name: /Accept Bid/i })).toBeInTheDocument();
+      expect(queryByRole("button", { name: /Accept Bid/i })).toBeInTheDocument();
-      expect(getByRole("button", { name: /Close Deployment/i })).toBeInTheDocument();
-      expect(queryByRole("button", { name: /Accept Bid/i })).not.toBeInTheDocument();
+      expect(queryByRole("button", { name: /Close Deployment/i })).toBeInTheDocument();
+      expect(queryByRole("button", { name: /Accept Bid/i })).not.toBeInTheDocument();
-      expect(screen.getByText(/Blockchain is unavailable/i)).toBeInTheDocument();
+      expect(screen.queryByText(/Blockchain is unavailable/i)).toBeInTheDocument();
-        expect(screen.getByRole<HTMLButtonElement>("button", { name: /Accept Bid/i })).not.toBeDisabled();
+        expect(screen.queryByRole<HTMLButtonElement>("button", { name: /Accept Bid/i })).not.toBeDisabled();
-        expect(screen.getByRole<HTMLButtonElement>("button", { name: /Accept Bid/i })).not.toBeDisabled();
+        expect(screen.queryByRole<HTMLButtonElement>("button", { name: /Accept Bid/i })).not.toBeDisabled();
-        expect(screen.getByRole<HTMLButtonElement>("button", { name: /Re-send Manifest/i })).not.toBeDisabled();
+        expect(screen.queryByRole<HTMLButtonElement>("button", { name: /Re-send Manifest/i })).not.toBeDisabled();

Also applies to: 88-96, 98-104, 127-133, 178-180, 196-199, 248-250, 316-318

apps/indexer/src/shared/utils/protobuf.ts (1)

18-26: Filter Akash API values by $type to avoid "/undefined" registry entries.

Current akashTypes maps all Object.values() without guarding for $type. This can register invalid keys (e.g., "/undefined") and non‑GeneratedType values.

Apply:

-const akashTypes: ReadonlyArray<[string, GeneratedType]> = [
-  ...Object.values(v1beta1),
-  ...Object.values(v1beta2),
-  ...Object.values(v1beta3),
-  ...Object.values(prevV1beta4)
-].map(x => ["/" + x.$type, x]);
+const akashTypes: ReadonlyArray<[string, GeneratedType]> = [
+  ...Object.values(v1beta1),
+  ...Object.values(v1beta2),
+  ...Object.values(v1beta3),
+  ...Object.values(prevV1beta4)
+]
+  .filter((x: any): x is { $type: string } => "$type" in x)
+  .map(x => ["/" + x.$type, x as unknown as GeneratedType]);
apps/deploy-web/src/hooks/useWalletBalance.ts (1)

66-68: Bug: totalDeploymentGrantsUUSDC is assigned from deploymentEscrowUAKT.

Likely copy/paste error.

-        totalDeploymentGrantsUUSDC: balances.deploymentEscrowUAKT,
+        totalDeploymentGrantsUUSDC: balances.deploymentGrantsUUSDC,
apps/notifications/src/modules/chain/services/tx-events-service/tx-events.service.ts (1)

73-79: Critical: Comet38 uses txsResults, not results; handle null safely.

blockResults.results will be undefined and break. Use txsResults ?? [] in both places.

-        transactionCount: blockResults.results.length
+        transactionCount: (blockResults.txsResults ?? []).length
@@
-    return blockResults.results
+    return (blockResults.txsResults ?? [])
       .map(result => {
         let events: Event[] = [];

Also applies to: 111-125

apps/stats-web/src/types/deployment.ts (1)

81-111: Remove any[] per repo TS guidelines; define an Attribute type.

Violations found at 8 locations across both DeploymentGroup_v2 and DeploymentGroup_v3:

  • Lines 86, 92, 98, 105 (cpu, gpu, memory, storage attributes in v2)
  • Lines 147, 153, 159, 166 (cpu, gpu, memory, storage attributes in v3)

Define an Attribute type and replace all instances:

+type Attribute = { key: string; value: string };

Then replace each attributes: any[] with attributes: Attribute[] across all 8 occurrences.

This aligns with the typed attributes pattern already used for provider.attributes and requirements.attributes elsewhere in the file.

apps/deploy-web/src/components/sdl/RentGpusForm.tsx (1)

126-136: Type deposit explicitly to avoid implicit any/over‑broad inference

Clarify union to match callers and SDK.

-async function createAndValidateDeploymentData(yamlStr: string, dseq: string | null = null, deposit = defaultDeposit) {
+async function createAndValidateDeploymentData(
+  yamlStr: string,
+  dseq: string | null = null,
+  deposit: number | DepositParams[] = defaultDeposit as number | DepositParams[]
+) {

Also consider dropping the default and always passing deposit from caller to prevent unintended string defaults.

apps/api/src/billing/services/trial-validation/trial-validation.service.ts (1)

47-57: AUDITOR check is too strict; use inclusion, not equality.

every(signedBy => signedBy === AUDITOR) rejects providers that include AUDITOR plus other signers. Use some(...) or includes(AUDITOR).

Apply this diff:

-      const hasSignedByAllOf = group.requirements?.signedBy?.allOf.every(signedBy => {
-        return signedBy === AUDITOR;
-      });
-      assert(hasAttribute && hasSignedByAllOf, 400, `provider not authorized: ${JSON.stringify(group.requirements?.attributes)}`);
+      const hasAuditor = group.requirements?.signedBy?.allOf?.some(addr => addr === AUDITOR) === true;
+      assert(hasAttribute && hasAuditor, 400, `provider not authorized: ${JSON.stringify(group.requirements?.attributes)}`);
apps/api/test/functional/balances.spec.ts (1)

47-47: Remove the any type cast.

The as any cast violates the coding guideline that forbids using type any. Define a proper TypeScript interface for the response structure.

As per coding guidelines.

Apply this diff to define a proper type:

+interface BalancesResponse {
+  data: {
+    balance: number;
+    deployments: number;
+    total: number;
+  };
+}
+
     const response = await app.request("/v1/balances", {
       method: "GET",
       headers: new Headers({
         "Content-Type": "application/json",
         "x-api-key": apiKey
       })
     });

     expect(response.status).toBe(200);
-    const result = (await response.json()) as any;
+    const result = (await response.json()) as BalancesResponse;
apps/deploy-web/src/services/auto-top-up-message/auto-top-up-message.service.ts (2)

48-69: Fix optional chaining and honor denom for fee allowances.

  1. Bug: options.next?.expiration.getTime() dereferences getTime on possibly undefined.
  2. Logic: collectFeeMessages always grants "uakt", ignoring USDC. Use options.denom (and pass it from callers).

Apply:

- const isSameExpiration = options.prev?.expiration?.getTime() === options.next?.expiration.getTime();
+ const isSameExpiration = options.prev?.expiration?.getTime() === options.next?.expiration?.getTime();
- if (options.next?.limit) {
-   messages.push(TransactionMessageData.getGrantBasicAllowanceMsg(options.granter, options.grantee, options.next.limit, "uakt", options.next.expiration));
+ if (options.next?.limit) {
+   messages.push(
+     TransactionMessageData.getGrantBasicAllowanceMsg(
+       options.granter,
+       options.grantee,
+       options.next.limit,
+       options.denom ?? "uakt",
+       options.next.expiration
+     )
+   );

And pass denom from callers:

- ...this.collectFeeMessages({
+ ...this.collectFeeMessages({
    ...uaktSides,
+   denom: "uakt",
    prev: { /* ... */ },
    next: options.next && { /* ... */ }
  }),
- ...this.collectFeeMessages({
+ ...this.collectFeeMessages({
    ...usdcSides,
+   denom: this.usdcDenom,
    prev: { /* ... */ },
    next: options.next && { /* ... */ }
  }),

Also applies to: 97-115


119-121: Same optional chaining bug here.

Mirror the fix in collectDeploymentMessages.

- const isSameExpiration = options.prev?.expiration?.getTime() === options.next?.expiration.getTime();
+ const isSameExpiration = options.prev?.expiration?.getTime() === options.next?.expiration?.getTime();
apps/api/test/functional/sign-and-broadcast-tx.spec.ts (1)

48-53: Remove as any; use typed destructuring.

Avoids forbidden any type. As per coding guidelines, line 48 violates the "Never use type any" rule.

- const { token } = (await differentUserResponse.json()) as any;
+ const { token }: { token: string } = await differentUserResponse.json();
apps/deploy-web/src/components/deployments/DeploymentDetail.tsx (1)

96-104: Guard against undefined wallet address before reading local storage.

On initial render address can be empty/undefined; calling deploymentLocalStorage.get(address, dseq) may throw or read the wrong key.

   useEffect(() => {
     if (deployment) {
-      getLeases();
-      getProviders();
-      const deploymentData = deploymentLocalStorage.get(address, dseq);
+      getLeases();
+      getProviders();
+      if (!address) return;
+      const deploymentData = deploymentLocalStorage.get(address, dseq);
       setDeploymentManifest(deploymentData?.manifest || "");
     }
-  }, [deployment, dseq, getLeases, getProviders, address, deploymentLocalStorage]);
+  }, [deployment, dseq, getLeases, getProviders, address, deploymentLocalStorage]);
apps/deploy-web/src/components/new-deployment/CreateLease/CreateLease.tsx (1)

183-198: Bug: isSendingManifest can get stuck true on early return.

You set setIsSendingManifest(true) and then return if no local manifest, skipping the finally reset. UI can hang.

   const sendManifest = useCallback(
     async (cert: LocalCert) => {
-      setIsSendingManifest(true);
       const bidKeys = Object.keys(selectedBids);
 
-      const localDeploymentData = deploymentLocalStorage.get(address, dseq);
+      const localDeploymentData = deploymentLocalStorage.get(address, dseq);
 
       analyticsService.track("send_manifest", {
         category: "deployments",
         label: "Send manifest after creating lease"
       });
 
-      if (!localDeploymentData || !localDeploymentData.manifest) {
-        return;
-      }
+      if (!localDeploymentData || !localDeploymentData.manifest) {
+        return;
+      }
 
+      setIsSendingManifest(true);
       const sendManifestNotification =
         !isManaged &&
         enqueueSnackbar(<Snackbar title="Deploying! 🚀" subTitle="Please wait a few seconds..." showLoading />, {
           variant: "info",
           autoHideDuration: null
         });

Alternatively, move the early-return into the try { ... } finally { setIsSendingManifest(false) } block.

apps/api/test/seeders/deployment-info.seeder.ts (1)

12-12: Rename input field to reflect API: version → hash

The seeder input still exposes version, but output writes hash. Rename for clarity and to avoid confusion across tests.

-export interface DeploymentInfoSeederInput {
+export interface DeploymentInfoSeederInput {
   owner?: string;
   dseq?: string;
   state?: string;
-  version?: string;
+  hash?: string;
   createdAt?: string;
   amount?: string;
   denom?: string;
 }

And update usages accordingly in this file.

apps/deploy-web/src/components/deployments/DeploymentDepositModal.tsx (1)

100-117: <!-- [scratchpad_start]
[task: verify_onDeploymentDeposit_signature 3/3]
[observations]

  • DeploymentDepositModal prop type (line 27): onDeploymentDeposit: (deposit: number) => void;
  • DeploymentDetailTopBar impl (line 101): async (deposit: number) => { ... return response; } - returns a value
  • DeploymentDetailTopBar usage (line 142): const isSuccess = await onDeploymentDeposit(deposit); - awaits and checks return
  • Reviewed code line 116: onDeploymentDeposit(deposit); - calls without await (consistent with void type)
  • All implementations (DetailTopBar, ListRow, RentGpusForm, ManifestEdit) are async with return values
  • Prop type is void but all callsites expect Promise with return value

[analysis]

  • CRITICAL TYPE MISMATCH: Prop signature declares void but all implementations return Promises
  • DeploymentDetailTopBar will receive undefined for isSuccess (line 144 check will always be falsy)
  • This is a runtime bug disguised as TypeScript: code compiles but fails at runtime
  • The reviewed code (onSubmit) itself is fine - it just calls the prop without await
  • The bug is in the prop type definition (line 27) which is outside reviewed code range
  • But the issue affects correctness of all callsites including DeploymentDetailTopBar

[critical_issue]

  • Type definition at line 27 is WRONG
  • Should be: onDeploymentDeposit: (deposit: number) => Promise<any>; or similar
  • Current type allows void return but all implementations return Promises

[decision]

  • Original review says "" but missed type error
  • The reviewed code (100-117) is fine, but prop type (line 27) needs fixing
  • Tag as to flag the type error
    [/scratchpad_end] -->

Prop type signature mismatch: onDeploymentDeposit returns Promise but typed as void

The prop type at line 27 declares onDeploymentDeposit: (deposit: number) => void;, but all implementations (DeploymentDetailTopBar, DeploymentListRow, RentGpusForm, ManifestEdit) are async functions that return Promise-based values.

DeploymentDetailTopBar at line 142 awaits and checks the return value (const isSuccess = await onDeploymentDeposit(deposit); if (!isSuccess) { return; }), but receives undefined because the prop is typed as void. This causes a logic bug.

Fix: Line 27 should be onDeploymentDeposit: (deposit: number) => Promise<any>; (or the appropriate Promise return type matching implementations).

apps/deploy-web/src/types/deployment.ts (2)

90-141: Resource.gpu/endpoints should be optional; also consider reusing DeploymentResource instead of inlining.

Many groups omit GPU; requiring gpu and endpoints can cause unnecessary type churn. Make them optional. Also, this inline struct duplicates DeploymentResource; prefer reuse.

Minimal fix (make fields optional):

-        gpu: {
+        gpu?: {
           units: {
             val: string;
           };
           attributes: Array<{
             key: string;
             value: string;
           }>;
         };
-        endpoints: Array<{
+        endpoints?: Array<{
           kind: string;
           sequence_number: number;
         }>;

De-duplication alternative:

-    resources: Array<{
-      resource: {
-        id: number;
-        cpu: { /* ... */ };
-        memory: { /* ... */ };
-        storage: Array<{ /* ... */ }>;
-        gpu?: { /* ... */ };
-        endpoints?: Array<{ /* ... */ }>;
-      };
+    resources: Array<{
+      resource: DeploymentResource_V3;
       count: number;
       price: { denom: string; amount: string };
     }>;

165-214: Same as v2: make gpu and endpoints optional; prefer reusing DeploymentResource_V3.

Mirror the v2 changes here to avoid divergence between versions.

-        gpu: {
+        gpu?: {
           units: {
             val: string;
           };
           attributes: Array<{
             key: string;
             value: string;
           }>;
         };
-        endpoints: Array<{
+        endpoints?: Array<{
           kind: string;
           sequence_number: number;
         }>;

Or replace the inline resource with DeploymentResource_V3 as in the v2 comment.

@@ -0,0 +1,59 @@
name: Deploy Deploy Web testnet
Copy link
Contributor

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🟡 Minor

Fix workflow name typo.

Line 1 has "Deploy Deploy Web testnet" – should be "Deploy Console Web testnet" (remove duplicate "Deploy").

-name: Deploy Deploy Web testnet
+name: Deploy Console Web testnet
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
name: Deploy Deploy Web testnet
name: Deploy Console Web testnet
🤖 Prompt for AI Agents
.github/workflows/console-web-deploy-testnet.yml lines 1-1: The workflow name
has a typo "Deploy Deploy Web testnet"; update the name to "Deploy Console Web
testnet" by removing the duplicate "Deploy" and inserting "Console" so the first
line reads the corrected workflow name.

Comment on lines 105 to 114
getRevokeAllowanceMsg({ granter, grantee }: { granter: string; grantee: string }) {
return {
typeUrl: "/cosmos.feegrant.v1beta1.MsgRevokeAllowance",
typeUrl: `/${MsgRevokeAllowance.$type}`,
value: MsgRevoke.fromPartial({
granter,
grantee,
msgTypeUrl: "/cosmos.feegrant.v1beta1.MsgGrantAllowance"
msgTypeUrl: `/${MsgGrantAllowance.$type}`
})
};
}
Copy link
Contributor

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🔴 Critical

🧩 Analysis chain

Bug: typeUrl/value mismatch for feegrant revoke.

You set typeUrl to /${MsgRevokeAllowance.$type} but encode MsgRevoke. Use MsgRevokeAllowance value (no msgTypeUrl) or switch typeUrl to /${MsgRevoke.$type}.

Apply one of these diffs (prefer A):

Option A (preferred: feegrant-specific revoke):

-  return {
-    typeUrl: `/${MsgRevokeAllowance.$type}`,
-    value: MsgRevoke.fromPartial({
-      granter,
-      grantee,
-      msgTypeUrl: `/${MsgGrantAllowance.$type}`
-    })
-  };
+  return {
+    typeUrl: `/${MsgRevokeAllowance.$type}`,
+    value: MsgRevokeAllowance.fromPartial({
+      granter,
+      grantee
+    })
+  };

Option B (generic authz revoke of feegrant):

-  return {
-    typeUrl: `/${MsgRevokeAllowance.$type}`,
-    value: MsgRevoke.fromPartial({
+  return {
+    typeUrl: `/${MsgRevoke.$type}`,
+    value: MsgRevoke.fromPartial({
       granter,
       grantee,
       msgTypeUrl: `/${MsgGrantAllowance.$type}`
     })
   };

🏁 Script executed:

#!/bin/bash
# Ensure no other mismatches between typeUrl and value constructor exist
rg -nP --type=ts 'typeUrl:\s*`/\$\{(.+?)\}`.*\n\s*value:\s*(\w+)\.fromPartial' -C1

Length of output: 0


I need to verify this issue more thoroughly using different approaches. Let me examine the file directly and search for type definitions.

Now let me examine the actual file to verify the imports and confirm the issue:

Based on my research, I've confirmed the distinction: MsgRevoke is from cosmos.authz.v1beta1 while MsgRevokeAllowance is from cosmos.feegrant.v1beta1. The review comment is identifying a real bug. Let me inspect the file to verify the exact context:


🏁 Script executed:

#!/bin/bash
# View the file with context around the bug
cat apps/api/src/billing/services/rpc-message-service/rpc-message.service.ts | head -120 | tail -25

Length of output: 604


🏁 Script executed:

#!/bin/bash
# Look for imports of MsgRevoke and MsgRevokeAllowance
rg -n "import.*Msg(Revoke|RevokeAllowance)" apps/api/src/billing/services/rpc-message-service/rpc-message.service.ts

Length of output: 158


🏁 Script executed:

#!/bin/bash
# Search for all typeUrl/value patterns in the file to find similar issues
rg -n "typeUrl:" apps/api/src/billing/services/rpc-message-service/rpc-message.service.ts -A2

Length of output: 1708


🏁 Script executed:

#!/bin/bash
# Check if this method is used elsewhere
rg -n "getRevokeAllowanceMsg" apps/

Length of output: 1152


🏁 Script executed:

#!/bin/bash
# Look for the pattern across the entire codebase
find apps/ -name "*.ts" -o -name "*.tsx" | xargs grep -l "getRevokeAllowanceMsg" 2>/dev/null || echo "No additional usage found"

Length of output: 415


Fix the typeUrl/value mismatch: use MsgRevokeAllowance instead of MsgRevoke.

The bug is confirmed. Line 107–108 mismatches the feegrant revocation message: typeUrl references MsgRevokeAllowance (feegrant module) but the value uses MsgRevoke.fromPartial() (authz module). These are incompatible. The method name getRevokeAllowanceMsg and typeUrl both clearly indicate this should be a feegrant operation, so apply Option A from the review: use MsgRevokeAllowance.fromPartial({ granter, grantee }) without the msgTypeUrl field (which doesn't exist on that message type).

🤖 Prompt for AI Agents
In apps/api/src/billing/services/rpc-message-service/rpc-message.service.ts
around lines 105 to 114, the returned message mixes feegrant and authz types:
the typeUrl indicates MsgRevokeAllowance but the value is built with
MsgRevoke.fromPartial and includes a msgTypeUrl field. Replace the value
construction to use MsgRevokeAllowance.fromPartial({ granter, grantee }) and
remove the msgTypeUrl property so the typeUrl and value match the feegrant
MsgRevokeAllowance shape.

Comment on lines 59 to 66
const acceptedBids = createBidMsgs.filter(createBidMsg =>
createLeaseMsgs.some(
l =>
l.bidId?.gseq === createBidMsg.decoded.order?.gseq &&
l.bidId?.oseq === createBidMsg.decoded.order?.oseq &&
l.bidId?.provider === createBidMsg.decoded.provider
)
createLeaseMsgs.some(l => {
const bidGseq = "gseq" in createBidMsg.decoded ? createBidMsg.decoded.gseq : (createBidMsg.decoded as v1beta5.MsgCreateBid).id?.gseq;
const bidOseq = "oseq" in createBidMsg.decoded ? createBidMsg.decoded.oseq : (createBidMsg.decoded as v1beta5.MsgCreateBid).id?.oseq;
const bidProvider = "provider" in createBidMsg.decoded ? createBidMsg.decoded.provider : (createBidMsg.decoded as v1beta5.MsgCreateBid).id?.provider;
return l.bidId?.gseq === bidGseq && l.bidId?.oseq === bidOseq && l.bidId?.provider === bidProvider;
})
);
Copy link
Contributor

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🔴 Critical

Bug: accepted bid match ignores order shape (v1beta1–v1beta4)

Older MsgCreateBid versions expose gseq/oseq under order. Current check will miss them. Extract from id || order before comparing.

Apply:

-    const acceptedBids = createBidMsgs.filter(createBidMsg =>
-      createLeaseMsgs.some(l => {
-        const bidGseq = "gseq" in createBidMsg.decoded ? createBidMsg.decoded.gseq : (createBidMsg.decoded as v1beta5.MsgCreateBid).id?.gseq;
-        const bidOseq = "oseq" in createBidMsg.decoded ? createBidMsg.decoded.oseq : (createBidMsg.decoded as v1beta5.MsgCreateBid).id?.oseq;
-        const bidProvider = "provider" in createBidMsg.decoded ? createBidMsg.decoded.provider : (createBidMsg.decoded as v1beta5.MsgCreateBid).id?.provider;
-        return l.bidId?.gseq === bidGseq && l.bidId?.oseq === bidOseq && l.bidId?.provider === bidProvider;
-      })
-    );
+    const acceptedBids = createBidMsgs.filter(({ decoded }) =>
+      createLeaseMsgs.some(l => {
+        const id = ("id" in decoded && decoded.id) || ("order" in decoded && decoded.order);
+        const provider = ("provider" in decoded && decoded.provider) || (id && "provider" in id ? id.provider : undefined);
+        const gseq = id?.gseq;
+        const oseq = id?.oseq;
+        return l.bidId?.gseq === gseq && l.bidId?.oseq === oseq && l.bidId?.provider === provider;
+      })
+    );
🤖 Prompt for AI Agents
In apps/api/src/deployment/repositories/message/message.repository.ts around
lines 59 to 66, the current matching logic extracts gseq/oseq/provider only from
top-level fields or id, but older MsgCreateBid versions store these under order;
update the extraction to prefer direct fields, then id, then order (i.e. use id
|| order) for gseq, oseq and provider before comparing to lease.bidId so all
v1beta1–v1beta5 shapes are covered; ensure null-safe optional chaining when
accessing id/order fields and keep comparisons unchanged otherwise.

Comment on lines +41 to 48
id: {
owner: lease.owner,
dseq: lease.dseq,
gseq: lease.gseq,
oseq: lease.oseq,
provider: lease.providerAddress
provider: lease.providerAddress,
bseq: 0 // Default value since bseq is not available in the database lease
},
Copy link
Contributor

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🟠 Major

Use database bseq instead of a hardcoded 0.

DB schema includes lease.bseq with default 0 and unique index across owner/dseq/gseq/oseq/provider/bseq. Hardcoding 0 can misidentify leases.

-          provider: lease.providerAddress,
-          bseq: 0 // Default value since bseq is not available in the database lease
+          provider: lease.providerAddress,
+          bseq: lease.bseq
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
id: {
owner: lease.owner,
dseq: lease.dseq,
gseq: lease.gseq,
oseq: lease.oseq,
provider: lease.providerAddress
provider: lease.providerAddress,
bseq: 0 // Default value since bseq is not available in the database lease
},
id: {
owner: lease.owner,
dseq: lease.dseq,
gseq: lease.gseq,
oseq: lease.oseq,
provider: lease.providerAddress,
bseq: lease.bseq
},
🤖 Prompt for AI Agents
In
apps/api/src/deployment/services/fallback-lease-reader/fallback-lease-reader.service.ts
around lines 41 to 48, the code hardcodes id.bseq = 0 which can misidentify
leases because the DB stores lease.bseq; replace the hardcoded 0 with the actual
lease.bseq value from the database (e.g., id.bseq = lease.bseq), and defensively
fall back to 0 only if lease.bseq is null/undefined to preserve existing
behavior.

Comment on lines +134 to 135
typeUrl: `${MsgCreateDeployment.$type}`,
value: MsgCreateDeployment.fromPartial({
Copy link
Contributor

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🔴 Critical

🧩 Analysis chain

typeUrl missing leading slash breaks registry matching.

EncodeObject.typeUrl must match the registry keys (usually /${Msg.$type}). Add the slash for both create and close messages.

Apply this diff:

-      typeUrl: `${MsgCreateDeployment.$type}`,
+      typeUrl: `/${MsgCreateDeployment.$type}`,
...
-      typeUrl: `${MsgCloseDeployment.$type}`,
+      typeUrl: `/${MsgCloseDeployment.$type}`,

Run to catch any other missing slashes:

Also applies to: 156-158


🏁 Script executed:

#!/bin/bash
# Find EncodeObjects whose typeUrl uses ${Msg.$type} without a leading slash
rg -nP --type=ts --type=tsx 'typeUrl:\s*`(?!/)\$\{[A-Za-z0-9_]+\.\$type\}`' -C2

Length of output: 27


I'll verify this by inspecting the file and running corrected shell scripts.Now let me run corrected verification scripts:


🏁 Script executed:

#!/bin/bash
# First, directly inspect the target file at the mentioned lines
echo "=== Checking lines 134-135 and 156-158 ==="
cat apps/api/src/deployment/services/gpu-bids-creator/gpu-bids-creator.service.ts | sed -n '130,160p'

Length of output: 888


Now let me search for other instances of typeUrl patterns in the codebase:

Now let me search for other instances of typeUrl patterns in the codebase:


🏁 Script executed:

#!/bin/bash
# Find all typeUrl patterns in the codebase (using basic grep first)
rg -n 'typeUrl:' --type=ts -C2

Length of output: 47073


Add leading slashes to typeUrl for MsgCreateDeployment and MsgCloseDeployment in gpu-bids-creator.service.ts.

Both lines 134 and 157 are missing the leading slash required for registry matching. The rest of the codebase consistently uses the /${Msg.$type} pattern (seen in rpc-message-service, TransactionMessageData, and test files). Apply the suggested diff:

-      typeUrl: `${MsgCreateDeployment.$type}`,
+      typeUrl: `/${MsgCreateDeployment.$type}`,
...
-      typeUrl: `${MsgCloseDeployment.$type}`,
+      typeUrl: `/${MsgCloseDeployment.$type}`,
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
typeUrl: `${MsgCreateDeployment.$type}`,
value: MsgCreateDeployment.fromPartial({
typeUrl: `/${MsgCreateDeployment.$type}`,
value: MsgCreateDeployment.fromPartial({
🤖 Prompt for AI Agents
In apps/api/src/deployment/services/gpu-bids-creator/gpu-bids-creator.service.ts
around lines 134 and 157, the typeUrl values for MsgCreateDeployment and
MsgCloseDeployment are missing the leading slash required for registry matching;
update both occurrences to prefix the message type with a slash (i.e. use
`/${MsgCreateDeployment.$type}` and `/${MsgCloseDeployment.$type}`) to match the
rest of the codebase and tests.

"@akashnetwork/logging": "*",
"@akashnetwork/net": "*",
"@cosmjs/encoding": "^0.32.4",
"@cosmjs/encoding": "~0.36.1",
Copy link
Contributor

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🔴 Critical

🧩 Analysis chain

Verify cosmjs version compatibility and rationale for tighter version pinning.

The changes shift from caret (^) to tilde (~) version specifiers for both @cosmjs/encoding and @cosmjs/amino, and bump the versions significantly (0.32→0.36, 0.33→0.36). While the alignment to ~0.36.1 is good, this stricter pinning strategy needs verification:

  1. Confirm that chain-sdk alpha.12 is compatible with cosmjs 0.36.1.
  2. Clarify why the version specifier was made more restrictive (was this to resolve breaking changes or other incompatibilities?).
  3. Verify that all cosmjs-related packages in the codebase are consistently updated (e.g., @cosmjs/stargate, @cosmjs/proto-signing, etc.).

Run the following script to audit the full cosmjs dependency tree and check for any other cosmjs packages that may need alignment:

Also applies to: 44-44


🏁 Script executed:

#!/bin/bash
# Description: Search for all cosmjs-related dependencies in the workspace
# Expected: Confirm all cosmjs packages are at 0.36.1 or understand version rationale

# Find package.json files
fd -e package.json --exec rg -A 50 '"dependencies"' {} + | rg '@cosmjs' -A 2 -B 2

# List all @cosmjs packages in this specific file for confirmation
echo "=== Current cosmjs versions in provider-proxy/package.json ==="
rg '@cosmjs' apps/provider-proxy/package.json

Length of output: 129


Need to expand the search to find all cosmjs packages and chain-sdk dependency across the workspace.


---

🏁 Script executed:

```shell
#!/bin/bash
# Comprehensive search for all cosmjs packages and chain-sdk in workspace
echo "=== All cosmjs packages in workspace ==="
fd -e package.json -exec grep -l '@cosmjs' {} \; | while read f; do
  echo "File: $f"
  grep '@cosmjs' "$f"
done

echo ""
echo "=== Chain-sdk version in workspace ==="
fd -e package.json -exec grep -l 'chain-sdk' {} \; | while read f; do
  echo "File: $f"
  grep 'chain-sdk' "$f"
done

echo ""
echo "=== All cosmjs references in entire workspace ==="
rg '@cosmjs' --type json

Length of output: 41786


Need to locate chain-sdk version and understand provider-proxy's actual cosmjs usage.


---

🏁 Script executed:

```shell
#!/bin/bash
# Find chain-sdk version
echo "=== Chain-SDK version ==="
grep -r '@akashnetwork/chain-sdk' package.json packages/*/package.json apps/*/package.json 2>/dev/null

echo ""
echo "=== Provider-proxy imports ==="
# Check what provider-proxy actually imports from cosmjs
find apps/provider-proxy -type f \( -name '*.ts' -o -name '*.tsx' -o -name '*.js' \) ! -path '*/node_modules/*' -exec grep -h "@cosmjs" {} + | sort -u

echo ""
echo "=== Provider-proxy package.json dependencies section ==="
sed -n '/"dependencies"/,/^  }/p' apps/provider-proxy/package.json | head -30

Length of output: 1285


Found a critical issue: provider-proxy imports from @cosmjs/amino but doesn't declare it as a direct dependency. Let me verify where this is coming from.


---

🏁 Script executed:

```shell
#!/bin/bash
# Check chain-sdk dependencies to see if it provides @cosmjs/amino
echo "=== Chain-SDK dependencies (from lock file) ==="
grep -A 20 '"@akashnetwork/chain-sdk"' package-lock.json | grep -E '("version"|"@cosmjs)' | head -20

echo ""
echo "=== Verify: does provider-proxy have @cosmjs/amino in node_modules? ==="
if [ -d "apps/provider-proxy/node_modules/@cosmjs/amino" ]; then
  echo "YES - @cosmjs/amino exists in provider-proxy node_modules"
  # Check what provides it
  grep -B 5 '"@cosmjs/amino"' apps/provider-proxy/package.json || echo "NOT in direct dependencies"
else
  echo "NO - @cosmjs/amino NOT in provider-proxy node_modules"
fi

Length of output: 969


Add missing direct dependency for @cosmjs/amino in provider-proxy.

The code imports Secp256k1HdWallet from @cosmjs/amino, but @cosmjs/amino is not declared as a direct dependency in apps/provider-proxy/package.json. While it's available transitively through @akashnetwork/chain-sdk, direct imports require explicit declaration. Add "@cosmjs/amino": "~0.36.1" to align with the current cosmjs version and best practices.

Verification summary:

  • Chain-SDK 1.0.0-alpha.12 declares cosmjs 0.36.1 packages
  • provider-proxy imports from both @cosmjs/amino and @cosmjs/encoding
  • Only @cosmjs/encoding is explicitly listed; @cosmjs/amino is missing from direct dependencies
🤖 Prompt for AI Agents
In apps/provider-proxy/package.json around line 28, package.json is missing a
direct dependency on @cosmjs/amino while the code imports Secp256k1HdWallet from
it; add "@cosmjs/amino": "~0.36.1" to the dependencies section (aligned with the
existing @cosmjs/encoding version) so the package explicitly declares the direct
import and avoids relying on transitive availability.

},
"dependencies": {
"@akashnetwork/chain-sdk": "1.0.0-alpha.9",
"@akashnetwork/chain-sdk": "1.0.0-alpha.12",
Copy link
Contributor

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🔴 Critical

🧩 Analysis chain

Verify @akashnetwork/chain-sdk v1.0.0-alpha.12 is available and compatible.

The update to an exact alpha version (1.0.0-alpha.12) is appropriate for reproducibility. However, ensure this pre-release version is officially available and that the codebase has been updated to handle any API changes introduced in v1.0.0-alpha.12 compared to v1.0.0-alpha.9.


🏁 Script executed:

#!/bin/bash
# Description: Verify @akashnetwork/chain-sdk v1.0.0-alpha.12 is available and check its release date

# Check if the package version exists on npm
npm info @akashnetwork/chain-sdk@1.0.0-alpha.12 --json | jq '.version, .time'

Length of output: 803


I've confirmed that @akashnetwork/chain-sdk v1.0.0-alpha.12 is available and officially released on npm (2025-10-23). However, the original review comment identifies two dependency updates that need verification. Let me check the second dependency before finalizing:

@cosmjs/encoding v0.36.1 does not exist on npm; this dependency cannot be installed and will cause build failure.

The latest version of @cosmjs/encoding is 0.33.1. The tilde pinning (~0.36.1) references a non-existent version that will fail during npm install. Update to an available version (recommend 0.33.1 or verify the intended version compatible with this SDK53 upgrade).

🤖 Prompt for AI Agents
In apps/stats-web/package.json around line 16, the dependency "@cosmjs/encoding"
was pinned as ~0.36.1 which does not exist on npm and will break installs;
update the package.json to use an actual published version (change to "0.33.1"
or another verified compatible version) and remove or adjust the tilde if exact
pinning is required, then run npm install and tests to confirm compatibility
with the SDK53 upgrade.

Comment on lines +1 to +2
import { MAINNET_ID, SANDBOX_ID } from "@akashnetwork/chain-sdk/web";
import type { SupportedChainNetworks } from "@akashnetwork/net";
Copy link
Contributor

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🔴 Critical

🧩 Analysis chain

Verify the new import sources are correct.

The import reorganization looks consistent with the SDK53 upgrade. However, please verify that:

  1. The old import source (@akashnetwork/network-store) is deprecated or replaced
  2. These new import paths are the canonical locations going forward

🏁 Script executed:

#!/bin/bash
# Verify that the old import source no longer exports these constants
# and confirm the new sources are correct

# Check if MAINNET_ID and SANDBOX_ID are still exported from the old location
rg -n "export.*MAINNET_ID|export.*SANDBOX_ID" --type ts -g '**/network-store/**'

# Check the new import sources
rg -n "export.*MAINNET_ID|export.*SANDBOX_ID" --type ts -g '**/chain-sdk/**'

# Check for SupportedChainNetworks type definition
ast-grep --pattern 'export type SupportedChainNetworks = $$$'

Length of output: 255



---

🏁 Script executed:

```shell
#!/bin/bash
# Search for MAINNET_ID and SANDBOX_ID exports without path restrictions
echo "=== Searching for MAINNET_ID and SANDBOX_ID exports ==="
rg -n "export.*MAINNET_ID|export.*SANDBOX_ID" --type ts

echo ""
echo "=== Searching for network-store references ==="
rg -n "network-store" --type ts

echo ""
echo "=== Searching for chain-sdk/web references ==="
rg -n "chain-sdk/web" --type ts

echo ""
echo "=== Checking package.json for @akashnetwork dependencies ==="
fd "package.json" --exec cat {} \; 2>/dev/null | grep -A 20 "@akashnetwork" | head -50

Length of output: 5222



---

🏁 Script executed:

```shell
#!/bin/bash
# View the complete denom.config.ts file under review
echo "=== apps/stats-web/src/config/denom.config.ts ==="
cat apps/stats-web/src/config/denom.config.ts

echo ""
echo "=== Compare with deploy-web version ==="
cat apps/deploy-web/src/config/denom.config.ts

echo ""
echo "=== Verify SupportedChainNetworks definition and usage ==="
rg -n "SupportedChainNetworks" --type ts -C 3

Length of output: 23982



---

🏁 Script executed:

```shell
#!/bin/bash
# Check how USDC_IBC_DENOMS is used in stats-web
echo "=== Usages of USDC_IBC_DENOMS in stats-web ==="
rg -n "USDC_IBC_DENOMS" apps/stats-web --type ts -C 3

echo ""
echo "=== Check if READABLE_DENOMS pattern exists in stats-web ==="
rg -n "READABLE_DENOMS" apps/stats-web --type ts -C 3

echo ""
echo "=== Verify type compatibility: is MAINNET_ID/SANDBOX_ID valid keys for SupportedChainNetworks? ==="
rg -n "netConfigData" packages/net/src/generated/netConfigData.ts 2>/dev/null | head -20
cat packages/net/src/generated/netConfigData.ts 2>/dev/null | head -50

Length of output: 3175



---

🏁 Script executed:

```shell
#!/bin/bash
# Find the actual values of MAINNET_ID and SANDBOX_ID constants
echo "=== Search for MAINNET_ID and SANDBOX_ID definitions in chain-sdk ==="
find . -path "*/chain-sdk/*" -name "*.ts" -type f 2>/dev/null | xargs grep -l "MAINNET_ID\|SANDBOX_ID" | head -5

echo ""
echo "=== Look for the definitions (not just imports) ==="
rg -n "const.*MAINNET_ID|const.*SANDBOX_ID" --type ts -A 1 | head -30

echo ""
echo "=== Check in node_modules if accessible, or look for SDK exports ==="
rg -n "MAINNET_ID.*=" --type ts -B 2 -A 2 | grep -v "import" | head -40

echo ""
echo "=== Check what chain-sdk/web might be exporting ==="
fd "index" packages/*/src --type f | xargs grep -l "MAINNET_ID\|SANDBOX_ID" 2>/dev/null

Length of output: 245



---

🌐 Web query:

```web
@akashnetwork/chain-sdk/web MAINNET_ID SANDBOX_ID constants values

💡 Result:

MAINNET_ID = "akashnet-2". [1]

SANDBOX_ID = "sandbox-01". [2]

Sources:

  • Akash network repo (net) — chain-id for mainnet. [1]
  • Akash Sandbox docs (chain id shown as sandbox-01). [2]


---

🏁 Script executed:

```shell
#!/bin/bash
# Verify the type of selectedNetworkId in networkStore
echo "=== Check networkStore type for selectedNetworkId ==="
cat apps/stats-web/src/store/network.store.ts | head -50

echo ""
echo "=== Check useDenom.ts full context ==="
cat apps/stats-web/src/hooks/useDenom.ts

echo ""
echo "=== Look for type definition of useSelectedNetworkId ==="
rg -n "useSelectedNetworkId" apps/stats-web --type ts -B 5 -A 5 | head -50

Length of output: 3477


Fix type annotation in USDC_IBC_DENOMS to use NetworkId instead of SupportedChainNetworks.

The type annotation is incorrect. The object uses MAINNET_ID and SANDBOX_ID as keys, which are "akashnet-2" and "sandbox-01" respectively—not values from SupportedChainNetworks. The type should match the actual keys being used.

Update line 2 and line 5:

  • Import NetworkId from @akashnetwork/chain-sdk/web
  • Change type from Partial<Record<SupportedChainNetworks, string>> to Partial<Record<NetworkId, string>>

This matches the pattern used in deploy-web and aligns the type with actual runtime values.

🤖 Prompt for AI Agents
In apps/stats-web/src/config/denom.config.ts around lines 1 to 2 and line 5, the
type annotation for USDC_IBC_DENOMS is wrong: import NetworkId from
"@akashnetwork/chain-sdk/web" instead of only importing MAINNET_ID and
SANDBOX_ID, and change the type from Partial<Record<SupportedChainNetworks,
string>> to Partial<Record<NetworkId, string>> so the keys (MAINNET_ID /
SANDBOX_ID) match the NetworkId type used at runtime.


export const UAKT_DENOM = "uakt";
export const USDC_IBC_DENOMS: Record<Exclude<NetworkId, "testnet">, string> = {
export const USDC_IBC_DENOMS: Partial<Record<SupportedChainNetworks, string>> = {
Copy link
Contributor

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🔴 Critical

🧩 Analysis chain

Consider aligning types with deploy-web for consistency.

There's a type inconsistency: this file uses Partial<Record<SupportedChainNetworks, string>> while apps/deploy-web/src/config/denom.config.ts uses Partial<Record<NetworkId, string>> for the same USDC_IBC_DENOMS constant. Using different types across apps for the same concept can make the codebase harder to maintain.

Additionally, since the type is Partial, accessing values could return undefined. The AI summary mentions that "READABLE_DENOMS indexing now uses non-null assertions" - please ensure all indexing into this object is properly guarded against undefined values or that non-null assertions are only used where the key is guaranteed to exist.


🏁 Script executed:

#!/bin/bash
# Check how USDC_IBC_DENOMS is indexed throughout the codebase
# to verify safe usage with Partial type

# Find all usages of USDC_IBC_DENOMS indexing
rg -n "USDC_IBC_DENOMS\[" --type ts -A 2 -B 2

# Check for non-null assertions
rg -n "USDC_IBC_DENOMS.*!" --type ts -A 2 -B 2

Length of output: 3298



---

🏁 Script executed:

```shell
#!/bin/bash
# Find type definitions for SupportedChainNetworks and NetworkId
rg -n "type SupportedChainNetworks|interface SupportedChainNetworks" --type ts -A 5

# Find NetworkId definition
rg -n "type NetworkId|interface NetworkId|enum NetworkId" --type ts -A 5

# Check stats-web's selectedNetworkId type
rg -n "useSelectedNetworkId" apps/stats-web/src --type ts -A 3 -B 1

# Verify stats-web USDC_IBC_DENOMS definition
cat apps/stats-web/src/config/denom.config.ts

Length of output: 5167



---

🏁 Script executed:

```shell
#!/bin/bash
# Find stats-web denom config with recursive search
fd -n "denom.config.ts" -x cat {}

# Also check stats-web hooks directly to see type usage
fd -n "useDenom.ts" apps/stats-web -x cat {}

Length of output: 461



---

🏁 Script executed:

```shell
#!/bin/bash
# Find denom config files
fd "denom.config.ts" --exec cat {}

# Also check stats-web hooks
fd "useDenom.ts" --exec cat {}

# Check what's in netConfigData to understand SupportedChainNetworks
rg -n "netConfigData" --type ts -A 10 | head -50

Length of output: 6250


Type inconsistency confirmed; stats-web needs defensive access pattern.

The review comment's concerns are substantiated:

  1. Type mismatch is real: stats-web uses Partial<Record<SupportedChainNetworks, string>> while deploy-web uses Partial<Record<NetworkId, string>> — these are fundamentally different types (SupportedChainNetworks is dynamically keyed from netConfigData, while NetworkId comes from an external package).

  2. Incomplete config: stats-web's USDC_IBC_DENOMS only has MAINNET_ID and SANDBOX_ID, while deploy-web's includes TESTNET_ID. This compounds the issue if selectedNetworkId is TESTNET_ID.

  3. Unsafe access pattern: stats-web directly accesses USDC_IBC_DENOMS[selectedNetworkId] without type casts or null checks, whereas deploy-web defensively uses as keyof typeof USDC_IBC_DENOMS and as string — critical given the Partial type can return undefined.

The review comment should be acted upon. Either align types across apps or add defensive casts/assertions in stats-web's indexing to handle potential undefined returns from the Partial type.

🤖 Prompt for AI Agents
In apps/stats-web/src/config/denom.config.ts around line 5, the USDC_IBC_DENOMS
map uses Partial<Record<SupportedChainNetworks, string>> and is missing
TESTNET_ID while code later indexes it unsafely with
USDC_IBC_DENOMS[selectedNetworkId]; update this file to either: (A) change the
map type to match deploy-web (Partial<Record<NetworkId, string>>) and add the
TESTNET_ID entry so the keyset aligns, or (B) keep SupportedChainNetworks but
make access defensive — add a runtime check/fallback when reading
USDC_IBC_DENOMS[selectedNetworkId] (e.g., verify the key exists, use a default
string or throw a clear error), and narrow types with a safe cast only after the
existence check; implement one of these fixes and ensure call sites do not index
the Partial map without checking for undefined.

Comment on lines +30 to 33
"peerDependencies": {
"@cosmjs/proto-signing": "^0.36.1",
"@cosmjs/stargate": "^0.36.1"
}
Copy link
Contributor

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🔴 Critical

🧩 Analysis chain

Peer dependency migration may require consumer updates.

Moving @cosmjs/proto-signing and @cosmjs/stargate from devDependencies to peerDependencies is architecturally correct for a library package, as it prevents version conflicts. However, this is a breaking change that requires all consumers to:

  1. Install these dependencies explicitly at version ^0.36.1
  2. Ensure compatibility with the upgraded CosmJS version

Verify that:

  • All consuming packages in the monorepo have been updated to include these peer dependencies
  • The version ^0.36.1 is compatible with the chain-sdk private-types being used throughout the codebase

🏁 Script executed:

#!/bin/bash
# Check if consuming packages declare these dependencies
fd -t f 'package.json' apps/ packages/ --exec jq -r 'select(.dependencies["@akashnetwork/http-sdk"]) | .name, .dependencies["@cosmjs/proto-signing"], .dependencies["@cosmjs/stargate"]'

# Check for version consistency across the monorepo
fd -t f 'package.json' --exec jq -r 'select(.dependencies["@cosmjs/proto-signing"] or .dependencies["@cosmjs/stargate"]) | {name: .name, proto: .dependencies["@cosmjs/proto-signing"], stargate: .dependencies["@cosmjs/stargate"]}'

Length of output: 614



🏁 Script executed:

#!/bin/bash
# Check if log-collector and provider-console depend on http-sdk
echo "=== Checking log-collector dependencies ==="
fd -t f 'package.json' packages/log-collector --exec jq -r '{name: .name, httpSdk: .dependencies["@akashnetwork/http-sdk"], devHttpSdk: .devDependencies["@akashnetwork/http-sdk"], peerHttpSdk: .peerDependencies["@akashnetwork/http-sdk"]}'

echo -e "\n=== Checking provider-console dependencies ==="
fd -t f 'package.json' apps/provider-console --exec jq -r '{name: .name, httpSdk: .dependencies["@akashnetwork/http-sdk"], devHttpSdk: .devDependencies["@akashnetwork/http-sdk"], peerHttpSdk: .peerDependencies["@akashnetwork/http-sdk"]}'

# Also check if http-sdk itself depends on specific cosmjs versions
echo -e "\n=== Checking http-sdk dependencies ==="
fd -t f 'package.json' packages/http-sdk --exec jq -r '{name: .name, proto: .dependencies["@cosmjs/proto-signing"], stargate: .dependencies["@cosmjs/stargate"], peerProto: .peerDependencies["@cosmjs/proto-signing"], peerStargate: .peerDependencies["@cosmjs/stargate"]}'

Length of output: 483


🏁 Script executed:

#!/bin/bash
# Check if log-collector and provider-console depend on http-sdk
echo "=== Checking log-collector dependencies ==="
fd -t f 'package.json' packages/log-collector --exec jq -r '{name: .name, httpSdk: .dependencies["@akashnetwork/http-sdk"], devHttpSdk: .devDependencies["@akashnetwork/http-sdk"], peerHttpSdk: .peerDependencies["@akashnetwork/http-sdk"]}'

echo -e "\n=== Checking provider-console dependencies ==="
fd -t f 'package.json' apps/provider-console --exec jq -r '{name: .name, httpSdk: .dependencies["@akashnetwork/http-sdk"], devHttpSdk: .devDependencies["@akashnetwork/http-sdk"], peerHttpSdk: .peerDependencies["@akashnetwork/http-sdk"]}'

# Also check if http-sdk itself depends on specific cosmjs versions
echo -e "\n=== Checking http-sdk dependencies ==="
fd -t f 'package.json' packages/http-sdk --exec jq -r '{name: .name, proto: .dependencies["@cosmjs/proto-signing"], stargate: .dependencies["@cosmjs/stargate"], peerProto: .peerDependencies["@cosmjs/proto-signing"], peerStargate: .peerDependencies["@cosmjs/stargate"]}'

Length of output: 483


🏁 Script executed:

#!/bin/bash
# Find log-collector package location
echo "=== Finding log-collector package ==="
fd -t f 'package.json' -x grep -l '"name".*"@akashnetwork/log-collector"'

# Get all packages that depend on http-sdk (regardless of dependency type)
echo -e "\n=== All packages consuming http-sdk ==="
fd -t f 'package.json' --exec jq -r 'select(.dependencies["@akashnetwork/http-sdk"] or .devDependencies["@akashnetwork/http-sdk"] or .peerDependencies["@akashnetwork/http-sdk"]) | {name: .name, httpSdk: (.dependencies["@akashnetwork/http-sdk"] // .devDependencies["@akashnetwork/http-sdk"] // .peerDependencies["@akashnetwork/http-sdk"]), proto: (.dependencies["@cosmjs/proto-signing"] // "not declared"), stargate: (.dependencies["@cosmjs/stargate"] // "not declared")}'

Length of output: 554



🏁 Script executed:

#!/bin/bash
# Examine log-collector's full dependency declarations
echo "=== log-collector package.json dependencies ==="
cat apps/log-collector/package.json | jq '.dependencies, .devDependencies, .peerDependencies'

# Search for any cosmjs imports/references in log-collector
echo -e "\n=== Checking for cosmjs references in log-collector ==="
fd -t f '\.(ts|tsx|js|jsx)$' apps/log-collector --exec grep -l '@cosmjs' {} \; 2>/dev/null | head -20

Length of output: 1055


🏁 Script executed:

#!/bin/bash
# Examine log-collector's full dependency declarations
echo "=== log-collector package.json dependencies ==="
cat apps/log-collector/package.json | jq '.dependencies, .devDependencies, .peerDependencies'

# Search for any cosmjs imports/references in log-collector
echo -e "\n=== Checking for cosmjs references in log-collector ==="
fd -t f '\.(ts|tsx|js|jsx)$' apps/log-collector --exec grep -l '@cosmjs' {} \; 2>/dev/null | head -20

Length of output: 1055


Add @cosmjs peer dependencies to log-collector package.json.

The peer dependency migration to http-sdk is partially implemented but incomplete. While three direct consumers (console-api, notifications, console-web) correctly declare @cosmjs dependencies at ~0.36.1, log-collector depends on http-sdk without declaring the required peer dependencies.

Since log-collector's source code does not directly use @cosmjs (verified via code search), the peer dependency declarations should be added to ensure proper dependency resolution and avoid installation failures in non-monorepo contexts:

  • Add "@cosmjs/proto-signing": "^0.36.1" to log-collector dependencies
  • Add "@cosmjs/stargate": "^0.36.1" to log-collector dependencies
🤖 Prompt for AI Agents
In packages/http-sdk/package.json around lines 30 to 33, the peerDependencies
for @cosmjs are declared in http-sdk but log-collector (a direct consumer of
http-sdk) lacks those peer dependencies; update log-collector's package.json to
add "@cosmjs/proto-signing": "^0.36.1" and "@cosmjs/stargate": "^0.36.1" under
its dependencies (or peerDependencies if you prefer to mirror http-sdk), then
run a quick install/test to verify resolution in non-monorepo contexts.

@ygrishajev ygrishajev merged commit cd8bf9b into main Oct 27, 2025
84 of 87 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.

3 participants

Comments