Commit Graph

29 Commits

Author SHA1 Message Date
Matt Isenhower
7cfe3775fe Remove unused variable in util test
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-16 15:51:53 -08:00
Matt Isenhower
6fba6f3076 Remove stale jsonpath tests from util.test.mjs
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-15 16:55:28 -08:00
Matt Isenhower
6e4b57f6a7 Add unit tests for fs utilities and ValueCache
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-15 16:45:20 -08:00
Matt Isenhower
7257c26869 Add unit tests for app/common/util
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-15 16:45:20 -08:00
Matt Isenhower
8b11900905 Revert jsonpath-plus back to jsonpath
jsonpath v1.2.1 (published Feb 2025) fixed the security vulnerability
that prompted the switch to jsonpath-plus. Reverting to the original
package simplifies the code by removing the jsonpathQuery/jsonpathApply
wrapper functions.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-15 15:56:05 -08:00
misenhower
f92267d0bf Fix styling 2026-02-15 22:04:22 +00:00
Matt Isenhower
7adb9c313e Add mkdirp utility to avoid verbose fs.mkdir calls
Added mkdirp() helper to app/common/fs.mjs that wraps
fs.mkdir(dir, { recursive: true }). Updated all call sites to use it.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-15 11:09:02 -08:00
Matt Isenhower
8780463c66 Replace deprecated and unmaintained packages
- Removed mkdirp in favor of native fs.mkdir({ recursive: true })
- Replaced ecstatic (unmaintained since 2021) with sirv
- Replaced jsonpath (security vulnerability) with jsonpath-plus
  - Added jsonpathQuery/jsonpathApply helpers in app/common/util.mjs
- Updated sharp: 0.32.6 → 0.34.5
- Updated puppeteer-core: 23.8.0 → 24.37.3

Vulnerabilities reduced from 40 to 1 (only remaining: axios in
threads-api transitive dependency).

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-15 11:05:49 -08:00
Matt Isenhower
f45a4654d1 Extract shared cache expiry calculation to utility function
Deduplicate identical _calculateCacheExpiry methods from
SplatNet3Client and NsoClient into a shared calculateCacheExpiry
function in util.mjs.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-31 20:04:23 -08:00
Matt Isenhower
37ee0c4dc9 Prefer single quotes and enforce semicolons 2024-03-17 10:20:17 -07:00
Matt Isenhower
c6091d822e Fix import errors 2024-03-17 10:12:13 -07:00
Matt Isenhower
3e2c31eaa7 Remove v-html 2024-03-16 22:41:13 -07:00
Matt Isenhower
38dd66b207 Fix <br /> in challenge posts 2023-11-23 08:31:11 -08:00
Matt Isenhower
9894ec30b1 Add Sentry 2023-08-03 08:52:01 -07:00
Matt Isenhower
e4e6051999 Run linter 2023-06-25 20:59:43 -07:00
Matt Isenhower
ba54d94e09 Make data archives more accessible, and store only one file per hour 2023-05-23 17:48:30 -07:00
Matt Isenhower
142f2a82c5 Fix a bug with outdated festival data 2023-04-22 14:27:55 -07:00
Matt Isenhower
46fdbbe8c7 Clean up the way we detect whether an update is needed 2023-04-22 14:05:59 -07:00
Matt Isenhower
cda854de0b Add a utility function to check whether a file exists 2023-04-22 13:33:04 -07:00
Matt Isenhower
2c1a77e63a Improve readability for X-Rank season IDs 2023-02-12 09:22:36 -08:00
Matt Isenhower
9719317a53 Consolidate festival ID parsing functions 2023-02-11 14:25:52 -08:00
Matt Isenhower
f689f13d9c Tweak derived ID logic to ensure consistency
This now strips out the domain and query string from the URL before hashing it. This way, we can help ensure the hashes will stay the same when those parameters change.
2022-10-20 16:16:46 -07:00
Matt Isenhower
133ed8ce56 Use shorter derived ID values 2022-10-17 20:55:20 -07:00
Matt Isenhower
47d0abb747 Retrieve localized strings from SplatNet 2022-10-17 20:32:38 -07:00
Matt Isenhower
212f05c88c Add gear icon to regular gear tweet 2022-10-04 16:26:41 -07:00
Matt Isenhower
668da0c1a9 Move "last tweet" tracking to the tweet generator 2022-09-20 20:32:51 -07:00
Matt Isenhower
231681bdac Improve logging 2022-09-10 12:56:21 -07:00
Matt Isenhower
314d61ecb4 Move cache files to their own directory 2022-09-09 14:55:30 -07:00
Matt Isenhower
9bd16d2e41 Add nxapi-powered NSO client 2022-09-09 14:41:39 -07:00