Title: PHP 8 &#8211; Uncaught ArgumentCountError: libxml_clear_errors()
Last modified: February 2, 2021

---

# PHP 8 – Uncaught ArgumentCountError: libxml_clear_errors()

 *  Resolved [Daniel Hendricks](https://wordpress.org/support/users/hendridm/)
 * (@hendridm)
 * [5 years, 4 months ago](https://wordpress.org/support/topic/php-8-uncaught-argumentcounterror-libxml_clear_errors/)
 * FYI – I’m in the process of updating my sites to PHP 8, and I noticed that Publish
   to Apple News is throwing an error:
 *     ```
       2021/02/01 10:17:07 [error] 22#22: *40706 FastCGI sent in stderr: "PHP message: PHP Fatal error:  Uncaught ArgumentCountError: libxml_clear_errors() expects exactly 0 arguments, 1 given in /var/www/****/wp-content/plugins/publish-to-apple-news/includes/apple-exporter/class-exporter-content.php:231
       Stack trace:
       #0 /var/www/****/wp-content/plugins/publish-to-apple-news/includes/apple-exporter/class-exporter-content.php(231): libxml_clear_errors()
       #1 /var/www/****/wp-content/plugins/publish-to-apple-news/includes/apple-exporter/builders/class-builder.php(123): Apple_Exporter\Exporter_Content->nodes()
       #2 /var/www/****/wp-content/plugins/publish-to-apple-news/includes/apple-exporter/builders/class-components.php(793): Apple_Exporter\Builders\Builder->content_nodes()
       #3 /var/www/****/wp-content/plugins/publish-to-apple-news/includes/apple-exporter/builders/class-components.php(42): Apple_Exporter\Builders\Components->split_into_components()
       #4 /var/www/****/wp-content/plugins/publish-to-apple-news/includes/apple-exporter/builders/class-builder.php(66): Apple_Exporter\Builders\Components->build()
       #5 /var/www/****/wp-content/plugins/publish-to-apple-news/includes/apple-exporter/class-exporter.php(216): Apple_Exporter\Builders\Builder->to_array()
       #6 /var/www/****/wp-content/plugins/publish-to-apple-news/includes/apple-exporter/class-exporter.php(144): Apple_Exporter\Exporter->generate_json()
       #7 /var/www/****/wp-content/plugins/publish-to-apple-news/admin/apple-actions/index/class-push.php(489): Apple_Exporter\Exporter->generate()
       #8 /var/www/****/wp-content/plugins/publish-to-apple-news/admin/apple-actions/index/class-push.php(235): Apple_Actions\Index\Push->generate_article()
       #9 /var/www/****/wp-content/plugins/publish-to-apple-news/admin/apple-actions/index/class-push.php(92): Apple_Actions\Index\Push->push()
       #10 /var/www/****/wp-content/plugins/publish-to-apple-news/admin/class-admin-apple-post-sync.php(107): Apple_Actions\
       ```
   
 * WordPress 5.6, PHP 8.0.1
 * Thank you,
    Daniel

Viewing 2 replies - 1 through 2 (of 2 total)

 *  Plugin Author [Kevin Fodness](https://wordpress.org/support/users/kevinfodness/)
 * (@kevinfodness)
 * [5 years, 3 months ago](https://wordpress.org/support/topic/php-8-uncaught-argumentcounterror-libxml_clear_errors/#post-14124019)
 * We haven’t tackled PHP 8 compatibility yet, but this is a good suggestion. I’ve
   created a GitHub issue to track progress: [https://github.com/alleyinteractive/apple-news/issues/842](https://github.com/alleyinteractive/apple-news/issues/842)
 * I’ll close this report in favor of the GitHub issue. This specific error will
   be fixed in the forthcoming v2.1.2 hotfix release.
 *  Plugin Author [Kevin Fodness](https://wordpress.org/support/users/kevinfodness/)
 * (@kevinfodness)
 * [5 years, 3 months ago](https://wordpress.org/support/topic/php-8-uncaught-argumentcounterror-libxml_clear_errors/#post-14125644)
 * I just released version 2.1.2, which fixes this immediate issue. We likely have
   additional testing that we need to do for PHP 8, however.

Viewing 2 replies - 1 through 2 (of 2 total)

The topic ‘PHP 8 – Uncaught ArgumentCountError: libxml_clear_errors()’ is closed
to new replies.

 * ![](https://ps.w.org/publish-to-apple-news/assets/icon-256x256.png?rev=3017580)
 * [Publish To Apple News](https://wordpress.org/plugins/publish-to-apple-news/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/publish-to-apple-news/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/publish-to-apple-news/)
 * [Active Topics](https://wordpress.org/support/plugin/publish-to-apple-news/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/publish-to-apple-news/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/publish-to-apple-news/reviews/)

## Tags

 * [Apple News](https://wordpress.org/support/topic-tag/apple-news/)

 * 2 replies
 * 2 participants
 * Last reply from: [Kevin Fodness](https://wordpress.org/support/users/kevinfodness/)
 * Last activity: [5 years, 3 months ago](https://wordpress.org/support/topic/php-8-uncaught-argumentcounterror-libxml_clear_errors/#post-14125644)
 * Status: resolved