Skip to content
This repository was archived by the owner on Aug 12, 2025. It is now read-only.
This repository was archived by the owner on Aug 12, 2025. It is now read-only.

playlist_updates.py is broken in newer versions of python #550

Open

Description

./playlist_updates.py
  File "/home/pmansfield/git/pmansfield/devops_utilities/google/./playlist_updates.py", line 60
    print 'New playlist ID: %s' % playlists_insert_response['id']
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
SyntaxError: Missing parentheses in call to 'print'. Did you mean print(...)?

then

$ ./playlist_updates.py
  File "/home/pmansfield/git/pmansfield/devops_utilities/google/./playlist_updates.py", line 77
    except HttpError, e:
           ^^^^^^^^^^^^
SyntaxError: multiple exception types must be parenthesized

then

$ ./playlist_updates.py
  File "/home/pmansfield/git/pmansfield/devops_utilities/google/./playlist_updates.py", line 78
    print 'An HTTP error %d occurred:\n%s' % (e.resp.status, e.content)
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
SyntaxError: Missing parentheses in call to 'print'. Did you mean print(...)?

then

Traceback (most recent call last):
  File "/home/pmansfield/git/pmansfield/devops_utilities/google/./playlist_updates.py", line 74, in <module>
    youtube = get_authenticated_service()
              ^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/pmansfield/git/pmansfield/devops_utilities/google/./playlist_updates.py", line 40, in get_authenticated_service
    credentials = flow.run_console()
                  ^^^^^^^^^^^^^^^^
AttributeError: 'InstalledAppFlow' object has no attribute 'run_console'

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions