How can I get a custom module's file path in a preprocess function?
A Drupal URI starts with a stream wrapper like &quot;public://&quot; that indicates to Drupal how to handle that resource. Typically, the &quot;public&quot; stream wrapper is defined as &quot;treat this resource as a local file within sites/default/files.&quot;
Your module assets are not located within sites/default/files, so they cannot use the &quot;public&quot; stream wrapper.
Drupal doesn't actually come out-of-the-box with a registered stream wrapper for module or theme assets. You might try installing https://www.drupal.org/project/system_stream_wrapper, which would then allow you to make a URI like module://tableau_partners_sync/images/premier-technology.png.