An error while installing india_compliance: 'AccountsController' no attribute 'get_voucher_subtype'

i just follow this step

  1. bench --site DTO.com install-app india_compliance
    output
    An error occurred while installing india_compliance: (‘Module Def’, ‘GST India’, IntegrityError(1062, “Duplicate entry ‘GST India’ for key ‘PRIMARY’”))

SELECT * FROM tabModule Def WHERE app_name = ‘india_compliance’;

DELETE FROM tabModule Def WHERE app_name = ‘india_compliance’;

output
deleted 4 rows

3 bench --site DTO.com install-app india_compliance
output
Updating DocTypes for india_compliance: [=============== ] 39%An error occurred while installing india_compliance: type object ‘AccountsController’ has no attribute ‘get_voucher_subtype’

so how to resolve this problem

You are likely on the develop branch of the India Compliance App.

What was the branch you used to install the India Compliance App?

You could use the following to switch the branch to the required version.

bench switch-to-branch [version] india_compliance

when i install India Compliance App. that time i use
bench get-app GitHub - resilient-tech/india-compliance: Simple, yet powerful compliance solutions for Indian businesses

You should use the branch flag as specified above. Otherwise, it will default to develop branch.

Please list the output of bench version here.

It is likely that you’re using an ERPNext version that isn’t compatible with the current version of India Compliance. In that case, you’ll need to upgrade the ERPNext version as suggested in the error message.