Squarespace Developer CLI未按预期工作

时间:2018-01-18 20:33:22

标签: shell developer-tools squarespace

我正在尝试使用网站上的快速指南设置新的方空间开发者网站。

https://developers.squarespace.com/get-started

我无法登录我的squarespace帐户,然后同步这些网站。输入密码后,我收到以下错误。

ERROR: { StatusCodeError: 404 - "<html>\n<head>\n<title>404 Not Found</title>\n<style> body { background-color: #F2F2F2; color: #3E3E3E; font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif; font-size: 12px; } pre { word-wrap: break-word; } </style>\n</head>\n<body>\n<h1>404 Not Found</h1>\n<p><pre>oy7BQZNq/qHYGjXF0 @ Thu, 18 Jan 2018 20:27:51 GMT</pre>\n<p><pre>SEC-1306</pre>\n<p><pre></pre>\n</body>\n</html>"
    at new StatusCodeError (/Users/cwahlfeldt/Apps/base-template-npm/node_modules/request-promise-core/lib/errors.js:32:15)
    at Request.plumbing.callback (/Users/cwahlfeldt/Apps/base-template-npm/node_modules/request-promise-core/lib/plumbing.js:104:33)
    at Request.RP$callback [as _callback] (/Users/cwahlfeldt/Apps/base-template-npm/node_modules/request-promise-core/lib/plumbing.js:46:31)
    at Request.self.callback (/Users/cwahlfeldt/Apps/base-template-npm/node_modules/request/request.js:186:22)
    at Request.emit (events.js:160:13)
    at Request.<anonymous> (/Users/cwahlfeldt/Apps/base-template-npm/node_modules/request/request.js:1163:10)
    at Request.emit (events.js:160:13)
    at IncomingMessage.<anonymous> (/Users/cwahlfeldt/Apps/base-template-npm/node_modules/request/request.js:1085:12)
    at Object.onceWrapper (events.js:255:19)
    at IncomingMessage.emit (events.js:165:20)
    at endReadableNT (_stream_readable.js:1101:12)
    at process._tickCallback (internal/process/next_tick.js:152:19)
  name: 'StatusCodeError',
  statusCode: 404,
  message: '404 - "<html>\\n<head>\\n<title>404 Not Found</title>\\n<style> body { background-color: #F2F2F2; color: #3E3E3E; font-family: \'Helvetica Neue\', Helvetica, Arial, sans-serif; font-size: 12px; } pre { word-wrap: break-word; } </style>\\n</head>\\n<body>\\n<h1>404 Not Found</h1>\\n<p><pre>oy7BQZNq/qHYGjXF0 @ Thu, 18 Jan 2018 20:27:51 GMT</pre>\\n<p><pre>SEC-1306</pre>\\n<p><pre></pre>\\n</body>\\n</html>"',
  error: '<html>\n<head>\n<title>404 Not Found</title>\n<style> body { background-color: #F2F2F2; color: #3E3E3E; font-family: \'Helvetica Neue\', Helvetica, Arial, sans-serif; font-size: 12px; } pre { word-wrap: break-word; } </style>\n</head>\n<body>\n<h1>404 Not Found</h1>\n<p><pre>oy7BQZNq/qHYGjXF0 @ Thu, 18 Jan 2018 20:27:51 GMT</pre>\n<p><pre>SEC-1306</pre>\n<p><pre></pre>\n</body>\n</html>',
  options:
   { method: 'POST',
     uri: 'https://www.squarespace.com/api/auth/Login?crumb=undefined',
     headers:
      { 'User-Agent': 'Squarespace Toolbelt (Squarespace)',
        cookie: 'secureauthtoken=a55fd6b7-4327-4e6d-92c7-7fa2f12dc00d&TBI8DK9VAN',
        'Content-Type': 'application/x-www-form-urlencoded' },
     resolveWithFullResponse: true,
     json: true,
     form:
      { email: 'chriswahlfeldt@gmail.com',
        password: '********',
        isClient: true,
        remember: true,
        includeWebsiteList: true },
     callback: [Function: RP$callback],
     transform: undefined,
     simple: true,
     transform2xxOnly: false },
  response:
   IncomingMessage {
     _readableState:
      ReadableState {
        objectMode: false,
        highWaterMark: 16384,
        buffer: [BufferList],
        length: 0,
        pipes: null,
        pipesCount: 0,
        flowing: true,
        ended: true,
        endEmitted: true,
        reading: false,
        sync: true,
        needReadable: false,
        emittedReadable: false,
        readableListening: false,
        resumeScheduled: false,
        destroyed: false,
        defaultEncoding: 'utf8',
        awaitDrain: 0,
        readingMore: false,
        decoder: null,
        encoding: null },
     readable: false,
     domain: null,
     _events:
      { end: [Array],
        close: [Array],
        data: [Function],
        error: [Function] },
     _eventsCount: 4,
     _maxListeners: undefined,
     socket:
      TLSSocket {
        _tlsOptions: [Object],
        _secureEstablished: true,
        _securePending: false,
        _newSessionPending: false,
        _controlReleased: true,
        _SNICallback: null,
        servername: 'www.squarespace.com',
        npnProtocol: undefined,
        alpnProtocol: false,
        authorized: true,
        authorizationError: null,
        encrypted: true,
        _events: [Object],
        _eventsCount: 9,
        connecting: false,
        _hadError: false,
        _handle: null,
        _parent: null,
        _host: 'www.squarespace.com',
        _readableState: [ReadableState],
        readable: false,
        domain: null,
        _maxListeners: undefined,
        _writableState: [WritableState],
        writable: false,
        allowHalfOpen: false,
        _bytesDispatched: 418,
        _sockname: null,
        _pendingData: null,
        _pendingEncoding: '',
        server: undefined,
        _server: null,
        ssl: null,
        _requestCert: true,
        _rejectUnauthorized: true,
        parser: null,
        _httpMessage: [ClientRequest],
        read: [Function],
        _consuming: true,
        _idleNext: null,
        _idlePrev: null,
        _idleTimeout: -1,
        [Symbol(res)]: null,
        [Symbol(asyncId)]: 254,
        [Symbol(bytesRead)]: 690,
        [Symbol(connect-options)]: [Object] },
     connection:
      TLSSocket {
        _tlsOptions: [Object],
        _secureEstablished: true,
        _securePending: false,
        _newSessionPending: false,
        _controlReleased: true,
        _SNICallback: null,
        servername: 'www.squarespace.com',
        npnProtocol: undefined,
        alpnProtocol: false,
        authorized: true,
        authorizationError: null,
        encrypted: true,
        _events: [Object],
        _eventsCount: 9,
        connecting: false,
        _hadError: false,
        _handle: null,
        _parent: null,
        _host: 'www.squarespace.com',
        _readableState: [ReadableState],
        readable: false,
        domain: null,
        _maxListeners: undefined,
        _writableState: [WritableState],
        writable: false,
        allowHalfOpen: false,
        _bytesDispatched: 418,
        _sockname: null,
        _pendingData: null,
        _pendingEncoding: '',
        server: undefined,
        _server: null,
        ssl: null,
        _requestCert: true,
        _rejectUnauthorized: true,
        parser: null,
        _httpMessage: [ClientRequest],
        read: [Function],
        _consuming: true,
        _idleNext: null,
        _idlePrev: null,
        _idleTimeout: -1,
        [Symbol(res)]: null,
        [Symbol(asyncId)]: 254,
        [Symbol(bytesRead)]: 690,
        [Symbol(connect-options)]: [Object] },
     httpVersionMajor: 1,
     httpVersionMinor: 1,
     httpVersion: '1.1',
     complete: true,
     headers:
      { 'content-length': '376',
        'x-synthetic': 'true',
        connection: 'close',
        expires: 'Thu, 01 Jan 1970 00:00:00 UTC',
        pragma: 'no-cache',
        'cache-control': 'no-cache, must-revalidate',
        'content-type': 'text/html; charset=UTF-8',
        date: 'Thu, 18 Jan 2018 20:27:51 UTC',
        'x-contextid': 'oy7BQZNq/qHYGjXF0',
        'x-via': '1.1 echo023' },
     rawHeaders:
      [ 'content-length',
        '376',
        'x-synthetic',
        'true',
        'connection',
        'close',
        'expires',
        'Thu, 01 Jan 1970 00:00:00 UTC',
        'pragma',
        'no-cache',
        'cache-control',
        'no-cache, must-revalidate',
        'content-type',
        'text/html; charset=UTF-8',
        'date',
        'Thu, 18 Jan 2018 20:27:51 UTC',
        'x-contextid',
        'oy7BQZNq/qHYGjXF0',
        'x-via',
        '1.1 echo023' ],
     trailers: {},
     rawTrailers: [],
     upgrade: false,
     url: '',
     method: null,
     statusCode: 404,
     statusMessage: 'Not Found',
     client:
      TLSSocket {
        _tlsOptions: [Object],
        _secureEstablished: true,
        _securePending: false,
        _newSessionPending: false,
        _controlReleased: true,
        _SNICallback: null,
        servername: 'www.squarespace.com',
        npnProtocol: undefined,
        alpnProtocol: false,
        authorized: true,
        authorizationError: null,
        encrypted: true,
        _events: [Object],
        _eventsCount: 9,
        connecting: false,
        _hadError: false,
        _handle: null,
        _parent: null,
        _host: 'www.squarespace.com',
        _readableState: [ReadableState],
        readable: false,
        domain: null,
        _maxListeners: undefined,
        _writableState: [WritableState],
        writable: false,
        allowHalfOpen: false,
        _bytesDispatched: 418,
        _sockname: null,
        _pendingData: null,
        _pendingEncoding: '',
        server: undefined,
        _server: null,
        ssl: null,
        _requestCert: true,
        _rejectUnauthorized: true,
        parser: null,
        _httpMessage: [ClientRequest],
        read: [Function],
        _consuming: true,
        _idleNext: null,
        _idlePrev: null,
        _idleTimeout: -1,
        [Symbol(res)]: null,
        [Symbol(asyncId)]: 254,
        [Symbol(bytesRead)]: 690,
        [Symbol(connect-options)]: [Object] },
     _consuming: true,
     _dumped: false,
     req:
      ClientRequest {
        domain: null,
        _events: [Object],
        _eventsCount: 5,
        _maxListeners: undefined,
        output: [],
        outputEncodings: [],
        outputCallbacks: [],
        outputSize: 0,
        writable: true,
        _last: true,
        upgrading: false,
        chunkedEncoding: false,
        shouldKeepAlive: false,
        useChunkedEncodingByDefault: true,
        sendDate: false,
        _removedConnection: false,
        _removedContLen: false,
        _removedTE: false,
        _contentLength: null,
        _hasBody: true,
        _trailer: '',
        finished: true,
        _headerSent: true,
        socket: [TLSSocket],
        connection: [TLSSocket],
        _header: 'POST /api/auth/Login?crumb=undefined HTTP/1.1\r\nUser-Agent: Squarespace Toolbelt (Squarespace)\r\ncookie: secureauthtoken=a55fd6b7-4327-4e6d-92c7-7fa2f12dc00d&TBI8DK9VAN\r\nContent-Type: application/x-www-form-urlencoded\r\nhost: www.squarespace.com\r\naccept: application/json\r\ncontent-length: 106\r\nConnection: close\r\n\r\n',
        _onPendingData: [Function: noopPendingOutput],
        agent: [Agent],
        socketPath: undefined,
        timeout: undefined,
        method: 'POST',
        path: '/api/auth/Login?crumb=undefined',
        _ended: true,
        res: [Circular],
        aborted: undefined,
        timeoutCb: null,
        upgradeOrConnect: false,
        parser: null,
        maxHeadersCount: null,
        [Symbol(outHeadersKey)]: [Object] },
     request:
      Request {
        domain: null,
        _events: [Object],
        _eventsCount: 5,
        _maxListeners: undefined,
        method: 'POST',
        uri: [Url],
        headers: [Object],
        resolveWithFullResponse: true,
        readable: true,
        writable: true,
        explicitMethod: true,
        _qs: [Querystring],
        _auth: [Auth],
        _oauth: [OAuth],
        _multipart: [Multipart],
        _redirect: [Redirect],
        _tunnel: [Tunnel],
        _rp_resolve: [Function],
        _rp_reject: [Function],
        _rp_promise: [Promise],
        _rp_callbackOrig: undefined,
        callback: [Function],
        _rp_options: [Object],
        setHeader: [Function],
        hasHeader: [Function],
        getHeader: [Function],
        removeHeader: [Function],
        localAddress: undefined,
        pool: {},
        dests: [],
        __isRequestRequest: true,
        _callback: [Function: RP$callback],
        proxy: null,
        tunnel: true,
        setHost: true,
        originalCookieHeader: 'secureauthtoken=a55fd6b7-4327-4e6d-92c7-7fa2f12dc00d&TBI8DK9VAN',
        _disableCookies: true,
        _jar: undefined,
        port: 443,
        host: 'www.squarespace.com',
        body: 'email=chriswahlfeldt%40gmail.com&password=*******&isClient=true&remember=true&includeWebsiteList=true',
        path: '/api/auth/Login?crumb=undefined',
        _json: true,
        httpModule: [Object],
        agentClass: [Function],
        agent: [Agent],
        _started: true,
        href: 'https://www.squarespace.com/api/auth/Login?crumb=undefined',
        req: [ClientRequest],
        ntick: true,
        response: [Circular],
        originalHost: 'www.squarespace.com',
        originalHostHeaderName: 'host',
        responseContent: [Circular],
        _destdata: true,
        _ended: true,
        _callbackCalled: true },
     toJSON: [Function: responseToJSON],
     caseless: Caseless { dict: [Object] },
     read: [Function],
     body: '<html>\n<head>\n<title>404 Not Found</title>\n<style> body { background-color: #F2F2F2; color: #3E3E3E; font-family: \'Helvetica Neue\', Helvetica, Arial, sans-serif; font-size: 12px; } pre { word-wrap: break-word; } </style>\n</head>\n<body>\n<h1>404 Not Found</h1>\n<p><pre>oy7BQZNq/qHYGjXF0 @ Thu, 18 Jan 2018 20:27:51 GMT</pre>\n<p><pre>SEC-1306</pre>\n<p><pre></pre>\n</body>\n</html>' } }
error Command failed with exit code 1.

要重现,您只需尝试链接上的“入门”页面即可。我做了所有这些步骤,并不断收到此错误。

干杯!

0 个答案:

没有答案