Similar question here, I tried the suggested answer but it didn't work for my situation. updating plugin from qgis 2 to 3. qRegisterResourceData . argument 2 has unexpected type 'str' I am trying to migrate a plugin to QGIS3 using qgis2to3 and I got stuck on an error; TypeError: qRegisterResourceData(int, bytes, bytes, bytes): argument 2 has unexpected type 'str' It seems that when I run the pyrcc5.bat I get a new resources.py but not a new resources.qrc, should have I?

1 Answer 1


So this is what I managed to come up with that ended up working for me; in the OSgeo4W Shell I ran; 04w_env, qt5_env, and py3_env then I cd'd to where my plugin folder was, then ran pyrcc5 resources.qrc -o resources_rc.py and that got me past this error.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.