Reconnecting to a WebSession example is not working

I was having trouble with reconnecting to my Session after an event in a subclass of SMTPSecureSocket. It worked fine in the IDE and failed when deployed to a Linux machine.

Because of its size and complexity I was not sure how to proceed. But I found an example in Xojo 2025r2 (could also be there earlier) called Reconnecting to a WebSession. [It can be found under Examples/Platforms/Web] It also exhibits the same behavior. Runs find in Windows IDE and fails when deployed to Linux.

Is this a defect? Am I missing something?

Thanks for any help on this,

Can you share the code in the event.

From Completed event of Shell class:

// Use the stored SessionID to try to get a lock on the user's Session. // You need to do this technique in each event/method where // you want to access Session.

Var context As New WebSessionContext(mSessionID)

// context will be Nil if the session no longer exists
If context <> Nil Then
// You don’t actually use the “context” variable, but
// now Session is available in this method.
Session.CurrentPage.Title = “WebSessionContext worked”

MessageBox(“Shell Completed”)
End If

Attached is the entire example project
Example.zip (37.2 KB)