title: Python Botocore remove unused files from data folder
body: <p>I have a Python app running on an OpenWrt router (Chaos Calmer) that uses the boto3 package for creating and updating AWS IoT thing shadows. The app is packaged with its own Python and dependencies (including boto3 and botocore). boto3 depends on botocore, which has a data folder with a bunch of json files for other AWS services unused by my app (S3, dynamoDB, route53, lambda, etc. etc.). Out of all the app's resources, this folder takes up the most space by far. Eventually I will need to do OTA updates over cellular to many of these routers, meaning data usage is a concern. Therefore I would like to trim out as many unused json files from the data folder as possible without breaking the code. </p>
  
  <p>These are the only three boto3 and botocore imports my app uses:</p>
  
  <pre><code>from boto3 import client as boto3_client
  from boto3.exceptions import ResourceNotExistsError
  from botocore.exceptions import ClientError
  </code></pre>
  
  <p>How can I determine which json files I can get rid of?</p>
  
  <p>Update (1-8-19): I figured out how to solve this problem. Instead of removing a handful of files that didn't look relevant, then running the app to make sure it wasn't broken, then removing more files etc. etc., I did the opposite: removed all the files, then slowly added files that looked relevant back until only the necessary files remained. In the end the data folder went from ~35 Mb to &lt; 2 Mb  (that's a huge deal for my use case) </p>