Giter Site home page Giter Site logo

pygithub put file about kp HOT 3 OPEN

qgbcs avatar qgbcs commented on August 22, 2024
pygithub put file

from kp.

Comments (3)

qgbcs avatar qgbcs commented on August 22, 2024

同一个文件 上传两次

<Response [422]>

{'message': 'Invalid request.\n\n"sha" wasn\'t supplied.', 'documentation_url': 'https://docs.github.com/rest/reference/repos#create-or-update-file-contents'}

from kp.

qgbcs avatar qgbcs commented on August 22, 2024
In [141]: f
Out[141]: '/home/klk/v/.git/refs/heads/master'

In [142]: ll -al {f}
-rw-rw-r-- 1 klk 41 Mar 25 00:56 /home/klk/v/.git/refs/heads/master

In [143]: F.read_byte f
--------> F.read_byte(f)
Out[143]: b'234820a25edef263f18db9b9e3778ff012dd6ea1\n'

In [144]: git.github_upload(f)
Out[144]: <Response [422]>

In [145]: r
Out[145]: <Response [422]>

In [146]: print(r.json()['message'])
path contains a malformed path component

{'message': 'path contains a malformed path component',
 'errors': [{'resource': 'Commit', 'field': 'path', 'code': 'invalid'}],
 'documentation_url': 'https://docs.github.com/rest/reference/repos#create-or-update-file-contents'}

from kp.

qgbcs avatar qgbcs commented on August 22, 2024

连续发送大约9千个 请求

Out[254]: <Response [403]>

In [255]: print(_.json()['message'])
API rate limit exceeded for user ID 36606669.


In [257]: n,f
Out[257]: 
(9257,
 '/home/klk/.local/lib/python3.6/site-packages/twisted/enterprise/adbapi.py')

from kp.

Related Issues (2)

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.