# Ignition 8.1.17 - after upgrading from 8.1.16, pages message sent doesn't trigger perspective message handler?

**URL:** <https://forum.inductiveautomation.com/t/ignition-8-1-17-after-upgrading-from-8-1-16-pages-message-sent-doesnt-trigger-perspective-message-handler/59542>\
**Category:** Module Development\
**Tags:** perspective, ignition81\
**Created:** [May 13, 2022, 1:42pm UTC](https://forum.inductiveautomation.com/t/ignition-8-1-17-after-upgrading-from-8-1-16-pages-message-sent-doesnt-trigger-perspective-message-handler/59542 "2022-05-13T13:42:21Z")\
**Posts on this page:** 20\
**Page:** 1

<div class="post-metadata">

**Author:** ![mazeyrat](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/mazeyrat/32/10955_2.png) [@mazeyrat](https://forum.inductiveautomation.com/u/mazeyrat)\
**Post date:** [May 13, 2022, 1:42pm UTC](https://forum.inductiveautomation.com/t/ignition-8-1-17-after-upgrading-from-8-1-16-pages-message-sent-doesnt-trigger-perspective-message-handler/59542/1 "2022-05-13T13:42:22Z")

</div>

Hi @paul-griffith,

I've upgraded an application from Ignition **8.1.16** to Ignition **8.1.17**

I have a module that send message to perspective pages.  
All works fine in 8.1.16, but after upgrading in 8.1.17, the message are not sent or received in the event bus.

**Does anything change in the way to send page's message ?**

> [@SDK transfert data from gateway to perspective](https://forum.inductiveautomation.com/t/sdk-transfert-data-from-gateway-to-perspective/36349/23):
>
> Hi @paul-griffith to obtain the sessionId String sessionId = InternalSession.SESSION.get().getSession().getSessionId().toString(); work fine. But if I need to obtain the pageId, I’ve tried: String pageId = InternalSession.SESSION.get().getSession().getPage().getId().toString(); or String pageId = InternalSession.SESSION.get().getPage().getId().toString(); But both of them are triggering a java.lang.NullPointerException: null Did I missed something ? I try to guess in a script function the …

The code used by the module to send message:

```auto
    public void sendCallbackMessage(String strSessionId,String pageId,String sessionName,Dataset data) {
        try {
            UUID sessionId = UUID.fromString(strSessionId);
            perspectiveContext.getSessionMonitor().findSession(sessionId).ifPresent(session -> {

                Optional<PageModel> pageModel = session.findPage(pageId);
                if (pageModel.isPresent()){

                    PyDictionary payloadMap = new PyDictionary();
                    QualifiedValue value = new BasicQualifiedValue(data);
                    payloadMap.put("data", value);

                    UserScopeMessageEvent message = new UserScopeMessageEvent(sessionName, payloadMap);

                    logger.debug("sendCallbackMessage() send to sessionName={} - sessionId={} - pageId={} - data={}",
                            sessionName,
                            sessionId.toString(),
                            pageId,
                            value);

                    session.queue().submit(() -> pageModel.get().getPageEventBus().post(message));

                } else {
                    logger.error("sendCallbackMessage() - sessionId={} - pageId={} not found !",
                            sessionId.toString(),
                            pageId);
                }
            });
        } catch (Exception e) {
            logger.error("sendCallbackMessage() - Exception : {}",e);
        }
    }

```

According to gateway and browser logs, session id and page id are OK,  
nevertheless **the message handler that is no more triggered since upgrading in 8.1.17:**

 ![chrome_PJq8ldbwVB](https://us1.discourse-cdn.com/inductiveautomation/original/3X/d/1/d19c3d96828d9e64459ac79659497bd453106549.png)

Perspective page message handler:

 ![mstsc_uuJG9yOBPQ](https://us1.discourse-cdn.com/inductiveautomation/original/3X/0/a/0a3b6c85bb69719c1f432e8b39ade0dbe6b261d5.png)

---

<div class="post-metadata">

**Author:** ![paul-griffith](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/paul-griffith/32/37249_2.png) [@paul-griffith](https://forum.inductiveautomation.com/u/paul-griffith)\
**Post date:** [May 13, 2022, 2:43pm UTC](https://forum.inductiveautomation.com/t/ignition-8-1-17-after-upgrading-from-8-1-16-pages-message-sent-doesnt-trigger-perspective-message-handler/59542/2 "2022-05-13T14:43:52Z")

</div>

Instead of subscribing to the page _eventbus_, subscribe to the page’s event manager (you’ll have to bump your SDK version). There was a catastrophic performance cliff in Guava’s eventbus, so we had to migrate away. The API is roughly the same, but the internals are different.

---

<div class="post-metadata">

**Author:** ![mazeyrat](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/mazeyrat/32/10955_2.png) [@mazeyrat](https://forum.inductiveautomation.com/u/mazeyrat)\
**Post date:** [May 13, 2022, 3:10pm UTC](https://forum.inductiveautomation.com/t/ignition-8-1-17-after-upgrading-from-8-1-16-pages-message-sent-doesnt-trigger-perspective-message-handler/59542/3 "2022-05-13T15:10:21Z")

</div>

Thanks a lot @paul-griffith !

I suppose that it’s the same for **session message** , I have to use event Manager instead of event bus:

before 8.1.17:

```auto
	perspectiveContext.getSessionMonitor().findSession(sessionId).ifPresent(session -> {
			PyDictionary payloadMap = new PyDictionary();
			payloadMap.put("sessionId", sessionId.toString());
			payloadMap.put("id", id);
			payloadMap.put("qv", qv);
			UserScopeMessageEvent message = new UserScopeMessageEvent(messageHandler, payloadMap);
			logger.debug("SessionEventBus().post : sessionId={}, id={}, qv={}",sessionId.toString(),id,qv);
			session.queue().submit(() -> session.getEventBus().post(message));
	});

```

from 8.1.17:

```auto
session.queue().submit(() -> session.getEventManager().post(message));

```

---

<div class="post-metadata">

**Author:** ![paul-griffith](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/paul-griffith/32/37249_2.png) [@paul-griffith](https://forum.inductiveautomation.com/u/paul-griffith)\
**Post date:** [May 13, 2022, 4:08pm UTC](https://forum.inductiveautomation.com/t/ignition-8-1-17-after-upgrading-from-8-1-16-pages-message-sent-doesnt-trigger-perspective-message-handler/59542/4 "2022-05-13T16:08:29Z")

</div>

Yeah, pretty much everything in Perspective was refactored to have the two side by side. I think we’re planning to remove the eventbus stuff in Perspective in 8.2.X, but I’m not positive on that.

---

<div class="post-metadata">

**Author:** ![Ahmed\_mohamed](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/ahmed_mohamed/32/53025_2.png) [@Ahmed\_mohamed](https://forum.inductiveautomation.com/u/Ahmed_mohamed)\
**Post date:** [November 16, 2022, 9:46pm UTC](https://forum.inductiveautomation.com/t/ignition-8-1-17-after-upgrading-from-8-1-16-pages-message-sent-doesnt-trigger-perspective-message-handler/59542/5 "2022-11-16T21:46:44Z")

</div>

is that required to depend on the Perspective module !?

---

<div class="post-metadata">

**Author:** ![paul-griffith](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/paul-griffith/32/37249_2.png) [@paul-griffith](https://forum.inductiveautomation.com/u/paul-griffith)\
**Post date:** [November 16, 2022, 10:11pm UTC](https://forum.inductiveautomation.com/t/ignition-8-1-17-after-upgrading-from-8-1-16-pages-message-sent-doesnt-trigger-perspective-message-handler/59542/6 "2022-11-16T22:11:39Z")

</div>

If you plan to use Perspective APIs in your code, you **must** do two things:

1. At compile time of your module, provide the appropriate Perspective SDK dependencies via your build system of choice.
2. Declare a dependency on the Perspective module in your `module.xml`, so that Ignition knows to load your code (on the Gateway, at least) within an appropriate classloader.

If you want to handle Perspective being _optional_, things get somewhat more complicated and can require reflection to handle cleanly.

---

<div class="post-metadata">

**Author:** ![Ahmed\_mohamed](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/ahmed_mohamed/32/53025_2.png) [@Ahmed\_mohamed](https://forum.inductiveautomation.com/u/Ahmed_mohamed)\
**Post date:** [November 16, 2022, 10:48pm UTC](https://forum.inductiveautomation.com/t/ignition-8-1-17-after-upgrading-from-8-1-16-pages-message-sent-doesnt-trigger-perspective-message-handler/59542/7 "2022-11-16T22:48:42Z")

</div>

Sorry for bothering you,  
there is an Archetype for Perspective Module To import an empty Template To write My code there.  
Thanks in Advanced

---

<div class="post-metadata">

**Author:** ![paul-griffith](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/paul-griffith/32/37249_2.png) [@paul-griffith](https://forum.inductiveautomation.com/u/paul-griffith)\
**Post date:** [November 16, 2022, 10:58pm UTC](https://forum.inductiveautomation.com/t/ignition-8-1-17-after-upgrading-from-8-1-16-pages-message-sent-doesnt-trigger-perspective-message-handler/59542/8 "2022-11-16T22:58:03Z")

</div>

No, there are no Maven archetypes for a Perspective component. We use Gradle internally, and no one (to my knowledge) has yet figured out how to build a Perspective component with Maven.

There are two public examples of a Perspective component built using Gradle:

> **[ignition-sdk-examples/perspective-component at master ·...](https://github.com/inductiveautomation/ignition-sdk-examples/tree/master/perspective-component)**
>
> master/perspective-component

> <https://github.com/inductiveautomation/ignition-sdk-examples/pull/92>
>
> This adds another perspective module component example, in the most simplified f…orm possible. There is no front-end tooling, and only the minimal required APIs for registering a component are demonstrated.  
> 
> This example is not 'production grade', as it is intended to be useful as a learning tool rather than the basis of a new module.
> 
> Fixes #81

---

<div class="post-metadata">

**Author:** ![Ahmed\_mohamed](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/ahmed_mohamed/32/53025_2.png) [@Ahmed\_mohamed](https://forum.inductiveautomation.com/u/Ahmed_mohamed)\
**Post date:** [November 16, 2022, 11:00pm UTC](https://forum.inductiveautomation.com/t/ignition-8-1-17-after-upgrading-from-8-1-16-pages-message-sent-doesnt-trigger-perspective-message-handler/59542/9 "2022-11-16T23:00:15Z")

</div>

Thanks [PGriffith](https://forum.inductiveautomation.com/t/ignition-8-1-17-after-upgrading-from-8-1-16-pages-message-sent-doesnt-trigger-perspective-message-handler/59542/8) ❤

---

<div class="post-metadata">

**Author:** ![Thomas\_Mulcahy](https://avatars.discourse-cdn.com/v4/letter/t/f1d935/32.png) [@Thomas\_Mulcahy](https://forum.inductiveautomation.com/u/Thomas_Mulcahy)\
**Post date:** [February 2, 2023, 3:04pm UTC](https://forum.inductiveautomation.com/t/ignition-8-1-17-after-upgrading-from-8-1-16-pages-message-sent-doesnt-trigger-perspective-message-handler/59542/10 "2023-02-02T15:04:17Z")

</div>

Hi,

In relation to the above, I have got this mechanism working with Message Handlers on views (root). But I can't seem to get this to work with the Perspective Session Events mechanism. Am I supposed to be doing something different?

---

<div class="post-metadata">

**Author:** ![paul-griffith](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/paul-griffith/32/37249_2.png) [@paul-griffith](https://forum.inductiveautomation.com/u/paul-griffith)\
**Post date:** [February 2, 2023, 4:20pm UTC](https://forum.inductiveautomation.com/t/ignition-8-1-17-after-upgrading-from-8-1-16-pages-message-sent-doesnt-trigger-perspective-message-handler/59542/11 "2023-02-02T16:20:42Z")

</div>

It's not clear at all to me what issue you're having or how it relates to the above. Are you also developing a module? What have you done/what are you currently doing/what's going wrong?

---

<div class="post-metadata">

**Author:** ![Thomas\_Mulcahy](https://avatars.discourse-cdn.com/v4/letter/t/f1d935/32.png) [@Thomas\_Mulcahy](https://forum.inductiveautomation.com/u/Thomas_Mulcahy)\
**Post date:** [February 2, 2023, 4:26pm UTC](https://forum.inductiveautomation.com/t/ignition-8-1-17-after-upgrading-from-8-1-16-pages-message-sent-doesnt-trigger-perspective-message-handler/59542/12 "2023-02-02T16:26:24Z")

</div>

Sorry, should have added some context.

I am trying to send a message from a Module running on the gateway to a connected client.

So I have my module configured as it is laid out in this thread. Although, when I send the message using:

```auto
session.queue().submit(() -> session.getEventManager().post(message));

```

I can only register that message on the client, if I put my message handler on one of the pages in my project (I used the root for this test).

What I actually want to do, is have the message handler in the Perspective Session Events. I tested it with the Session Events and it seems that I cannot handle the message being sent from my module.

 ![image](https://us1.discourse-cdn.com/inductiveautomation/original/3X/d/e/dee1c91ea587b207a2fb0174239c65a586afaa95.png)

I do not get the message printed to the log from this message handler.

 ![image](https://us1.discourse-cdn.com/inductiveautomation/original/3X/f/3/f3bc1297502e745f14bffe0d282f91028412b65f.png)

But I do from this message handler.

So I assume I need to send the messages in a different context, if it is possible at all?

---

<div class="post-metadata">

**Author:** ![paul-griffith](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/paul-griffith/32/37249_2.png) [@paul-griffith](https://forum.inductiveautomation.com/u/paul-griffith)\
**Post date:** [February 2, 2023, 5:00pm UTC](https://forum.inductiveautomation.com/t/ignition-8-1-17-after-upgrading-from-8-1-16-pages-message-sent-doesnt-trigger-perspective-message-handler/59542/13 "2023-02-02T17:00:14Z")

</div>

Ah, yeah. The former are messages sent via (typically) `system.util.sendMessage`, on an overall platform-level bus. The latter are messages sent via `system.perspective.sendMessage`, on a Perspective-specific bus. To use the overall system bus, you want the [`MessageDispatchManager`](https://files.inductiveautomation.com/sdk/javadoc/ignition81/8.1.24/com/inductiveautomation/ignition/common/script/message/MessageDispatchManager.html) you get from `GatewayContext`. You build up a `Properties` instance with the static string constant keys in MessageDispatchManager.

---

<div class="post-metadata">

**Author:** ![Thomas\_Mulcahy](https://avatars.discourse-cdn.com/v4/letter/t/f1d935/32.png) [@Thomas\_Mulcahy](https://forum.inductiveautomation.com/u/Thomas_Mulcahy)\
**Post date:** [February 3, 2023, 8:49am UTC](https://forum.inductiveautomation.com/t/ignition-8-1-17-after-upgrading-from-8-1-16-pages-message-sent-doesnt-trigger-perspective-message-handler/59542/14 "2023-02-03T08:49:47Z")

</div>

So this is what I have tried at the moment.

```auto
PyDictionary payload = new PyDictionary();
payload.put("param", number);

Properties filterParams = new Properties();
filterParams.setProperty(MessageDispatchManager.KEY_SCOPE, MessageDispatchManager.SCOPE_CLIENT_ONLY);

dispatchManager.dispatch("ProjectName", "test", payload, filterParams);

```

The ProjectName is the actual name of my project. Looking through the KEYs in MessageDispatchManager I can't see any other I need (I could be wrong)

The message is still not handled by the client.

---

<div class="post-metadata">

**Author:** ![victordcq](https://avatars.discourse-cdn.com/v4/letter/v/f6c823/32.png) [@victordcq](https://forum.inductiveautomation.com/u/victordcq)\
**Post date:** [February 3, 2023, 12:55pm UTC](https://forum.inductiveautomation.com/t/ignition-8-1-17-after-upgrading-from-8-1-16-pages-message-sent-doesnt-trigger-perspective-message-handler/59542/15 "2023-02-03T12:55:48Z")

</div>

> [@Thomas\_Mulcahy](#):
>
> `SCOPE_CLIENT_ONLY`

I think this is vision client, for perspective its probabbly SCOPE\_SESSION

> [@Thomas\_Mulcahy](#):
>
> The ProjectName is the actual name of my project

you should probably not hardcode a project name in a module

---

<div class="post-metadata">

**Author:** ![Thomas\_Mulcahy](https://avatars.discourse-cdn.com/v4/letter/t/f1d935/32.png) [@Thomas\_Mulcahy](https://forum.inductiveautomation.com/u/Thomas_Mulcahy)\
**Post date:** [February 3, 2023, 1:06pm UTC](https://forum.inductiveautomation.com/t/ignition-8-1-17-after-upgrading-from-8-1-16-pages-message-sent-doesnt-trigger-perspective-message-handler/59542/16 "2023-02-03T13:06:44Z")

</div>

Ah! That worked. Thank you.

Yes, the ProjectName will come from the configuration eventually. It is easier to ignore that for now.

One last question, is there a way that I can display a Popup from the Perspective Session Events handler.

```auto
com.inductiveautomation.ignition.common.script.JythonExecException: Traceback (most recent call last): File "", line 2, in handleMessage at com.inductiveautomation.perspective.gateway.script.AbstractScriptingFunctions.lambda$operateOnPage$0(AbstractScriptingFunctions.java:64) at com.inductiveautomation.perspective.gateway.script.AbstractScriptingFunctions.operateOnSession(AbstractScriptingFunctions.java:120) at com.inductiveautomation.perspective.gateway.script.AbstractScriptingFunctions.operateOnPage(AbstractScriptingFunctions.java:47) at com.inductiveautomation.perspective.gateway.script.PerspectiveScriptingFunctions.popupAction(PerspectiveScriptingFunctions.java:758) at com.inductiveautomation.perspective.gateway.script.PerspectiveScriptingFunctions.openPopup(PerspectiveScriptingFunctions.java:240) at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at java.base/java.lang.reflect.Method.invoke(Unknown Source) java.lang.IllegalArgumentException: java.lang.IllegalArgumentException: No perspective page attached to this thread.

at org.python.core.Py.JavaError(Py.java:547)

at org.python.core.Py.JavaError(Py.java:538)

at org.python.core.PyReflectedFunction. __call__ (PyReflectedFunction.java:192)

at com.inductiveautomation.ignition.common.script.ScriptManager$ReflectedInstanceFunction. __call__ (ScriptManager.java:552)

at org.python.core.PyObject. __call__ (PyObject.java:477)

at org.python.core.PyObject. __call__ (PyObject.java:481)

at org.python.pycode._pyx351.handleMessage$1(:2)

at org.python.pycode._pyx351.call_function()

at org.python.core.PyTableCode.call(PyTableCode.java:173)

at org.python.core.PyBaseCode.call(PyBaseCode.java:306)

at org.python.core.PyFunction.function ___call__ (PyFunction.java:474)

at org.python.core.PyFunction. __call__ (PyFunction.java:469)

at org.python.core.PyFunction. __call__ (PyFunction.java:464)

at com.inductiveautomation.ignition.common.script.ScriptManager.runFunction(ScriptManager.java:846)

at com.inductiveautomation.ignition.common.script.ScriptManager.runFunction(ScriptManager.java:828)

at com.inductiveautomation.ignition.gateway.project.ProjectScriptLifecycle$TrackingProjectScriptManager.runFunction(ProjectScriptLifecycle.java:832)

at com.inductiveautomation.ignition.common.script.ScriptManager$ScriptFunctionImpl.invoke(ScriptManager.java:1009)

at com.inductiveautomation.ignition.gateway.project.ProjectScriptLifecycle$AutoRecompilingScriptFunction.invoke(ProjectScriptLifecycle.java:897)

at com.inductiveautomation.perspective.gateway.script.ScriptFunctionHelper.invoke(ScriptFunctionHelper.java:147)

at com.inductiveautomation.perspective.gateway.script.ScriptRunner.run(ScriptRunner.java:23)

at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source)

at java.base/java.util.concurrent.FutureTask.run(Unknown Source)

at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)

at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)

at com.inductiveautomation.perspective.gateway.threading.BlockingWork$BlockingWorkRunnable.run(BlockingWork.java:58)

at java.base/java.lang.Thread.run(Unknown Source)

Caused by: org.python.core.PyException: java.lang.IllegalArgumentException: java.lang.IllegalArgumentException: No perspective page attached to this thread.

... 26 common frames omitted

Caused by: java.lang.IllegalArgumentException: No perspective page attached to this thread.

at com.inductiveautomation.perspective.gateway.script.AbstractScriptingFunctions.lambda$operateOnPage$0(AbstractScriptingFunctions.java:64)

at com.inductiveautomation.perspective.gateway.script.AbstractScriptingFunctions.operateOnSession(AbstractScriptingFunctions.java:120)

at com.inductiveautomation.perspective.gateway.script.AbstractScriptingFunctions.operateOnPage(AbstractScriptingFunctions.java:47)

at com.inductiveautomation.perspective.gateway.script.PerspectiveScriptingFunctions.popupAction(PerspectiveScriptingFunctions.java:758)

at com.inductiveautomation.perspective.gateway.script.PerspectiveScriptingFunctions.openPopup(PerspectiveScriptingFunctions.java:240)

at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)

at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)

at java.base/java.lang.reflect.Method.invoke(Unknown Source)

at org.python.core.PyReflectedFunction. __call__ (PyReflectedFunction.java:190)

```

Because I get this error, so I am assuming I can't use system.perspective.openPopup without calling from within a Perspective View?

---

<div class="post-metadata">

**Author:** ![victordcq](https://avatars.discourse-cdn.com/v4/letter/v/f6c823/32.png) [@victordcq](https://forum.inductiveautomation.com/u/victordcq)\
**Post date:** [February 3, 2023, 1:10pm UTC](https://forum.inductiveautomation.com/t/ignition-8-1-17-after-upgrading-from-8-1-16-pages-message-sent-doesnt-trigger-perspective-message-handler/59542/17 "2023-02-03T13:10:40Z")

</div>

you can put you will need to fill in a pageId, as the session has many pages

---

<div class="post-metadata">

**Author:** ![Thomas\_Mulcahy](https://avatars.discourse-cdn.com/v4/letter/t/f1d935/32.png) [@Thomas\_Mulcahy](https://forum.inductiveautomation.com/u/Thomas_Mulcahy)\
**Post date:** [February 3, 2023, 1:11pm UTC](https://forum.inductiveautomation.com/t/ignition-8-1-17-after-upgrading-from-8-1-16-pages-message-sent-doesnt-trigger-perspective-message-handler/59542/18 "2023-02-03T13:11:16Z")

</div>

Ok great, I will take a look at that. Thank you.

---

<div class="post-metadata">

**Author:** ![victordcq](https://avatars.discourse-cdn.com/v4/letter/v/f6c823/32.png) [@victordcq](https://forum.inductiveautomation.com/u/victordcq)\
**Post date:** [February 3, 2023, 1:12pm UTC](https://forum.inductiveautomation.com/t/ignition-8-1-17-after-upgrading-from-8-1-16-pages-message-sent-doesnt-trigger-perspective-message-handler/59542/19 "2023-02-03T13:12:40Z")

</div>

> [@Open popup from session event](https://forum.inductiveautomation.com/t/open-popup-from-session-event/53148/5):
>
> Session Events have no context of “page”. Consider the following code: def runAction(self, event): """ This event is fired when the 'action' of the component occurs. Arguments: self: A reference to the component that is invoking this function. event: An empty event object. """ system.perspective.openPopup(“0”,‘Popups/PopupLoginAck’) Note that you are NOT supplying a pageId. This sort of usage allows the thread in use to fallback to the page which is in use, because this is from a…

---

<div class="post-metadata">

**Author:** ![Thomas\_Mulcahy](https://avatars.discourse-cdn.com/v4/letter/t/f1d935/32.png) [@Thomas\_Mulcahy](https://forum.inductiveautomation.com/u/Thomas_Mulcahy)\
**Post date:** [February 3, 2023, 1:15pm UTC](https://forum.inductiveautomation.com/t/ignition-8-1-17-after-upgrading-from-8-1-16-pages-message-sent-doesnt-trigger-perspective-message-handler/59542/20 "2023-02-03T13:15:20Z")

</div>

Great! That got it working. Many thanks.
