juzisang / picgo-plugin-compress

Image compression plugin for PicGo
MIT License
129 stars 31 forks source link

使用自定义 key 的 tinypng 上传失败,提示未授权 #41

Open jasonchio-cn opened 2 years ago

jasonchio-cn commented 2 years ago

在不使用自己申请的 key 上传图片时是正常的,如果配置了自己的 key,不管是一个还是多个,都是会上传失败,log 都是一样的

Picgo log 如下:

StatusCodeError: 401 - {"error":"Unauthorized","message":"Credentials are invalid."}
    at new StatusCodeError (D:\Program Files\PicGo\resources\app.asar\node_modules\request-promise-core\lib\errors.js:32:15)
    at Request.plumbing.callback (D:\Program Files\PicGo\resources\app.asar\node_modules\request-promise-core\lib\plumbing.js:104:33)
    at Request.RP$callback [as _callback] (D:\Program Files\PicGo\resources\app.asar\node_modules\request-promise-core\lib\plumbing.js:46:31)
    at Request.self.callback (D:\Program Files\PicGo\resources\app.asar\node_modules\request\request.js:185:22)
    at Request.emit (events.js:200:13)
    at Request.<anonymous> (D:\Program Files\PicGo\resources\app.asar\node_modules\request\request.js:1154:10)
    at Request.emit (events.js:200:13)
    at IncomingMessage.<anonymous> (D:\Program Files\PicGo\resources\app.asar\node_modules\request\request.js:1076:12)
    at Object.onceWrapper (events.js:288:20)
    at IncomingMessage.emit (events.js:205:15)
real-jiakai commented 2 years ago

我也碰到了这个问题,请问您解决了嘛?