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

Merge dev into main #905

Merged
merged 49 commits into from
Oct 16, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
49 commits
Select commit Hold shift + click to select a range
5f9c01c
Bump chart.js from 4.4.1 to 4.4.2 (#840)
dependabot[bot] Mar 4, 2024
0db5f30
Bump moment from 2.29.4 to 2.30.1 (#819)
dependabot[bot] Mar 4, 2024
0313291
Bump webpack from 5.90.2 to 5.90.3 (#837)
dependabot[bot] Mar 4, 2024
3a1f39b
Bump actions/checkout from 4.1.1 to 4.1.2 (#843)
dependabot[bot] Mar 18, 2024
060fa11
Bump superstruct from 1.0.3 to 1.0.4 (#844)
dependabot[bot] Mar 22, 2024
af0d6d9
Bump webpack from 5.90.3 to 5.91.0 (#846)
dependabot[bot] Mar 25, 2024
7a1e98e
Bump actions/checkout from 4.1.2 to 4.1.3 (#851)
dependabot[bot] Apr 22, 2024
9e4d434
Bump actions/checkout from 4.1.3 to 4.1.4 (#853)
dependabot[bot] May 6, 2024
fa870bf
Bump actions/checkout from 4.1.4 to 4.1.5 (#858)
dependabot[bot] May 13, 2024
4c1b276
Bump actions/checkout from 4.1.5 to 4.1.6 (#862)
dependabot[bot] May 20, 2024
7d6e72a
Bump chart.js from 4.4.2 to 4.4.3 (#860)
dependabot[bot] May 20, 2024
323ceeb
Bump cloudflare/wrangler-action from 3.3.2 to 3.6.1 (#863)
dependabot[bot] May 27, 2024
73f2971
Bump wrangler from 3.19.0 to 3.60.0 (#866)
dependabot[bot] Jun 10, 2024
7953e0e
Bump actions/checkout from 4.1.6 to 4.1.7 (#869)
dependabot[bot] Jun 17, 2024
52b9578
Bump webpack from 5.91.0 to 5.92.0 (#867)
dependabot[bot] Jun 17, 2024
b95e91e
Bump wrangler from 3.60.0 to 3.60.3 (#868)
dependabot[bot] Jun 17, 2024
2ef0892
Bump toucan-js from 3.3.1 to 3.4.0 (#855)
dependabot[bot] Jun 21, 2024
6689cbf
Bump webpack from 5.92.0 to 5.92.1 (#870)
dependabot[bot] Jun 24, 2024
82a065a
Bump wrangler from 3.60.3 to 3.61.0 (#871)
dependabot[bot] Jun 24, 2024
7904552
Bump wrangler from 3.61.0 to 3.62.0 (#872)
dependabot[bot] Jul 1, 2024
aa12981
Bump cloudflare/wrangler-action from 3.6.1 to 3.7.0 (#873)
dependabot[bot] Jul 8, 2024
12c370d
Bump wrangler from 3.62.0 to 3.63.1 (#875)
dependabot[bot] Jul 8, 2024
5d9ba3d
Bump toucan-js from 3.4.0 to 4.0.0 (#876)
dependabot[bot] Jul 9, 2024
d6fd8ab
Bump superstruct from 1.0.4 to 2.0.2 (#874)
dependabot[bot] Jul 9, 2024
32bfacd
Bump webpack from 5.92.1 to 5.93.0 (#877)
dependabot[bot] Jul 15, 2024
de505f4
Bump actions/setup-node from 4.0.2 to 4.0.3 (#879)
dependabot[bot] Jul 15, 2024
d212751
Bump wrangler from 3.63.1 to 3.64.0 (#878)
dependabot[bot] Jul 15, 2024
4ad63ee
Bump wrangler from 3.64.0 to 3.65.1 (#880)
dependabot[bot] Jul 22, 2024
58457a2
Bump wrangler from 3.65.1 to 3.67.1 (#881)
dependabot[bot] Jul 29, 2024
22d0cc1
Bump svgmap from 2.10.1 to 2.11.1 (#882)
dependabot[bot] Aug 5, 2024
059b5d6
Bump wrangler from 3.67.1 to 3.68.0 (#883)
dependabot[bot] Aug 5, 2024
05e7ec0
Bump wrangler from 3.68.0 to 3.70.0 (#884)
dependabot[bot] Aug 12, 2024
d5aa054
Bump wrangler from 3.70.0 to 3.72.0 (#885)
dependabot[bot] Aug 22, 2024
d951cae
Bump webpack from 5.93.0 to 5.94.0 (#887)
dependabot[bot] Aug 26, 2024
2b1ca7f
Bump wrangler from 3.72.0 to 3.75.0 (#890)
dependabot[bot] Sep 10, 2024
188ce38
Bump chart.js from 4.4.3 to 4.4.4 (#886)
dependabot[bot] Sep 12, 2024
7402069
Bump wrangler from 3.75.0 to 3.78.2 (#891)
dependabot[bot] Sep 16, 2024
f7cbaaa
Bump actions/setup-node from 4.0.3 to 4.0.4 (#892)
dependabot[bot] Sep 23, 2024
e25ef02
Bump wrangler from 3.78.2 to 3.78.7 (#893)
dependabot[bot] Sep 23, 2024
9bfcceb
Bump actions/checkout from 4.1.7 to 4.2.0 (#894)
dependabot[bot] Sep 30, 2024
71788b4
Bump webpack from 5.94.0 to 5.95.0 (#895)
dependabot[bot] Sep 30, 2024
089af80
Bump wrangler from 3.78.7 to 3.78.12 (#896)
dependabot[bot] Sep 30, 2024
3f00496
Bump cloudflare/wrangler-action from 3.7.0 to 3.8.0 (#897)
dependabot[bot] Oct 7, 2024
6ab89b7
Bump wrangler from 3.78.12 to 3.80.0 (#898)
dependabot[bot] Oct 7, 2024
8c7b7e6
Bump @11ty/eleventy from 2.0.1 to 3.0.0 (#899)
dependabot[bot] Oct 7, 2024
e6fd84f
Bump actions/checkout from 4.2.0 to 4.2.1 (#901)
dependabot[bot] Oct 14, 2024
66a1486
Bump wrangler from 3.80.0 to 3.80.4 (#903)
dependabot[bot] Oct 14, 2024
2dab981
Bump cloudflare/wrangler-action from 3.8.0 to 3.9.0 (#902)
dependabot[bot] Oct 14, 2024
7497339
Allow longer versions (#904)
ludeeus Oct 15, 2024
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
14 changes: 7 additions & 7 deletions .github/workflows/test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,9 @@ jobs:
- local-dev
- production
steps:
- uses: actions/checkout@v4.1.1
- uses: actions/checkout@v4.2.1

- uses: actions/[email protected].2
- uses: actions/[email protected].4
with:
node-version-file: '.nvmrc'

Expand All @@ -31,7 +31,7 @@ jobs:
run: script/bootstrap

- name: Build ${{ matrix.environment }} worker
uses: cloudflare/wrangler-action@v3.3.2
uses: cloudflare/wrangler-action@v3.9.0
with:
workingDirectory: "worker"
packageManager: yarn
Expand All @@ -42,9 +42,9 @@ jobs:
runs-on: ubuntu-latest
name: Build site
steps:
- uses: actions/checkout@v4.1.1
- uses: actions/checkout@v4.2.1

- uses: actions/[email protected].2
- uses: actions/[email protected].4
with:
node-version-file: '.nvmrc'

Expand All @@ -58,9 +58,9 @@ jobs:
runs-on: ubuntu-latest
name: Test worker
steps:
- uses: actions/checkout@v4.1.1
- uses: actions/checkout@v4.2.1

- uses: actions/[email protected].2
- uses: actions/[email protected].4
with:
node-version-file: '.nvmrc'

Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/worker.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,9 @@ jobs:
runs-on: ubuntu-latest
name: Publish
steps:
- uses: actions/checkout@v4.1.1
- uses: actions/checkout@v4.2.1

- uses: actions/[email protected].2
- uses: actions/[email protected].4
with:
node-version-file: '.nvmrc'

Expand All @@ -36,7 +36,7 @@ jobs:
echo "environment=${environment}" >> "$GITHUB_OUTPUT"

- name: Publish ${{ steps.environment.outputs.environment }} worker
uses: cloudflare/wrangler-action@v3.3.2
uses: cloudflare/wrangler-action@v3.9.0
with:
apiToken: ${{ secrets.CF_WORKER_API_TOKEN }}
workingDirectory: "worker"
Expand Down
16 changes: 8 additions & 8 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,26 +1,26 @@
{
"dependencies": {
"chart.js": "^4.4.1",
"chart.js": "^4.4.4",
"chartjs-adapter-date-fns": "^2.0.1",
"svg-pan-zoom": "^3.6.1",
"svgmap": "^2.10.1",
"superstruct": "1.0.3",
"toucan-js": "^3.3.1"
"svgmap": "^2.11.1",
"superstruct": "2.0.2",
"toucan-js": "^4.0.0"
},
"devDependencies": {
"@11ty/eleventy": "^2.0.1",
"@11ty/eleventy": "^3.0.0",
"@cloudflare/workers-types": "^3.17.0",
"@types/jest": "^27.5.0",
"@types/node": "^18.15.10",
"jest": "^26.6.3",
"memoize-one": "^6.0.0",
"moment": "^2.29.4",
"moment": "^2.30.1",
"ts-jest": "^26.5.6",
"ts-loader": "^9.5.1",
"typescript": "^4.9.5",
"webpack": "^5.90.2",
"webpack": "^5.95.0",
"webpack-cli": "^5.1.4",
"wrangler": "^3.19.0"
"wrangler": "^3.80.4"
},
"jest": {
"transform": {
Expand Down
2 changes: 1 addition & 1 deletion worker/src/utils/validate.ts
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ export const IncomingPayloadStruct = object({
certificate: optional(boolean()),
user_count: optional(number()),
uuid: size(string(), 32, 32),
version: size(string(), 7, 22),
version: size(string(), 7, 25),
});

export const createIncomingPayload = (data: unknown): IncomingPayload => {
Expand Down
26 changes: 25 additions & 1 deletion worker/tests/utils/validate.spec.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
import { string } from "superstruct";
import { createIncomingPayload } from "../../src/utils/validate";

describe("createIncomingPayload", function () {
Expand Down Expand Up @@ -112,4 +111,29 @@ describe("createIncomingPayload", function () {
});
expect(payload.addons![0].auto_update).toBe(false);
});

it("Valid versions", function () {
for (const version of [
"YYYY.MM.P",
"YYYY.MM.P.devYYYYMMDDHHMM",
"YYYY.M.P.devYYYYMMDDHHMM",
]) {
const payload = createIncomingPayload({ ...BASE_PAYLOAD, version });
expect(payload.version).toBe(version);
}
});

it("Invalid versions", function () {
for (const version of [
"9999.9",
"YYYY.MM.P.devYYYYMMDDHHMMX",
"9999.99.9.dev9999999999999",
]) {
expect(() => {
createIncomingPayload({ ...BASE_PAYLOAD, version });
}).toThrow(
`At path: version -- Expected a string with a length between \`7\` and \`25\` but received one with a length of \`${version.length}\``
);
}
});
});
Loading