Connect Google Using Credentials

Home / Topic / Connect Google Using Credentials

Home Forums Google Sheets Report Generator Discussion Forum Connect Google Using Credentials

Viewing 1 reply thread
  • Author
    Posts
    • #3338
      Nguyen Le
      Participant

      Hello,

      I am trying to read data from a google spreadsheet, but I am not sure how to use this add-on. I have installed Python 3.9 and got the Google API credentials stored in credentials.json as shown below:

      I am getting this error: 

      Error Detail: OSError: [WinError 10013] An attempt was made to access a socket in a way forbidden by its access permissions

      Error Traceback (most recent call last):
      –> File “C:\Program Files (x86)\National Instruments\LabVIEW 2021\vi.lib\AJ\Report Generation Toolkit For Google Sheets\bin\0cca5078”, line 64, in <module>
      –> main(sys.argv[1:])
      –> File “C:\Program Files (x86)\National Instruments\LabVIEW 2021\vi.lib\AJ\Report Generation Toolkit For Google Sheets\bin\0cca5078”, line 57, in main
      –> creds = flow.run_local_server()
      –> File “C:\Users\CRXG46\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.9_qbz5n2kfra8p0\LocalCache\local-packages\Python39\site-packages\google_auth_oauthlib\flow.py”, line 485, in run_local_server
      –> local_server = wsgiref.simple_server.make_server(
      –> File “C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.9_3.9.3312.0_x64__qbz5n2kfra8p0\lib\wsgiref\simple_server.py”, line 154, in make_server
      –> server = server_class((host, port), handler_class)
      –> File “C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.9_3.9.3312.0_x64__qbz5n2kfra8p0\lib\socketserver.py”, line 452, in __init__
      –> self.server_bind()
      –> File “C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.9_3.9.3312.0_x64__qbz5n2kfra8p0\lib\wsgiref\simple_server.py”, line 50, in server_bind
      –> HTTPServer.server_bind(self)
      –> File “C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.9_3.9.3312.0_x64__qbz5n2kfra8p0\lib\http\server.py”, line 136, in server_bind
      –> socketserver.TCPServer.server_bind(self)
      –> File “C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.9_3.9.3312.0_x64__qbz5n2kfra8p0\lib\socketserver.py”, line 466, in server_bind
      –> self.socket.bind(self.server_address)
      –> OSError: [WinError 10013] An attempt was made to access a socket in a way forbidden by its access permissions

       

      I hope you could help,

      Thank you.

    • #3808
      Ajay
      Keymaster

      Hi Nguyen Le,

      There is a FAQ section in the installation procedure document whiche explains specifically about WinError 10013.  Below is the excerpt

      Why do I get the OSError: [WinError 10013] error?

      Error 899404774 occurred at Error Detail: OSError: [WinError 10013] An attempt was made to access a socket in a way forbidden by its access permissions

      Answer: This error occurs due to the usage of port 8080 by some other applications in the PC. To fix this, open flow.py under google python package and edit the ln:369 with different port. Any port like 8070 would work. Flow.py can be typically found under C:\Users\Win7VM\AppData\Local\Programs\Python\Python37-32\Lib\sitepackages\google_auth_oauthlib

      Thanks,
      AJ

Viewing 1 reply thread
  • You must be logged in to reply to this topic.