Skip to content
Open
Show file tree
Hide file tree
Changes from 15 commits
Commits
Show all changes
40 commits
Select commit Hold shift + click to select a range
2bdcaf4
feat: migrate web app frontend to Astro and update GAE routing to ser…
max-ostapenko Jun 28, 2026
d0702b1
refactor: remove Python/Jinja2 server and templates in favor of a Nod…
max-ostapenko Jun 28, 2026
f0e7cad
feat: update UI headers, improve pagination links, and refine timesta…
max-ostapenko Jun 28, 2026
f5c20a4
docs: add comprehensive HTTP Archive documentation and guides structure
max-ostapenko Jun 28, 2026
e37a0d6
feat: implement versioned filename helper and replace Starlight heade…
max-ostapenko Jun 28, 2026
4cb8ff9
style: override documentation header layout with custom height and pa…
max-ostapenko Jun 28, 2026
a53b588
refactor: implement comprehensive style system and optimize FAQ initi…
max-ostapenko Jun 28, 2026
0d91e60
chore: reorganize project dependencies and devDependencies in package…
max-ostapenko Jun 28, 2026
ac31257
fix: remove redundant normalize.css source comment from bootstrap.min…
max-ostapenko Jun 28, 2026
fa43e0d
fix: resolve font preload duplicate downloads and CSP violations
max-ostapenko Jun 28, 2026
2ba80b6
feat: add dynamic page timestamp management to Base layout using last…
max-ostapenko Jun 28, 2026
6daf7d6
fix: refactor website test script and workflows to support fully Node…
max-ostapenko Jun 28, 2026
30488f5
Potential fix for pull request finding 'CodeQL / Client-side cross-si…
max-ostapenko Jun 28, 2026
a3be0c6
Potential fix for pull request finding 'CodeQL / Log injection'
max-ostapenko Jun 28, 2026
b61b456
Potential fix for pull request finding 'CodeQL / Unused variable, imp…
max-ostapenko Jun 28, 2026
ae6d7bb
feat: add data analysis workbooks and refactor documentation and inde…
max-ostapenko Jun 28, 2026
d9cfa65
chore: update documentation content hashes in last_updated.json
max-ostapenko Jun 28, 2026
01f4aa4
chore: update project documentation
max-ostapenko Jun 28, 2026
8180e57
chore: upgrade local linter configuration
max-ostapenko Jun 28, 2026
f9c3dc5
refactor: remove legacy static CSS files, update deployment config, a…
max-ostapenko Jun 28, 2026
ce8acb9
refactor: migrate Highcharts to module-based initialization via highc…
max-ostapenko Jun 28, 2026
ee2b5a8
refactor: inline summary component styles into SummaryCard.astro and …
max-ostapenko Jun 28, 2026
5b3492c
refactor: migrate all static assets to the public directory for Astro…
max-ostapenko Jun 28, 2026
67444a5
Merge branch 'main' into visiting-snail
max-ostapenko Jun 28, 2026
d28629c
refactor: remove font module imports and update icon SVG symbols
max-ostapenko Jun 28, 2026
36cfd76
Merge branch 'visiting-snail' of https://github.com/HTTPArchive/httpa…
max-ostapenko Jun 28, 2026
de493ae
refactor: remove Python dependencies and modernize build configuratio…
max-ostapenko Jun 29, 2026
d433d71
refactor: migrate deployment and testing scripts from Python to Node.…
max-ostapenko Jun 29, 2026
0296cc6
chore: remove unused .htmlhintrc_morechecks configuration file
max-ostapenko Jun 29, 2026
f0f263d
Merge branch 'main' into visiting-snail
max-ostapenko Jun 29, 2026
ed38d9b
feat: revert .htmlhintrc_morechecks configuration
max-ostapenko Jun 29, 2026
25e2994
refactor: update test workflow to keep server running and exclude nod…
max-ostapenko Jun 29, 2026
9886803
fix: disable valid-source-maps in lighthouse, add tech report filter …
max-ostapenko Jun 29, 2026
a7c1580
feat: enable build sourcemaps via environment variable and re-enable …
max-ostapenko Jun 29, 2026
b604418
fix: improve security and update server configuration
max-ostapenko Jun 30, 2026
986d842
unnecessary escape
max-ostapenko Jun 30, 2026
8fcddb5
Merge branch 'main' into visiting-snail
max-ostapenko Jul 2, 2026
e9f960a
refactor: replace object with Map for latestMetricDates and latestMet…
max-ostapenko Jul 2, 2026
8b0c110
fix: enhance path normalization and sanitization to prevent directory…
max-ostapenko Jul 2, 2026
122d5cc
refactor: centralize API base URL constants and remove deprecated loc…
max-ostapenko Jul 2, 2026
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
15 changes: 1 addition & 14 deletions .github/workflows/code-static-analysis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ on:
branches: [main]
paths:
- '**.js'
- '**.py'
schedule:
# ┌───────────── minute (0 - 59)
# │ ┌───────────── hour (0 - 23)
Expand All @@ -29,22 +28,10 @@ jobs:
runs-on: ubuntu-latest
strategy:
matrix:
language: ['javascript', 'python']
language: ['javascript']
steps:
- name: Checkout repository
uses: actions/checkout@v6
- name: Set up Python 3.12
if: ${{ matrix.language == 'python' }}
uses: actions/setup-python@v6
with:
python-version: '3.12'
- name: Install dependencies
if: ${{ matrix.language == 'python' }}
run: |
pip install -r requirements.txt;
# Set the `CODEQL-PYTHON` environment variable to the Python executable
# that includes the dependencies
echo "CODEQL_PYTHON=$(which python)" >> $GITHUB_ENV
- name: Initialize CodeQL
uses: github/codeql-action/init@v4
with:
Expand Down
8 changes: 1 addition & 7 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -37,15 +37,9 @@ jobs:
- name: Install Python dependencies
run: pip install -r requirements.txt

- name: Build static assets
- name: Build website
run: npm run build

- name: Update timestamps
run: npm run timestamps

- name: Generate scripts
run: npm run generate

- name: Authenticate to Google Cloud
uses: google-github-actions/auth@v3
with:
Expand Down
6 changes: 0 additions & 6 deletions .github/workflows/predeploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,14 +25,8 @@ jobs:
uses: actions/setup-node@v6
with:
node-version: '24'
- name: Set up Python 3.14
uses: actions/setup-python@v6
with:
python-version: '3.14'
- name: Run the website
run: ./tools/scripts/run_and_test_website.sh
- name: Update timestamps
run: npm run timestamps
- name: Create Pull Request
id: cpr
uses: peter-evans/create-pull-request@v8
Expand Down
4 changes: 0 additions & 4 deletions .github/workflows/test-website.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,10 +24,6 @@ jobs:
uses: actions/setup-node@v6
with:
node-version: '24'
- name: Set up Python 3.14
uses: actions/setup-python@v6
with:
python-version: '3.14'
- name: Run the website
run: ./tools/scripts/run_and_test_website.sh
- name: Remove node modules to avoid linting errors
Expand Down
4 changes: 4 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -11,3 +11,7 @@ templates/sitemap.xml
.coverage
.idx/dev.nix
.coverage.*
.pytest_cache
__pycache__
.astro/
/dist
124 changes: 80 additions & 44 deletions app.yaml
Original file line number Diff line number Diff line change
@@ -1,48 +1,84 @@
runtime: python312
entrypoint: gunicorn -b :$PORT main:app
runtime: nodejs24
entrypoint: node server.js
default_expiration: 3h

handlers:

# Add longer caching for fonts
- url: /static/fonts/(.*\.(woff|woff2))$
static_files: static/fonts/\1
upload: static/fonts/.*\.(woff|woff2)$
secure: always
expiration: 365d
http_headers:
strict-transport-security: max-age=31556926; includeSubDomains
x-content-type-options: nosniff
vary: Accept-Encoding

# Set the UTF-8 charset for CSS and JS files.
# Makes the assumption that only CSS and JS files existing in the relevant dirs
# but avoids complex regexes
- url: /static/css
static_dir: static/css
secure: always
http_headers:
content-type: text/css; charset=utf-8
strict-transport-security: max-age=31556926; includeSubDomains
x-content-type-options: nosniff
vary: Accept-Encoding
- url: /static/js
static_dir: static/js
secure: always
http_headers:
content-type: application/javascript; charset=utf-8
strict-transport-security: max-age=31556926; includeSubDomains
x-content-type-options: nosniff
vary: Accept-Encoding

- url: /static
static_dir: static
secure: always
http_headers:
strict-transport-security: max-age=31556926; includeSubDomains
x-content-type-options: nosniff
vary: Accept-Encoding

- url: /.*
script: auto
secure: always
# Python API endpoints — must be routed to gunicorn before static handlers
- url: /metric.json
script: auto
secure: always

- url: /api/.*
script: auto
secure: always

- url: /.well-known/(.*)
static_files: static/well-known/\1
upload: static/well-known/.*
secure: always

# Add longer caching for fonts
- url: /static/fonts/(.*\.(woff|woff2))$
static_files: static/fonts/\1
upload: static/fonts/.*\.(woff|woff2)$
secure: always
expiration: 365d
http_headers:
strict-transport-security: max-age=31556926; includeSubDomains
x-content-type-options: nosniff
vary: Accept-Encoding

# Set the UTF-8 charset for CSS and JS files.
- url: /static/css
static_dir: static/css
secure: always
http_headers:
content-type: text/css; charset=utf-8
strict-transport-security: max-age=31556926; includeSubDomains
x-content-type-options: nosniff
vary: Accept-Encoding
- url: /static/js
static_dir: static/js
secure: always
http_headers:
content-type: application/javascript; charset=utf-8
strict-transport-security: max-age=31556926; includeSubDomains
x-content-type-options: nosniff
vary: Accept-Encoding

- url: /static
static_dir: static
secure: always
http_headers:
strict-transport-security: max-age=31556926; includeSubDomains
x-content-type-options: nosniff
vary: Accept-Encoding

# Serve Astro-built HTML pages as static files from dist/
# Index page
- url: /$
static_files: dist/index.html
upload: dist/index.html
secure: always
expiration: 1h
http_headers:
strict-transport-security: max-age=31556926; includeSubDomains
x-content-type-options: nosniff
content-security-policy: "default-src 'self' https:; script-src 'self' https: 'unsafe-inline'; style-src 'self' https: 'unsafe-inline'; img-src 'self' https: data:; font-src 'self' https: data:; connect-src 'self' https:; frame-ancestors 'none'"

# Astro pages — serve /path as dist/path/index.html
- url: /(.+)
static_files: dist/\1/index.html
upload: dist/.*/index\.html
secure: always
expiration: 1h
http_headers:
strict-transport-security: max-age=31556926; includeSubDomains
x-content-type-options: nosniff
content-security-policy: "default-src 'self' https:; script-src 'self' https: 'unsafe-inline'; style-src 'self' https: 'unsafe-inline'; img-src 'self' https: data:; font-src 'self' https: data:; connect-src 'self' https:; frame-ancestors 'none'"

# Fallback: all remaining routes to Python (legacy redirects, 404s, robots.txt, .well-known)
- url: /.*
script: auto
secure: always
66 changes: 66 additions & 0 deletions astro.config.mjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,66 @@
import { defineConfig } from 'astro/config';
import starlight from '@astrojs/starlight';
import starlightLinksValidator from 'starlight-links-validator';

Check notice

Code scanning / CodeQL

Unused variable, import, function or class Note

Unused import starlightLinksValidator.
Comment thread
github-advanced-security[bot] marked this conversation as resolved.
Fixed
import starlightLlmsTxt from 'starlight-llms-txt';

export default defineConfig({
output: 'static',
outDir: 'dist',
// Static assets pass-through from /static directory
publicDir: 'static',
// Base URL
site: 'https://httparchive.org',
build: {
// Don't add trailing slashes to output filenames
format: 'directory',
},
integrations: [
starlight({
title: 'HTTP Archive Docs',
components: {
Header: './src/components/docs/Header.astro',
},
sidebar: [
{
label: 'Guides',
items: [
{ label: 'Getting started', link: 'docs/guides/getting-started' },
{ label: 'Minimizing query costs', link: 'docs/guides/minimizing-costs' },
{ label: 'Guided tour', link: 'docs/guides/guided-tour' },
{ label: 'Release cycle', link: 'docs/guides/release-cycle' },
],
},
{
label: 'Tables',
items: [{ autogenerate: { directory: 'docs/reference/tables' } }]
},
{
label: 'Structs',
items: [{ autogenerate: { directory: 'docs/reference/structs' } }]
},
{
label: 'Blobs',
items: [{ autogenerate: { directory: 'docs/reference/blobs' } }]
},
{
label: 'Custom Metrics',
items: [{ autogenerate: { directory: 'docs/reference/custom-metrics' } }]
},
{
label: 'Functions',
items: [{ autogenerate: { directory: 'docs/reference/functions' } }]
},
],
plugins: [starlightLlmsTxt()],
}),
],
vite: {
server: {
proxy: {
'/api': 'http://127.0.0.1:8080',
'/metric.json': 'http://127.0.0.1:8080',
'/.well-known': 'http://127.0.0.1:8080',
},
},
},
});
Loading
Loading