Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore(content-distribution): support newspack_log #196

Merged
merged 2 commits into from
Jan 20, 2025

Conversation

miguelpeixe
Copy link
Member

Support newspack_log so incoming post errors are logged to Newspack's log infrastructure.

Testing

  1. Make sure you have Newspack manager configured
  2. Add the following to line 342 of includes/content-distribution/class-incoming-post.php:
$term = new WP_Error( 'test_error',  'Test error' );
  1. On the same file, add the following to line 312:
$attachment_id = new WP_Error( 'test_error', 'Test error' );
  1. Distribute a post with a featured image and categories/tags
  2. Sync via CLI: wp newspack-network sync-all
  3. Visit logstash and confirm your error is logged with appropriate error code and data

@miguelpeixe miguelpeixe self-assigned this Jan 20, 2025
@miguelpeixe miguelpeixe requested a review from a team as a code owner January 20, 2025 18:59
Copy link
Contributor

@leogermani leogermani left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍

@miguelpeixe miguelpeixe merged commit f1b52ec into trunk Jan 20, 2025
2 of 3 checks passed
@miguelpeixe miguelpeixe deleted the chore/content-distribution-logstash branch January 20, 2025 22:26
Copy link

Hey @miguelpeixe, good job getting this PR merged! 🎉

Now, the needs-changelog label has been added to it.

Please check if this PR needs to be included in the "Upcoming Changes" and "Release Notes" doc. If it doesn't, simply remove the label.

If it does, please add an entry to our shared document, with screenshots and testing instructions if applicable, then remove the label.

Thank you! ❤️

@matticbot
Copy link
Contributor

🎉 This PR is included in version 2.5.0-alpha.1 🎉

The release is available on GitHub release

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants