How should I handle `deposed` resources in Terraform? : <p>I am struggling to understand how I should handle <code>deposed</code> resources found in my TF state. </p>

<p>In particular, when running an apply, I am now getting some errors like the below: </p>

<pre><code>Error applying plan:

11 error(s) occurred:

* aws_instance.mongo-replica-01 (deposed #0): Error terminating instance: InvalidInstanceID.NotFound: The instance ID 'i-0f0bdc2c16e922fbc' does not exist
    status code: 400, request id: 71b98708-cb06-4f11-ad14-8d3d160fbc1a
* aws_instance.mongo-replica-01 (deposed #1): Error terminating instance: InvalidInstanceID.NotFound: The instance ID 'i-080ef01dc84c09685' does not exist
    status code: 400, request id: 07c96f82-1e32-4944-a1d6-ab0e6306b82e
* aws_instance.mongo-replica-02 (deposed #1): Error terminating instance: InvalidInstanceID.NotFound: The instance ID 'i-085b997daac742c1e' does not exist
    status code: 400, request id: 20ff2b73-39c9-4d49-af41-f4ec542ec782
* aws_instance.mongo-replica-02 (deposed #0): Error terminating instance: InvalidInstanceID.NotFound: The instance ID 'i-00bc7fd15b04a3688' does not exist
    status code: 400, request id: cdea3c4f-9bec-496a-aedd-bcfbf0a706d2
</code></pre>

<p>The AWS EC2 instances in question do not exist indeed, but TF errors out when trying to delete them (presumably because they don't exist) and still keeps them in the state. </p>

<p>I tried using the <code>terraform state</code> command in an attempt to remove the <code>deposed</code> resources, but it only allows me to delete the whole resource, not just the <code>deposed</code> instance of it... </p>

<p>Am I expected to, simply, manually go in the terraform state file and delete the deposed sections??</p>
