Git Product home page Git Product logo

Comments (2)

SahilAujla avatar SahilAujla commented on August 11, 2024

Here is a complete log of the error:

e: Writable {
_writableState: [WritableState],
_events: [Object: null prototype],
_eventsCount: 2,
_maxListeners: undefined,
_options: [Object],
_ended: true,
_ending: true,
_redirectCount: 0,
_redirects: [],
_requestBodyLength: 253,
_requestBodyBuffers: [],
_onNativeResponse: [Function (anonymous)],
_currentRequest: [Circular 1],
_currentUrl: 'https://api.openai.com/v1/answers',
[Symbol(kCapture)]: false
},
[Symbol(kCapture)]: false,
[Symbol(kNeedDrain)]: false,
[Symbol(corked)]: 0,
[Symbol(kOutHeaders)]: [Object: null prototype] {
accept: [Array],
'content-type': [Array],
authorization: [Array],
'user-agent': [Array],
'content-length': [Array],
host: [Array]
}
},
response: {
status: 401,
statusText: 'UNAUTHORIZED',
headers: {
date: 'Sun, 12 Dec 2021 14:22:01 GMT',
'content-type': 'application/json',
'content-length': '251',
connection: 'close',
'www-authenticate': 'Basic realm="OpenAI API"',
'access-control-allow-origin': '
',
'openai-version': '2020-10-01',
'x-request-id': 'e4ce97e771ae5316d6a93c7dc8f5709a',
'openai-processing-ms': '393',
'strict-transport-security': 'max-age=15724800; includeSubDomains'
},
config: {
url: 'https://api.openai.com/v1/answers',
method: 'post',
data: '{"documents":[],"question":"Who is the prime Minister of India?","search_model":"ada","model":"ada","examples_context":"","examples":[["What is human life expectancy in the United States?","78 years."]],"max_tokens":64,"stop":["\n","<|endoftext|>","."]}',
headers: [Object],
transformRequest: [Array],
transformResponse: [Array],
timeout: 0,
adapter: [Function: httpAdapter],
xsrfCookieName: 'XSRF-TOKEN',
xsrfHeaderName: 'X-XSRF-TOKEN',
maxContentLength: -1,
maxBodyLength: -1,
validateStatus: [Function: validateStatus],
transitional: [Object]
},
request: <ref *1> ClientRequest {
_events: [Object: null prototype],
_eventsCount: 7,
_maxListeners: undefined,
outputData: [],
outputSize: 0,
writable: true,
destroyed: false,
_last: true,
chunkedEncoding: false,
shouldKeepAlive: false,
_defaultKeepAlive: true,
useChunkedEncodingByDefault: true,
sendDate: false,
_removedConnection: false,
_removedContLen: false,
_removedTE: false,
_contentLength: null,
_hasBody: true,
_trailer: '',
finished: true,
_headerSent: true,
socket: [TLSSocket],
_header: 'POST /v1/answers HTTP/1.1\r\n' +
'Accept: application/json, text/plain, /\r\n' +
'Content-Type: application/json\r\n' +
'Authorization: Bearer "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"\r\n' +
'User-Agent: axios/0.21.4\r\n' +
'Content-Length: 253\r\n' +
'Host: api.openai.com\r\n' +
'Connection: close\r\n' +
'\r\n',
_keepAliveTimeout: 0,
_onPendingData: [Function: noopPendingOutput],
agent: [Agent],
socketPath: undefined,
method: 'POST',
maxHeaderSize: undefined,
insecureHTTPParser: undefined,
path: '/v1/answers',
_ended: true,
res: [IncomingMessage],
aborted: false,
timeoutCb: null,
upgradeOrConnect: false,
parser: null,
maxHeadersCount: null,
reusedSocket: false,
host: 'api.openai.com',
protocol: 'https:',
_redirectable: [Writable],
[Symbol(kCapture)]: false,
[Symbol(kNeedDrain)]: false,
[Symbol(corked)]: 0,
[Symbol(kOutHeaders)]: [Object: null prototype]
},
data: { error: [Object] }
},
isAxiosError: true,
toJSON: [Function: toJSON]
}

from openai-api.

LKNSI avatar LKNSI commented on August 11, 2024

Here is a complete log of the error:

e: Writable { _writableState: [WritableState], _events: [Object: null prototype], _eventsCount: 2, _maxListeners: undefined, _options: [Object], _ended: true, _ending: true, _redirectCount: 0, _redirects: [], _requestBodyLength: 253, _requestBodyBuffers: [], _onNativeResponse: [Function (anonymous)], _currentRequest: [Circular _1], currentUrl: 'https://api.openai.com/v1/answers', [Symbol(kCapture)]: false }, [Symbol(kCapture)]: false, [Symbol(kNeedDrain)]: false, [Symbol(corked)]: 0, [Symbol(kOutHeaders)]: [Object: null prototype] { accept: [Array], 'content-type': [Array], authorization: [Array], 'user-agent': [Array], 'content-length': [Array], host: [Array] } }, response: { status: 401, statusText: 'UNAUTHORIZED', headers: { date: 'Sun, 12 Dec 2021 14:22:01 GMT', 'content-type': 'application/json', 'content-length': '251', connection: 'close', 'www-authenticate': 'Basic realm="OpenAI API"', 'access-control-allow-origin': '', 'openai-version': '2020-10-01', 'x-request-id': 'e4ce97e771ae5316d6a93c7dc8f5709a', 'openai-processing-ms': '393', 'strict-transport-security': 'max-age=15724800; includeSubDomains' }, config: { url: 'https://api.openai.com/v1/answers', method: 'post', data: '{"documents":[],"question":"Who is the prime Minister of India?","search_model":"ada","model":"ada","examples_context":"","examples":[["What is human life expectancy in the United States?","78 years."]],"max_tokens":64,"stop":["\n","<|endoftext|>","."]}', headers: [Object], transformRequest: [Array], transformResponse: [Array], timeout: 0, adapter: [Function: httpAdapter], xsrfCookieName: 'XSRF-TOKEN', xsrfHeaderName: 'X-XSRF-TOKEN', maxContentLength: -1, maxBodyLength: -1, validateStatus: [Function: validateStatus], transitional: [Object] }, request: <ref *1> ClientRequest { _events: [Object: null prototype], _eventsCount: 7, _maxListeners: undefined, outputData: [], outputSize: 0, writable: true, destroyed: false, _last: true, chunkedEncoding: false, shouldKeepAlive: false, _defaultKeepAlive: true, useChunkedEncodingByDefault: true, sendDate: false, _removedConnection: false, _removedContLen: false, _removedTE: false, _contentLength: null, _hasBody: true, _trailer: '', finished: true, _headerSent: true, socket: [TLSSocket], _header: 'POST /v1/answers HTTP/1.1\r\n' + 'Accept: application/json, text/plain, /\r\n' + 'Content-Type: application/json\r\n' + 'Authorization: Bearer "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"\r\n' + 'User-Agent: axios/0.21.4\r\n' + 'Content-Length: 253\r\n' + 'Host: api.openai.com\r\n' + 'Connection: close\r\n' + '\r\n', _keepAliveTimeout: 0, _onPendingData: [Function: noopPendingOutput], agent: [Agent], socketPath: undefined, method: 'POST', maxHeaderSize: undefined, insecureHTTPParser: undefined, path: '/v1/answers', _ended: true, res: [IncomingMessage], aborted: false, timeoutCb: null, upgradeOrConnect: false, parser: null, maxHeadersCount: null, reusedSocket: false, host: 'api.openai.com', protocol: 'https:', _redirectable: [Writable], [Symbol(kCapture)]: false, [Symbol(kNeedDrain)]: false, [Symbol(corked)]: 0, [Symbol(kOutHeaders)]: [Object: null prototype] }, data: { error: [Object] } }, isAxiosError: true, toJSON: [Function: toJSON] }

I was browsing the issue because I was board and I see you've posted your OpenAI API key/credentials into the wild above. Please change your key!

from openai-api.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.