mganss / HtmlSanitizer

Cleans HTML to avoid XSS attacks
MIT License
1.51k stars 198 forks source link

Unable to load assembly AngleSharp Version 0.17.0 when HtmlSanitizer Initialized #549

Closed dutchaussie closed 3 weeks ago

dutchaussie commented 1 month ago

image

I am using .net 4.8 Framework running on Windows 10. Using VS2022 Community Edition - version 17.9.6

Have looked for any other projects in my solution that would reference Version 0.17.0 of AngleSharp but did not find. I have followed all manner of instructions from copilot to resolve this issue, but to no avail. Version 0.17.0 of AngleSharp does not even exist as such.

tiesont commented 1 month ago

Should probably check existing issues. See #544 and #528.

Basically: AngleSharp.Css has a hard dependency/reference on AngleSharp 0.17.0, but HtmlSanitizer references AngleSharp 0.17.1. Adding a binding redirect will solve the reference error.