Allow xmlfile.write() to accept a None

Bug #1465357 reported by Charlie_X
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Fix Released

Bug Description

This is a convenience request that xmlfile.write(None) should not raise an exception as it currently does. I find it fairly common to have to want to pass elements coming from functions or methods that might return an Element or None. This means wrapping the call to xmlfile.write() in conditional code whereas "do nothing" is required. I don't know if this is a common use case but I can imagine it might be.

Revision history for this message
scoder (scoder) wrote :
Changed in lxml:
assignee: nobody → scoder (scoder)
importance: Undecided → Wishlist
milestone: none → 3.9.0
status: New → Fix Committed
scoder (scoder)
Changed in lxml:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.