<p></p>
<p dir="auto">I came across something similar yesterday while doing some refactoring, so I think I've figured this out although I haven't had time to fix it.</p>
<p dir="auto">The /history/nearby call is handled by <a href="https://github.com/openstreetmap/openstreetmap-website/blob/226e2d654af2ddb843d39d80a25c2501ff016de3/app/controllers/changesets_controller.rb">ChangesetsController</a>. It <a href="https://github.com/openstreetmap/openstreetmap-website/blob/226e2d654af2ddb843d39d80a25c2501ff016de3/app/controllers/changesets_controller.rb#L41-L43">initially loads the page</a> with the spinner, and then <a href="https://github.com/openstreetmap/openstreetmap-website/blob/226e2d654af2ddb843d39d80a25c2501ff016de3/app/assets/javascripts/index/history.js#L58-L77">via javascript calls the same page again</a> but with the list=1 parameter. This call actually does the query to the database, which times out. (This happens to me too, the timeout <a href="https://github.com/openstreetmap/openstreetmap-website/issues/2396" data-hovercard-type="issue" data-hovercard-url="/openstreetmap/openstreetmap-website/issues/2396/hovercard">is a known issue</a>).</p>
<p dir="auto">However, the problem here is that the second call is expected to <a href="https://github.com/openstreetmap/openstreetmap-website/blob/226e2d654af2ddb843d39d80a25c2501ff016de3/app/controllers/changesets_controller.rb#L65">render with no layout</a>, i.e. just return the list. But the call is wrapped in <a href="https://github.com/openstreetmap/openstreetmap-website/blob/226e2d654af2ddb843d39d80a25c2501ff016de3/app/controllers/changesets_controller.rb#L65"><code class="notranslate">web_timeout</code></a> which doesn't know about this intention, and so it returns an entire page that is crammed into the sidebar, top menu and everything.</p>
<p dir="auto">I'll have a think about the best approach to fix this. There are other pages that behave differently, e.g. ones that use <a href="https://github.com/openstreetmap/openstreetmap-website/blob/226e2d654af2ddb843d39d80a25c2501ff016de3/app/controllers/application_controller.rb#L249-L266">map_layout</a>, where the choice of layout is handled differently (and potentially better, when that layout choice is also inherited by the error handling) and it would be good to align on a single approach.</p>

<p style="font-size:small;-webkit-text-size-adjust:none;color:#666;">—<br />Reply to this email directly, <a href="https://github.com/openstreetmap/openstreetmap-website/issues/3883#issuecomment-1380073000">view it on GitHub</a>, or <a href="https://github.com/notifications/unsubscribe-auth/AAK2OLICEESEF2KZYFJYGZLWR7H57ANCNFSM6AAAAAATVUSLGQ">unsubscribe</a>.<br />You are receiving this because you are subscribed to this thread.<img src="https://github.com/notifications/beacon/AAK2OLNB6DGSEQOXW5IEEMLWR7H57A5CNFSM6AAAAAATVUSLGSWGG33NNVSW45C7OR4XAZNMJFZXG5LFINXW23LFNZ2KUY3PNVWWK3TUL5UWJTSSII7CQ.gif" height="1" width="1" alt="" /><span style="color: transparent; font-size: 0; display: none; visibility: hidden; overflow: hidden; opacity: 0; width: 0; height: 0; max-width: 0; max-height: 0; mso-hide: all">Message ID: <span><openstreetmap/openstreetmap-website/issues/3883/1380073000</span><span>@</span><span>github</span><span>.</span><span>com></span></span></p>
<script type="application/ld+json">[
{
"@context": "http://schema.org",
"@type": "EmailMessage",
"potentialAction": {
"@type": "ViewAction",
"target": "https://github.com/openstreetmap/openstreetmap-website/issues/3883#issuecomment-1380073000",
"url": "https://github.com/openstreetmap/openstreetmap-website/issues/3883#issuecomment-1380073000",
"name": "View Issue"
},
"description": "View this Issue on GitHub",
"publisher": {
"@type": "Organization",
"name": "GitHub",
"url": "https://github.com"
}
}
]</script>