Nick,
Did not know or remember that interesting fact about Scotland (GB-SCT) under 3166-2. Seeing https://en.m.wikipedia.org/wiki/ISO_3166-2 which reports that ISO-2 list, I just realized that it indirectly differentiates between independent countries and non-sovereign territories that possess 3166-1 country codes: those with subdivisions are independent countries and those without are not. Thanks a lot!
Note that Wikipedia is not a normative source for ISO information. Apart from that, the conclusion you make about the difference between ISO 3166 Part 1 and Part 2 is incorrect. Part 2 defines subdivisions codes and given that, none of them are independent. These codes have the form AA-XXXX. The AA part is the alpha-2 code defined in Part 1. It doesn't say anything about the dependency status of those subdivisions. In Part 1, there is an indicator whether it the code is assigned to an Independent country or not. Also note Part 2 only has subdivisions from Codes in Part 1. If one want to know what ISO 3166 actually says, it is best to go to the source directly. You can browse the ISO database using <https://www.iso.org/obp>. In the search box, select the country button and type in the query. Then you can click on the results and see the glory details. For Scotland one gets something like <https://www.iso.org/obp/ui#iso:code:3166:GB>. Note the "Yes" in the dependency status of GB. Hope this helps, Regards, jaap