question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

1.12.0 Release broke radio buttons, check boxes

See original GitHub issue
  • Package version: 1.12.0
  • Django version: 3.2.4
  • Python version: 3.8.5
  • Template pack: Bootstrap 4

Description: Upgrading to 1.12.0 broke all radio buttons and checkboxes on a previously working site. I have confirmed that the 1.12.0 release is where the bug was introduced by stepping back to 1.11 and then updating to 1.11.2 with all still working at 1.11.2. Looking at the HTML, it looks like the problem is that there are no IDs on the <input>s and only a for with no =some_id on the <label> corresponding to the <input>.

Following are screenshots of one of the fields on the rendered form, the HTML, and the Crispy Forms Python code:

image

image

image

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:10 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
smithdc1commented, May 22, 2022

Hi all 👋

So it seems that we’ve found the source of the issue and crispy-forms continues to behave as documented even if there was a bug in previous versions that meant a different behaviour could also be achieved.

On that basis I’m going to close this as I don’t think there’s anything else we should do here. Maybe we can document better but happy to take feedback on this point. 🙏

(I wonder if folk will find this with a Web search now in any case).

Thanks again for all of your input and feedback. 🎁

1reaction
dfrankowcommented, Mar 29, 2022

FYI for others who come here, this comment has another workaround:

Also the docs say that the widget should be set to forms.RadioSelect.

So if you set your widget to forms.RadioSelect, it’ll work.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Radio buttons and checkboxes are broken in Microsoft Forms
Radio buttons and checkboxes are broken in Microsoft Forms ... forms are filled out, entries into checkbox or radio button fields are lost....
Read more >
Changelog - Streamlit Docs
This allows caching checkboxes, sliders, radio buttons, and more! Other Changes. ‍ Design tweak to prevent jittering in sliders (#5612). Bug...
Read more >
Checkboxes vs. Radio Buttons vs. Select Lists - Formstack
A common mistake we often see people making on their forms is the use of checkboxes instead of radio buttons.
Read more >
How to Create Custom Checkboxes and Radio Buttons
For removing the default checkbox style, you need to set the CSS visibility property with its "hidden" value. Or use the opacity property...
Read more >
How to Create Custom Radio Buttons and Checkboxes
All browsers provide a default look for the radio button and checkbox input elements. If you add a multiple choice or multiple response...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found