I've noticed that sometimes I get a System.ArgumentException when attempting to add a layer at this line:
LayerFactory.Instance.CreateLayer(new Uri(uri), map)
var 'uri' is a string containing the full path of a .lyrx file (ex: "D:\Data\my_layer.lyrx"). If the path is on a shared network drive, some of the time I get the exception. I'm also unable to navigate to that folder in the ArcGIS Pro Catalog. Sometime it does work, however but it seems random. There is no loss of connection to the folder in Windows Explorer when this error occurs.
Is it possible to force a refresh or reconnect to the network folder before attempting to access files? Has anyone else experienced a similar issue?