Split the large resolve() method into smaller, focused methods:
- extractFragment(): handles URL fragment extraction
- hasDynamoDbConfigured(): checks DynamoDB availability
- tryDynamoDbLookup(): handles DynamoDB lookup with error handling
- fallbackToGoogleShortener(): handles Google API fallback
Added comprehensive unit tests for the utility methods covering various URL formats and edge cases.
🤖 Generated with [Claude Code](https://claude.ai/code)
Co-Authored-By: Claude <noreply@anthropic.com>
- Add Prometheus counters for successful DynamoDB hits and misses
- Log warnings when links are not found in DynamoDB (expected to be comprehensive)
- Track fallback usage to Google URL shortener for monitoring purposes
These metrics will help identify missing data in DynamoDB and monitor
the transition from Google URL shortener to our own storage.
🤖 Generated with [Claude Code](https://claude.ai/code)
Co-Authored-By: Claude <noreply@anthropic.com>
- Replace SQLite database with DynamoDB for Google link resolution
- Add awsProps to ServerDependencies and pass through component hierarchy
- Configure googleLinksDynamoTable property in AWS config files
- Maintain backwards compatibility with fallback to Google service
- Update tests to accommodate new awsProps parameter
This change prepares for the retirement of goo.gl by storing link
mappings in DynamoDB instead of SQLite, while keeping the Google
service fallback until August 2025.
🤖 Generated with [Claude Code](https://claude.ai/code)
Co-Authored-By: Claude <noreply@anthropic.com>
The test was expecting 'Missing location url in null' but the implementation
now returns 'Missing location url' after the recent improvement to error messages.
- Update ShortLinkResolver to accept optional SQLite database path
- First check database for fragment lookup before falling back to Google
- Return 404 if expanded_url is 'NULL' in database
- Refactor resolve method to use async/await instead of raw promises
- Add googleShortLinkSqlitePath configuration property support
🤖 Generated with [Claude Code](https://claude.ai/code)
Co-Authored-By: Claude <noreply@anthropic.com>
## Summary
Fix production CDN loading issues where URLs like
`https://static.ce-cdn.net//vendor.v57...css` (double slash) were being
generated when the `staticUrl` config has a trailing slash.
## Root Cause
PR #7681 refactored static asset handling and replaced
`urljoin(staticRoot, path)` with `${staticRoot}/${path}` string
interpolation, losing URL normalization that `urljoin` provides.
## Changes
- Replace string interpolation with `urljoin()` in
`createDefaultPugRequireHandler()`
- Add comprehensive tests covering all trailing slash scenarios
- Maintain full backward compatibility with existing configurations
## Test plan
- [x] All existing tests pass
- [x] Added 4 new test cases for static URL handling with various slash
scenarios
- [x] Verified TypeScript compilation and linting
- [x] Tested production CDN scenario where
`staticUrl=https://static.ce-cdn.net/`
🤖 Generated with [Claude Code](https://claude.ai/code)
Co-authored-by: Claude <noreply@anthropic.com>
Add nvc 25.5 to etc/config/c.amazon.properties
Add nvc++ 25.5 to etc/config/c++.amazon.properties
Add nvfortran 25.5 to etc/config/fortran.amazon.properties
Add CUDA 12.9 to etc/config/cuda.amazon.properties
Follow up to
https://github.com/compiler-explorer/compiler-explorer/pull/7540.
Fixes#7528
Last time I tried this, the 14.2.0 GCC builds were still using 2.38 for
Arm and AArch64, now there are 15.1.0 builds and those both use 2.44.
Which I have confirmed locally:
$
/opt/compiler-explorer/arm64/gcc-15.1.0/aarch64-unknown-linux-gnu/bin/aarch64-unknown-linux-gnu-as
--version
GNU assembler (GNU Binutils) 2.44
$
/opt/compiler-explorer/arm/gcc-15.1.0/arm-unknown-linux-gnueabihf/bin/arm-unknown-linux-gnueabihf-as
--version
GNU assembler (GNU Binutils) 2.44
While I'm here, I added 2.38 to Arm since it was missing. From the GCC
13.2.0 build:
$
/opt/compiler-explorer/arm/gcc-13.2.0/arm-unknown-linux-gnueabihf/bin/arm-unknown-linux-gnueabihf-as
--version
GNU assembler (GNU Binutils) 2.38
This PR adds support for the Mojo programming language.
Explicitly tested viewing the generated assembly, LLVM IR, and running
the generated executable.
## Summary
This PR significantly improves maintainability by breaking up the 880+ line monolithic app.ts file into smaller, focused modules with proper testing. The code is now organized into dedicated modules under the lib/app/ directory, making the codebase more maintainable and testable.
## Key changes
- Extract functionality into modules under lib/app/ directory:
- Command-line handling (cli.ts)
- Configuration loading (config.ts)
- Web server setup and middleware (server.ts)
- Core application initialization (main.ts)
- URL handlers, routing, rendering, and controllers
- Add comprehensive unit tests for all new modules
- Make compilationQueue non-optional in the compilation environment
- Improve separation of concerns with dedicated interfaces
- Ensure backward compatibility with existing functionality
- Maintain cross-platform compatibility (Windows/Linux)
## Benefits
- Improved code organization and modularity
- Enhanced testability with proper unit tests
- Better separation of concerns
- Reduced complexity in individual files
- Easier maintenance and future development
This refactoring is a significant step toward a more maintainable codebase while preserving all existing functionality.
<!-- THIS COMMENT IS INVISIBLE IN THE FINAL PR, BUT FEEL FREE TO REMOVE
IT
Thanks for taking the time to improve CE. We really appreciate it.
Before opening the PR, please make sure that the tests & linter pass
their checks,
by running `make check`.
In the best case scenario, you are also adding tests to back up your
changes,
but don't sweat it if you don't. We can discuss them at a later date.
Feel free to append your name to the CONTRIBUTORS.md file
Thanks again, we really appreciate this!
-->
* For `nightly` Rust (and 1.88+), the output format of `--help` was
changed in https://github.com/rust-lang/rust/pull/140152.
This PR changes the parser to parse the new format, so that edition
overrides are selectable for `nightly` Rust. Note the `<>`:
```
--edition <2015|2018|2021|2024|future>
Specify which edition of the compiler to use when
compiling code. The default is 2015 and the latest
stable edition is 2024.
```
* Rust <= 1.34 (and >= 1.31) support the 2018 edition, but the help
message only includes `--edition` in verbose mode.