FlutterArtist Log Viewer
FlutterArtist LogViewer is a tool that allows users to review previously displayed application errors or warnings via SnackBar. This tool is beneficial for both end-users and developers.

The Logger system in FlutterArtist is more than just a logging tool; it acts as the application's "black box". Allowing end-users to access the LogViewer is a breakthrough step, significantly reducing communication time between support teams and users when issues arise. Instead of describing errors verbally, users can simply screenshot the LogViewer, complete with the full StackTrace and ErrorInfo.
- FlutterArtist Rest Debug Viewer
- FlutterArtist Debug Filter Model Viewer
- FlutterArtist Debug Form Model Viewer
- FlutterArtist Debug Filter Criteria Viewer
1. LogViewer
Once the application has at least one recorded Log entry, you can access this feature from the DebugMenu dropdown (typically located in the top-right corner of the application).


You can also open the LogViewer via code:
bool hasLogs = FlutterArtist.logger.hasLogEntries();
if(hasLogs) {
await FlutterArtist.showLogViewerDialog();
}No ADS
Note: By default, the Logger only stores up to 20 LogEntries; older LogEntries will be discarded. However, you can specify a different value using the FlutterArtist.config() method called in main.dart.main.dart (*)await FlutterArtist.config( maxStoredLogEntryCount: 20, ... );
- FlutterArtist Starter (***)

recentErrorCount | The number of errors occurring since the last time the Log Viewer was opened. This value will be reset to 0 immediately after the user closes the Log Viewer Dialog. |
recentWarningCount | The number of warnings occurring since the last time the Log Viewer was opened. This value will be reset to 0 immediately after the user closes the Log Viewer Dialog. |
totalErrorCount | The total number of error occurrences |
totalWarningCount | The total number of warning occurrences. |
Accessing Log Info via Code
void printLogInfo() {
Logger logger = FlutterArtist.logger;
print("hasRecentLogEntries: ${logger.hasRecentLogEntries}");
print("recentErrorCount ${logger.recentErrorCount}");
print("recentWarningCount ${logger.recentWarningCount}");
print("totalErrorCount ${logger.totalErrorCount}");
print("totalWarningCount ${logger.totalWarningCount}");
for (LogEntry logEntry in logger.logEntries) {
// error, warning,..
print("logEntry.logEntryType: ${logEntry.logEntryType}");
if (logEntry.logEntryType == LogEntryType.error) {
ErrorInfo errorInfo = logEntry.errorInfo as ErrorInfo;
print("errorInfo.errorMessage: ${errorInfo.errorMessage}");
print("errorInfo.errorDetails: ${errorInfo.errorDetails}");
print("StackTrace:\n ${errorInfo.stackTrace}");
}
//
else if (logEntry.logEntryType == LogEntryType.warning) {
WarningInfo warningInfo = logEntry.warningInfo as WarningInfo;
print("warningInfo.errorMessage: ${warningInfo.warningMessage}");
}
}
}DebugMenu is a built-in class in the flutter_artist library that allows you to create a button. When the user clicks this button, a dropdown menu will appear containing various standard FlutterArtist debugging functions. This article guides you on how to add this menu to your application.
No ADS
FlutterArtist
- Basic concepts in Flutter Artist
- FlutterArtist Block ex1
- FlutterArtist Filter Example
- FlutterArtist FilterModel MultiOptFilterCriterion ex1
- FlutterArtist FilterInput Example 1
- FlutterArtist Form ex1
- The idea of designing filter models in FlutterArtist
- FlutterArtist FormModel.patchFormFields() Ex1
- FlutterArtist BlockQuickItemUpdateAction Example
- FlutterArtist BlockNumberPagination Ex1
- FlutterArtist GridView Infinite Scroll Example
- FlutterArtist BlockQuickMultiItemCreationAction Example
- FlutterArtist ListView Infinite Scroll Pagination Example
- FlutterArtist Pagination
- FlutterArtist Sort DropdownSortPanel Example
- FlutterArtist Dio
- FlutterArtist BlockBackendAction Example
- FlutterArtist BackgroundWebDownloadAction Example
- FlutterArtist StorageBackendAction ex1
- FlutterArtist Block External Shelf Event ex1
- FlutterArtist Filter FormBuilderMultiDropDown Ex1
- FlutterArtist Master-detail Blocks ex1
- FlutterArtist Scalar ex1
- FlutterArtist Pagination Davi table Infinite Scroll Ex1
- FlutterArtist Filter Tree FormBuilderField ex1
- FlutterArtist Filter FormBuilderRadioGroup ex1
- FlutterArtist Form Parent-child MultiOptFormProp ex1
- FlutterArtist Manual Sorting ReorderableGridView Example
- FlutterArtist Manual Sorting ReorderableListView
- FlutterArtist Scalar External Shelf Event ex1
- FlutterArtist Code Flow Viewer
- FlutterArtist Log Viewer
- FlutterArtist config
- FlutterArtist StorageStructure
- FlutterArtist Debug Storage Viewer
- FlutterArtist DebugMenu
- FlutterArtist Debug UI Components Viewer
- FlutterArtist Debug Shelf Structure Viewer
- FlutterArtist Context Provider Views
- FlutterArtist FilterModelStructure ex1
- FlutterArtist FilterModelStructure ex2
- FlutterArtist FilterModelStructure ex3
- FlutterArtist Internal Shelf Event ex1
- FlutterArtist Deferring External Shelf Events (Ex1)
- FlutterArtist DropdownSortPanel
Show More
