Hacktoberfest 2026: the issues maintainers tagged for October, open and beginner-friendly. Browse Hacktoberfest issues

MCP startup discovery ignores tools/list pagination

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

Nobody has claimed this yet.

Assessment

Difficulty
2/5
Estimated time
1-3 hours
Newbie friendliness
75/100
Issue type
Bug
Clarity
Clearly specified
Activity status
Active
Tech stack
node.js, typescript
Domain
api, backend

Research direction

The bug is in packages/coding-agent/src/step/mcp.ts at the connectStepMcpServer function around line 309. Look at the existing listAllMcpTools function to see how pagination is handled. The fix involves replacing the single listTools call with a call to listAllMcpTools or implementing similar pagination logic. Run the new regression tests to verify the fix works.

Written by the indexing model from the issue text.

Description

untriaged
What happened?

MCP startup only discovers the first tools/list page. A server can connect successfully while tools on later pages are missing. An enabled_tools entry naming only a second-page tool produces an empty catalog.

connectStepMcpServer calls listTools once and ignores nextCursor.

Steps to reproduce
  1. Serve a local HTTP MCP fixture: the first tools/list response contains tool_0 and nextCursor; the next page contains tool_1.
  2. Connect through connectStepMcpServer.
  3. Observe only one tools/list request and tool_0. The existing invokeRemoteMcpTool path correctly follows both pages against the same fixture.

The reproduction calls the production function directly without loading extensions.

Expected behavior

Collect every page before filtering and publishing the tools.

I have a small fix in my fork that reuses listAllMcpTools. Six new regression cases fail before the fix and pass afterwards; 33 focused tests and npm run check pass on Windows. Full Linux validation passed: build:offline, npm run check, and the complete isolated ./test.sh.

I'd like to submit the PR once approved with lgtm.

Version

Step Code 0.1.0, main @ cb5fc1456d49d49c62e072bfed2926220083214e; Node v24.14.0, Windows.

Dominant language
TypeScript
Stars
54
Forks
20
Avg merge
23m
Merged PRs (30d)
7

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.

More from stepfun-ai/Step-Code

All issues in stepfun-ai/Step-Code

Similar issues

More TypeScript issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.