Author Topic: Why do my Dependencies sometimes break?  (Read 2409 times)

I've had this situation a couple of times on this project, but this is the worst.

I have a substance that is used in hundreds of other substances. I've not changed it in months and months. I've not touched it in the top level graphs. It's been there and working forever. Now suddenly whenever I open any of these top level graphs, it's broken. The node reads Ghost Graph. The tooltip says " Represents a graph that cannot be located in any of the packages". It's right there. I can open it individually. I haven't moved it. (it's checked in, in perforce and hasn't moved or changed) and I can drag a new copy of it into a graph and hook it up and it works fine.

But I don't want to have to go through each of the HUNDREDS of top level substances I have and re-hook it up.

Why does this happen? And is there any way to fix it without manually adding it back in hundreds of times. I've reverted the troublesome substance. No difference. I've reverted the top level substance, still get the ghost graph broken reference. There should be no difference to when it was working. I've even got someone else to get latest on the files before my current changes and it works in their Substance Designer just fine. So something I've done in this update has broken them all. But how if it's still broken if I revert the files?

How do dependencies work? There's a long number next to the package path that seems to be the same as another similar but different substance I also use in the top level graphs. Has it got confused? Are these supposed to be a unique id? In which case, why aren't they? And can I change them? And if I do, will that fix the broken links?

I'm using Substance 4.6.2. I'm in the middle of production so can't try upgrading. I can't risk any differences in the results. I already know that using Designer 5 makes my 4k graphs come out at 8k somehow, I can't risk that.

Anything I can do or try?

Thanks

Dependencies are quite simple, as soon as you instantiate something (a graph for example) from a package into another, a dependency is created.
If you move, rename the package or rename the graph while the graph(s) where you have instantiated it is not opened, it breaks the dependency. Also, if you use an alias, make sure the alias is correctly setup.

We've never seen dependencies being broken by them selves, so one of the aforementioned action has probably been done.

If you were using SD 5.x you'd have been able to retarget the dependencies using the Dependencies Manager.
In 4.x the only way to fix that is to specify the missing dependency when you open the package, or to edit the sbs xml manually (do that at your own risk..).
Product Manager - Allegorithmic

Thanks for your help Nicolas. It's quite mysterious. I don't get any error on opening the top level graphs like I do if I actually do move the package. I have no opportunity to point it at the correct node. The package is right there where it's always been. The name appears to be correct. I even did a save as and saved over the old file. I'm not sure how it could have ever changed when the file is in version control.

The only thing I can think of is that the mapped drive we use might not have been set up one time at launch. But it's definitely working when I've done all this work. All of the packages are on it and nothing else has broken. I wouldn't be able to load any of the files if the drive didn't exist.

I did also have an issue when my drive got filled 100% once. Substance managed to destroy my preferences and filters. But the packages weren't affected and once I set up the filters it was all ok again. Perhaps something relating to that.

I've sent you a pm.
Product Manager - Allegorithmic