Skip to main content

Troubleshooting

Panduan mengatasi masalah umum dalam development MStore Mobile.

🔧 Build Issues

Flutter Build Errors

Error: “Gradle build failed”

Gejala:
Solusi:

Error: “Pod install failed”

Gejala:
Solusi:

Error: “Native Sound Plugin not found”

Gejala:
Solusi:

Code Generation Issues

Error: “Conflicting outputs”

Gejala:
Solusi:

Error: “Part file doesn’t exist”

Gejala:
Solusi:

🌐 Network Issues

API Connection Failed

Gejala:
Debugging:
Solusi:
  1. Verify .env file loaded correctly
  2. Check network connection
  3. Verify API server is running
  4. Check firewall/proxy settings

Token Refresh Failed

Gejala:
Solusi:

MQTT Connection Failed

Gejala:
Debugging:
Solusi:
  1. Verify MQTT broker URL and port
  2. Check credentials
  3. Ensure network allows MQTT port (usually 1883)
  4. Check broker is running

💾 Database Issues

Isar Database Errors

Error: “Isar instance already opened”

Gejala:
Solusi:

Error: “Schema mismatch”

Gejala:
Solusi:

Data Not Syncing

Debugging:
Solusi:
  1. Verify network connection
  2. Check API endpoints
  3. Review sync logic in OfflineSyncService
  4. Clear local cache and re-sync

🎨 UI Issues

Widget Not Rebuilding

Gejala: UI tidak update setelah state berubah. Debugging:
Solusi:
  1. Ensure state implements Equatable properly
  2. Check buildWhen condition
  3. Verify BLoC is provided correctly
  4. Use BlocConsumer if needed

Layout Overflow

Gejala:
Solusi:

Performance Issues

Gejala: UI terasa lag atau jank. Debugging:
Solusi:
  1. Use const constructors
  2. Avoid rebuilding entire tree
  3. Use ListView.builder for long lists
  4. Optimize images (use cached_network_image)
  5. Profile with Flutter DevTools

🔐 Authentication Issues

Login Failed

Gejala:
Debugging:
Solusi:
  1. Verify email/password correct
  2. Check API endpoint URL
  3. Review backend logs
  4. Test with Postman/curl

Token Expired

Gejala:
Solusi:

🖨️ Printer Issues

Bluetooth Printer Not Found

Gejala:
Solusi:
Gejala: Receipt tidak tercetak. Debugging:
Solusi:
  1. Verify printer is paired and connected
  2. Check printer has paper
  3. Verify receipt format
  4. Test with simple text first

📱 Platform-Specific Issues

iOS Issues

Error: “Signing for … requires a development team”

Solusi:
  1. Open Xcode
  2. Select project → Signing & Capabilities
  3. Select your team
  4. Enable “Automatically manage signing”

Error: “Module not found”

Solusi:

Android Issues

Error: “Minimum SDK version”

Gejala:
Solusi:

Error: “MultiDex”

Solusi:

🔍 Debugging Tools

Flutter DevTools

Logging

Network Inspector

🆘 Getting Help

Before Asking for Help

  1. ✅ Check this troubleshooting guide
  2. ✅ Search existing issues
  3. ✅ Review logs and error messages
  4. ✅ Try to reproduce the issue
  5. ✅ Prepare minimal reproduction code

Creating a Bug Report

[Paste relevant logs here]

Useful Commands

📚 Additional Resources

Next Steps


Jika masalah masih berlanjut:
  • 💬 Hubungi tim development
  • 📧 Buat issue di repository
  • 🔍 Review dengan senior developer