Giter Club home page Giter Club logo

Comments (3)

 avatar commented on May 16, 2024

Eazy, eazy, it's possible to run upload.py without virtualenv, it should fix this problem!

from gphotos-upload.

pferland avatar pferland commented on May 16, 2024

It does not show anything when I run it without the VirtaulEnv.

But when I do run it with VirtualEnv it does show the following error:

[pferland@piecave gphotos-upload]$ pipenv shell
Launching subshell in virtual environment...
 . /home/pferland/.local/share/virtualenvs/gphotos-upload-gXXXWQmf/bin/activate
[pferland@piecave gphotos-upload]$  . /home/pferland/.local/share/virtualenvs/gphotos-upload-gXXXWQmf/bin/activate
(gphotos-upload) [pferland@piecave gphotos-upload]$ python upload.py --auth ./client_id.json --log ./upload.log /storage/files/Phil/Google\ Takeout/Takeout/Google\ Photos/Weekend\ in\ Niagara\ Falls/
Traceback (most recent call last):
  File "/storage/files/Phil/GitHub/gphotos-upload/upload.py", line 1, in <module>
    from google_auth_oauthlib.flow import InstalledAppFlow
  File "/home/pferland/.local/share/virtualenvs/gphotos-upload-gXXXWQmf/lib/python3.11/site-packages/google_auth_oauthlib/flow.py", line 62, in <module>
    import google.oauth2.credentials
  File "/home/pferland/.local/share/virtualenvs/gphotos-upload-gXXXWQmf/lib/python3.11/site-packages/google/oauth2/credentials.py", line 42, in <module>
    from google.oauth2 import _client
  File "/home/pferland/.local/share/virtualenvs/gphotos-upload-gXXXWQmf/lib/python3.11/site-packages/google/oauth2/_client.py", line 35, in <module>
    from google.auth import jwt
  File "/home/pferland/.local/share/virtualenvs/gphotos-upload-gXXXWQmf/lib/python3.11/site-packages/google/auth/jwt.py", line 49, in <module>
    import cachetools
  File "/home/pferland/.local/share/virtualenvs/gphotos-upload-gXXXWQmf/lib/python3.11/site-packages/cachetools/__init__.py", line 8, in <module>
    from .cache import Cache
  File "/home/pferland/.local/share/virtualenvs/gphotos-upload-gXXXWQmf/lib/python3.11/site-packages/cachetools/cache.py", line 5, in <module>
    from .abc import DefaultMapping
  File "/home/pferland/.local/share/virtualenvs/gphotos-upload-gXXXWQmf/lib/python3.11/site-packages/cachetools/abc.py", line 7, in <module>
    class DefaultMapping(collections.MutableMapping):
                         ^^^^^^^^^^^^^^^^^^^^^^^^^^
AttributeError: module 'collections' has no attribute 'MutableMapping'

from gphotos-upload.

pferland avatar pferland commented on May 16, 2024

I ran the pipenv Lock file from this Branch: https://github.com/eshmu/gphotos-upload/blob/dependabot/pip/certifi-2022.12.7/Pipfile.lock

That got past the MutableMapping error, but is now the following even with specifying the path to the browser in upload.py

(gphotos-upload) [pferland@piecave gphotos-upload]$ python upload.py --auth ./client_id.json --log ./upload.log /storage/files/Phil/Google\ Takeout/Takeout/Google\ Photos/Weekend\ in\ Niagara\ Falls/
Traceback (most recent call last):
  File "/storage/files/Phil/GitHub/gphotos-upload/upload.py", line 206, in <module>
    main()
  File "/storage/files/Phil/GitHub/gphotos-upload/upload.py", line 194, in main
    session = get_authorized_session(args.auth_file)
              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/storage/files/Phil/GitHub/gphotos-upload/upload.py", line 52, in get_authorized_session
    cred = auth(scopes)
           ^^^^^^^^^^^^
  File "/storage/files/Phil/GitHub/gphotos-upload/upload.py", line 27, in auth
    credentials = flow.run_local_server(host='localhost',
                  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/pferland/.local/share/virtualenvs/gphotos-upload-gXXXWQmf/lib/python3.11/site-packages/google_auth_oauthlib/flow.py", line 444, in run_local_server
    webbrowser.get(browser).open(auth_url, new=1, autoraise=True)
    ^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib64/python3.11/webbrowser.py", line 66, in get
    raise Error("could not locate runnable browser")
webbrowser.Error: could not locate runnable browser
(gphotos-upload) [pferland@piecave gphotos-upload]$

from gphotos-upload.

Related Issues (12)

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.