Skip to content

[TASK] Tangle Cloud: Deploy Argument Encoding & Request Flow ParityΒ #3122

@vutuanlinh2k2

Description

@vutuanlinh2k2

Goal

Fix request-arg encoding so deploy works with non-empty args, and support all three contract request variants (basic, with exposure, with security).

Status

πŸ”΄ BROKEN FOR NON-EMPTY ARGS β€” encodeServiceConfig throws when args are non-empty. Exposure request variant is unsupported.

Must-Have Tasks

# Task Type Contract Function Current State
3.1 Implement end-to-end request arg encoder aligned with contract schema Bug fix N/A encodeServiceConfig throws on non-empty args
3.2 Support requestService (basic) variant Feature Services.requestService() Partially working
3.3 Support requestServiceWithExposure variant Feature Services.requestServiceWithExposure() Not implemented
3.4 Support requestServiceWithSecurity variant Feature Services.requestServiceWithSecurity() Partially implemented
3.5 Add hook selection logic to auto-route to correct variant Feature N/A Basic/security only
3.6 Add explicit validation and user-readable errors before tx step Feature N/A Not implemented

Files

  • apps/tangle-cloud/src/pages/blueprints/[id]/deploy/page.tsx β€” deploy page
  • libs/tangle-shared-ui/src/data/graphql/useServiceRequest.ts β€” request hook
  • ../tnt-core/src/interfaces/ITangleServices.sol β€” contract interface
  • ../tnt-core/src/core/ServicesLifecycle.sol β€” contract implementation

Test Criteria

  • Deploy succeeds with empty request args
  • Deploy succeeds with non-empty structured request args
  • Exposure-only request variant can be selected and submitted
  • Security request variant works with asset/security combinations
  • User sees readable validation errors for malformed args before tx step
  • Correct contract function is called based on deploy configuration

Nice-to-Have

  • Arg schema auto-detection from blueprint metadata
  • Preview of encoded args before submission

Metadata

Metadata

Assignees

Type

No type

Projects

Status

Not Started πŸ•§

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions