axios+telemetry cleanup
This commit is contained in:
@@ -11,6 +11,7 @@ import {
|
||||
} from 'src/services/analytics/index.js'
|
||||
import { getModelStrings } from 'src/utils/model/modelStrings.js'
|
||||
import { getAPIProvider } from 'src/utils/model/providers.js'
|
||||
import { FEEDBACK_CHANNEL } from 'src/constants/product.js'
|
||||
import {
|
||||
getIsNonInteractiveSession,
|
||||
preferThirdPartyAuthentication,
|
||||
@@ -547,7 +548,7 @@ async function _executeApiKeyHelper(
|
||||
const hasTrust = checkHasTrustDialogAccepted()
|
||||
if (!hasTrust && !isNonInteractiveSession) {
|
||||
const error = new Error(
|
||||
`Security: apiKeyHelper executed before workspace trust is confirmed. If you see this message, post in ${MACRO.FEEDBACK_CHANNEL}.`,
|
||||
`Security: apiKeyHelper executed before workspace trust is confirmed. If you see this message, post in ${FEEDBACK_CHANNEL}.`,
|
||||
)
|
||||
logAntError('apiKeyHelper invoked before trust check', error)
|
||||
logEvent('tengu_apiKeyHelper_missing_trust11', {})
|
||||
@@ -622,7 +623,7 @@ async function runAwsAuthRefresh(): Promise<boolean> {
|
||||
const hasTrust = checkHasTrustDialogAccepted()
|
||||
if (!hasTrust && !getIsNonInteractiveSession()) {
|
||||
const error = new Error(
|
||||
`Security: awsAuthRefresh executed before workspace trust is confirmed. If you see this message, post in ${MACRO.FEEDBACK_CHANNEL}.`,
|
||||
`Security: awsAuthRefresh executed before workspace trust is confirmed. If you see this message, post in ${FEEDBACK_CHANNEL}.`,
|
||||
)
|
||||
logAntError('awsAuthRefresh invoked before trust check', error)
|
||||
logEvent('tengu_awsAuthRefresh_missing_trust', {})
|
||||
@@ -719,7 +720,7 @@ async function getAwsCredsFromCredentialExport(): Promise<{
|
||||
const hasTrust = checkHasTrustDialogAccepted()
|
||||
if (!hasTrust && !getIsNonInteractiveSession()) {
|
||||
const error = new Error(
|
||||
`Security: awsCredentialExport executed before workspace trust is confirmed. If you see this message, post in ${MACRO.FEEDBACK_CHANNEL}.`,
|
||||
`Security: awsCredentialExport executed before workspace trust is confirmed. If you see this message, post in ${FEEDBACK_CHANNEL}.`,
|
||||
)
|
||||
logAntError('awsCredentialExport invoked before trust check', error)
|
||||
logEvent('tengu_awsCredentialExport_missing_trust', {})
|
||||
@@ -886,7 +887,7 @@ async function runGcpAuthRefresh(): Promise<boolean> {
|
||||
const hasTrust = checkHasTrustDialogAccepted()
|
||||
if (!hasTrust && !getIsNonInteractiveSession()) {
|
||||
const error = new Error(
|
||||
`Security: gcpAuthRefresh executed before workspace trust is confirmed. If you see this message, post in ${MACRO.FEEDBACK_CHANNEL}.`,
|
||||
`Security: gcpAuthRefresh executed before workspace trust is confirmed. If you see this message, post in ${FEEDBACK_CHANNEL}.`,
|
||||
)
|
||||
logAntError('gcpAuthRefresh invoked before trust check', error)
|
||||
logEvent('tengu_gcpAuthRefresh_missing_trust', {})
|
||||
|
||||
Reference in New Issue
Block a user