# Bug OP-11938 - [AppSignal] "No route matches" error in projects/identifier controller

Project: OpenProject
Status: closed
URL: https://community.openproject.org/work_packages/OP-11938

## Open points

_No work packages_

## Details

| Attribute | Value |
| --- | --- |
| Date |  |
| Priority | Medium |
| Module |  |
| Target versions | 12.5.0 |
| Observed in versions | 12.4.0 |
| Sprint | 12.5.0 |
| Backlog bucket |  |
| Bug found in version (deprecated) | 12.4.x |
| Found in mobile app version |  |
| Follow-up feedback e-mail |  |
| Requires doc change | No |
| Accessibility | No |
| Pull preview |  |
| List |  |
| Labels |  |

## People

| Attribute | Value |
| --- | --- |
| Assignee |  |
| Accountable |  |
| Product manager |  |
| Developers |  |
| Designer |  |
| Ordered by |  |
| Signed off by |  |
| Interest by |  |

## Planning

| Attribute | Value |
| --- | --- |
| Relevance |  |

## Costs

| Attribute | Value |
| --- | --- |
| Votes |  |
| Work |  |
| Labor costs |  |

## Description

See [error on AppSignal](https://appsignal.com/openproject-gmbh/sites/632371afd2a5e463ef717ecb/exceptions/incidents/45/samples/632371afd2a5e463ef717ecb-1039489568120015008016756740001?timestamp=2023-02-06T09%3A25%3A20Z)

### Error Message

`No route matches {:action=>"show", :controller=>"overviews/overviews", :layout=>nil, :project_id=>#<Project id: 239, name: "redacted title", description: "Test", public: false, parent_id: 76, created_at: "2023-01-04 13:27:28.797093000 +0000", updated_at: "2023-02-06 09:22:28.756373000 +0000", identifier: "redacted title", lft: 101, rgt: 102, active: true, templated: false>}, possible unmatched constraints: [:project_id]`

### Information

<figure class="table op-uc-figure_align-center op-uc-figure"><table class="op-uc-table"><tbody><tr class="op-uc-table--row"><td class="op-uc-p op-uc-table--cell">hostname</td><td class="op-uc-p op-uc-table--cell">2cc20ff43e49</td><td class="op-uc-p op-uc-table--cell"></td></tr><tr class="op-uc-table--row"><td class="op-uc-p op-uc-table--cell">request_method</td><td class="op-uc-p op-uc-table--cell">PATCH</td><td class="op-uc-p op-uc-table--cell"></td></tr><tr class="op-uc-table--row"><td class="op-uc-p op-uc-table--cell">path</td><td class="op-uc-p op-uc-table--cell">/projects/redacted-name-1/identifier</td><td class="op-uc-p op-uc-table--cell"></td></tr><tr class="op-uc-table--row"><td class="op-uc-p op-uc-table--cell">request_id</td><td class="op-uc-p op-uc-table--cell">1b31de6d-610b-456c-9132-6a22c65c5b7d</td><td class="op-uc-p op-uc-table--cell"></td></tr><tr class="op-uc-table--row"><td class="op-uc-p op-uc-table--cell">revision</td><td class="op-uc-p op-uc-table--cell">12.4.3.88218f7037</td><td class="op-uc-p op-uc-table--cell"></td></tr><tr class="op-uc-table--row"><td class="op-uc-p op-uc-table--cell">core_hash</td><td class="op-uc-p op-uc-table--cell">88218f7037</td><td class="op-uc-p op-uc-table--cell"></td></tr><tr class="op-uc-table--row"><td class="op-uc-p op-uc-table--cell">core_version</td><td class="op-uc-p op-uc-table--cell">88218f7037 (2023-01-30 10:25:40 +0000)</td><td class="op-uc-p op-uc-table--cell"></td></tr><tr class="op-uc-table--row"><td class="op-uc-p op-uc-table--cell">locale</td><td class="op-uc-p op-uc-table--cell">en</td><td class="op-uc-p op-uc-table--cell"></td></tr><tr class="op-uc-table--row"><td class="op-uc-p op-uc-table--cell">product_version</td><td class="op-uc-p op-uc-table--cell">2fea4704 (2023-01-30 10:29:21 +0000)</td><td class="op-uc-p op-uc-table--cell"></td></tr><tr class="op-uc-table--row"><td class="op-uc-p op-uc-table--cell">shard</td><td class="op-uc-p op-uc-table--cell">multitenancy-vips2</td><td class="op-uc-p op-uc-table--cell"></td></tr><tr class="op-uc-table--row"><td class="op-uc-p op-uc-table--cell">tenant</td><td class="op-uc-p op-uc-table--cell">redacted</td><td class="op-uc-p op-uc-table--cell"></td></tr><tr class="op-uc-table--row"><td class="op-uc-p op-uc-table--cell">version</td><td class="op-uc-p op-uc-table--cell">12.4.3</td><td class="op-uc-p op-uc-table--cell"></td></tr><tr class="op-uc-table--row"><td class="op-uc-p op-uc-table--cell">method</td><td class="op-uc-p op-uc-table--cell">PATCH</td><td class="op-uc-p op-uc-table--cell"></td></tr></tbody></table></figure>

### Backtrace

<figure class="table op-uc-figure_align-center op-uc-figure"><table class="op-uc-table"><tbody><tr class="op-uc-table--row"><td class="op-uc-p op-uc-table--cell">lib/redmine/menu_manager/menu_helper.rb:282 node_url</td><td class="op-uc-p op-uc-table--cell"></td></tr><tr class="op-uc-table--row"><td class="op-uc-p op-uc-table--cell">lib/redmine/menu_manager/menu_helper.rb:271 allowed_node_url</td><td class="op-uc-p op-uc-table--cell"></td></tr><tr class="op-uc-table--row"><td class="op-uc-p op-uc-table--cell">lib/redmine/menu_manager/menu_helper.rb:256 extract_node_details</td><td class="op-uc-p op-uc-table--cell"></td></tr><tr class="op-uc-table--row"><td class="op-uc-p op-uc-table--cell">lib/redmine/menu_manager/menu_helper.rb:164 render_single_menu_node</td><td class="op-uc-p op-uc-table--cell"></td></tr><tr class="op-uc-table--row"><td class="op-uc-p op-uc-table--cell">lib/redmine/menu_manager/menu_helper.rb:239 render_single_node_or_partial</td><td class="op-uc-p op-uc-table--cell"></td></tr><tr class="op-uc-table--row"><td class="op-uc-p op-uc-table--cell">lib/redmine/menu_manager/menu_helper.rb:129 render_menu_node</td><td class="op-uc-p op-uc-table--cell"></td></tr><tr class="op-uc-table--row"><td class="op-uc-p op-uc-table--cell">lib/redmine/menu_manager/menu_helper.rb:61 block in render_menu</td><td class="op-uc-p op-uc-table--cell"></td></tr><tr class="op-uc-table--row"><td class="op-uc-p op-uc-table--cell">lib/redmine/menu_manager/menu_helper.rb:298 block in menu_items_for</td><td class="op-uc-p op-uc-table--cell"></td></tr><tr class="op-uc-table--row"><td class="op-uc-p op-uc-table--cell">lib/redmine/menu_manager/menu_helper.rb:292 each</td><td class="op-uc-p op-uc-table--cell"></td></tr><tr class="op-uc-table--row"><td class="op-uc-p op-uc-table--cell">lib/redmine/menu_manager/menu_helper.rb:292 menu_items_for</td><td class="op-uc-p op-uc-table--cell"></td></tr><tr class="op-uc-table--row"><td class="op-uc-p op-uc-table--cell">lib/redmine/menu_manager/menu_helper.rb:197 first_level_menu_items_for</td><td class="op-uc-p op-uc-table--cell"></td></tr><tr class="op-uc-table--row"><td class="op-uc-p op-uc-table--cell">lib/redmine/menu_manager/menu_helper.rb:59 render_menu</td><td class="op-uc-p op-uc-table--cell"></td></tr><tr class="op-uc-table--row"><td class="op-uc-p op-uc-table--cell">lib/redmine/menu_manager/menu_helper.rb:48 render_main_menu</td><td class="op-uc-p op-uc-table--cell"></td></tr><tr class="op-uc-table--row"><td class="op-uc-p op-uc-table--cell">app/views/layouts/base.html.erb:63</td><td class="op-uc-p op-uc-table--cell"></td></tr><tr class="op-uc-table--row"><td class="op-uc-p op-uc-table--cell">app/views/layouts/no_menu.html.erb:30</td><td class="op-uc-p op-uc-table--cell"></td></tr><tr class="op-uc-table--row"><td class="op-uc-p op-uc-table--cell">app/helpers/errors_helper.rb:97 block (2 levels) in render_error</td><td class="op-uc-p op-uc-table--cell"></td></tr><tr class="op-uc-table--row"><td class="op-uc-p op-uc-table--cell">app/helpers/errors_helper.rb:95 render_error</td><td class="op-uc-p op-uc-table--cell"></td></tr><tr class="op-uc-table--row"><td class="op-uc-p op-uc-table--cell">app/helpers/errors_helper.rb:57 render_500</td><td class="op-uc-p op-uc-table--cell"></td></tr><tr class="op-uc-table--row"><td class="op-uc-p op-uc-table--cell">app/controllers/application_controller.rb:119 block in &lt;class:ApplicationController&gt;</td><td class="op-uc-p op-uc-table--cell"></td></tr></tbody></table></figure>

### **Analysis**

When rendering the view, menu items urls are generated. During this process, the parameter `:project_id` of the overviews/overviews route is constrained to match the regex `/(?!(new)$)(\w|-)+/` (defined in `modules/overviews/config/routes.rb`). As the identifier name is invalid, the regex does not match, the route is not found, and the view rendering fails.

A bug in friendly\_id gem is talking about the same issue: [to\_param does not work as expected when record fails to save and a new slug is set in memory norman/friendly\_id\#959](https://github.com/norman/friendly_id/issues/959).
