Fix: Allow Re-adding Deleted Team Members (Bug #73) & Modernize Build System
Description
This PR modernizes the Gradle build system to fix a critical error with BuildConfig class generation, while maintaining compatibility with existing devices. It also fixes bug #73 which prevented re-adding deleted team members.
Major changes
-
Fixed BuildConfig generation: Resolved the "cannot find symbol BuildConfig" error by adding the explicit
buildConfig trueflag and proper namespace configuration, which is required by newer Android Gradle Plugin versions -
Upgraded build tools:
- Gradle: 4.8.1 → 8.11.1
- Android Gradle Plugin: 3.1.3 → 8.9.1
- Gradle Versions Plugin: 0.20.0 → 0.51.0
-
Updated compilation environment:
- Increased compileSdkVersion from 27 to 35 while maintaining targetSdkVersion at 27
- This approach allows us to use modern build tools without requiring runtime compatibility with newer Android versions
-
Repository migrations:
- Replaced jcenter() with mavenCentral() as JCenter is now sunset
- Added proper repository declarations to ensure all dependencies can be resolved
-
Build performance improvements:
- Added JVM memory settings to improve build speed
- Fixed resource handling with android.nonFinalResIds=false to prevent build errors
-
Bug fix #73: Fixed the issue preventing re-adding deleted members
- The validation query now properly checks for non-deleted members only
- This allows users to re-add previously deleted members to teams
Why these changes are necessary
The app was failing to build due to missing BuildConfig class, which is essential for AboutActivity and other components. Modern AGP requires explicit configuration for BuildConfig generation which these changes provide.
These updates ensure compatibility with newer Android Studio versions and development environments while maintaining the same runtime behavior and device compatibility as before.
The bug fix addresses user frustration when trying to re-add previously deleted team members, improving the overall user experience.
Screenshots
Initial team screen
On deleting Ashley from team a
On re-adding Ashley you can see it doesn't give the error that team member already exists
When trying to add the same member again it gives error, thus no functionality is compromised
Quality checklist
- [x] Self review: I have reviewed this PR myself before opening it for review.
- [x] Tests I have done:
- Built and verified BuildConfig is properly generated
- Run the app on devices with API 27 to confirm runtime behavior is unchanged
- Verified all existing functionality works with updated build system
- Verified that deleted members can now be re-added to teams
- Confirmed backward compatibility with existing installation base