Note: This is a public test instance of Red Hat Bugzilla. The data contained within is a snapshot of the live data so any changes you make will not be reflected in the production Bugzilla. Email is disabled so feel free to test any aspect of the site that you want. File any problems you find or give feedback at bugzilla.redhat.com.
Bug 1242599
Summary: | Regression in bs4 4.4.0 when manipulating html document | ||||||
---|---|---|---|---|---|---|---|
Product: | [Fedora] Fedora | Reporter: | Michal Hlavinka <mhlavink> | ||||
Component: | python-beautifulsoup4 | Assignee: | Terje Røsten <terjeros> | ||||
Status: | CLOSED ERRATA | QA Contact: | Fedora Extras Quality Assurance <extras-qa> | ||||
Severity: | unspecified | Docs Contact: | |||||
Priority: | unspecified | ||||||
Version: | 22 | CC: | hhorak, rbean, terjeros | ||||
Target Milestone: | --- | ||||||
Target Release: | --- | ||||||
Hardware: | Unspecified | ||||||
OS: | Unspecified | ||||||
Whiteboard: | |||||||
Fixed In Version: | python-beautifulsoup4-4.4.1-1.fc23 python-beautifulsoup4-4.4.1-1.fc22 python-beautifulsoup4-4.4.1-1.fc21 | Doc Type: | Bug Fix | ||||
Doc Text: | Story Points: | --- | |||||
Clone Of: | Environment: | ||||||
Last Closed: | 2015-10-04 19:12:13 UTC | Type: | Bug | ||||
Regression: | --- | Mount Type: | --- | ||||
Documentation: | --- | CRM: | |||||
Verified Versions: | Category: | --- | |||||
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |||||
Cloudforms Team: | --- | Target Upstream Version: | |||||
Embargoed: | |||||||
Attachments: |
|
Reported also to upstream bug tracker https://bugs.launchpad.net/beautifulsoup/+bug/1474732 Thanks for report! python-beautifulsoup4-4.4.1-1.fc21 has been submitted as an update to Fedora 21. https://bodhi.fedoraproject.org/updates/FEDORA-2015-0aacd6a0a8 python-beautifulsoup4-4.4.1-1.fc23 has been submitted as an update to Fedora 23. https://bodhi.fedoraproject.org/updates/FEDORA-2015-b5bc948c58 python-beautifulsoup4-4.4.1-1.fc22 has been pushed to the Fedora 22 testing repository. If problems still persist, please make note of it in this bug report. If you want to test the update, you can install it with $ su -c 'dnf --enablerepo=updates-testing update python-beautifulsoup4' You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2015-0f9c92ca7f python-beautifulsoup4-4.4.1-1.fc23 has been pushed to the Fedora 23 testing repository. If problems still persist, please make note of it in this bug report. If you want to test the update, you can install it with $ su -c 'dnf --enablerepo=updates-testing update python-beautifulsoup4' You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2015-b5bc948c58 python-beautifulsoup4-4.4.1-1.fc21 has been pushed to the Fedora 21 testing repository. If problems still persist, please make note of it in this bug report. If you want to test the update, you can install it with $ su -c 'dnf --enablerepo=updates-testing update python-beautifulsoup4' You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2015-0aacd6a0a8 python-beautifulsoup4-4.4.1-1.fc23 has been pushed to the Fedora 23 stable repository. If problems still persist, please make note of it in this bug report. python-beautifulsoup4-4.4.1-1.fc22 has been pushed to the Fedora 22 stable repository. If problems still persist, please make note of it in this bug report. python-beautifulsoup4-4.4.1-1.fc21 has been pushed to the Fedora 21 stable repository. If problems still persist, please make note of it in this bug report. |
Created attachment 1051473 [details] reproducer.py Description of problem: bs4 4.4.0 update breaks our script that works with previous version 4.3.2-3 Version-Release number of selected component (if applicable): python3-beautifulsoup4-4.4.0-1.fc22.noarch How reproducible: always Steps to Reproduce: 1. ./reproducer.py 2. 3. Actual results: dst= <class 'bs4.element.Tag'> src1= <class 'bs4.element.Tag'> dst= <class 'bs4.element.Tag'> src2= <class 'bs4.element.Tag'> dst= <class 'bs4.element.Tag'> src3= <class 'NoneType'> Traceback (most recent call last): File "./reproducer.py", line 84, in <module> update_html_template(html, 3) # regression File "./reproducer.py", line 75, in update_html_template dst.insert(0, src3) File "/usr/lib/python3.4/site-packages/bs4/element.py", line 317, in insert new_child.parent = self AttributeError: 'NoneType' object has no attribute 'parent' src3 find call fails which causes this backtrace Expected results: dst= <class 'bs4.element.Tag'> src1= <class 'bs4.element.Tag'> dst= <class 'bs4.element.Tag'> src2= <class 'bs4.element.Tag'> dst= <class 'bs4.element.Tag'> src3= <class 'bs4.element.Tag'> DONE <class 'bs4.BeautifulSoup'> Additional info: