UNPKG

mcp-openapi-schema-explorer

Version:
94 lines (70 loc) 3.65 kB
# Active Context ## Current Focus Successfully upgraded @modelcontextprotocol/sdk from 1.10.1 to 1.11.0 and addressed breaking changes in test mocks. ## Implementation Status - @modelcontextprotocol/sdk updated from 1.10.1 to 1.11.0 - Updated all test mocks to include new `RequestHandlerExtra` property (`requestId`). - Corrected import path for `RequestId` to `@modelcontextprotocol/sdk/types.js`. - Modified test files: - component-map-handler.test.ts - component-detail-handler.test.ts - operation-handler.test.ts - path-item-handler.test.ts - top-level-field-handler.test.ts - All tests passing successfully - Server now loads OpenAPI v3.0 and Swagger v2.0 specs from local files or remote URLs - Swagger v2.0 specs are automatically converted to v3.0 - Internal references are transformed to MCP URIs - Added `json-minified` output format option - Server name is now dynamically set based on the loaded spec's `info.title` - Automated versioning and release process implemented using `semantic-release` - CI workflow adapted for Node 22, uses `just` for checks, and includes a `release` job - Docker support added with automated Docker Hub publishing - Dependencies correctly categorized - Resource completion logic implemented - Dynamic server name implemented - Minified JSON output format added - Remote spec loading and Swagger v2.0 conversion support added - Core resource exploration functionality remains operational - Unit tests updated for latest SDK version - E2E tests cover all main functionality ## Recent Changes ### SDK Update to v1.11.0 & Test Fixes (✓) 1. **Dependency Update:** - Updated @modelcontextprotocol/sdk from 1.10.1 to 1.11.0 in `package.json`. - Identified breaking change in `RequestHandlerExtra` type requiring a new `requestId` property. 2. **Test Suite Updates:** - Added the `requestId` property to `mockExtra` objects in all handler unit tests: - `test/__tests__/unit/handlers/top-level-field-handler.test.ts` - `test/__tests__/unit/handlers/component-map-handler.test.ts` - `test/__tests__/unit/handlers/path-item-handler.test.ts` - `test/__tests__/unit/handlers/operation-handler.test.ts` - `test/__tests__/unit/handlers/component-detail-handler.test.ts` - Corrected the import path for `RequestId` to `import { RequestId } from '@modelcontextprotocol/sdk/types.js';` in these files. This resolved previous TypeScript import errors and an ESLint warning regarding unsafe assignment also disappeared. - Confirmed all test fixes by running `just build && just test` successfully. ## Next Actions 1. **Continue with Previous Plans:** - Complete README updates with release process details - Clean up any remaining TODOs in codebase - Address minor ESLint warnings 2. **Documentation:** - Document the SDK upgrade in CHANGELOG.md - Update dependencies section in relevant documentation 3. **Testing:** - Monitor for any new breaking changes in future SDK updates - Consider adding test utilities to simplify mock creation 4. **Code Cleanup:** - Refactor duplicated mock setup code in tests - Consider creating shared test fixtures for common mocks ## Future Considerations 1. **SDK Integration:** - Stay updated with MCP SDK releases - Plan for future breaking changes - Consider automated dependency update checks 2. **Testing Infrastructure:** - Improve test mock reusability - Add test coverage for edge cases - Consider adding integration tests 3. **Previous Future Considerations:** - Implement reference traversal/resolution service - Enhance support for all component types