Plugin did not respond errors while running Terraform

I have been using Terraform to create Azure resources. Recently I upgraded the TF version and Azurerm version and facing issue of plugin crash error several times whenever I run it. The execution happens in GitHub via GitHub Actions.

I get Plugin did not respond many times while running TF via GitHub actions:
│ Error: Plugin did not respond
│ The plugin encountered an error, and failed to respond to the
│ plugin.(*GRPCProvider).ApplyResourceChange call. The plugin logs may
│ contain more detailsThe version of TF is 1.0.2 and Azurerm version is 2.59.0
I have tried using various versions including 1.0.4 and other Azurerm versions but it runs into these error many times.
Is there a way to avoid this?Rerun of job makes it success but many times while TF create it misses some resources from state files and needs to be rerun again in TF import step.