Noir::PythonGraphqlExtractor
Outline of the Python modules behind a code-first GraphQL schema
(Strawberry, Graphene): top-level classes with their bases, decorators
and members, module-level functions, imports and Schema(...) calls,
plus the cross-file name resolution that stitches root types together
from mixins in other modules. Library rules (which member is a field,
what its arguments are) stay with the analyzers; no file I/O here.
Constants
Schema(...) keyword => root operation type; also the positional order.
Literal mount paths: Django/Flask path("graphql/", GraphQLView...),
add_url_rule, FastAPI include_router(router, prefix=...) and ASGI
add_route / mount of a GraphQL app.
Instance methods
Positional and keyword argument source text of callee(...), or nil
when text is not a single call.
Callee of text when it is a call (graphene.String(...) => graphene.String).
The to_camel_case both libraries share: user_id => userId,
with an empty component (a doubled _) kept as _.
What an analyzer needs from one file, or nil. A file importing the
library (library) gets a full outline. One that does not may still
compose the root types from other modules' mixins, or mount the
project's own GraphQLView subclass in urls.py: it is read for its
classes or its mount paths only.
ref as written in outline's file (Query, users.schema.Query,
an import alias) to the declaration it names. Module paths are matched
as path suffixes, so absolute imports need no source-root guess.