gitbutlerapp/gitbutler · error · anyhow::Error
Reactions for forge {forge:?} are not implemented yet.
Error message
Reactions for forge {forge:?} are not implemented yet. What it means
`add_review_reaction()` adds the caller's reaction (e.g. an emoji) to the review itself. Only GitHub is implemented (via `but_github::pr::add_review_reaction`, mapped through `github_reaction`); GitLab, Bitbucket and Azure hit the wildcard arm and fail before any network call.
Source
Thrown at crates/but-forge/src/review.rs:1554
) -> Result<ForgeReviewReaction> {
let crate::forge::ForgeRepoInfo {
forge, owner, repo, ..
} = forge_repo_info;
match forge {
ForgeName::GitHub => {
let preferred_account = preferred_forge_user.as_ref().and_then(|user| user.github());
let reaction = but_github::pr::add_review_reaction(
preferred_account,
owner,
repo,
review_number,
kind,
storage,
)
.await?;
Ok(github_reaction(reaction))
}
_ => Err(anyhow::anyhow!(
"Reactions for forge {forge:?} are not implemented yet."
)),
}
}
/// Remove one of the caller's reactions from the review itself.
pub async fn remove_review_reaction(
preferred_forge_user: &Option<crate::ForgeUser>,
forge_repo_info: &crate::forge::ForgeRepoInfo,
review_number: usize,
reaction_id: i64,
storage: &but_forge_storage::Controller,
) -> Result<()> {
let crate::forge::ForgeRepoInfo {
forge, owner, repo, ..
} = forge_repo_info;
match forge {
ForgeName::GitHub => {View on GitHub (pinned to caf1f223d3)
Solutions
- Use the forge's native reactions API/UI for non-GitHub reviews.
- Hide reaction buttons for non-GitHub reviews.
- Implement reaction backends in `but_gitlab`/`but_bitbucket` and extend the match at crates/but-forge/src/review.rs:1546-1554.
Example fix
// before
add_review_reaction(&user, &info, number, "heart", &storage).await?;
// after
if !matches!(info.forge, ForgeName::GitHub) {
return Ok(Default::default()); // reactions are GitHub-only; hide the button
}
add_review_reaction(&user, &info, number, "heart", &storage).await?; Defensive patterns
Strategy: validation
Validate before calling
use but_forge::forge::ForgeName;
if !matches!(info.forge, ForgeName::GitHub) {
// hide reaction buttons on the review header
} Type guard
fn review_reactions_supported(forge: &but_forge::forge::ForgeName) -> bool {
matches!(forge, ForgeName::GitHub)
} Try / catch
match add_review_reaction(&user, &info, number, kind, &storage).await {
Ok(r) => r,
Err(e) if e.to_string().contains("not implemented yet") => { /* don't toggle emoji state */ return Ok(Default::default()); }
Err(e) => return Err(e),
} Prevention
- Gate all four reaction operations (add/remove x review/comment) behind one forge capability check.
- Don't optimistically render the reaction before the forge confirms.
- Use one 'reactions supported' flag rather than per-button checks to avoid drift.
When it happens
Trigger: Reacting to a PR/MR whose `ForgeRepoInfo.forge` is GitLab, Bitbucket or Azure — e.g. the emoji button on the review header of a non-GitHub review.
Common situations: Reaction UIs enabled for every forge; GitHub-parity assumptions in shared components; SDK integrations that toggle reactions programmatically.
Related errors
- Repository labels for forge {forge:?} are not implemented ye
- Review labels for forge {forge:?} are not implemented yet.
- Reviewer candidates for forge {forge:?} are not implemented
- Review requests for forge {forge:?} are not implemented yet.
- Review comments for forge {forge:?} are not implemented yet.
AI-assisted analysis of gitbutlerapp/gitbutler@caf1f223d3 (2026-08-20).
Data as JSON: /api/errors/383d44d98bf39dcd.
Report an issue: GitHub.