Skip to content

Feat/parsing#8

Draft
AlexAxthelm wants to merge 7 commits into
mainfrom
feat/parsing
Draft

Feat/parsing#8
AlexAxthelm wants to merge 7 commits into
mainfrom
feat/parsing

Conversation

@AlexAxthelm

Copy link
Copy Markdown
Owner

Add feed parsing utilities

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

Adds end-to-end feed import support: a new HTTP capability fetches an RSS feed in the iOS shell, Rust parses it into Subscription + Episode records, and the iOS database upserts the feed and episodes while preserving existing IDs on refresh.

Changes:

  • Introduces an HttpOperation/HttpResult capability and wires it through the Rust effect system and iOS Core.
  • Adds parse_feed utility (feed-rs) and a new storage op to upsert a subscription and its episodes together.
  • Updates iOS UI to accept a feed URL and display errors; adds DB tests for the new upsert behavior.

Reviewed changes

Copilot reviewed 15 out of 16 changed files in this pull request and generated 4 comments.

Show a summary per file
File Description
shared/src/model.rs Tracks current feed fetch state via fetching_feed.
shared/src/lib.rs Registers feed_parser module and re-exports HTTP capability types.
shared/src/feed_parser.rs New RSS parsing utility producing Subscription + Episodes.
shared/src/effect.rs Adds Http to the Crux effect enum.
shared/src/capabilities/storage.rs Adds UpsertFeedWithEpisodes operation.
shared/src/capabilities/mod.rs Exposes new http capability module.
shared/src/capabilities/http.rs Defines FetchFeed operation and HttpResult output.
shared/src/app.rs Adds fetch/parse/save events plus tests for the new flow.
shared/Cargo.toml Adds feed-rs and uuid dependencies.
iOS/project.yml Adds UILaunchScreen property config.
iOS/PolluxTests/DatabaseManagerTests.swift Adds tests covering upsertFeedWithEpisodes behavior.
iOS/Pollux/Info.plist Adds UILaunchScreen key.
iOS/Pollux/DatabaseManager.swift Implements upsertFeedWithEpisodes in SQLite via GRDB.
iOS/Pollux/core.swift Adds HTTP effect handling and result resolution for HttpResult.
iOS/Pollux/ContentView.swift Adds feed URL input UI and displays errors.
Cargo.lock Locks new transitive deps for feed parsing + uuid.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread shared/src/app.rs
Comment thread iOS/Pollux/core.swift
Comment thread iOS/Pollux/DatabaseManager.swift Outdated
Comment thread iOS/Pollux/ContentView.swift Outdated

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 15 out of 16 changed files in this pull request and generated 1 comment.

Comment thread shared/src/app.rs
Comment on lines +87 to +95
StorageResult::Subscription(sub) => {
if let Some(pos) = model.subscriptions.iter().position(|s| s.id == sub.id) {
model.subscriptions[pos] = sub;
} else {
model.subscriptions.push(sub);
model.subscriptions.sort_by_key(|a| a.title.to_lowercase());
}
model.error = None;
}
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.

2 participants