feat(python-sdk): Complete TypeScript Parity, Enterprise Security, Background Tasks & Dev Tooling#4
Open
Gautam-7-7 wants to merge 7 commits into
Conversation
…ead safety, and cycle detection
…ing & widget compilation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This Pull Request achieves complete behavioral, architectural, and API parity between the NitroStack Python SDK and the reference TypeScript SDK
Core Capabilities & Subsystems Included
Dependency Injection & Modules :
inspect.signature+get_type_hints).threading.RLock.CircularDependencyError.MCP Primitives & Programmatic Builders :
@tooland@promptdescription fallback.build_tool,build_tools,build_resources,build_prompts,build_controller).Execution Pipeline & Security :
PyJWTand asynchronous OAuth 2.1 token introspection usinghttpx.AsyncClient.SecretValuewrapper, PKCE verification,MemoryTokenStore/FileTokenStore, andsetup_jwt_authhelper utilities.Background Tasks & Concurrency (
nitrostack.core.task):TaskRegistrybacked by nativeasyncio.Taskreferences supporting.cancel()andasyncio.CancelledError.TaskContextexposingabort_signal/abortControllerand status lifecycle transitions.asyncio.to_thread.UI Widgets & Next.js Asset Inlining (
nitrostack.ui_next):compile_next_widget) for serving Next.js widgets without Node.js production runtime dependencies.CLI Scaffolding & Pytest Plugin (
nitrostack.cli&nitrostack.testing):--filehot reloading, Claude Desktop registration, and Cursor config integration (nitrostack-py cursor).pytestplugin fixture (nitro_client) registered viapytest11entrypoint.Verification & Automated Tests
35 passed in 4.72s):tests/test_decorators.pytests/test_di.pytests/test_gaps_resolved.pytests/test_jwt_security.pytests/test_next_widget_compilation.pytests/test_oauth.pytests/test_pipeline_gaps.pytests/test_production.pytests/test_pytest_fixture.pytests/test_sync_tools.pytests/test_task_cancellation_real.pytests/test_tasks.pytests/test_testing_module.pyBackward Compatibility
@tool,@resource,@prompt).JwtModule,OauthModule,APIKeyModule.