Skip to content

Commit

Permalink
fix: remove deps on custom.d
Browse files Browse the repository at this point in the history
Signed-off-by: Matt Krick <[email protected]>
  • Loading branch information
mattkrick committed Feb 12, 2025
1 parent 63141ff commit 967a32c
Show file tree
Hide file tree
Showing 5 changed files with 21 additions and 21 deletions.
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
export interface AuthToken {
sub: string
tms: string[]
rol?: 'su' | 'impersonate'
rol?: 'su' | 'impersonate' | null
bet?: 1
iat: number
iss: string
Expand Down
2 changes: 1 addition & 1 deletion packages/server/graphql/executeGraphQL.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
import tracer from 'dd-trace'
import {graphql} from 'graphql'
import {FormattedExecutionResult} from 'graphql/execution/execute'
import type {GQLRequest} from '../types/custom'
import type {GQLRequest} from '../types/GQLRequest'
import sendToSentry from '../utils/sendToSentry'
import CompiledQueryCache from './CompiledQueryCache'
import getDataLoader from './getDataLoader'
Expand Down
18 changes: 18 additions & 0 deletions packages/server/types/GQLRequest.d.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
import type {AuthToken} from '../../client/types/AuthToken'

export interface GQLRequest {
authToken: AuthToken
ip?: string
socketId?: string
variables?: {[key: string]: any}
docId?: string
query?: string
rootValue?: {[key: string]: any}
dataLoaderId?: string
// true if the query is on the private schema
isPrivate?: boolean
// true if the query is ad-hoc (e.g. GraphiQL, CLI)
isAdHoc?: boolean
// Datadog opentracing span of the calling server
carrier?: any
}
18 changes: 0 additions & 18 deletions packages/server/types/custom.d.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
import type {GraphQLSchema} from 'graphql'
import type nestGitHubEndpoint from 'nest-graphql-endpoint/lib/nestGitHubEndpoint'
import '../../client/types/reactHTML4'
import type AuthToken from '../database/types/AuthToken'
import type ScheduledJobMeetingStageTimeLimit from '../database/types/ScheduledJobMetingStageTimeLimit'
import type ScheduledTeamLimitsJob from '../database/types/ScheduledTeamLimitsJob'
export interface OAuth2Success {
Expand All @@ -23,23 +22,6 @@ export interface OAuth2Error {
error_description?: string
error_uri?: string
}
export interface GQLRequest {
authToken: AuthToken
ip?: string
socketId?: string
variables?: {[key: string]: any}
docId?: string
query?: string
rootValue?: {[key: string]: any}
dataLoaderId?: string
// true if the query is on the private schema
isPrivate?: boolean
// true if the query is ad-hoc (e.g. GraphiQL, CLI)
isAdHoc?: boolean
// Datadog opentracing span of the calling server
carrier?: any
}

export type ScheduledJobUnion = ScheduledJobMeetingStageTimeLimit | ScheduledTeamLimitsJob

export type RootSchema = GraphQLSchema & {
Expand Down
2 changes: 1 addition & 1 deletion packages/server/utils/PubSubPromise.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import type {ExecutionResult} from 'graphql'
import ms from 'ms'
import GQLExecutorChannelId from '../../client/shared/gqlIds/GQLExecutorChannelId'
import type {GQLRequest} from '../types/custom'
import type {GQLRequest} from '../types/GQLRequest'
import {Logger} from './Logger'
import RedisInstance from './RedisInstance'
import {getUserId} from './authorization'
Expand Down

0 comments on commit 967a32c

Please sign in to comment.