Skip to content

Add Chrome Devtools Protocol modules #5381

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 4 commits into from
Jul 3, 2023

Conversation

bastimeyer
Copy link
Member

@bastimeyer bastimeyer commented Jun 15, 2023

Part 1/4 of #5380

CDP documentation here:
https://chromedevtools.github.io/devtools-protocol/

Generator script borrowed from:
https://github.com/HyperionGray/python-chrome-devtools-protocol


This

  1. Adds the unmodified script file with added license info
  2. Fixes linting issues
  3. Adds features, fixes bugs and fixes style of generated code
  4. Adds the following CDP domains:
    fetch, runtime, input, and dom, as well as all their dependent domains and the mandatory target and inspector domains.
    Anything else is not worth adding in my opinion. As you can see, this already adds 17k lines of code...

Opening as a draft until I have the remaining stuff ready.

@bastimeyer
Copy link
Member Author

Rebased to current head of master, because this PR is the base branch for other PRs until it got merged into master.

@bastimeyer bastimeyer marked this pull request as ready for review July 3, 2023 15:26
- Add inflection to dev-requirements
- Add argparser
- Add package output path
- Add version selection
- Add domain selection
- Fetch protocol JSON files from gh:ChromeDevTools/devtools-protocol
- Fetch latest version from NPMJS if unset (latest tag by date)
- Include util.py
- Clean up headers and imports of generated modules
- Re-order clean+write logic in output path
- Remove docs/sphinx related stuff
- Remove deprecation notes
- Remove custom protocol patches/hacks
- Fix generated code style
- Fix domain self-references
- Fix command param order
domain selection: fetch runtime input dom
@bastimeyer
Copy link
Member Author

Rebased to master, no other changes. Going to merge now, so I can rebase the dependent PRs...

@bastimeyer bastimeyer merged commit 81d2ff2 into streamlink:master Jul 3, 2023
@bastimeyer bastimeyer deleted the generate-cdp branch July 3, 2023 15:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant