Bugs
In July I spent 3+ weeks working on Supply. That was mostly spent on tertiary supply, to make sure all possible supply sources are correctly identified. There were only a handful of bugs, but those were very difficult to locate in the 18,000+ lines of code devoted solely to calculating and displaying supply. In effect, I went over and over code that was working perfectly, looking for the few places where the logic had a fault.
I am late posting this report (as usual), so I will just give 4 examples of the supply calculations working correctly, which had been failing - before my ordeal of searching for the less than 10 wrong lines of code in the 18,000+ lines of supply code.
(1) Here the Allies are fighting northwards to Casablanca and going around the Axis flank in the Atlas mountains. The Axis controls Cape St. Vincent, which means that the Allies have to use the port of Cisneros in Spanish Sahara to reach the Cape Verde Basin. MacArthur is tracing to Eisenhower, who traces to Bradley, who traces to Gort, who traces overseas to Liverpool. MacArthur is crucial for the flanking operations east around the German front line. The top Supply Sources form for the Commonwealth shows Gort having to go the long way by sea, skipping Cape St. Vincent, to reach Liverpool. On the Supply Sources form below that, for the United States, Gort appears with a ‘C’ in his route type, indicating that for the US, the supply path is for a cooperating major power. Getting MacArthur to appear as a tertiary supply source was the main bug I fixed here. Another bug was that for France, shown below the United States Supply Source form, the program was not displaying any of the cooperating tertiary supply sources. This saved game was from Alex.
(2) Here the Axis is moving east to conquer Saudi Arabia. German and Italian forces have moved down the Hejaz railway to Medina, where von Bock is providing secondary supply. Balbo traces supply to Graziani who traces to von Bock who traces supply overseas to Vienna. The German Stuka is in supply from Balbo (along with an Italian land unit) next to the Saudi 1-5 cavalry unit. Note that the program is taking into consideration the weather effects on supply. Hence the Italian motorized unit south of von Bock is out of supply. Getting Balbo to be in supply was the bug here. This saved game was from Subeto.
(3) Here the war is going badly for the Germans in Mar/Apr 1944, with the Commonwealth and United States coming from the west and the USSR coming from the east. I have put the Allied HQs on top of their stacks. For the Commonwealth, Crerar is a secondary supply source tracing through Amsterdam and the North Sea to Liverpool. For the US, Crerar appears twice, once tracing overseas (the same path as for the Commonwealth) as a cooperating supply source. The second time he is shown as having an overland supply path to Nice. That involves both the Commonwealth and France as cooperating major powers. Of particular interest is that the Commonwealth units in Denmark are out of supply. Although there are Commonwealth convoys in the Baltic Sea and the North Sea, the Germans still hold both Copenhagen and Kiel, which makes the Kattegat impassable to the Allies for supply. They can trace 4 basic path hexes to Frederikshavn, but that is too many because the overseas link requires one more. This saved game was from Courtenay.
(4) Here the Axis is marching across the desert to Iraq with their eyes on taking out Persia. Iraq is aligned to Italy and Syria is conquered by Italy. Damascus is a potential secondary supply source for both Italy and Germany, while Baghdad is only a potential secondary source for Italy. von Leeb traces to Balbo, who traces to Graziani, who traces to Cavallero (under the Italian 5-3 infantry corps), who traces to Damascus, which traces overseas to Genoa. Balbo has a ‘pure’ path back to supply, not involving any cooperating major powers in the supply path or links therein. The bottom Supply Sources form is for Iraq and shows Balbo twice, as a secondary supply source for Iraqi units because he can trace supply to Baghdad (a primary supply source for Iraqi units). The ‘A’ in Balbo’s path type indicates it is for an aligned minor country. This saved game was from Tobias.
This past month’s corrections to supply should speed up the calculations in some instances, simply because when supply paths are found, the program can stop searching. Also, once a valid supply path has been found, then the program always starts the next search by testing whether the old path still works. That can save a lot of time when recalculating supply.
