We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see ourdocumentation.
There was an error while loading.Please reload this page.
1 parent2d8919a commit4b22754Copy full SHA for 4b22754
html5lib/_ihatexml.py
@@ -254,15 +254,15 @@ def toXmlName(self, name):
254
nameRest=name[1:]
255
m=nonXmlNameFirstBMPRegexp.match(nameFirst)
256
ifm:
257
-warnings.warn("Coercing non-XML name",DataLossWarning)
+warnings.warn("Coercing non-XML name: %s"%name,DataLossWarning)
258
nameFirstOutput=self.getReplacementCharacter(nameFirst)
259
else:
260
nameFirstOutput=nameFirst
261
262
nameRestOutput=nameRest
263
replaceChars=set(nonXmlNameBMPRegexp.findall(nameRest))
264
forcharinreplaceChars:
265
266
replacement=self.getReplacementCharacter(char)
267
nameRestOutput=nameRestOutput.replace(char,replacement)
268
returnnameFirstOutput+nameRestOutput