Pylint showing invalid variable name in output

前端 未结 3 1474
北荒
北荒 2020-12-23 13:22

I made a simple python script to post data on a website.

#Imports

url_to_short = sys.argv[1]

post_url = \'https://www.googleapis.com/urlshortener/v1/url\'
         


        
3条回答
  •  借酒劲吻你
    2020-12-23 13:54

    As your code is not contained in a class or function it is expecting those variables to be constants and as such they should be uppercase.

    You can read PEP8 for further information.

提交回复
热议问题