Reading a github file using python returns HTML tags

后端 未结 5 1600
情书的邮戳
情书的邮戳 2020-12-18 07:40

I am trying to read a text file saved in github using requests package. Here is the python code I am using:

    import requests
    url = \'https://github.co         


        
5条回答
  •  一个人的身影
    2020-12-18 07:59

    You could first clone the repo, either via bash, or using a python library like GitPython. Then just open and read the file locally.

提交回复
热议问题