Skip to main content
Glama

MCP Language Server

shared-constant.snap1.79 kB
--- /TEST_OUTPUT/workspace/another_consumer.py References in File: 3 At: L4:C5, L16:C51, L34:C30 1|"""Another module that uses helpers and shared components.""" 2| 3|from helper import ( 4| SHARED_CONSTANT, 5| SharedClass, 6| helper_function, 7| Color, 8|) 9| ... 11|class AnotherImplementation: 12| """A class that uses shared components but doesn't implement interfaces.""" 13| 14| def __init__(self): 15| """Initialize the implementation.""" 16| self.shared = SharedClass[str]("another", SHARED_CONSTANT) 17| 18| def do_something(self) -> str: 19| """Do something with the shared components. 20| 21| Returns: ... 31|def another_consumer_function() -> None: 32| """Another function that uses various shared components.""" 33| # Use shared constants 34| print(f"Using constant: {SHARED_CONSTANT}") 35| 36| # Use shared class with a different type parameter 37| shared = SharedClass[float]("another example", 3.14) 38| 39| # Use methods from shared class --- /TEST_OUTPUT/workspace/consumer.py References in File: 2 At: L8:C5, L46:C43 3|from helper import ( 4| helper_function, 5| get_items, 6| SharedClass, 7| SharedInterface, 8| SHARED_CONSTANT, 9| Color, 10|) 11| 12| 13|class MyImplementation(SharedInterface): ... 34|def consumer_function() -> None: ... 41| items = get_items() 42| for item in items: 43| print(f"Processing {item}") 44| 45| # Use the shared class 46| shared = SharedClass[str]("consumer", SHARED_CONSTANT) 47| print(f"Using shared class: {shared.get_name()} - {shared.get_value()}") 48| 49| # Use our implementation of the shared interface 50| impl = MyImplementation() 51| result = impl.process(items)

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/isaacphi/mcp-language-server'

If you have feedback or need assistance with the MCP directory API, please join our Discord server