-
Notifications
You must be signed in to change notification settings - Fork 758
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
chore: update wrangler versions in templates #7742
Conversation
🦋 Changeset detectedLatest commit: 8836e90 The changes in this PR will be included in the next version bump. This PR includes changesets to release 1 package
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
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/12736662831/npm-package-wrangler-7742 You can reference the automatically updated head of this PR with: npm install --save-dev https://prerelease-registry.devprod.cloudflare.dev/workers-sdk/prs/7742/npm-package-wrangler-7742 Or you can use npx https://prerelease-registry.devprod.cloudflare.dev/workers-sdk/runs/12736662831/npm-package-wrangler-7742 dev path/to/script.js Additional artifacts:cloudflare-workers-bindings-extension: wget https://prerelease-registry.devprod.cloudflare.dev/workers-sdk/runs/12736662831/npm-package-cloudflare-workers-bindings-extension-7742 -O ./cloudflare-workers-bindings-extension.0.0.0-v83a103592.vsix && code --install-extension ./cloudflare-workers-bindings-extension.0.0.0-v83a103592.vsix create-cloudflare: npx https://prerelease-registry.devprod.cloudflare.dev/workers-sdk/runs/12736662831/npm-package-create-cloudflare-7742 --no-auto-update @cloudflare/kv-asset-handler: npm install https://prerelease-registry.devprod.cloudflare.dev/workers-sdk/runs/12736662831/npm-package-cloudflare-kv-asset-handler-7742 miniflare: npm install https://prerelease-registry.devprod.cloudflare.dev/workers-sdk/runs/12736662831/npm-package-miniflare-7742 @cloudflare/pages-shared: npm install https://prerelease-registry.devprod.cloudflare.dev/workers-sdk/runs/12736662831/npm-package-cloudflare-pages-shared-7742 @cloudflare/unenv-preset: npm install https://prerelease-registry.devprod.cloudflare.dev/workers-sdk/runs/12736662831/npm-package-cloudflare-unenv-preset-7742 @cloudflare/vitest-pool-workers: npm install https://prerelease-registry.devprod.cloudflare.dev/workers-sdk/runs/12736662831/npm-package-cloudflare-vitest-pool-workers-7742 @cloudflare/workers-editor-shared: npm install https://prerelease-registry.devprod.cloudflare.dev/workers-sdk/runs/12736662831/npm-package-cloudflare-workers-editor-shared-7742 @cloudflare/workers-shared: npm install https://prerelease-registry.devprod.cloudflare.dev/workers-sdk/runs/12736662831/npm-package-cloudflare-workers-shared-7742 @cloudflare/workflows-shared: npm install https://prerelease-registry.devprod.cloudflare.dev/workers-sdk/runs/12736662831/npm-package-cloudflare-workflows-shared-7742 Note that these links will no longer work once the GitHub Actions artifact expires.
Please ensure constraints are pinned, and |
d2c8281
to
8836e90
Compare
@@ -14,7 +14,7 @@ import { DurableObject } from "cloudflare:workers"; | |||
*/ | |||
|
|||
/** A Durable Object's behavior is defined in an exported Javascript class */ | |||
export class MyDurableObject extends DurableObject { | |||
export class MyDurableObject extends DurableObject<Env> { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
also added this fix here
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this correct? In workers-types DurableObject
has no type param.
Hmm... interestingly the @cloudflare/workers-types
library has two files of note: index.ts and index.d.ts.
The latter contains export abstract class DurableObject<Env = unknown>
while the former does not.
But in my setup it appears that VS Code is picking up the index.ts
and so erroring if I provide a type param.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Doh! I see now. This is imported from the cloudflare:workers
module, which is what brings in this class.
@@ -8,6 +8,6 @@ | |||
"start": "wrangler dev" | |||
}, | |||
"devDependencies": { | |||
"wrangler": "^3.60.3" | |||
"wrangler": "^3.101.0" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just to be clear, for my sake, I believe that updating these has no practical effect, since the ^
will cause the most recent Wrangler v3 minor version to be installed anyway. Right?
The only reason to worry about updating these would be if there was a new feature in a minor that the template relied upon.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Considering it more of a cleanliness thing really. Looks bad if our own official templates don't point to the latest version. Ideally this would be automated.
@@ -14,7 +14,7 @@ import { DurableObject } from "cloudflare:workers"; | |||
*/ | |||
|
|||
/** A Durable Object's behavior is defined in an exported Javascript class */ | |||
export class MyDurableObject extends DurableObject { | |||
export class MyDurableObject extends DurableObject<Env> { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this correct? In workers-types DurableObject
has no type param.
Hmm... interestingly the @cloudflare/workers-types
library has two files of note: index.ts and index.d.ts.
The latter contains export abstract class DurableObject<Env = unknown>
while the former does not.
But in my setup it appears that VS Code is picking up the index.ts
and so erroring if I provide a type param.
@@ -14,7 +14,7 @@ import { DurableObject } from "cloudflare:workers"; | |||
*/ | |||
|
|||
/** A Durable Object's behavior is defined in an exported Javascript class */ | |||
export class MyDurableObject extends DurableObject { | |||
export class MyDurableObject extends DurableObject<Env> { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Doh! I see now. This is imported from the cloudflare:workers
module, which is what brings in this class.
We should probably automate this, but doing it manually for now since it's so behind.
Fixes #0000