Hi,
 
Version 12.3 now requiers the module where the function is fetched from, to be imported in the same module as where the "function-lookup"-function is called from. Before this wasn't the case, the module only needed to be imported  in the module where the qName for the function is created. So I could have a module for generic function retrieval. Those days seem to be over.
 
Is this behaviour to stay or can it be reversed. 
 
(app.xqm)
import module namespace c = "_function-lookup-test.c" ;
import module namespace m = "_function-lookup-test.m" ;
c:method( xs:QName( "m:test")
, 0
)()
 
(m.xqm)
module namespace m = "_function-lookup-test.m" ;
declare %public function m:test( ) { "test"} ;
 
(c.xqm)
module namespace c = "_function-lookup-test.c" ;
(: Basex 12.3 requiers the lookup-module to be imported in the module that executes the 'function-lookup'-function
in previous versions this was not necessary, the-lookup-module only needed to be imported in the calling module, here: "m.xqm"
import module namespace m = "_function-lookup-test.m" ; (: not working anymore since 123 when not active :)
:)
declare %public function c:method
( $qName as xs:QName
, $arity as xs:integer
) as function(*)?
{ function-lookup( $qName
, $arity
)
otherwise message( "WARNING!: Method not found: " || xs:string( $qName) || "#" || $arity
)
} ;
 
Best.
Rob Stapper