Skip to content
Advertisement

module ‘qrcode’ has no attribute ‘make’

While integrating python library qrcode==6.1 with django==3.1.2. I have been trying to generate a qrcode which will contain the URL links for my other websites.

Models.py

JavaScript

But It always display an error saying that module ‘qrcode’ doesnot contain any attribute named ‘make()’. I want to know how to resolve this?

Advertisement

Answer

Make sure there are not any files named qrcode.py in the directory where models.py is located.

For more information check https://github.com/lincolnloop/python-qrcode/issues/185

Advertisement