Commit Graph

105 Commits

Author SHA1 Message Date
github-actions[bot]
f74c8cb23b Deploy e11da61 from main 2026-04-24 08:27:29 +00:00
github-actions[bot]
319aa83117 Deploy 6060aa3 from main 2026-04-16 15:39:08 +00:00
github-actions[bot]
755b71bbde Deploy f57bf15 from main 2026-04-16 15:37:52 +00:00
github-actions[bot]
09fad2e2da Deploy 64e7153 from main 2026-04-16 15:31:27 +00:00
github-actions[bot]
b7ca7d1e49 Deploy 69cb000 from main 2026-04-16 15:23:20 +00:00
github-actions[bot]
27c560477b Deploy 19fea30 from main 2026-04-16 10:02:08 +00:00
github-actions[bot]
4284675a1f Deploy 9e6c566 from main 2026-04-13 01:00:57 +00:00
github-actions[bot]
102104f4dc Deploy b92dc4b from main 2026-04-12 21:22:34 +00:00
github-actions[bot]
5d4e73b947 Deploy 6796121 from main 2026-04-12 10:29:18 +00:00
github-actions[bot]
24d15ca938 Deploy b05913e from main 2026-04-11 14:23:03 +00:00
github-actions[bot]
2e916c12c8 Deploy 71f7a35 from main 2026-04-11 14:01:45 +00:00
github-actions[bot]
ad67ab89e5 Deploy 221a46a from main 2026-04-09 05:34:35 +00:00
github-actions[bot]
759b22ce3b Deploy d78347d from main 2026-04-08 04:53:09 +00:00
github-actions[bot]
95870bfe7b Deploy 44cc4f5 from main 2026-04-08 04:02:57 +00:00
github-actions[bot]
fb12a6a835 Deploy 0a550ca from main 2026-04-08 03:54:21 +00:00
github-actions[bot]
568529fdae Deploy aeceab2 from main 2026-04-08 03:50:13 +00:00
github-actions[bot]
8fe79459de Deploy d6b111f from main 2026-04-08 03:44:32 +00:00
github-actions[bot]
2ee59cab6a Deploy 8fe3d82 from main 2026-04-08 03:38:35 +00:00
github-actions[bot]
722293a8ea Deploy 672cdac from main 2026-04-08 03:27:12 +00:00
github-actions[bot]
260d2b6a1d Deploy 88766d7 from main 2026-04-07 09:43:46 +00:00
github-actions[bot]
3e0565fc83 Deploy e8a45e9 from main 2026-04-07 09:14:49 +00:00
github-actions[bot]
dda0da31e8 Deploy 6c57f6c from main 2026-04-07 08:59:43 +00:00
github-actions[bot]
9fd08b7834 Deploy e1d18ba from main 2026-04-07 08:30:04 +00:00
github-actions[bot]
d0713aa561 Deploy 0cea96f from main 2026-04-07 08:25:15 +00:00
github-actions[bot]
a1a7fe6ea0 Deploy 67f932a from main 2026-04-07 08:22:17 +00:00
github-actions[bot]
d77cff73b3 Deploy 99aa2ca from main 2026-04-07 08:18:48 +00:00
github-actions[bot]
c242f0d59f Deploy 359b001 from main 2026-04-07 08:12:35 +00:00
github-actions[bot]
1e2a973acc Deploy 245b24b from main 2026-04-07 08:04:43 +00:00
github-actions[bot]
526959257f Deploy ab56ec7 from main 2026-04-07 07:59:55 +00:00
github-actions[bot]
8831622d03 Deploy f6629a8 from main 2026-04-07 07:29:44 +00:00
github-actions[bot]
dd36c7fe6e Deploy 8b14e9e from main 2026-04-07 07:22:55 +00:00
github-actions[bot]
a767833036 Deploy c899476 from main 2026-04-07 06:35:07 +00:00
github-actions[bot]
89c7b553b2 Deploy 99ef0c9 from main 2026-04-07 06:20:58 +00:00
github-actions[bot]
9db9bb01c8 Deploy 1ae831e from main 2026-04-07 02:45:50 +00:00
Terence Ong
cd8eee11b8 Replace broken DDG search with AI thumbnail generation fallback
DuckDuckGo's HTML search endpoint now requires vqd session tokens,
making server-side search-based URL resolution unreliable. Simplified
the thumbnail pipeline:

- OG scrape only for non-aggregator URLs (direct publisher pages)
- AI image generation via OpenRouter for aggregator articles (Google News)
- Added Image Model settings field in admin UI
- Added thumbnail_local column for AI-generated images
- Updated public/admin display to check thumbnail_local as fallback
- Removed all DuckDuckGo search code (find_article_url_via_search,
  extract_ddg_url, resolve_article_for_scraping)

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-06 20:29:32 +07:00
Terence Ong
de35f2d684 Fix thumbnail scraping: use search-based URL resolution for Google News articles
Google News RSS stores encrypted article URLs that cannot be resolved
server-side (JS SPA, no HTTP redirects, encrypted base64 IDs). Replace
the failed decode/parse strategies with DuckDuckGo search-based lookup
using article title + publisher name to find actual article pages, then
scrape OG images from those pages.

- Add find_article_url_via_search() using DuckDuckGo HTML endpoint
- Add resolve_article_for_scraping() combining redirect + search fallback
- Mark failed lookups with '_no_image' sentinel to avoid repeated retries
- Backfill button resets sentinels to allow manual re-scraping
- Clean up verbose debug instrumentation from prior attempts
- Update frontend to handle '_no_image' sentinel gracefully

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-06 20:01:25 +07:00
Terence Ong
acf7e61b90 Switch to multi-strategy HTML parsing for Google News URL resolution
Replace batchexecute API with direct fetch + HTML parsing strategies:
data-n-au attributes, anchor href extraction, meta refresh, JS redirect.
Add verbose debug output to diagnose server-side response from Google News.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-06 19:47:10 +07:00
Terence Ong
f828cec229 Use Google batchexecute API to resolve Google News article URLs
Replace broken base64 decoding with Google's internal batchexecute API
endpoint to resolve encrypted article IDs to actual publisher URLs.
This is the approach used by known Google News decoder libraries.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-06 19:42:22 +07:00
Terence Ong
2c09ee4664 Add diagnostic debug output to thumbnail backfill for troubleshooting
Temporary debug version that returns query counts, URL resolution results,
and OG scraping outcomes to identify why thumbnail scraping returns 0.
Also adds Google News URL decoder (base64/protobuf approach).

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-06 19:39:26 +07:00
Terence Ong
5918a7d446 Fix missing thumbnails by resolving Google News redirect URLs before OG scraping
The OG image scraper was using Google News redirect URLs (source_url) directly,
which don't serve og:image tags. Added resolve_scrape_url() to follow redirects
(including meta-refresh and JS redirects) to reach the actual publisher page
before scraping. Also added a backfill AJAX endpoint and admin button to
re-scrape thumbnails for existing articles.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-06 19:32:09 +07:00
Terence Ong
18158a3b81 fix: resolve actual article source instead of showing aggregator domain
Google News RSS feeds report every article as coming from
"news.google.com" because the source was extracted from the feed URL
rather than the individual article. This adds a multi-strategy
resolver that extracts the real publisher name via:

1. SimplePie <source> element (Google News provides this)
2. Title suffix parsing ("Headline - Source" format)
3. HTTP HEAD redirect resolution as a fallback

Also adds a one-click "Fix Article Sources" backfill button on the
settings page to correct existing articles in the database.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-06 19:11:14 +07:00
peptiderepo
9ec67591bd Merge pull request #1 from peptiderepo/feature/list-layout
feat: switch article display from grid to list layout
2026-04-06 18:58:58 +07:00
Peptide News Team
aad57424c9 fix: add focus states for keyboard a11y and guard empty excerpt
Addresses QA Agent 2 findings:
- Add :focus outline on title and thumbnail links for keyboard navigation
- Wrap excerpt paragraph in conditional to avoid empty <p> when both
  ai_summary and excerpt are missing

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-06 18:55:22 +07:00
Peptide News Team
203aa46036 feat: switch article display from grid to list layout
Rewrites public CSS to match actual .pn-* class names from the PHP
template and changes the default shortcode layout from card/grid to a
horizontal list: fixed-width thumbnail on the left, title + summary on
the right.  Includes compact variant for widgets and responsive
stacking on small screens.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-06 18:43:16 +07:00
Peptide News Team
15306ade35 chore: bump version to 1.2.2 — pipeline verification test
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-06 18:28:04 +07:00
Peptide News Team
d99c505d1c Add missing Loader class and public CSS
The Peptide_News_Loader class was referenced by class-peptide-news.php
but never committed, causing a fatal error on plugin activation.
Also adds public/css/public-style.css which is enqueued by the public
class.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-06 16:32:42 +07:00
Terence Ong
0b29059463 fix: use linear history for deploy branch instead of orphan/force-push
Hostinger's git pull fails with divergent branches when force-pushing
orphan commits. Switch to a linear commit strategy: checkout the
existing deploy branch, sync plugin files from main, and push normally.
This keeps Hostinger's git pull fast-forward compatible.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-06 15:14:19 +07:00
Terence Ong
1304d205fa refactor: switch deploy to Hostinger GIT pull-based strategy
Replace broken SCP/SSH deploy (blocked by Hostinger firewall) with a
deploy-branch strategy. After CI passes, GitHub Actions pushes only
plugin files to the 'deploy' branch. Hostinger's built-in GIT
integration watches this branch via webhook and auto-pulls.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-06 15:06:18 +07:00
Terence Ong
61d06c10c4 Switch deploy from FTP to SSH/SCP for Hostinger compatibility
FTP deploy timed out due to Hostinger blocking FTPS from external CI
servers. Switched to appleboy/scp-action using SSH on port 65002,
which is more reliable for CI/CD pipelines.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-06 14:48:50 +07:00
Terence Ong
b9d14cbb59 Add workflow_call trigger to CI for reusable workflow support
The deploy workflow references CI via `uses: ./.github/workflows/ci.yml`
which requires the CI workflow to have an `on: workflow_call` trigger.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-06 14:35:27 +07:00