tracker's unload order sometimes incorrect


The attached patch contains a new test namespace that demonstrates the incorrect unload order, if you leave out the proposed fix in file track.clj




Stuart Sierra
February 1, 2015, 3:39 PM

Included in release version 0.2.9

Stuart Sierra
January 30, 2015, 3:57 PM
Andy Fingerhut
October 2, 2014, 11:12 PM

My application right now is very simple compared to the component workflow – simply use dir/scan-all to get the namespaces and their dependencies, and then print them in a particular order consistent with a correct unload order. I'm sorry, but I don't have the interest right now in testing whether the unload order is correct after doing additional operations on the tracker, since it isn't needed in my application.

I do have a sanity check in my application that confirms the load order is consistent with the dependencies in my application, and will file a bug if I ever see that trigger anything, but I don't expect there is a bug there.

I have switched to using the reverse of the load order in my application for what I believe should always be a correct unload order.

I may look into the branch change you made, but it may fall off my radar unless my needs change.

Stuart Sierra
September 26, 2014, 3:44 PM

After release 0.2.7, which fixed the regression in 0.2.6, :unload order should be correct in all cases except the first time files are added to a new tracker, even with scan-all. I would appreciate it if you can confirm this in your application.

It may be possible to fix the new-tracker case too. For example, commit c0b6b93d, currently on the branch TNS-20-fix-initial-unload-order. This works for the tests in your patch.

I'm not sure if the same change is needed at track.clj line 104 as well.

Andy Fingerhut
September 20, 2014, 7:08 PM

OK, makes sense. Is it already documented anywhere that the unload order is independent of the dependencies after scan-all (and perhaps other calls)? I can create a separate ticket for that if you think it is worth adding such documentation.

It sounds like for the application I had in mind, the reverse of the load order is always defined, and is a correct unload order. You are welcome to close this ticket.

Your pinned fields
Click on the next to a field label to start pinning.


Stuart Sierra


Andy Fingerhut