Skip to content
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

Fix the worker-speedtest template (#5830) #5840

Merged
merged 2 commits into from
Jul 3, 2024

Conversation

nielsreijers
Copy link
Contributor

The code had been converted to typescript in 026d944, but packages.json and several other places still refered to .js files.

In addition a refactoring of the test code meant tests for both /up and /down urls were now being sent to the handler for /up, causing the tests to fail. I removed some of the test in up.test.ts since they were testing different values of the ?bytes= parameter, but this parameter is only used in down.ts, not in up.ts.

What this PR solves / how to test

Fixes #5830.

Author has addressed the following

  • Tests
    • TODO (before merge)
    • Included
    • Not necessary because:
  • E2E Tests CI Job required? (Use "e2e" label or ask maintainer to run separately)
    • I don't know
    • Required / Maybe required
    • Not required because:
  • Changeset (Changeset guidelines)
    • TODO (before merge)
    • Included
    • Not necessary because: small change to an example template, not touching main production code
  • Public documentation

The code had been converted to typescript in 026d944, but packages.json and several other places still refered to .js files.

In addition a refactoring of the test code meant tests for both /up and /down urls were now being sent to the handler for /up, causing the tests to fail. I removed some of the test in up.test.ts since they were testing different values of the ?bytes= parameter, but this parameter is only used in down.ts, not in up.ts.
@nielsreijers nielsreijers requested a review from a team as a code owner May 15, 2024 14:56
Copy link

changeset-bot bot commented May 15, 2024

⚠️ No Changeset found

Latest commit: 780c7d2

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@nielsreijers nielsreijers changed the title Fix the worked-speedtest template (#5830) Fix the worker-speedtest template (#5830) May 15, 2024
Copy link
Contributor

A wrangler prerelease is available for testing. You can install this latest build in your project with:

npm install --save-dev https://prerelease-registry.devprod.cloudflare.dev/workers-sdk/runs/9711551332/npm-package-wrangler-5840

You can reference the automatically updated head of this PR with:

npm install --save-dev https://prerelease-registry.devprod.cloudflare.dev/workers-sdk/prs/5840/npm-package-wrangler-5840

Or you can use npx with this latest build directly:

npx https://prerelease-registry.devprod.cloudflare.dev/workers-sdk/runs/9711551332/npm-package-wrangler-5840 dev path/to/script.js
Additional artifacts:
npx https://prerelease-registry.devprod.cloudflare.dev/workers-sdk/runs/9711551332/npm-package-create-cloudflare-5840 --no-auto-update
npm install https://prerelease-registry.devprod.cloudflare.dev/workers-sdk/runs/9711551332/npm-package-cloudflare-kv-asset-handler-5840
npm install https://prerelease-registry.devprod.cloudflare.dev/workers-sdk/runs/9711551332/npm-package-miniflare-5840
npm install https://prerelease-registry.devprod.cloudflare.dev/workers-sdk/runs/9711551332/npm-package-cloudflare-pages-shared-5840
npm install https://prerelease-registry.devprod.cloudflare.dev/workers-sdk/runs/9711551332/npm-package-cloudflare-vitest-pool-workers-5840

Note that these links will no longer work once the GitHub Actions artifact expires.


wrangler@3.62.0 includes the following runtime dependencies:

Package Constraint Resolved
miniflare workspace:* 3.20240620.0
workerd 1.20240620.1 1.20240620.1
workerd --version 1.20240620.1 2024-06-20

Please ensure constraints are pinned, and miniflare/workerd minor versions match.

@nielsreijers
Copy link
Contributor Author

Thanks for the approve @petebacondarwin !
Any idea what's causing the failed test? It doesn't seem related to my change, does it?

@penalosa penalosa merged commit 062e414 into cloudflare:main Jul 3, 2024
19 checks passed
@workers-devprod workers-devprod added the contribution [Holopin] Recognizes an open-source contribution, big or small label Jul 3, 2024
Copy link

holopin-bot bot commented Jul 3, 2024

Congratulations @nielsreijers, the maintainer of this repository has issued you a holobyte! Here it is: https://holopin.io/holobyte/cly5yd30w78580cl9zn7yhoh2

This badge can only be claimed by you, so make sure that your GitHub account is linked to your Holopin account. You can manage those preferences here: https://holopin.io/account.
Or if you're new to Holopin, you can simply sign up with GitHub, which will do the trick!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
contribution [Holopin] Recognizes an open-source contribution, big or small
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

🐛 BUG: worker-speedtest template can't be deployed
5 participants