Skip to content

Fix Dracula MissingDefaultResource lint errors (unblocks release build)#49

Merged
hawkff merged 1 commit into
mainfrom
fix/dracula-missing-default-resource
Jun 20, 2026
Merged

Fix Dracula MissingDefaultResource lint errors (unblocks release build)#49
hawkff merged 1 commit into
mainfrom
fix/dracula-missing-default-resource

Conversation

@hawkff

@hawkff hawkff commented Jun 20, 2026

Copy link
Copy Markdown
Owner

Summary

Fixes the 3 MissingDefaultResource lint errors that block assembleOssRelease (surfaced
while validating release signing in #48).

Problem

dracula_background, dracula_surface, and dracula_on_surface were declared only in
values-night/colors.xml. Android lint's MissingDefaultResource flags this as fatal for a
release build: the color could be queried in a non-night configuration where it has no
declaration, leading to a crash.

Fix

Add base declarations in values/colors.xml for the three colors, using the same dark Dracula
palette as the night values. The Dracula theme forces night mode on (so the night values are
what render in practice), but the base declarations guarantee the resources always resolve —
matching the existing card_elevated_dracula pattern (base + night).

Testing

  • CodeRabbit CLI: No findings.
  • ./gradlew :app:lintVitalOssReleaseBUILD SUCCESSFUL (previously failed with 3
    MissingDefaultResource errors).
  • ./gradlew :app:assembleOssRelease (lint + signing) — BUILD SUCCESSFUL, APK signed with
    the release key. Release builds are now fully functional end-to-end.

Greptile Summary

This PR adds base-configuration declarations for three Dracula theme color resources (dracula_background, dracula_surface, dracula_on_surface) to values/colors.xml, resolving MissingDefaultResource lint errors that were blocking assembleOssRelease.

  • The added hex values (#282A36, #343746, #F8F8F2) exactly match their counterparts already present in values-night/colors.xml, so there is no visual regression — the Dracula theme forces night mode on, meaning the night-qualified values are what actually render.
  • The approach mirrors the pre-existing card_elevated_dracula pattern (base declaration + night override) and is accompanied by a clear inline comment explaining the intent.

Confidence Score: 5/5

Safe to merge — the change is a minimal, targeted addition of three color fallbacks with no logic changes and no visual side effects.

The three added hex values are identical to the night-qualified values already in values-night/colors.xml, so they introduce no visual difference at runtime (Dracula always runs in night mode). The change follows the established card_elevated_dracula pattern and is well-commented. There are no functional code changes, no theme logic alterations, and the lint issue it fixes was verified with the actual release build task.

No files require special attention.

Important Files Changed

Filename Overview
app/src/main/res/values/colors.xml Adds base declarations for dracula_background, dracula_surface, and dracula_on_surface with the same dark Dracula hex values as values-night/colors.xml, fixing MissingDefaultResource lint errors that blocked release builds.

Flowchart

%%{init: {'theme': 'neutral'}}%%
flowchart TD
    A[Android Resource Resolution] --> B{Night mode active?}
    B -->|Yes| C[values-night/colors.xml\ndracula_background #282A36\ndracula_surface #343746\ndracula_on_surface #F8F8F2]
    B -->|No| D[values/colors.xml\ndracula_background #282A36\ndracula_surface #343746\ndracula_on_surface #F8F8F2]
    C --> E[Dracula Theme renders correctly]
    D --> E
    E --> F[No MissingDefaultResource crash]
Loading
%%{init: {'theme': 'base', 'themeVariables': {"darkMode": true, "background": "#0d1117", "primaryColor": "#21262d", "primaryTextColor": "#e6edf3", "primaryBorderColor": "#8b949e", "lineColor": "#8b949e", "textColor": "#e6edf3", "edgeLabelBackground": "#161b22", "actorBkg": "#21262d", "actorBorder": "#8b949e", "actorTextColor": "#e6edf3", "actorLineColor": "#8b949e", "signalColor": "#8b949e", "signalTextColor": "#e6edf3", "noteBkgColor": "#373320", "noteBorderColor": "#d4a72c", "noteTextColor": "#f0e6c0", "labelBoxBkgColor": "#21262d", "labelBoxBorderColor": "#8b949e", "labelTextColor": "#e6edf3", "loopTextColor": "#e6edf3", "activationBkgColor": "#30363d", "activationBorderColor": "#8b949e"}}}%%
flowchart TD
    A[Android Resource Resolution] --> B{Night mode active?}
    B -->|Yes| C[values-night/colors.xml\ndracula_background #282A36\ndracula_surface #343746\ndracula_on_surface #F8F8F2]
    B -->|No| D[values/colors.xml\ndracula_background #282A36\ndracula_surface #343746\ndracula_on_surface #F8F8F2]
    C --> E[Dracula Theme renders correctly]
    D --> E
    E --> F[No MissingDefaultResource crash]
Loading

Reviews (1): Last reviewed commit: "fix(theme): declare Dracula canvas color..." | Re-trigger Greptile

…ultResource)

dracula_background / dracula_surface / dracula_on_surface existed only in
values-night, so release lint failed with MissingDefaultResource (the colors could
be queried in a non-night configuration and crash). Add base declarations using the
same dark Dracula palette (the Dracula theme forces night mode, so these are a
correctness fallback). Fixes the 3 lint errors that blocked assembleOssRelease;
verified full assembleOssRelease now passes lint + signs.
@coderabbitai

coderabbitai Bot commented Jun 20, 2026

Copy link
Copy Markdown

Warning

Review limit reached

@hawkff, we couldn't start this review because you've reached your PR review rate limit.

More reviews will be available in 23 minutes and 5 seconds. Learn how PR review limits work.

Your organization has used up its prepaid credits, and credit purchases are no longer available. Enable the review add-on in the billing tab to keep reviews running — you're only billed for reviews past your plan's rate limits ($0.25/file).

⌛ How to resolve this issue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based credits.

🚦 How do rate limits work?

CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan refill rate.

For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, the refill rate gradually slows as usage increases. The highest same-day bursts are limited more strictly.

Please see our Fair Usage Limits Policy for further information.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 23c549a7-fda2-4624-a96d-4c9d0952e34e

📥 Commits

Reviewing files that changed from the base of the PR and between d0c3b1d and 7516913.

📒 Files selected for processing (1)
  • app/src/main/res/values/colors.xml

Comment @coderabbitai help to get the list of available commands and usage tips.

@hawkff hawkff merged commit ed61a81 into main Jun 20, 2026
5 checks passed
@hawkff hawkff deleted the fix/dracula-missing-default-resource branch June 20, 2026 22:55
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.

1 participant