question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Vivaldi cookies can't be extracted "no such table: cookies"

See original GitHub issue

DO NOT REMOVE OR SKIP THE ISSUE TEMPLATE

  • I understand that I will be blocked if I remove or skip any mandatory* field

Checklist

  • I’m reporting a bug unrelated to a specific site
  • I’ve verified that I’m running yt-dlp version 2022.09.01 (update instructions) or later (specify commit)
  • I’ve checked that all provided URLs are playable in a browser with the same IP and same login details
  • I’ve checked that all URLs and arguments with special characters are properly quoted or escaped
  • I’ve searched the bugtracker for similar issues including closed ones. DO NOT post duplicates
  • I’ve read the guidelines for opening an issue

Provide a description that is worded well enough to be understood

I call yt-dlp from zsh with this line: yt-dlp -o "%(title)s.%(ext)s" --extract-audio --audio-format mp3 --cookies-from-browser vivaldi https://www.youtube.com/watch?v=y8trd3gjJt0 and it worked fine until now. Now it complains that the sql file has no table named cookies.

attaching my vivaldi version:

Vivaldi | 5.4.2753.47 (Stable channel) (x86_64)
-- | --
Revision | 9fb7fdb85e69a976cc6784ef2de077e88b01995d
OS | macOS Version 12.3.1 (Build 21E258)
JavaScript | V8 10.4.132.23
User Agent | Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/104.0.5112.115 Safari/537.36
Command Line | /Applications/Vivaldi.app/Contents/MacOS/Vivaldi --enable-features --disable-features --flag-switches-begin --disable-features=HardwareMediaKeyHandling --flag-switches-end --restore-last-session --disable-smooth-scrolling --save-page-as-mhtml
Executable Path | /Applications/Vivaldi.app/Contents/MacOS/Vivaldi
Profile Path | /Users/andreasbeer/Library/Application Support/Vivaldi/Default
Linker | lld

Provide verbose output that clearly demonstrates the problem

  • Run your yt-dlp command with -vU flag added (yt-dlp -vU <your command line>)
  • Copy the WHOLE output (starting with [debug] Command-line config) and insert it below

Complete Verbose Output

[debug] Command-line config: ['-vU', '-o', '%(title)s.%(ext)s', '--extract-audio', '--audio-format', 'mp3', '--cookies-from-browser', 'vivaldi', 'https://www.youtube.com/watch?v=y8trd3gjJt0']
[debug] Encodings: locale UTF-8, fs utf-8, pref UTF-8, out utf-8, error utf-8, screen utf-8
[debug] yt-dlp version 2022.09.01 [5d7c7d6] (pip)
[debug] Python 3.10.6 (CPython 64bit) - macOS-12.3.1-x86_64-i386-64bit 
[debug] Checking exe version: ffmpeg -bsfs
[debug] Checking exe version: ffprobe -bsfs
[debug] exe versions: ffmpeg 5.1.1 (setts), ffprobe 5.1.1, rtmpdump 2.4
[debug] Optional libraries: Cryptodome-3.15.0, brotli-1.0.9, certifi-2022.06.15, mutagen-1.45.1, sqlite3-2.6.0, websockets-10.3
[Cookies] Extracting cookies from vivaldi
[debug] Extracting cookies from: "/Users/andreasbeer/Library/Application Support/Vivaldi/Default/Cookies"
[debug] using find-generic-password to obtain password from OSX keychain
Traceback (most recent call last):
  File "/usr/local/bin/yt-dlp", line 33, in <module>
    sys.exit(load_entry_point('yt-dlp==2022.9.1', 'console_scripts', 'yt-dlp')())
  File "/usr/local/Cellar/yt-dlp/2022.9.1/libexec/lib/python3.10/site-packages/yt_dlp/__init__.py", line 962, in main
    _exit(*variadic(_real_main(argv)))
  File "/usr/local/Cellar/yt-dlp/2022.9.1/libexec/lib/python3.10/site-packages/yt_dlp/__init__.py", line 924, in _real_main
    with YoutubeDL(ydl_opts) as ydl:
  File "/usr/local/Cellar/yt-dlp/2022.9.1/libexec/lib/python3.10/site-packages/yt_dlp/YoutubeDL.py", line 681, in __init__
    self.print_debug_header()
  File "/usr/local/Cellar/yt-dlp/2022.9.1/libexec/lib/python3.10/site-packages/yt_dlp/YoutubeDL.py", line 3734, in print_debug_header
    self._setup_opener()
  File "/usr/local/Cellar/yt-dlp/2022.9.1/libexec/lib/python3.10/site-packages/yt_dlp/YoutubeDL.py", line 3763, in _setup_opener
    self.cookiejar = load_cookies(opts_cookiefile, opts_cookiesfrombrowser, self)
  File "/usr/local/Cellar/yt-dlp/2022.9.1/libexec/lib/python3.10/site-packages/yt_dlp/cookies.py", line 97, in load_cookies
    extract_cookies_from_browser(browser_name, profile, YDLLogger(ydl), keyring=keyring, container=container))
  File "/usr/local/Cellar/yt-dlp/2022.9.1/libexec/lib/python3.10/site-packages/yt_dlp/cookies.py", line 118, in extract_cookies_from_browser
    return _extract_chrome_cookies(browser_name, profile, keyring, logger)
  File "/usr/local/Cellar/yt-dlp/2022.9.1/libexec/lib/python3.10/site-packages/yt_dlp/cookies.py", line 291, in _extract_chrome_cookies
    cursor.execute(f'SELECT host_key, name, value, encrypted_value, path, expires_utc, {secure_column} FROM cookies')
sqlite3.OperationalError: no such table: cookies

Issue Analytics

  • State:closed
  • Created a year ago
  • Comments:9 (6 by maintainers)

github_iconTop GitHub Comments

1reaction
mbwaycommented, Sep 19, 2022

I think catching this case is still a good thing, and giving some output that hints at what the problem is

I don’t think there is much else we can report in that case though. The error already says no such table: cookies. I suppose we could continue the download (without cookies) if any SQL queries fail though?

This should be

Good point.

Should I merge your patch directly?

You can do. I thought it was a bit small to bother with a PR but I can open one if you prefer

0reactions
pukkandancommented, Sep 19, 2022

Should I merge your patch directly?

Read more comments on GitHub >

github_iconTop Results From Across the Web

Manage browser cookies - Vivaldi Help
Cookies are small pieces of data (text files) that a website – when visited by a user – asks your browser to store...
Read more >
Stop Trackers Dead: The Best Private Browsers for 2022
Cookies are small bits of data that websites deposit in your browser's storage to keep track of where you've already logged in and...
Read more >
Browser Compatibility & Cookies - Qualtrics
Because there is only one page of the survey, the survey does not get a chance to drop a session cookie because the...
Read more >
Cookie Policy - Vivaldi Group
If you do not agree to our use of cookies in this way, you should set your browser settings accordingly or not use...
Read more >
The URL bar has vanished from Vivaldi browser - Super User
Move critical data such as Bookmarks, Favicons, Login Data, history, cookies, etc. from Bernice to Default (check the "Back up some Vivaldi ......
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found