<titledata-rh="true">Contributing | Puppeteer</title><metadata-rh="true"name="viewport"content="width=device-width,initial-scale=1"><metadata-rh="true"name="twitter:card"content="summary_large_image"><metadata-rh="true"property="og:url"content="https://pptr.dev/next/contributing"><metadata-rh="true"name="docsearch:language"content="en"><metadata-rh="true"name="docsearch:counter"content="3"><metadata-rh="true"property="og:title"content="Contributing | Puppeteer"><metadata-rh="true"name="description"content="First of all, thank you for your interest in Puppeteer! We'd love to accept your"><metadata-rh="true"property="og:description"content="First of all, thank you for your interest in Puppeteer! We'd love to accept your"><linkdata-rh="true"rel="icon"href="/img/favicon.ico"><linkdata-rh="true"rel="canonical"href="https://pptr.dev/next/contributing"><linkdata-rh="true"rel="alternate"href="https://pptr.dev/next/contributing"hreflang="en"><linkdata-rh="true"rel="alternate"href="https://pptr.dev/next/contributing"hreflang="x-default"><linkdata-rh="true"rel="preconnect"href="https://DVKY664LG7-dsn.algolia.net"crossorigin="anonymous"><linkrel="search"type="application/opensearchdescription+xml"title="Puppeteer"href="/opensearch.xml">
patches and contributions!</p><h2class="anchor anchorWithStickyNavbar_LWe7"id="contributor-license-agreement">Contributor License Agreement<ahref="#contributor-license-agreement"class="hash-link"aria-label="Direct link to Contributor License Agreement"title="Direct link to Contributor License Agreement"></a></h2><p>Contributions to this project must be accompanied by a Contributor License
Agreement. You (or your employer) retain the copyright to your contribution,
this simply gives us permission to use and redistribute your contributions as
part of the project. Head over to <ahref="https://cla.developers.google.com/"target="_blank"rel="noopener noreferrer">https://cla.developers.google.com/</a> to see
your current agreements on file or to sign a new one.</p><p>You generally only need to submit a CLA once, so if you've already submitted one
(even if it was for a different project), you probably don't need to do it
every test run) and then you can run the tests:</p><divclass="language-bash codeBlockContainer_Ckt0 theme-code-block"style="--prism-color:#393A34;--prism-background-color:#f6f8fa"><divclass="codeBlockContent_biex"><pretabindex="0"class="prism-code language-bash codeBlock_bY9V thin-scrollbar"><codeclass="codeBlockLines_e6Vv"><spanclass="token-line"style="color:#393A34"><spanclass="token assign-left variable"style="color:#36acaa">PUPPETEER_EXPERIMENTAL_CHROMIUM_MAC_ARM</span><spanclass="token operator"style="color:#393A34">=</span><spanclass="token number"style="color:#36acaa">1</span><spanclass="token plain"></span><spanclass="token function"style="color:#d73a49">npm</span><spanclass="token plain"></span><spanclass="token function"style="color:#d73a49">install</span><spanclass="token plain"></span><br></span><spanclass="token-line"style="color:#393A34"><spanclass="token plain"></span><spanclass="token assign-left variable"style="color:#36acaa">PUPPETEER_EXPERIMENTAL_CHROMIUM_MAC_ARM</span><spanclass="token operator"style="color:#393A34">=</span><spanclass="token number"style="color:#36acaa">1</span><spanclass="token plain"></span><spanclass="token function"style="color:#d73a49">npm</span><spanclass="token plain"> run </span><spanclass="token builtin class-name">test</span><br></span></code></pre><divclass="buttonGroup__atx"><buttontype="button"aria-label="Copy code to clipboard"title="Copy"class="clean-btn"><spanclass="copyButtonIcons_eSgA"aria-hidden="true"><svgclass="copyButtonIcon_y97N"viewBox="0 0 24 24"><pathd="M19,21H8V7H19M19,5H8A2,2 0 0,0 6,7V21A2,2 0 0,0 8,23H19A2,2 0 0,0 21,21V7A2,2 0 0,0 19,5M16,1H4A2,2 0 0,0 2,3V17H4V3H16V1Z"></path></svg><svgclass="copyButtonSuccessIcon_LjdS"viewBox="0 0 24 24"><pathd="M21,7L9,19L3.5,13.5L4.91,12.09L9,16.17L19.59,5.59L21,7Z"></path></svg></span></button></div></div></div></li><li><p>To run tests with custom browser executable:</p><divclass="language-bash codeBlockContainer_Ckt0 theme-code-block"style="--prism-color:#393A34;--prism-background-color:#f6f8fa"><divclass="codeBlockContent_biex"><pretabindex="0"class="prism-code language-bash codeBlock_bY9V thin-scrollbar"><codeclass="codeBlockLines_e6Vv"><spanclass="token-line"style="color:#393A34"><spanclass="token assign-left variable"style="color:#36acaa">BINARY</span><spanclass="token operator"style="color:#393A34">=</span><spanclass="token operator"style="color:#393A34"><</span><spanclass="token plain">path-to-chrome/firefox-executable</span><spanclass="token operator"style="color:#393A34">></span><spanclass="token plain"></span><spanclass="token function"style="color:#d73a49">npm</span><spanclass="token plain"> run test:chrome </span><spanclass="token comment"style="color:#999988;font-style:italic"># Or npm run test:firefox</span><br></span></code></pre><divclass="buttonGroup__atx"><buttontype="button"aria-label="Copy code to clipboard"title="Copy"class="clean-btn"><spanclass="copyButtonIcons_eSgA"aria-hidden="true"><svgclass="copyButtonIcon_y97N"viewBox="0 0 24 24"><pathd="M19,21H8V7H19M19,5H8A2,2 0 0,0 6,7V21A2,2 0 0,0 8,23H19A2,2 0 0,0 21,21V7A2,2 0 0,0 19,5M16,1H4A2,2 0 0,0 2,3V17H4V3H16V1Z"></path></svg><svgclass="copyButtonSuccessIcon_LjdS"viewBox="0 0 24 24"><pathd="M21,7L9,19L3.5,13.5L4.91,12.09L9,16.17L19.59,5.59L21,7Z"></path></svg></span></button></div></div></div></li></ul><h2class="anchor anchorWithStickyNavbar_LWe7"id="building-a-single-package">Building a single package<ahref="#building-a-single-package"class="hash-link"aria-label="Direct link to Building a single package"title="Direct link to Building a single package"></a></h2><p>To build a single package, you can run:</p><divclass="language-sh codeBlockContainer_Ckt0 theme-code-block"style="--prism-color:#393A34;--prism-background-color:#f6f8fa"><divclass="codeBlockContent_biex"><pretabindex="0"class="prism-code language-sh codeBlock_bY9V thin-scrollbar"><codeclass="codeBlockLines_e6Vv"><spanclass="token-line"style="color:#393A34"><spanclass="tok
<ahref="https://www.gnu.org/software/make/"target="_blank"rel="noopener noreferrer">GNU Make</a>.</p><h3class="anchor anchorWithStickyNavbar_LWe7"id="watch-mode">Watch mode<ahref="#watch-mode"class="hash-link"aria-label="Direct link to Watch mode"title="Direct link to Watch mode"></a></h3><p>To continuously build a package, you can run:</p><divclass="language-sh codeBlockContainer_Ckt0 theme-code-block"style="--prism-color:#393A34;--prism-background-color:#f6f8fa"><divclass="codeBlockContent_biex"><pretabindex="0"class="prism-code language-sh codeBlock_bY9V thin-scrollbar"><codeclass="codeBlockLines_e6Vv"><spanclass="token-line"style="color:#393A34"><spanclass="token plain">npm run build --watch --workspace <package> # e.g. puppeteer</span><br></span></code></pre><divclass="buttonGroup__atx"><buttontype="button"aria-label="Copy code to clipboard"title="Copy"class="clean-btn"><spanclass="copyButtonIcons_eSgA"aria-hidden="true"><svgclass="copyButtonIcon_y97N"viewBox="0 0 24 24"><pathd="M19,21H8V7H19M19,5H8A2,2 0 0,0 6,7V21A2,2 0 0,0 8,23H19A2,2 0 0,0 21,21V7A2,2 0 0,0 19,5M16,1H4A2,2 0 0,0 2,3V17H4V3H16V1Z"></path></svg><svgclass="copyButtonSuccessIcon_LjdS"viewBox="0 0 24 24"><pathd="M21,7L9,19L3.5,13.5L4.91,12.09L9,16.17L19.59,5.59L21,7Z"></path></svg></span></button></div></div></div><p>You have to only specify a single package to watch else things will not work as expected
all dependencies will be build or rebuild (if needed).</p><h2class="anchor anchorWithStickyNavbar_LWe7"id="removing-stale-artifacts">Removing stale artifacts<ahref="#removing-stale-artifacts"class="hash-link"aria-label="Direct link to Removing stale artifacts"title="Direct link to Removing stale artifacts"></a></h2><p>It's possible some generated artifacts (such as
captured by the build system. To clean artifacts, you can run</p><divclass="language-sh codeBlockContainer_Ckt0 theme-code-block"style="--prism-color:#393A34;--prism-background-color:#f6f8fa"><divclass="codeBlockContent_biex"><pretabindex="0"class="prism-code language-sh codeBlock_bY9V thin-scrollbar"><codeclass="codeBlockLines_e6Vv"><spanclass="token-line"style="color:#393A34"><spanclass="token plain">npm run clean # or npm run clean --workspace <package></span><br></span></code></pre><divclass="buttonGroup__atx"><buttontype="button"aria-label="Copy code to clipboard"title="Copy"class="clean-btn"><spanclass="copyButtonIcons_eSgA"aria-hidden="true"><svgclass="copyButtonIcon_y97N"viewBox="0 0 24 24"><pathd="M19,21H8V7H19M19,5H8A2,2 0 0,0 6,7V21A2,2 0 0,0 8,23H19A2,2 0 0,0 21,21V7A2,2 0 0,0 19,5M16,1H4A2,2 0 0,0 2,3V17H4V3H16V1Z"></path></svg><svgclass="copyButtonSuccessIcon_LjdS"viewBox="0 0 24 24"><pathd="M21,7L9,19L3.5,13.5L4.91,12.09L9,16.17L19.59,5.59L21,7Z"></path></svg></span></button></div></div></div><h2class="anchor anchorWithStickyNavbar_LWe7"id="comprehensive-testing">Comprehensive testing<ahref="#comprehensive-testing"class="hash-link"aria-label="Direct link to Comprehensive testing"title="Direct link to Comprehensive testing"></a></h2><p>Outside of <code>npm test</code>, there are several other
<ahref="https://docs.npmjs.com/cli/v8/using-npm/scripts"target="_blank"rel="noopener noreferrer"><code>npm</code> scripts</a> that are
usually check through CI:</p><ul><li><code>test-install</code> - Tests whether <code>puppeteer</code> and <code>puppeteer-core</code> install
properly and are functional.</li><li><code>test-types</code> - Tests the TypeScript types in <code>puppeteer</code> using
<ahref="https://github.com/SamVerschueren/tsd"target="_blank"rel="noopener noreferrer"><code>tsd</code></a>.</li><li><code>test:chrome:**</code> - Tests <code>puppeteer</code> on Chromium.</li><li><code>test:firefox:**</code> - Tests <code>puppeteer</code> on Firefox.</li></ul><p>The default <code>npm test</code> runs <code>test:{chrome,firefox}:headless</code> which is generally
sufficient.</p><p>Puppeteer uses a custom test runner on top of Mocha that consults the
<ahref="https://github.com/puppeteer/puppeteer/tree/main/tools/mochaRunner"target="_blank"rel="noopener noreferrer"><code>tools/mochaRunner</code></a>.</p><h2class="anchor anchorWithStickyNavbar_LWe7"id="code-reviews">Code reviews<ahref="#code-reviews"class="hash-link"aria-label="Direct link to Code reviews"title="Direct link to Code reviews"></a></h2><p>All submissions, including submissions by project members, require review. We
information on using pull requests.</p><h2class="anchor anchorWithStickyNavbar_LWe7"id="code-style">Code Style<ahref="#code-style"class="hash-link"aria-label="Direct link to Code Style"title="Direct link to Code Style"></a></h2><p>Our coding style is fully defined in
manually by running:</p><divclass="language-bash codeBlockContainer_Ckt0 theme-code-block"style="--prism-color:#393A34;--prism-background-color:#f6f8fa"><divclass="codeBlockContent_biex"><pretabindex="0"class="prism-code language-bash codeBlock_bY9V thin-scrollbar"><codeclass="codeBlockLines_e6Vv"><spanclass="token-line"style="color:#393A34"><spanclass="token function"style="color:#d73a49">npm</span><spanclass="token plain"> run lint</span><br></span></code></pre><divclass="buttonGroup__atx"><buttontype="button"aria-label="Copy code to clipboard"title="Copy"class="clean-btn"><spanclass="copyButtonIcons_eSgA"aria-hidden="true"><svgclass="copyButtonIcon_y97N"viewBox="0 0 24 24"><pathd="M19,21H8V7H19M19,5H8A2,2 0 0,0 6,7V21A2,2 0 0,0 8,23H19A2,2 0 0,0 21,21V7A2,2 0 0,0 19,5M16,1H4A2,2 0 0,0 2,3V17H4V3H16V1Z"></path></svg><svgclass="copyButtonSuccessIcon_LjdS"viewBox="0 0 24 24"><pathd="M21,7L9,19L3.5,13.5L4.91,12.09L9,16.17L19.59,5.59L21,7Z"></path></svg></span></button></div></div></div><p>If some errors are returned, you can attempt to fix them using:</p><divclass="language-bash codeBlockContainer_Ckt0 theme-code-block"style="--prism-color:#393A34;--prism-background-color:#f6f8fa"><divclass="codeBlockContent_biex"><pretabindex="0"class="prism-code language-bash codeBlock_bY9V thin-scrollbar"><codeclass="codeBlockLines_e6Vv"><spanclass="token-line"style="color:#393A34"><spanclass="token function"style="color:#d73a49">npm</span><spanclass="token plain"> run </span><spanclass="token function"style="color:#d73a49">format</span><br></span></code></pre><divclass="buttonGroup__atx"><buttontype="button"aria-label="Copy code to clipboard"title="Copy"class="clean-btn"><spanclass="copyButtonIcons_eSgA"aria-hidden="true"><svgclass="copyButtonIcon_y97N"viewBox="0 0 24 24"><pathd="M19,21H8V7H19M19,5H8A2,2 0 0,0 6,7V21A2,2 0 0,0 8,23H19A2,2 0 0,0 21,21V7A2,2 0 0,0 19,5M16,1H4A2,2 0 0,0 2,3V17H4V3H16V1Z"></path></svg><svgclass="copyButtonSuccessIcon_LjdS"viewBox="0 0 24 24"><pathd="M21,7L9,19L3.5,13.5L4.91,12.09L9,16.17L19.59,5.59L21,7Z"></path></svg></span></button></div></div></div><h2class="anchor anchorWithStickyNavbar_LWe7"id="project-structure">Project structure<ahref="#project-structure"class="hash-link"aria-label="Direct link to Project structure"title="Direct link to Project structure"></a></h2><p>The following is a description of the primary folders in Puppeteer:</p><ul><li><code>packages</code> contains all public source code.</li><li><code>test</code> contains all test source code.</li><li><code>test-d</code> contains type tests using
<ahref="https://github.com/SamVerschueren/tsd"target="_blank"rel="noopener noreferrer"><code>tsd</code></a>.</li><li><code>tools</code> contains miscellaneous scripts that are used in building and etc.</li><li><code>tools/mochaRunner</code> - contains the source code for our test runner.</li></ul><h2class="anchor anchorWithStickyNavbar_LWe7"id="api-guidelines">API guidelines<ahref="#api-guidelines"class="hash-link"aria-label="Direct link to API guidelines"title="Direct link to API guidelines"></a></h2><p>When authoring new API methods, consider the following:</p><ul><li>Expose as little information as needed. When in doubt, don’t expose new
information.</li><li>Methods are used in favor of getters/setters.<ul><li>The only exception is namespaces, e.g. <code>page.keyboard</code> and <code>page.coverage</code></li></ul></li><li>All string literals must be small case. This includes event names and option
values.</li><li>Avoid adding "sugar" API (API that is trivially implementable in user-space)
unless they're <strong>extremely</strong> demanded.</li></ul><h2class="anchor anchorWithStickyNavbar_LWe7"id="commit-messages">Commit messages<ahref="#commit-messages"class="hash-link"aria-label="Direct link to Commit messages"title="Direct link to Commit messages"></a></h2><p>Commit messages should follow
the commit message footer. Example:</p><divclass="codeBlockContainer_Ckt0 theme-code-block"style="--prism-color:#393A34;--prism-background-color:#f6f8fa"><divclass="codeBlockContent_biex"><pretabindex="0"class="prism-code language-text codeBlock_bY9V thin-scrollbar"><codeclass="codeBlockLines_e6Vv"><spanclass="token-line"style="color:#393A34"><spanclass="token plain">fix(page): fix page.pizza method</span><br></span><spanclass="token-line"style="color:#393A34"><spanclass="token plain"style="display:inline-block"></span><br></span><spanclass="token-line"style="color:#393A34"><spanclass="token plain">This patch fixes page.pizza so that it works with iframes.</span><br></span><spanclass="token-line"style="color:#393A34"><spanclass="token plain"style="display:inline-block"></span><br></span><spanclass="token-line"style="color:#393A34"><spanclass="token plain">Issues: #123, #234</span><br></span><spanclass="token-line"style="color:#393A34"><spanclass="token plain"style="display:inline-block"></span><br></span><spanclass="token-line"style="color:#393A34"><spanclass="token plain">BREAKING CHANGE: page.pizza now delivers pizza at home by default.</span><br></span><spanclass="token-line"style="color:#393A34"><spanclass="token plain">To deliver to a different location, use the "deliver" option:</span><br></span><spanclass="token-line"style="color:#393A34"><spanclass="token plain"> `page.pizza({deliver: 'work'})`.</span><br></span></code></pre><divclass="buttonGroup__atx"><buttontype="button"aria-label="Copy code to clipboard"title="Copy"class="clean-btn"><spanclass="copyButtonIcons_eSgA"aria-hidden="true"><svgclass="copyButtonIcon_y97N"viewBox="0 0 24 24"><pathd="M19,21H8V7H19M19,5H8A2,2 0 0,0 6,7V21A2,2 0 0,0 8,23H19A2,2 0 0,0 21,21V7A2,2 0 0,0 19,5M16,1H4A2,2 0 0,0 2,3V17H4V3H16V1Z"></path></svg><svgclass="copyButtonSuccessIcon_LjdS"viewBox="0 0 24 24"><pathd="M21,7L9,19L3.5,13.5L4.91,12.09L9,16.17L19.59,5.59L21,7Z"></path></svg></span></button></div></div></div><h2class="anchor anchorWithStickyNavbar_LWe7"id="writing-documentation">Writing documentation<ahref="#writing-documentation"class="hash-link"aria-label="Direct link to Writing documentation"title="Direct link to Writing documentation"></a></h2><p>Documentation is generated via <code>npm run docs</code>. It is automatically published to
our documentation site on merge and gets versioned on release.</p><h2class="anchor anchorWithStickyNavbar_LWe7"id="writing-tsdoc-comments">Writing TSDoc comments<ahref="#writing-tsdoc-comments"class="hash-link"aria-label="Direct link to Writing TSDoc comments"title="Direct link to Writing TSDoc comments"></a></h2><p>Each change to Puppeteer should be thoroughly documented using TSDoc comments.
is highly recommended!</li></ul><h2class="anchor anchorWithStickyNavbar_LWe7"id="running-the-documentation-site-locally">Running the documentation site locally<ahref="#running-the-documentation-site-locally"class="hash-link"aria-label="Direct link to Running the documentation site locally"title="Direct link to Running the documentation site locally"></a></h2><ol><li>At root, install all dependencies with <code>npm i --ignore-scripts</code>.</li><li>run <code>npm run docs</code> which will generate all the <code>.md</code> files on
<code>puppeteer/docs/api</code>.</li><li>run <code>npm i</code> in <code>puppeteer/website</code>.</li><li>run <code>npm start</code> in <code>puppeteer/website</code>.</li></ol><h2class="anchor anchorWithStickyNavbar_LWe7"id="adding-new-dependencies">Adding new dependencies<ahref="#adding-new-dependencies"class="hash-link"aria-label="Direct link to Adding new dependencies"title="Direct link to Adding new dependencies"></a></h2><p>For all dependencies (both installation and development):</p><ul><li><strong>Do not add</strong> a dependency if the desired functionality is easily
implementable.</li><li>If adding a dependency, it should be well-maintained and trustworthy.</li></ul><p>A barrier for introducing new installation dependencies is especially high:</p><ul><li><strong>Do not add</strong> installation dependency unless it's critical to project
success.</li></ul><p>There are additional considerations for dependencies that are environment
for details.</p><h2class="anchor anchorWithStickyNavbar_LWe7"id="testing-tips">Testing tips<ahref="#testing-tips"class="hash-link"aria-label="Direct link to Testing tips"title="Direct link to Testing tips"></a></h2><ul><li>Every feature should be accompanied by a test.</li><li>Every public api event/method should be accompanied by a test.</li><li>Tests should not depend on external services.</li><li>Tests should work on all three platforms: Mac, Linux and Win. This is
<ahref="https://github.com/puppeteer/puppeteer/tree/main/tools/mochaRunner"target="_blank"rel="noopener noreferrer"><code>tools/mochaRunner</code></a>.</p><h2class="anchor anchorWithStickyNavbar_LWe7"id="api-coverage">API Coverage<ahref="#api-coverage"class="hash-link"aria-label="Direct link to API Coverage"title="Direct link to API Coverage"></a></h2><p>Every public API method or event should be called at least once in tests. To
ensure this, the main <code>test</code> command runs coverage during testing.</p><h2class="anchor anchorWithStickyNavbar_LWe7"id="debugging-puppeteer">Debugging Puppeteer<ahref="#debugging-puppeteer"class="hash-link"aria-label="Direct link to Debugging Puppeteer"title="Direct link to Debugging Puppeteer"></a></h2><p>See <ahref="https://pptr.dev/guides/debugging"target="_blank"rel="noopener noreferrer">Debugging Tips</a>.</p><h3class="anchor anchorWithStickyNavbar_LWe7"id="debugging-puppeteer-tests-via-vscode">Debugging Puppeteer tests via VSCode<ahref="#debugging-puppeteer-tests-via-vscode"class="hash-link"aria-label="Direct link to Debugging Puppeteer tests via VSCode"title="Direct link to Debugging Puppeteer tests via VSCode"></a></h3><p>Copy the provided default <code>.vscode/launch.template.json</code> to <code>.vscode/launch.json</code> and then use the integrated VSCode debugger to debug test.</p><p>Remember to build test before launching via:</p><divclass="language-sh codeBlockContainer_Ckt0 theme-code-block"style="--prism-color:#393A34;--prism-background-color:#f6f8fa"><divclass="codeBlockContent_biex"><pretabindex="0"class="prism-code language-sh codeBlock_bY9V thin-scrollbar"><codeclass="codeBlockLines_e6Vv"><spanclass="token-line"style="color:#393A34"><spanclass="token plain">npm run build --workspace @puppeteer-test/test</span><br></span></code></pre><divclass="buttonGroup__atx"><buttontype="button"aria-label="Copy code to clipboard"title="Copy"class="clean-btn"><spanclass="copyButtonIcons_eSgA"aria-hidden="true"><svgclass="copyButtonIcon_y97N"viewBox="0 0 24 24"><pathd="M19,21H8V7H19M19,5H8A2,2 0 0,0 6,7V21A2,2 0 0,0 8,23H19A2,2 0 0,0 21,21V7A2,2 0 0,0 19,5M16,1H4A2,2 0 0,0 2,3V17H4V3H16V1Z"></path></svg><svgclass="copyButtonSuccessIcon_LjdS"viewBox="0 0 24 24"><pathd="M21,7L9,19L3.5,13.5L4.91,12.09L9,16.17L19.59,5.59L21,7Z"></path></svg></span></button></div></div></div><h1>For Project Maintainers</h1><h2class="anchor anchorWithStickyNavbar_LWe7"id="rolling-new-chromium-version">Rolling new Chromium version<ahref="#rolling-new-chromium-version"class="hash-link"aria-label="Direct link to Rolling new Chromium version"title="Direct link to Rolling new Chromium version"></a></h2><p>The following steps are needed to update the Chromium version.</p><ol><li>Find a suitable Chromium revision. Not all revisions have builds for all
platforms, so we need to find one that does. The easiest way is to run
<code>tools/check_availability.js -rd</code> to find the latest suitable <code>dev</code> Chromium
revision (see <code>tools/check_availability.js -help</code> for more options).</li><li>Update <code>packages/puppeteer-core/src/revisions.ts</code> with the found revision
number.</li><li>Update <code>versions.js</code> with the new Chromium-to-Puppeteer version mapping and
update <code>lastMaintainedChromiumVersion</code> with the latest stable Chrome version.
You can find the corresponding version by going to <ahref="https://omahaproxy.appspot.com/"target="_blank"rel="noopener noreferrer">omahaproxy.appspot.com</a> then
searching in <code>Find Releases</code> for <code>r<revision></code>.</li><li>Run <code>npm run check</code>. If it fails, update
with the expected <code>devtools-protocol</code> version and run <code>npm install</code> to generate an updated <code>package-lock.json</code>.</li><li>Run <code>npm run clean</code>, <code>npm run build</code> and <code>npm install</code>.</li><li>Run <code>npm test</code> and ensure that all tests pass. If a test fails,
<code>'feat(chromium): roll to Chromium 90.0.4427.0 (r856583)'</code>.</li></ol><h3class="anchor anchorWithStickyNavbar_LWe7"id="bisecting-upstream-changes">Bisecting upstream changes<ahref="#bisecting-upstream-changes"class="hash-link"aria-label="Direct link to Bisecting upstream changes"title="Direct link to Bisecting upstream changes"></a></h3><p>Sometimes, performing a Chromium roll causes tests to fail. To figure out the
working tree to determine the range to bisect.</p><h2class="anchor anchorWithStickyNavbar_LWe7"id="releasing-to-npm">Releasing to npm<ahref="#releasing-to-npm"class="hash-link"aria-label="Direct link to Releasing to npm"title="Direct link to Releasing to npm"></a></h2><p>We use <ahref="https://github.com/googleapis/release-please"target="_blank"rel="noopener noreferrer">release-please</a> to
our <ahref="https://github.com/puppeteer/puppeteer/pulls"target="_blank"rel="noopener noreferrer">pull requests</a> and merge it.</p><h3class="anchor anchorWithStickyNavbar_LWe7"id="in-case-release-please-fails">In case Release Please fails<ahref="#in-case-release-please-fails"class="hash-link"aria-label="Direct link to In case Release Please fails"title="Direct link to In case Release Please fails"></a></h3><p>In the event release-please fails, the following needs to be done:</p><ol><li><p>Update anything missing in the CHANGELOG of every package that was supposed
to be published. For example, if the header is missing, you may need to add</p><ul><li><p>For puppeteer:</p><divclass="language-md codeBlockContainer_Ckt0 theme-code-block"style="--prism-color:#393A34;--prism-background-color:#f6f8fa"><divclass="codeBlockContent_biex"><pretabindex="0"class="prism-code language-md codeBlock_bY9V thin-scrollbar"><codeclass="codeBlockLines_e6Vv"><spanclass="token-line"style="color:#393A34"><spanclass="token title important punctuation"style="color:#393A34">##</span><spanclass="token title important"> [{NEW_VERSION}](https://github.com/puppeteer/puppeteer/compare/v{PREVIOUS_VERSION}...v{NEW_VERSION}) ({CURRENT_DATE})`</span><br></span></code></pre><divclass="buttonGroup__atx"><buttontype="button"aria-label="Copy code to clipboard"title="Copy"class="clean-btn"><spanclass="copyButtonIcons_eSgA"aria-hidden="true"><svgclass="copyButtonIcon_y97N"viewBox="0 0 24 24"><pathd="M19,21H8V7H19M19,5H8A2,2 0 0,0 6,7V21A2,2 0 0,0 8,23H19A2,2 0 0,0 21,21V7A2,2 0 0,0 19,5M16,1H4A2,2 0 0,0 2,3V17H4V3H16V1Z"></path></svg><svgclass="copyButtonSuccessIcon_LjdS"viewBox="0 0 24 24"><pathd="M21,7L9,19L3.5,13.5L4.91,12.09L9,16.17L19.59,5.59L21,7Z"></path></svg></span></button></div></div></div></li><li><p>For other packages:</p><divclass="language-md codeBlockContainer_Ckt0 theme-code-block"style="--prism-color:#393A34;--prism-background-color:#f6f8fa"><divclass="codeBlockContent_biex"><pretabindex="0"class="prism-code language-md codeBlock_bY9V thin-scrollbar"><codeclass="codeBlockLines_e6Vv"><spanclass="token-line"style="color:#393A34"><spanclass="token title important punctuation"style="color:#393A34">##</span><spanclass="token title important"> [{NEW_VERSION}](https://github.com/puppeteer/puppeteer/compare/{PACKAGE_FOLDER_NAME}-v{PREVIOUS_VERSION}...{PACKAGE_FOLDER_NAME}-v{NEW_VERSION}) ({CURRENT_DATE})</span><br></span></code></pre><divclass="buttonGroup__atx"><buttontype="button"aria-label="Copy code to clipboard"title="Copy"class="clean-btn"><spanclass="copyButtonIcons_eSgA"aria-hidden="true"><svgclass="copyButtonIcon_y97N"viewBox="0 0 24 24"><pathd="M19,21H8V7H19M19,5H8A2,2 0 0,0 6,7V21A2,2 0 0,0 8,23H19A2,2 0 0,0 21,21V7A2,2 0 0,0 19,5M16,1H4A2,2 0 0,0 2,3V17H4V3H16V1Z"></path></svg><svgclass="copyButtonSuccessIcon_LjdS"viewBox="0 0 24 24"><pathd="M21,7L9,19L3.5,13.5L4.91,12.09L9,16.17L19.59,5.59L21,7Z"></path></svg></span></button></div></div></div></li></ul></li><li><p>Create a GitHub release for each package, following the practice of previous
releases.</p></li></ol><h2class="anchor anchorWithStickyNavbar_LWe7"id="bug-triage-guidelines">Bug triage guidelines<ahref="#bug-triage-guidelines"class="hash-link"aria-label="Direct link to Bug triage guidelines"title="Direct link to Bug triage guidelines"></a></h2><p><ahref="https://github.com/puppeteer/puppeteer/issues"target="_blank"rel="noopener noreferrer">Check incoming bug reports</a> that do not have a <code>confirmed</code> or <code>needs-feedback</code> label:</p><ol><li>Make sure the issue is labeled as either <code>bug</code> or <code>feature</code>.</li><li>If the issue does not have a clear repro or you cannot repro, ask for the repro and set the <code>needs-feedback</code> label.</li><li>Follow-up on the issues you previously asked for a feedback on (you should get a notification on GitHub when the user responds).</li><li>If the user does not provide feedback, the issue will be closed by the stale bot eventually.</li><li>If you are able to reproduce the issue, add the label <code>confirmed</code>.</li><li>If the bug is on the Chromium side, create a corresponding crbug.com issue, label the GitHub issue with the <code>upstream</code> label, and post a link to crbug.com in the comments.</li><li>If the issue is not related to either Puppeteer or Chromium, close the issue.</li><li>If the issue is about missing/incorrect documentation, label it as <code>documentation</code>.</li></ol><p>Issues with PDFs:</p><ol><li>If the issue reproduces using the regular print dialog and/or headful, <ahref="https://bugs.chromium.org/p/chromium/issues/entry?components=Blink%3ELayout"target="_blank"rel="noopener noreferrer">file a crbug.com against the <code>Blink>Layout</code> component</a>.</li><li>If the issue is specific to Headless mode, <ahref="https://bugs.chromium.org/p/chromium/issues/entry?components=Internals%3EHeadless"target="_blank"rel="noopener noreferrer">file an issue on crbug.com against the <code>Internals>Headless</code> component</a>.</li></ol></div></article><navclass="pagination-nav docusaurus-mt-lg"aria-label="Docs pages navigation"><aclass="pagination-nav__link pagination-nav__link--prev"href="/next/troubleshooting"><divclass="pagination-nav__sublabel">Previous</div><divclass="pagination-nav__label">Troubleshooting</div></a><aclass="pagination-nav__link pagination-nav__link--next"href="/next/faq"><divclass="pagination-nav__sublabel">Next</div><divclass="pagination-nav__label">FAQ</div></a></nav></div></div><divclass="col col--3"><divclass="tableOfContents_bqdL thin-scrollbar theme-doc-toc-desktop"><ulclass="table-of-contents table-of-contents__left-border"><li><ahref="#contributor-license-agreement"class="table-of-contents__link toc-highlight">Contributor License Agreement</a></li><li><ahref="#getting-started"class="table-of-contents__link toc-highlight">Getting started</a><ul><li><ahref="#macos-arm-and-custom-executables"class="table-of-contents__link toc-highlight">macOS ARM and custom executables.</a></li></ul></li><li><ahref="#building-a-single-package"class="table-of-contents__link toc-highlight">Building a single package</a><ul><li><ahref="#watch-mode"class="table-of-contents__link toc-highlight">Watch mode</a></li></ul></li><li><ahref="#removing-stale-artifacts"class="table-of-contents__link toc-highlight">Removing stale artifacts</a></li><li><ahref="#comprehensive-testing"class="table-of-contents__link toc-highlight">Comprehensive testing</a></li><li><ahref="#code-reviews"class="table-of-contents__link toc-highlight">Code reviews</a></li><li><ahref="#code-style"class="table-of-contents__link toc-highlight">Code Style</a></li><li><ahref="#project-structure"class="table-of-contents__link toc-highlight">Project structure</a></li><li><ahref="#api-guidelines"class="table-of-contents__link toc-highlight">API guidelines</a></li><li><ahref="#commit-messages"class="table-of-contents__link toc-highlight">Commit messages</a></li><li><ahref="#writing-documentation"class="table-of-contents__link toc-highlight">Writing documentation</a></li><li>