Skip to content
This repository was archived by the owner on Jun 13, 2025. It is now read-only.

Commit dcefcab

Browse files
Merge remote-tracking branch 'origin/main' into sshin/fix/max-depth
2 parents fff11f0 + 168d5f2 commit dcefcab

File tree

5 files changed

+9
-0
lines changed

5 files changed

+9
-0
lines changed

codecov/settings_base.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -104,6 +104,8 @@
104104

105105
GRAPHQL_RATE_LIMIT_RPM = get_config("setup", "graphql", "rate_limit_rpm", default=300)
106106

107+
GRAPHQL_INTROSPECTION_ENABLED = False
108+
107109
GRAPHQL_MAX_DEPTH = 15
108110

109111
GRAPHQL_MAX_ALIASES = 15

codecov/settings_dev.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -55,3 +55,5 @@
5555
# SHELTER_SHARED_SECRET = "test-supertoken"
5656

5757
GUEST_ACCESS = True
58+
59+
GRAPHQL_INTROSPECTION_ENABLED = True

codecov/settings_staging.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -75,3 +75,5 @@
7575
CSRF_TRUSTED_ORIGINS = [
7676
get_config("setup", "trusted_origin", default="https://*.codecov.dev")
7777
]
78+
79+
GRAPHQL_INTROSPECTION_ENABLED = True

codecov/settings_test.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,3 +10,5 @@
1010
# Mock the Pub/Sub host for testing
1111
# this prevents the pubsub SDK from trying to load credentials
1212
os.environ["PUBSUB_EMULATOR_HOST"] = "localhost"
13+
14+
GRAPHQL_INTROSPECTION_ENABLED = True

graphql_api/views.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -189,6 +189,7 @@ def __exit__(self, exc_type, exc_value, exc_traceback):
189189
class AsyncGraphqlView(GraphQLAsyncView):
190190
schema = schema
191191
extensions = [QueryMetricsExtension]
192+
introspection = getattr(settings, "GRAPHQL_INTROSPECTION_ENABLED", False)
192193

193194
def get_validation_rules(
194195
self,

0 commit comments

Comments
 (0)