Betterforms library are they deprecated? if yes, any other solution?

I grabbed the Betterforms library in order to create a Multimodel Form and after having gotten the hang of it and had it ready, it turns out it is not compatible anymore with current version of django. No warning or notice anywhere on their
Am I wrong? and if no, what other solution do I have?

File “C:\Users\chefv\WEBS\inmo\inmoproject\inmoapp\”, line 3, in
from betterforms.multiform import MultiModelForm
File “C:\Users\chefv\WEBS\inmo\vinmo\lib\site-packages\betterforms\”, line 15, in
from django.utils.encoding import python_2_unicode_compatible
ImportError: cannot import name ‘python_2_unicode_compatible’ from ‘django.utils.encoding’ (C:\Users\chefv\WEBS\inmo\vinmo\lib\site-packages\django\utils\

No, but their pypi listing does show that their last deployment was 2018 and that they only claim compatibility with Python 3.6 / Django 2.0 and earlier.

I don’t use Betterforms, so I don’t know what specific functionality it provides that you may be looking for, making the identification of potential alternatives difficult.

However, in the grander scheme of things, and in the short run, you’ve got a couple of reasonable options. (This is the world of Open Source after all)

  • Under the assumption that there’s not likely to be a newer release in the near future that you will need to patch, you can hot-fix the source yourself in your installed copies. (Not generally recommended, but it is an option)
  • You can fork the repo and bring your copy up-to-date, and use that to create installation packages for deployment.
  • You can check the 58 forks of the repo to see if anyone else has already brought their copy up-to-date, and contact them to see if they’re interested in collaboration.
  • You can find a different third-party library providing the same features / benefits that you’re getting from Betterforms.
  • You can migrate away from Betterforms to other libraries.

Thank you very much for the info. I am not that good as to engage into most of the options you mentioned.
The reason I used betteforms is because I have several models that have to be in one form (registering a property, its address and owner) so the Multimodel Form was exactly what I needed. Now, I have to start over from scratch :confused:
Any direction I should look to?
Thank you
best regards

I don’t know what approach you want to take with this, but we use Crispy Forms. It works really well for us.

I have looked at crispy but it seems to me it is mostly for styling and some programming things. I haven’t seen that it makes it easier to create a form with 3 interrelated models plus the views as the betterforms explicitly did.

The only issue with creating a form containing references to multiple models is ensuring that the model form isn’t rendered with a form tag. You can even do that with a standard form as long as you render the individual fields.
Setting the form_tag = True attribute on the helper allows you to render as many Django forms within one HTML form as you would like, such that one submit button submits them all as a set.

ok thank you I will walk that way.