Named query in timer script

Getting an error when trying to call a named query from a client timer script. The script works when called from e.g. the script console, a button or another thing called from the UI Thread, just not from the timer script.

Here’s the error

Traceback (most recent call last):

  File "<module:project.core.smartcardio>", line 125, in authenticate

com.inductiveautomation.ignition.client.gateway_interface.GatewayException: com.inductiveautomation.ignition.client.gateway_interface.GatewayException: Named query smartcardio/AuthenticateCard not found

	caused by GatewayException: Named query smartcardio/AuthenticateCard not found
	caused by GatewayFunctionException: Named query smartcardio/AuthenticateCard not found

Ignition v7.9.9 (b2018081621)
Java: Oracle Corporation 1.8.0_171

I tried adding the project name, which doesn’t work, as the error suggests its a gateway exception. That just generates another mapping error, similar to this

http://forum.inductiveautomation.com/t/cannot-coerce-value-named-query-path-into-type-interface-java-util-map/18042

Any suggestions on what’s wrong?

EDIT

Also tried to call it on the UI thread from the timer script, still the same.