Hi,<div><br></div><div>I'm using a hidden iframe in my file upload component. If an error occurs during uploading, the error page is rendered in the hidden iframe - which means I end up debugging by inspecting the http responses in the browsers development tools. Not ideal so I thought I'd trap the error and present the page myself. In the exception trap I send a script to the page which redirects the parent window to the error page - 'parent.parent.window.location.replace(..error url..)' This works well apart from when I click on the "debug" link, the debugger in the Pharo reports: "Error: context not in self" and doesn't shows an unrelated (to the original error) stack trace.</div>
<div><br></div><div>I've patched together my error handling code, by examining the error handling filter in Seaside. I've had to add an accessor on WASession>>#continuations, which probably indicates there is an easier way to achieve my goal:</div>
<div><br></div><div><div>handleException: ex</div><div><span class="Apple-tab-span" style="white-space:pre">        </span>| session requestContext key continuation renderContinuation |</div><div><span class="Apple-tab-span" style="white-space:pre">        </span>requestContext := self requestContext.</div>
<div><span class="Apple-tab-span" style="white-space:pre">        </span>session := requestContext session.</div><div><span class="Apple-tab-span" style="white-space:pre">        </span>key := requestContext request fields at: session actionField.</div>
<div><span class="Apple-tab-span" style="white-space:pre">        </span>continuation := session continuations at: key.</div><div><span class="Apple-tab-span" style="white-space:pre">        </span>renderContinuation := continuation createRenderContinuation.</div>
<div><span class="Apple-tab-span" style="white-space:pre">        </span>session presenter show: (WAWalkback current exception: ex) onAnswer: [:answer | </div><div><span class="Apple-tab-span" style="white-space:pre">                </span>answer ifTrue: [ </div>
<div><span class="Apple-tab-span" style="white-space:pre">                        </span>self flag: #todo. "work out why I get the error: 'Error: context not in self'"</div><div><span class="Apple-tab-span" style="white-space:pre">                        </span>GRPlatform current openDebuggerOn: ex ] ].</div>
<div><br></div><div><span class="Apple-tab-span" style="white-space:pre">        </span>"redirect the main page to the error location"</div><div><span class="Apple-tab-span" style="white-space:pre">        </span>self requestContext respond: </div>
<div><span class="Apple-tab-span" style="white-space:pre">                </span>[ :response | </div><div><span class="Apple-tab-span" style="white-space:pre">                </span>response</div><div><span class="Apple-tab-span" style="white-space:pre">                        </span>contentType: WAMimeType textHtml;</div>
<div><span class="Apple-tab-span" style="white-space:pre">                        </span>nextPutAll: (WARenderCanvas builder</div><div><span class="Apple-tab-span" style="white-space:pre">                                </span>fullDocument: true;</div><div><span class="Apple-tab-span" style="white-space:pre">                                </span>scriptGeneratorClass: JQScriptGenerator; "removes the onload from body"</div>
<div><span class="Apple-tab-span" style="white-space:pre">                                </span>render: [ :html | </div><div><span class="Apple-tab-span" style="white-space:pre">                                        </span>html script: 'parent.parent.window.location.replace("', renderContinuation registerForUrl greaseString, '")' ] )]</div>
</div><div><br></div><div>I've a horrible feeling I'm missing an obvious, simpler solution</div><div><br></div><div>Thanks,</div><div><br></div><div>Nick</div>