Skip to content
Merged
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
5 changes: 5 additions & 0 deletions .changeset/puny-coins-dream.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"wrangler": patch
---

switch zone route warning to an info message
29 changes: 13 additions & 16 deletions packages/wrangler/src/__tests__/deploy.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1419,24 +1419,22 @@ describe("deploy", () => {
});
await runWrangler("deploy ./index");

expect(std.info).toMatchInlineSnapshot(`
"The current authentication token does not have 'All Zones' permissions.
Falling back to using the zone-based API endpoint to update each route individually.
Note that there is no access to routes associated with zones that the API token does not have permission for.
Existing routes for this Worker in such zones will not be deleted."
`);
expect(std.err).toMatchInlineSnapshot(`""`);
expect(std.warn).toMatchInlineSnapshot(`
"▲ [WARNING] The current authentication token does not have 'All Zones' permissions.

Falling back to using the zone-based API endpoint to update each route individually.
Note that there is no access to routes associated with zones that the API token does not have
permission for.
Existing routes for this Worker in such zones will not be deleted.


▲ [WARNING] Previously deployed routes:
"▲ [WARNING] Previously deployed routes:

The following routes were already associated with this worker, and have not been deleted:
- \\"foo.example.com/other-route\\"
If these routes are not wanted then you can remove them in the dashboard.
The following routes were already associated with this worker, and have not been deleted:
- \\"foo.example.com/other-route\\"
If these routes are not wanted then you can remove them in the dashboard.

"
`);
"
`);
expect(std.out).toMatchInlineSnapshot(`
"Total Upload: xx KiB / gzip: xx KiB
Worker Startup Time: 100 ms
Expand Down Expand Up @@ -5250,7 +5248,6 @@ addEventListener('fetch', event => {});`
["Q29udGVudCBvZiBmaWxlLTM="],
"ff5016e92f039aa743a4ff7abb3180fa",
{
// TODO: this should be "text/plain; charset=utf-8", but msw? is stripping the charset part
type: "text/plain",
}
)
Expand Down Expand Up @@ -14037,7 +14034,7 @@ expect.extend({
};
}

if (!equals(received.type, expected.type)) {
if (!equals(received.type, expect.stringMatching(expected.type))) {
return {
pass: false,
message: () =>
Expand Down
2 changes: 1 addition & 1 deletion packages/wrangler/src/deploy/deploy.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1068,7 +1068,7 @@ async function publishRoutesFallback(
{ telemetryMessage: true }
);
}
logger.warn(
logger.info(
"The current authentication token does not have 'All Zones' permissions.\n" +
"Falling back to using the zone-based API endpoint to update each route individually.\n" +
"Note that there is no access to routes associated with zones that the API token does not have permission for.\n" +
Expand Down
Loading