Buggy code:
public class NamespaceSet { private static final String SOY_EXTENSION = ".soy" ; private static final String JS_SOY_EXTENSION = ".js.soy" ; private static final String MSG_EXTENSION = ".xlf" ; private static final String GLOBALS_EXTENSION = ".globals" ; private final String namespace ; private final Config config ; private Object cacheLock = new Object ( ) ; private SoyTofu tofu ; private final Map < Locale , SoyMsgBundle > msgBundleCache = new MapMaker ( ) . softValues ( ) . makeComputingMap ( new Function < Locale , SoyMsgBundle > ( ) { public SoyMsgBundle apply ( Locale locale ) { } } ) ; private final Map < Locale , String > javaScriptCache = new MapMaker ( ) . softValues ( ) . makeComputingMap ( new Function < Locale , String > ( ) { public String apply ( Locale locale ) { } } ) ; protected NamespaceSet ( String namespace , Config config ) { } private void compile ( ) { } protected void flush ( ) { } protected String render ( String templateName , SoyMapData model , Locale locale ) { } protected String provideAsJavaScript ( Locale locale ) { } private SoyFileSet generateSoyFileSet ( String suffix ) { final FileSetResolver fileSetResolver = config . getFileSetResolver ( ) ; final String searchPath = config . getSearchPath ( ) ; SoyFileSet . Builder builder = new SoyFileSet . Builder ( ) ; boolean hasSetGlobals = false ; if ( ( config . getCompileTimeGlobalsProvider ( ) ) != null ) { builder . setCompileTimeGlobals ( config . getCompileTimeGlobalsProvider ( ) . getGlobals ( ) ) ; hasSetGlobals = true ; } for ( String ns : config . getSharedNameSpaces ( ) ) { <START_BUG> List < URL > sharedSoyFiles = fileSetResolver . filesFromNamespace ( searchPath , ns , NamespaceSet . SOY_EXTENSION ) ; <END_BUG> for ( URL url : sharedSoyFiles ) { builder . add ( url ) ; } if ( ! hasSetGlobals ) { List < URL > sharedGlobalFiles = fileSetResolver . filesFromNamespace ( searchPath , ns , NamespaceSet . GLOBALS_EXTENSION ) ; if ( ( sharedGlobalFiles . size ( ) ) > 0 ) { try { builder . setCompileTimeGlobals ( sharedGlobalFiles . get ( 0 ) ) ; } catch ( IOException e ) { throw new RuntimeException ( "Error<seq2seq4repair_space>sourcing<seq2seq4repair_space>globals<seq2seq4repair_space>file." , e ) ; } hasSetGlobals = true ; } } } List < URL > namespaceSoyFiles = fileSetResolver . filesFromNamespace ( searchPath , namespace , suffix ) ; if ( ( namespaceSoyFiles . size ( ) ) == 0 ) { throw new RuntimeException ( ( "No<seq2seq4repair_space>soy<seq2seq4repair_space>template<seq2seq4repair_space>files<seq2seq4repair_space>found<seq2seq4repair_space>in<seq2seq4repair_space>namespace:<seq2seq4repair_space>" + ( namespace ) ) ) ; } for ( URL url : namespaceSoyFiles ) { builder . add ( url ) ; } if ( ! hasSetGlobals ) { List < URL > globalFiles = fileSetResolver . filesFromNamespace ( searchPath , namespace , NamespaceSet . GLOBALS_EXTENSION ) ; if ( ( globalFiles . size ( ) ) > 0 ) { try { builder . setCompileTimeGlobals ( globalFiles . get ( 0 ) ) ; } catch ( IOException e ) { throw new RuntimeException ( "Error<seq2seq4repair_space>sourcing<seq2seq4repair_space>globals<seq2seq4repair_space>file." , e ) ; } hasSetGlobals = true ; } } return builder . build ( ) ; } }

Fix:
List < URL > sharedSoyFiles = fileSetResolver . filesFromNamespace ( searchPath , ns , suffix ) ;