onflow / onflow/flow-cli

Simplify MCP contract sorting with slices helpers

Open Beginner friendly
#2,362 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Go
Stars
209
Forks
87
Avg merge
1d 17h
Merged PRs (30d)
3

Description

Problem

The MCP tools code uses custom index-based callbacks for both natural string ordering and contract ordering.

Proposed change

Use slices.Sort for naturally ordered strings and slices.SortFunc for contract values. The output order remains unchanged.

Scope

This is an internal refactor with no command-line, MCP schema, or user-visible behavior changes.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Search the MCP tools code for custom index-based callbacks that sort natural strings and contract values, then inspect the surrounding tests or callers. Replace those sorting paths with the specified slices helpers while preserving output order, and run the relevant Go tests to confirm there are no behavior changes.

Written by the indexing model from the issue text.

Assessment

Tech stack
go
Domain
cli
Issue type
Refactor
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Active
Clarity
Mostly clear
Newbie friendliness
72/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.