Fix Dracula MissingDefaultResource lint errors (unblocks release build)#49
Conversation
…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.
|
Warning Review limit reached
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 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 configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (1)
Comment |
Summary
Fixes the 3
MissingDefaultResourcelint errors that blockassembleOssRelease(surfacedwhile validating release signing in #48).
Problem
dracula_background,dracula_surface, anddracula_on_surfacewere declared only invalues-night/colors.xml. Android lint'sMissingDefaultResourceflags this as fatal for arelease 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.xmlfor the three colors, using the same dark Draculapalette 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_draculapattern (base + night).Testing
./gradlew :app:lintVitalOssRelease— BUILD SUCCESSFUL (previously failed with 3MissingDefaultResource errors).
./gradlew :app:assembleOssRelease(lint + signing) — BUILD SUCCESSFUL, APK signed withthe 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) tovalues/colors.xml, resolvingMissingDefaultResourcelint errors that were blockingassembleOssRelease.#282A36,#343746,#F8F8F2) exactly match their counterparts already present invalues-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.card_elevated_draculapattern (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
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]%%{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]Reviews (1): Last reviewed commit: "fix(theme): declare Dracula canvas color..." | Re-trigger Greptile