Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ import { fetchNodeRuntimeVersions } from '../../shared/runtime-versions.ts';
const playwrightVersions = await fetchPackageVersions('playwright');
const apifyVersions = await fetchPackageVersions('apify');
const crawleeVersions = await fetchPackageVersions('crawlee');
const camoufoxVersions = await fetchPackageVersions('camoufox-js');
const camoufoxVersions = await fetchPackageVersions('camoufox');
const nodeRuntimeVersions = await fetchNodeRuntimeVersions(supportedNodeVersions);

if (!shouldUseLastFive) {
Expand Down Expand Up @@ -46,7 +46,7 @@ console.error('Latest apify version', latestApifyVersion);
console.error('Latest crawlee version', latestCrawleeVersion);
console.error('Latest camoufox version', latestCamoufoxVersion);
console.error(
`Playwright versions for camoufox (camoufox-js@${latestCamoufoxVersion} supports ${camoufoxPlaywrightRange ?? 'nothing we could resolve'})`,
`Playwright versions for camoufox (camoufox@${latestCamoufoxVersion} supports ${camoufoxPlaywrightRange ?? 'nothing we could resolve'})`,
camoufoxPlaywrightVersions.length ? camoufoxPlaywrightVersions : '(none, camoufox images will be skipped)',
);
console.error('Node runtime versions', nodeRuntimeVersions);
Expand Down
8 changes: 4 additions & 4 deletions .github/actions/version-matrix/src/shared/camoufox.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,10 +16,10 @@ describe('resolveCamoufoxPlaywrightVersions', () => {
assert.deepEqual(versions, ['1.56.0', '1.59.0', '1.60.0']);
});

it('reads the supported range from the camoufox-js package on npm', async () => {
const { range, versions } = await resolveCamoufoxPlaywrightVersions('node', '0.12.0', playwrightVersions);
it('reads the supported range from the camoufox package on npm', async () => {
const { range, versions } = await resolveCamoufoxPlaywrightVersions('node', '0.5.8', playwrightVersions);

// camoufox-js declares the range as a `playwright-core` peer dependency. What it declares is up to camoufox and
// camoufox declares the range as a `playwright-core` peer dependency. What it declares is up to camoufox and
// is expected to change, so this asserts that we read a range and apply it - not what the range happens to be.
assert.notEqual(range, undefined);
assert.deepEqual(
Expand Down Expand Up @@ -49,7 +49,7 @@ describe('fetchPackageManifest', () => {
});

it('reads the declared peer dependency ranges of a published version', async () => {
const manifest = await fetchPackageManifest('camoufox-js', '0.12.0');
const manifest = await fetchPackageManifest('camoufox', '0.5.8');

assert.equal(typeof manifest.peerDependencies?.['playwright-core'], 'string');
});
Expand Down
4 changes: 2 additions & 2 deletions .github/actions/version-matrix/src/shared/camoufox.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import { fetchPackageVersion, findRequirementSpecifierSet, pythonSpecifierSetToS
* That range is not pinned here. It is read from the camoufox package metadata instead, so that the images follow
* whatever camoufox currently supports:
*
* - `camoufox-js` declares it as a `playwright-core` peer dependency
* - `camoufox` (npm) declares it as a `playwright-core` peer dependency
* - `camoufox` (PyPI) declares it as a `playwright` requirement
*
* Note that the images install camoufox with a caret / compatible-release range, so the version actually installed
Expand All @@ -18,7 +18,7 @@ import { fetchPackageVersion, findRequirementSpecifierSet, pythonSpecifierSetToS
*/
const camoufoxPackages = {
node: {
packageName: 'camoufox-js',
packageName: 'camoufox',
// `playwright` and `playwright-core` are released in lockstep under the same version numbers, so the range
// declared for `playwright-core` applies as-is to the `playwright` version installed in the image
dependencyName: 'playwright-core',
Expand Down
2 changes: 1 addition & 1 deletion .github/scripts/set-dependency-versions.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ const DEPENDENCY_VERSIONS = {
'playwright-chromium': process.env.PLAYWRIGHT_VERSION,
'playwright-firefox': process.env.PLAYWRIGHT_VERSION,
'playwright-webkit': process.env.PLAYWRIGHT_VERSION,
'camoufox-js': process.env.CAMOUFOX_VERSION,
'camoufox': process.env.CAMOUFOX_VERSION,
};

for (const path of PACKAGE_JSON_PATHS) {
Expand Down
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
NODE_VERSION ?= 22
# Tag must have format: v1.42.0-
PLAYWRIGHT_VERSION ?= v1.57.0-
CAMOUFOX_VERSION ?= 0.12.0
CAMOUFOX_VERSION ?= 0.5.8
# Tag must have format: 22.6.2
PUPPETEER_VERSION ?= 24.34.0
# Set SLIM=1 to build the -slim variant of a node image (uses package.slim.json)
Expand Down
2 changes: 1 addition & 1 deletion node-playwright-camoufox/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
ARG NODE_VERSION=

# Use trixie to be consistent across node versions.
FROM node:${NODE_VERSION}-trixie-slim

Check warning on line 5 in node-playwright-camoufox/Dockerfile

View workflow job for this annotation

GitHub Actions / img: node-playwright-camoufox node: 24, apify: ^3.7.2, crawlee: ^3.18.2, pw: 1.62.1, cf: ^0.5.8, is-latest: true

Default value for global ARG results in an empty or invalid base image name

InvalidDefaultArgInFrom: Default value for ARG node:${NODE_VERSION}-trixie-slim results in empty or invalid base image name More info: https://docs.docker.com/go/dockerfile/rule/invalid-default-arg-in-from/

Check warning on line 5 in node-playwright-camoufox/Dockerfile

View workflow job for this annotation

GitHub Actions / img: node-playwright-camoufox node: 24, apify: ^3.7.2, crawlee: ^3.18.2, pw: 1.62.1, cf: ^0.5.8, is-latest: true

Default value for global ARG results in an empty or invalid base image name

InvalidDefaultArgInFrom: Default value for ARG node:${NODE_VERSION}-trixie-slim results in empty or invalid base image name More info: https://docs.docker.com/go/dockerfile/rule/invalid-default-arg-in-from/

Check warning on line 5 in node-playwright-camoufox/Dockerfile

View workflow job for this annotation

GitHub Actions / img: node-playwright-camoufox node: 22, apify: ^3.7.2, crawlee: ^3.18.2, pw: 1.62.1, cf: ^0.5.8, is-latest: true

Default value for global ARG results in an empty or invalid base image name

InvalidDefaultArgInFrom: Default value for ARG node:${NODE_VERSION}-trixie-slim results in empty or invalid base image name More info: https://docs.docker.com/go/dockerfile/rule/invalid-default-arg-in-from/

Check warning on line 5 in node-playwright-camoufox/Dockerfile

View workflow job for this annotation

GitHub Actions / img: node-playwright-camoufox node: 22, apify: ^3.7.2, crawlee: ^3.18.2, pw: 1.62.1, cf: ^0.5.8, is-latest: true

Default value for global ARG results in an empty or invalid base image name

InvalidDefaultArgInFrom: Default value for ARG node:${NODE_VERSION}-trixie-slim results in empty or invalid base image name More info: https://docs.docker.com/go/dockerfile/rule/invalid-default-arg-in-from/

Check warning on line 5 in node-playwright-camoufox/Dockerfile

View workflow job for this annotation

GitHub Actions / img: node-playwright-camoufox node: 26, apify: ^3.7.2, crawlee: ^3.18.2, pw: 1.62.1, cf: ^0.5.8, is-latest: true

Default value for global ARG results in an empty or invalid base image name

InvalidDefaultArgInFrom: Default value for ARG node:${NODE_VERSION}-trixie-slim results in empty or invalid base image name More info: https://docs.docker.com/go/dockerfile/rule/invalid-default-arg-in-from/

Check warning on line 5 in node-playwright-camoufox/Dockerfile

View workflow job for this annotation

GitHub Actions / img: node-playwright-camoufox node: 26, apify: ^3.7.2, crawlee: ^3.18.2, pw: 1.62.1, cf: ^0.5.8, is-latest: true

Default value for global ARG results in an empty or invalid base image name

InvalidDefaultArgInFrom: Default value for ARG node:${NODE_VERSION}-trixie-slim results in empty or invalid base image name More info: https://docs.docker.com/go/dockerfile/rule/invalid-default-arg-in-from/

Check warning on line 5 in node-playwright-camoufox/Dockerfile

View workflow job for this annotation

GitHub Actions / img: node-playwright-camoufox node: 24, apify: ^3.7.2, crawlee: ^3.18.2, pw: 1.61.1, cf: ^0.5.8, is-latest: false

Default value for global ARG results in an empty or invalid base image name

InvalidDefaultArgInFrom: Default value for ARG node:${NODE_VERSION}-trixie-slim results in empty or invalid base image name More info: https://docs.docker.com/go/dockerfile/rule/invalid-default-arg-in-from/

Check warning on line 5 in node-playwright-camoufox/Dockerfile

View workflow job for this annotation

GitHub Actions / img: node-playwright-camoufox node: 24, apify: ^3.7.2, crawlee: ^3.18.2, pw: 1.61.1, cf: ^0.5.8, is-latest: false

Default value for global ARG results in an empty or invalid base image name

InvalidDefaultArgInFrom: Default value for ARG node:${NODE_VERSION}-trixie-slim results in empty or invalid base image name More info: https://docs.docker.com/go/dockerfile/rule/invalid-default-arg-in-from/

Check warning on line 5 in node-playwright-camoufox/Dockerfile

View workflow job for this annotation

GitHub Actions / img: node-playwright-camoufox node: 24, apify: ^3.7.2, crawlee: ^3.18.2, pw: 1.61.1, cf: ^0.5.8, is-latest: false

Default value for global ARG results in an empty or invalid base image name

InvalidDefaultArgInFrom: Default value for ARG node:${NODE_VERSION}-trixie-slim results in empty or invalid base image name More info: https://docs.docker.com/go/dockerfile/rule/invalid-default-arg-in-from/

Check warning on line 5 in node-playwright-camoufox/Dockerfile

View workflow job for this annotation

GitHub Actions / img: node-playwright-camoufox node: 24, apify: ^3.7.2, crawlee: ^3.18.2, pw: 1.61.1, cf: ^0.5.8, is-latest: false

Default value for global ARG results in an empty or invalid base image name

InvalidDefaultArgInFrom: Default value for ARG node:${NODE_VERSION}-trixie-slim results in empty or invalid base image name More info: https://docs.docker.com/go/dockerfile/rule/invalid-default-arg-in-from/

Check warning on line 5 in node-playwright-camoufox/Dockerfile

View workflow job for this annotation

GitHub Actions / img: node-playwright-camoufox node: 24, apify: ^3.7.2, crawlee: ^3.18.2, pw: 1.62.0, cf: ^0.5.8, is-latest: false

Default value for global ARG results in an empty or invalid base image name

InvalidDefaultArgInFrom: Default value for ARG node:${NODE_VERSION}-trixie-slim results in empty or invalid base image name More info: https://docs.docker.com/go/dockerfile/rule/invalid-default-arg-in-from/

Check warning on line 5 in node-playwright-camoufox/Dockerfile

View workflow job for this annotation

GitHub Actions / img: node-playwright-camoufox node: 24, apify: ^3.7.2, crawlee: ^3.18.2, pw: 1.62.0, cf: ^0.5.8, is-latest: false

Default value for global ARG results in an empty or invalid base image name

InvalidDefaultArgInFrom: Default value for ARG node:${NODE_VERSION}-trixie-slim results in empty or invalid base image name More info: https://docs.docker.com/go/dockerfile/rule/invalid-default-arg-in-from/

Check warning on line 5 in node-playwright-camoufox/Dockerfile

View workflow job for this annotation

GitHub Actions / img: node-playwright-camoufox node: 24, apify: ^3.7.2, crawlee: ^3.18.2, pw: 1.62.0, cf: ^0.5.8, is-latest: false

Default value for global ARG results in an empty or invalid base image name

InvalidDefaultArgInFrom: Default value for ARG node:${NODE_VERSION}-trixie-slim results in empty or invalid base image name More info: https://docs.docker.com/go/dockerfile/rule/invalid-default-arg-in-from/

Check warning on line 5 in node-playwright-camoufox/Dockerfile

View workflow job for this annotation

GitHub Actions / img: node-playwright-camoufox node: 24, apify: ^3.7.2, crawlee: ^3.18.2, pw: 1.62.0, cf: ^0.5.8, is-latest: false

Default value for global ARG results in an empty or invalid base image name

InvalidDefaultArgInFrom: Default value for ARG node:${NODE_VERSION}-trixie-slim results in empty or invalid base image name More info: https://docs.docker.com/go/dockerfile/rule/invalid-default-arg-in-from/

# Playwright version is passed in the format `v1.57.0-` (matching the tag
# format used by the full node-playwright image). Stripped below before
Expand Down Expand Up @@ -138,7 +138,7 @@
RUN npm --quiet set progress=false \
\
# Install Camoufox browser
&& PLAYWRIGHT_SKIP_BROWSER_DOWNLOAD=0 npx camoufox-js fetch \
&& npx camoufox fetch \
# Resolve both flat and versioned Camoufox cache layouts.
&& CAMOUFOX_BINARY="$(find /home/myuser/.cache/camoufox -type f -name camoufox-bin)" \
&& test -x "$CAMOUFOX_BINARY" \
Expand Down
2 changes: 1 addition & 1 deletion node-playwright-camoufox/firefox_test.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
const playwright = require('playwright');
const { launchOptions: camoufoxLaunchOptions } = require('camoufox-js');
const { launchOptions: camoufoxLaunchOptions } = require('camoufox');

const testPageLoading = async (browser) => {
const page = await browser.newPage();
Expand Down
2 changes: 1 addition & 1 deletion node-playwright-camoufox/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
},
"dependencies": {
"apify": "APIFY_VERSION",
"camoufox-js": "CAMOUFOX_VERSION",
"camoufox": "CAMOUFOX_VERSION",
"crawlee": "CRAWLEE_VERSION",
"impit": "latest",
"playwright": "PLAYWRIGHT_VERSION",
Expand Down
2 changes: 1 addition & 1 deletion node-playwright-camoufox/package.slim.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
"start": "node main.js"
},
"dependencies": {
"camoufox-js": "CAMOUFOX_VERSION",
"camoufox": "CAMOUFOX_VERSION",
"impit": "latest",
"playwright": "PLAYWRIGHT_VERSION"
},
Expand Down
Loading