Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

We can't connect to the server for this app or website at this time. There might be too much traffic or a configuration error. Try again later, or contact the app or website owner. #66

Open
miladtsx opened this issue Feb 16, 2025 · 1 comment

Comments

@miladtsx
Copy link

When running the command npx @defi-wonderland/natspec-smells on my Solidity files, I encounter a 400 Bad Request error.

my project source code structure:

src/*.sol files

Environment:

  • @defi-wonderland/natspec-smells: "^1.1.6"
  • Node.js: v22.0.0
  • Linux
  • ZSH Terminal

Investigation:
The URL https://binaries.soliditylang.org/wasm/list.json is reachable and returns a valid response when accessed directly via curl from the same terminal. This suggests that the issue is not related to network connectivity or the availability of the Solidity service.

Expected behavior:
The tool should proceed without encountering the 400 Bad Request error when fetching the list from https://binaries.soliditylang.org/wasm/list.json.

I followed instructions; but I get 400 HTTP error.

Steps to reproduce:

npx @defi-wonderland/natspec-smells --include "src/*.sol"

Error:

npx @defi-wonderland/natspec-smells --include "src/*.sol" > res AxiosError: Request failed with status code 400 at settle (~/tsx/wonderland/malad-ants/node_modules/axios/dist/node/axios.cjs:2019:12) at IncomingMessage.handleStreamEnd (~/tsx/wonderland/malad-ants/node_modules/axios/dist/node/axios.cjs:3135:11) at IncomingMessage.emit (node:events:532:35) at endReadableNT (node:internal/streams/readable:1696:12) at process.processTicksAndRejections (node:internal/process/task_queues:82:21) at Axios.request (~/tsx/wonderland/malad-ants/node_modules/axios/dist/node/axios.cjs:4287:41) at process.processTicksAndRejections (node:internal/process/task_queues:95:5) at async downloadCompilerMDForPlatform (~/tsx/wonderland/malad-ants/node_modules/solc-typed-ast/dist/compile/kinds/md.js:53:22) at async getCompilerForVersion (~/tsx/wonderland/malad-ants/node_modules/solc-typed-ast/dist/compile/kinds/compiler.js:97:20) at async compile (~/tsx/wonderland/malad-ants/node_modules/solc-typed-ast/dist/compile/utils.js:66:22) at async compileSol (~/tsx/wonderland/malad-ants/node_modules/solc-typed-ast/dist/compile/utils.js:165:22) at async getProjectCompiledSources (~/tsx/wonderland/malad-ants/node_modules/@defi-wonderland/natspec-smells/lib/utils.js:18:27) at async ~/tsx/wonderland/malad-ants/node_modules/@defi-wonderland/natspec-smells/lib/main.js:17:25 { code: 'ERR_BAD_REQUEST', config: { transitional: { silentJSONParsing: true, forcedJSONParsing: true, clarifyTimeoutError: false }, adapter: [ 'xhr', 'http', 'fetch' ], transformRequest: [ [Function: transformRequest] ], transformResponse: [ [Function: transformResponse] ], timeout: 0, xsrfCookieName: 'XSRF-TOKEN', xsrfHeaderName: 'X-XSRF-TOKEN', maxContentLength: -1, maxBodyLength: -1, env: { FormData: [Function], Blob: [class Blob] }, validateStatus: [Function: validateStatus], headers: Object [AxiosHeaders] { Accept: 'application/json, text/plain, */*', 'Content-Type': undefined, 'User-Agent': 'axios/1.7.7', 'Accept-Encoding': 'gzip, compress, deflate, br' }, method: 'get', url: 'https://binaries.soliditylang.org/wasm/list.json', data: undefined }, request: <ref *1> ClientRequest { _events: [Object: null prototype] { abort: [Function (anonymous)], aborted: [Function (anonymous)], connect: [Function (anonymous)], error: [Function (anonymous)], socket: [Function (anonymous)], timeout: [Function (anonymous)], finish: [Function: requestOnFinish] }, _eventsCount: 7, _maxListeners: undefined, outputData: [], outputSize: 0, writable: true, destroyed: true, _last: true, chunkedEncoding: false, shouldKeepAlive: true, maxRequestsOnConnectionReached: false, _defaultKeepAlive: true, useChunkedEncodingByDefault: false, sendDate: false, _removedConnection: false, _removedContLen: false, _removedTE: false, strictContentLength: false, _contentLength: 0, _hasBody: true, _trailer: '', finished: true, _headerSent: true, _closed: true, _header: 'GET https://binaries.soliditylang.org/wasm/list.json HTTP/1.1\r\n' + 'Accept: application/json, text/plain, */*\r\n' + 'User-Agent: axios/1.7.7\r\n' + 'Accept-Encoding: gzip, compress, deflate, br\r\n' + 'host: binaries.soliditylang.org\r\n' + 'Connection: keep-alive\r\n' + '\r\n', _keepAliveTimeout: 0, _onPendingData: [Function: nop], agent: Agent { _events: [Object: null prototype], _eventsCount: 2, _maxListeners: undefined, defaultPort: 80, protocol: 'http:', options: [Object: null prototype], requests: [Object: null prototype] {}, sockets: [Object: null prototype] {}, freeSockets: [Object: null prototype], keepAliveMsecs: 1000, keepAlive: true, maxSockets: Infinity, maxFreeSockets: 256, scheduling: 'lifo', maxTotalSockets: Infinity, totalSocketCount: 1, [Symbol(shapeMode)]: false, [Symbol(kCapture)]: false }, socketPath: undefined, method: 'GET', maxHeaderSize: undefined, insecureHTTPParser: undefined, joinDuplicateHeaders: undefined, path: 'https://binaries.soliditylang.org/wasm/list.json', _ended: true, res: IncomingMessage { _events: [Object], _readableState: [ReadableState], _maxListeners: undefined, socket: null, httpVersionMajor: 1, httpVersionMinor: 1, httpVersion: '1.1', complete: true, rawHeaders: [Array], rawTrailers: [], joinDuplicateHeaders: undefined, aborted: false, upgrade: false, url: '', method: null, statusCode: 400, statusMessage: 'Bad Request', client: [Socket], _consuming: false, _dumped: false, req: [Circular *1], _eventsCount: 4, responseUrl: 'https://binaries.soliditylang.org/wasm/list.json', redirects: [], [Symbol(shapeMode)]: true, [Symbol(kCapture)]: false, [Symbol(kHeaders)]: [Object], [Symbol(kHeadersCount)]: 22, [Symbol(kTrailers)]: null, [Symbol(kTrailersCount)]: 0 }, aborted: false, timeoutCb: null, upgradeOrConnect: false, parser: null, maxHeadersCount: null, reusedSocket: false, host: '127.0.0.1', protocol: 'http:', _redirectable: Writable { _events: [Object], _writableState: [WritableState], _maxListeners: undefined, _options: [Object], _ended: true, _ending: true, _redirectCount: 0, _redirects: [], _requestBodyLength: 0, _requestBodyBuffers: [], _eventsCount: 3, _onNativeResponse: [Function (anonymous)], _currentRequest: [Circular *1], _currentUrl: 'https://binaries.soliditylang.org/wasm/list.json', [Symbol(shapeMode)]: true, [Symbol(kCapture)]: false }, [Symbol(shapeMode)]: false, [Symbol(kCapture)]: false, [Symbol(kBytesWritten)]: 0, [Symbol(kNeedDrain)]: false, [Symbol(corked)]: 0, [Symbol(kChunkedBuffer)]: [], [Symbol(kChunkedLength)]: 0, [Symbol(kSocket)]: Socket { connecting: false, _hadError: false, _parent: null, _host: null, _closeAfterHandlingError: false, _events: [Object], _readableState: [ReadableState], _writableState: [WritableState], allowHalfOpen: false, _maxListeners: undefined, _eventsCount: 6, _sockname: null, _pendingData: null, _pendingEncoding: '', server: null, _server: null, timeout: 4000, parser: null, _httpMessage: null, [Symbol(async_id_symbol)]: -1, [Symbol(kHandle)]: [TCP], [Symbol(lastWriteQueueSize)]: 0, [Symbol(timeout)]: Timeout { _idleTimeout: 4000, _idlePrev: [TimersList], _idleNext: [TimersList], _idleStart: 984, _onTimeout: [Function: bound ], _timerArgs: undefined, _repeat: null, _destroyed: false, [Symbol(refed)]: false, [Symbol(kHasPrimitive)]: false, [Symbol(asyncId)]: 139, [Symbol(triggerId)]: 137 }, [Symbol(kBuffer)]: null, [Symbol(kBufferCb)]: null, [Symbol(kBufferGen)]: null, [Symbol(shapeMode)]: true, [Symbol(kCapture)]: false, [Symbol(kSetNoDelay)]: true, [Symbol(kSetKeepAlive)]: true, [Symbol(kSetKeepAliveInitialDelay)]: 1, [Symbol(kBytesRead)]: 0, [Symbol(kBytesWritten)]: 0 }, [Symbol(kOutHeaders)]: [Object: null prototype] { accept: [Array], 'user-agent': [Array], 'accept-encoding': [Array], host: [Array] }, [Symbol(errored)]: null, [Symbol(kHighWaterMark)]: 65536, [Symbol(kRejectNonStandardBodyWrites)]: false, [Symbol(kUniqueHeaders)]: null }, response: { status: 400, statusText: 'Bad Request', headers: Object [AxiosHeaders] { 'content-length': '915', connection: 'keep-alive', 'content-type': 'text/html', date: 'Sun, 16 Feb 2025 15:31:18 GMT', 'keep-alive': 'timeout=4', 'proxy-connection': 'keep-alive', server: 'CloudFront', via: '1.1 2a6277094357eb47f8dbeacb06ed96c2.cloudfront.net (CloudFront)', 'x-amz-cf-id': 'GvvXfz2nSy9nHS6_KjnI1srXGHVXpTwxvTGu2jVghdp4neS0EJZciQ==', 'x-amz-cf-pop': 'FRA60-P2', 'x-cache': 'Error from cloudfront' }, config: { transitional: [Object], adapter: [Array], transformRequest: [Array], transformResponse: [Array], timeout: 0, xsrfCookieName: 'XSRF-TOKEN', xsrfHeaderName: 'X-XSRF-TOKEN', maxContentLength: -1, maxBodyLength: -1, env: [Object], validateStatus: [Function: validateStatus], headers: [Object [AxiosHeaders]], method: 'get', url: 'https://binaries.soliditylang.org/wasm/list.json', data: undefined }, request: <ref *1> ClientRequest { _events: [Object: null prototype], _eventsCount: 7, _maxListeners: undefined, outputData: [], outputSize: 0, writable: true, destroyed: true, _last: true, chunkedEncoding: false, shouldKeepAlive: true, maxRequestsOnConnectionReached: false, _defaultKeepAlive: true, useChunkedEncodingByDefault: false, sendDate: false, _removedConnection: false, _removedContLen: false, _removedTE: false, strictContentLength: false, _contentLength: 0, _hasBody: true, _trailer: '', finished: true, _headerSent: true, _closed: true, _header: 'GET https://binaries.soliditylang.org/wasm/list.json HTTP/1.1\r\n' + 'Accept: application/json, text/plain, */*\r\n' + 'User-Agent: axios/1.7.7\r\n' + 'Accept-Encoding: gzip, compress, deflate, br\r\n' + 'host: binaries.soliditylang.org\r\n' + 'Connection: keep-alive\r\n' + '\r\n', _keepAliveTimeout: 0, _onPendingData: [Function: nop], agent: [Agent], socketPath: undefined, method: 'GET', maxHeaderSize: undefined, insecureHTTPParser: undefined, joinDuplicateHeaders: undefined, path: 'https://binaries.soliditylang.org/wasm/list.json', _ended: true, res: [IncomingMessage], aborted: false, timeoutCb: null, upgradeOrConnect: false, parser: null, maxHeadersCount: null, reusedSocket: false, host: '127.0.0.1', protocol: 'http:', _redirectable: [Writable], [Symbol(shapeMode)]: false, [Symbol(kCapture)]: false, [Symbol(kBytesWritten)]: 0, [Symbol(kNeedDrain)]: false, [Symbol(corked)]: 0, [Symbol(kChunkedBuffer)]: [], [Symbol(kChunkedLength)]: 0, [Symbol(kSocket)]: [Socket], [Symbol(kOutHeaders)]: [Object: null prototype], [Symbol(errored)]: null, [Symbol(kHighWaterMark)]: 65536, [Symbol(kRejectNonStandardBodyWrites)]: false, [Symbol(kUniqueHeaders)]: null }, data: '<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">\n' + '<HTML><HEAD><META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=iso-8859-1">\n' + '<TITLE>ERROR: The request could not be satisfied</TITLE>\n' + '</HEAD><BODY>\n' + '<H1>400 ERROR</H1>\n' + '<H2>The request could not be satisfied.</H2>\n' + '<HR noshade size="1px">\n' + 'Bad request.\n' + "We can't connect to the server for this app or website at this time. There might be too much traffic or a configuration error. Try again later, or contact the app or website owner.\n" + '<BR clear="all">\n' + 'If you provide content to customers through CloudFront, you can find steps to troubleshoot and help prevent this error by reviewing the CloudFront documentation.\n' + '<BR clear="all">\n' + '<HR noshade size="1px">\n' + '<PRE>\n' + 'Generated by cloudfront (CloudFront)\n' + 'Request ID: GvvXfz2nSy9nHS6_KjnI1srXGHVXpTwxvTGu2jVghdp4neS0EJZciQ==\n' + '</PRE>\n' + '<ADDRESS>\n' + '</ADDRESS>\n' + '</BODY></HTML>' }, status: 400 }

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant