vaadin / flow

Vaadin Flow is a Java framework binding Vaadin web components to Java. This is part of Vaadin 10+.
Apache License 2.0
609 stars 167 forks source link

fix: fail fast if view defines same path for route and route alias #19977

Closed mcollovati closed 1 week ago

mcollovati commented 1 week ago

Currently, if a view defines @Route and @RouteAlias with the same path, the alias is rejected at startup, but there is no evidence of the error. However, when hot swap is enabled and the view class is reloaded, an exception is thrown. This change adds an explicit check for duplicate paths, preventing the application from starting if the configuration is invalid.

Fixes #19972

sonarcloud[bot] commented 1 week ago

Quality Gate Passed Quality Gate passed

Issues
2 New issues
0 Accepted issues

Measures
0 Security Hotspots
0.0% Coverage on New Code
0.0% Duplication on New Code

See analysis details on SonarCloud

github-actions[bot] commented 1 week ago

Test Results

1 135 files  ±0  1 135 suites  ±0   1h 25m 23s :stopwatch: - 7m 32s 7 395 tests +2  7 345 :white_check_mark: +2  50 :zzz: ±0  0 :x: ±0  7 731 runs  +7  7 671 :white_check_mark: +7  60 :zzz: ±0  0 :x: ±0 

Results for commit cebd90c0. ± Comparison against base commit c615be5b.

:recycle: This comment has been updated with latest results.

vaadin-bot commented 3 days ago

This ticket/PR has been released with Vaadin 24.5.0.beta2 and is also targeting the upcoming stable 24.5.0 version.