[PR #128] [MERGED] Fix remove_account() missing provider parameter #125

Closed
opened 2026-03-02 04:06:54 +03:00 by kerem · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/FujiwaraChoki/MoneyPrinterV2/pull/128
Author: @FujiwaraChoki
Created: 2/26/2026
Status: Merged
Merged: 2/26/2026
Merged by: @FujiwaraChoki

Base: mainHead: fix/remove-account-missing-provider


📝 Commits (2)

  • 8b9f0b0 Fix remove_account() missing provider parameter and hardcoded cache path
  • d5a4605 Add CLI account deletion flow and provider-safe cache handling

📊 Changes

2 files changed (+86 additions, -32 deletions)

View changed files

📝 src/cache.py (+38 -30)
📝 src/main.py (+48 -2)

📄 Description

Summary

  • remove_account() called get_accounts() without the required provider parameter, causing an immediate TypeError on any call.
  • Even if it didn't crash, the function hardcoded get_twitter_cache_path(), so removing a YouTube account would have written to the Twitter cache file instead — corrupting it.
  • Added a provider parameter and cache path branching to match the pattern already used by add_account().

Test plan

  • Call remove_account("twitter", account_id) — verify the account is removed from the Twitter cache
  • Call remove_account("youtube", account_id) — verify the account is removed from the YouTube cache
  • Verify remaining accounts in each cache are unaffected after removal

🤖 Generated with Claude Code


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/FujiwaraChoki/MoneyPrinterV2/pull/128 **Author:** [@FujiwaraChoki](https://github.com/FujiwaraChoki) **Created:** 2/26/2026 **Status:** ✅ Merged **Merged:** 2/26/2026 **Merged by:** [@FujiwaraChoki](https://github.com/FujiwaraChoki) **Base:** `main` ← **Head:** `fix/remove-account-missing-provider` --- ### 📝 Commits (2) - [`8b9f0b0`](https://github.com/FujiwaraChoki/MoneyPrinterV2/commit/8b9f0b0e754bc6b8d4965cde76acbca66e7cea60) Fix remove_account() missing provider parameter and hardcoded cache path - [`d5a4605`](https://github.com/FujiwaraChoki/MoneyPrinterV2/commit/d5a4605fd9efac8eba26459ef4e1130e9c0e03ac) Add CLI account deletion flow and provider-safe cache handling ### 📊 Changes **2 files changed** (+86 additions, -32 deletions) <details> <summary>View changed files</summary> 📝 `src/cache.py` (+38 -30) 📝 `src/main.py` (+48 -2) </details> ### 📄 Description ## Summary - `remove_account()` called `get_accounts()` without the required `provider` parameter, causing an immediate `TypeError` on any call. - Even if it didn't crash, the function hardcoded `get_twitter_cache_path()`, so removing a YouTube account would have written to the Twitter cache file instead — corrupting it. - Added a `provider` parameter and cache path branching to match the pattern already used by `add_account()`. ## Test plan - [x] Call `remove_account("twitter", account_id)` — verify the account is removed from the Twitter cache - [x] Call `remove_account("youtube", account_id)` — verify the account is removed from the YouTube cache - [x] Verify remaining accounts in each cache are unaffected after removal 🤖 Generated with [Claude Code](https://claude.com/claude-code) --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
kerem 2026-03-02 04:06:54 +03:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/MoneyPrinterV2#125
No description provided.