Skip to content

Conversation

@Alkarex
Copy link
Member

@Alkarex Alkarex commented Jan 18, 2026

jtojnar and others added 3 commits January 18, 2026 09:16
Currently, we only use these to test code paths that do not involve parsing
but it would be nice to be able to reuse the tests for other simple tests.

Unfortunately, `Parser::parse` will actually fail with `error_string == "Unknown"`.

That is because `xml_get_error_code()` returns 201, which is not one of XML_ERROR_* codes:
https://www.php.net/manual/en/xml.error-codes.php

It looks like it is actually `XML_NS_ERR_UNDEFINED_NAMESPACE` leaking from libxml2.
I can confirm it with `libxml_use_internal_errors(true);` and dumping `libxml_get_errors()`:

    Namespace prefix media on thumbnail is not defined

Since we never use it anywhere, we can just drop the element.
- Improve typing and fix issues that will trip up PHPStan 2.0.
- Fix insufficient regex escaping in `SimplePie::get_links()`.
- Add editor config for .neon files.
- Add PHPStan results cache to .gitignore.
- Check our PHPStan extension.
- Use `assertNull` in tests instead of `assertSame`.
@Alkarex Alkarex merged commit dbcf155 into freshrss Jan 18, 2026
20 checks passed
@Alkarex Alkarex deleted the merge-upstream20260118 branch January 18, 2026 11:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants