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

[ISSUE] Gist 上传提示错误 实际已成功 #179

Open
tindy2013 opened this issue May 31, 2020 · 7 comments
Open

[ISSUE] Gist 上传提示错误 实际已成功 #179

tindy2013 opened this issue May 31, 2020 · 7 comments

Comments

@tindy2013
Copy link
Owner

请遇到此问题的用户执行以下操作,便于排查问题:

  1. 创建新 Gist 提示错误实际上已创建的用户,执行以下指令:
curl -v -X POST -H "Authorization: token 你的具有 Gist 权限的 Personal Access Token" -d '{"description":"test","public":false,"files":{"file":{"content":"content"}}}' https://api.github.com/gists

将服务器返回的 Header 脱敏后回复到此 Issue 下面。
2. 修改已有 Gist 提示错误实际上已成功的用户,执行以下指令:

curl -v -X PATCH -H "Authorization: token 你的具有 Gist 权限的 Personal Access Token" -d '{"description":"test","public":false,"files":{"file":{"content":"content"}}}' https://api.github.com/gists/你的 Gist ID

将服务器返回的 Header 脱敏后回复到此 Issue 下面。

#57

@tindy2013 tindy2013 pinned this issue May 31, 2020
@Quackgrass
Copy link

C:\Users\G>curl -v -X PATCH -H "Authorization: ****************************************" -d '{"description":"test","public":false,"files":{"file":{"content":"content"}}}' https://api.github.com/gists/********************************
*   Trying 13.250.94.254...
* TCP_NODELAY set
* Connected to api.github.com (13.250.94.254) port 443 (#0)
* schannel: SSL/TLS connection with api.github.com port 443 (step 1/3)
* schannel: checking server certificate revocation
* schannel: sending initial handshake data: sending 185 bytes...
* schannel: sent initial handshake data: sent 185 bytes
* schannel: SSL/TLS connection with api.github.com port 443 (step 2/3)
* schannel: failed to receive handshake, need more data
* schannel: SSL/TLS connection with api.github.com port 443 (step 2/3)
* schannel: encrypted data got 2400
* schannel: encrypted data buffer: offset 2400 length 4096
* schannel: encrypted data length: 2298
* schannel: encrypted data buffer: offset 2298 length 4096
* schannel: received incomplete message, need more data
* schannel: SSL/TLS connection with api.github.com port 443 (step 2/3)
* schannel: encrypted data got 872
* schannel: encrypted data buffer: offset 3170 length 4096
* schannel: sending next handshake data: sending 93 bytes...
* schannel: SSL/TLS connection with api.github.com port 443 (step 2/3)
* schannel: encrypted data got 51
* schannel: encrypted data buffer: offset 51 length 4096
* schannel: SSL/TLS handshake complete
* schannel: SSL/TLS connection with api.github.com port 443 (step 3/3)
* schannel: stored credential handle in session cache
> PATCH /gists/******************************** HTTP/1.1
> Host: api.github.com
> User-Agent: curl/7.55.1
> Accept: */*
> Authorization: ****************************************
> Content-Length: 64
> Content-Type: application/x-www-form-urlencoded
>
* upload completely sent off: 64 out of 64 bytes
* schannel: client wants to read 102400 bytes
* schannel: encdata_buffer resized 103424
* schannel: encrypted data buffer: offset 0 length 103424
* schannel: encrypted data got 1095
* schannel: encrypted data buffer: offset 1095 length 103424
* schannel: decrypted data length: 1066
* schannel: decrypted data added: 1066
* schannel: decrypted data cached: offset 1066 length 102400
* schannel: encrypted data buffer: offset 0 length 103424
* schannel: decrypted data buffer: offset 1066 length 102400
* schannel: schannel_recv cleanup
* schannel: decrypted data returned 1066
* schannel: decrypted data buffer: offset 0 length 102400
< HTTP/1.1 404 Not Found
< Date: Sat, 13 Jun 2020 15:49:49 GMT
< Content-Type: application/json; charset=utf-8
< Content-Length: 106
< Server: GitHub.com
< Status: 404 Not Found
< X-RateLimit-Limit: 60
< X-RateLimit-Remaining: 59
< X-RateLimit-Reset: 1592066989
< X-GitHub-Media-Type: github.v3; format=json
< Access-Control-Expose-Headers: ETag, Link, Location, Retry-After, X-GitHub-OTP, X-RateLimit-Limit, X-RateLimit-Remaining, X-RateLimit-Reset, X-OAuth-Scopes, X-Accepted-OAuth-Scopes, X-Poll-Interval, X-GitHub-Media-Type, Deprecation, Sunset
< Access-Control-Allow-Origin: *
< Strict-Transport-Security: max-age=31536000; includeSubdomains; preload
< X-Frame-Options: deny
< X-Content-Type-Options: nosniff
< X-XSS-Protection: 1; mode=block
< Referrer-Policy: origin-when-cross-origin, strict-origin-when-cross-origin
< Content-Security-Policy: default-src 'none'
< Vary: Accept-Encoding, Accept, X-Requested-With
< X-GitHub-Request-Id: 8A0C:7ADD:C4286E:FF7C33:5EE4F59B
<
{
  "message": "Not Found",
  "documentation_url": "https://developer.github.com/v3/gists/#edit-a-gist"
}
* Connection #0 to host api.github.com left intact
2020/06/13 Sat 23:48:04.464413 [13900 31][INFO] Generate target: Clash
2020/06/13 Sat 23:48:04.545438 [13900 31][INFO] Gist id provided. Modifying Gist...
*   Trying 127.0.0.1:7890...
* Connected to 127.0.0.1 (127.0.0.1) port 7890 (#0)
* allocate connect buffer!
* Establish HTTP proxy tunnel to api.github.com:443
> CONNECT api.github.com:443 HTTP/1.1
Host: api.github.com:443
User-Agent: subconverter/v0.5.2 cURL/7.64.1
Proxy-Connection: Keep-Alive

< HTTP/1.1 200 Connection established
<
* Proxy replied 200 to CONNECT request
* CONNECT phase completed!
* ALPN, offering http/1.1
* CONNECT phase completed!
* CONNECT phase completed!
* SSL connection using TLSv1.3 / TLS_AES_128_GCM_SHA256
* ALPN, server accepted to use http/1.1
* Server certificate:
*  subject: C=US; ST=California; L=San Francisco; O=GitHub, Inc.; CN=*.github.com
*  start date: Jul  8 00:00:00 2019 GMT
*  expire date: Jul 16 12:00:00 2020 GMT
*  issuer: C=US; O=DigiCert Inc; OU=www.digicert.com; CN=DigiCert SHA2 High Assurance Server CA
*  SSL certificate verify result: unable to get local issuer certificate (20), continuing anyway.
> PATCH /gists/******************************** HTTP/1.1
Host: api.github.com
User-Agent: subconverter/v0.5.2 cURL/7.64.1
Accept: */*
Content-Type: application/json;charset='utf-8'
Authorization: token ****************************************
Content-Length: 398742

* We are completely uploaded and fine
* old SSL session ID is stale, removing
* Mark bundle as not supporting multiuse
< HTTP/1.1 200 OK
< Date: Sat, 13 Jun 2020 15:48:10 GMT
< Content-Type: application/json; charset=utf-8
* Maximum file size exceeded
* Closing connection 0
2020/06/13 Sat 23:48:10.076572 [13900 31][ERRO] Modify Gist failed! Return data:

2020/06/13 Sat 23:48:10.082570 [13900 31][INFO] Generate completed.

@tindy2013
Copy link
Owner Author

tindy2013 commented Jun 21, 2020

* Maximum file size exceeded
超出文件大小限制 下个版本会进行调整 不限制上传时的文件大小

@lcy65595996
Copy link

  • Trying 198.18.2.112...
  • TCP_NODELAY set
  • Connected to api.github.com (198.18.2.112) port 443 (#0)
  • schannel: SSL/TLS connection with api.github.com port 443 (step 1/3)
  • schannel: checking server certificate revocation
  • schannel: sending initial handshake data: sending 185 bytes...
  • schannel: sent initial handshake data: sent 185 bytes
  • schannel: SSL/TLS connection with api.github.com port 443 (step 2/3)
  • schannel: failed to receive handshake, need more data
  • schannel: SSL/TLS connection with api.github.com port 443 (step 2/3)
  • schannel: failed to receive handshake, SSL/TLS connection failed
  • Closing connection 0
  • schannel: shutting down SSL/TLS connection with api.github.com port 443
  • Send failure: Connection was reset
  • schannel: failed to send close msg: Failed sending data to the peer (bytes written: -1)
  • schannel: clear security context handle
    curl: (35) schannel: failed to receive handshake, SSL/TLS connection failed

@tindy2013
Copy link
Owner Author

  • Trying 198.18.2.112...
  • TCP_NODELAY set
  • Connected to api.github.com (198.18.2.112) port 443 (#0)
  • schannel: SSL/TLS connection with api.github.com port 443 (step 1/3)
  • schannel: checking server certificate revocation
  • schannel: sending initial handshake data: sending 185 bytes...
  • schannel: sent initial handshake data: sent 185 bytes
  • schannel: SSL/TLS connection with api.github.com port 443 (step 2/3)
  • schannel: failed to receive handshake, need more data
  • schannel: SSL/TLS connection with api.github.com port 443 (step 2/3)
  • schannel: failed to receive handshake, SSL/TLS connection failed
  • Closing connection 0
  • schannel: shutting down SSL/TLS connection with api.github.com port 443
  • Send failure: Connection was reset
  • schannel: failed to send close msg: Failed sending data to the peer (bytes written: -1)
  • schannel: clear security context handle
    curl: (35) schannel: failed to receive handshake, SSL/TLS connection failed

此为无法连接 Gist 服务器,如可能请先为 curl 添加代理设置。

@AdoShan
Copy link

AdoShan commented Dec 29, 2021

大佬们,问一下我push自己的gist为啥提示
remote: Repository not found. fatal: repository 'https://gist.github.com/xxx.git/' not found

咋办,使用的就是 git push
ps:
测试ssh密钥时[email protected]通过,但是[email protected]不通过,很疑惑

@tindy2013
Copy link
Owner Author

@AdoShan
Copy link

AdoShan commented Jan 5, 2022

@AdoShan [email protected]

那为啥push失败了,说找不到这个库

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

4 participants