I found the answer at http://www.portalsolutions.net/WhatWeKnow/Blog/Lists/Posts/Post.aspx?ID=120
After creating a site template based off a site. You go to the SharePoint Solutions Gallery. When you attempt to deactivate the template you get the following error: ?
Unable to access web scoped feature (Id: 7970f9d4-1980-40dc-bac9-3ffe14b8b74d) because it references a non-existent or broken web (Id: f2a7b3f9-21e9-4be7-b77d-00993c6ea30c) on site ‘/PWA’. Exception: System.ArgumentException: Value does not fall within the expected range.
at Microsoft.SharePoint.SPWebCollection.get_Item(Guid id)
at Microsoft.SharePoint.SPFeatureEnumeratorBase.GetCachedWeb(SPSite site, Guid webId, Guid featureId)
To fix this issue, you will have to go to the recycle bin and remove the solution from there. Then you will have to go to the Site Collection Recycle Bin and remove the solution from there also.