An interesting Android software exception statistics, and an interesting Android software Statistics
Statistical background:
To improve the coding quality, submit the bugs that occur during software development to your personal website, end the year, and make statistics for them.
Statistical items: one online project, three development projects, and one private project
Project developers: Author and five colleagues
Project themes: e-commerce and System Applications
Information Collection Date: 20:37:54 (capture the first exception) to 00:19:36 (last exception submission time during statistics)
Number of exceptions: 3192
Exception information collected by the database:
Exception statistics SQL:
SELECT (SELECT count (Id) From t_apperror WHERE Context LIKE '% Exception: cannot?mthisactionafteronsaveinstancestate %')/(SELECT count (ID) From t_apperror) as 'framage hiding failed'/** 0.0047 **/SELECT (SELECT count (Id) From t_apperror WHERE Context LIKE '% Exception: syntaxerror %')/(SELECT count (ID) from t_apperror) as 'syntaxerror'/** 0.0119 **/SELECT (SELECT count (Id) From t_apperror WHERE Context LIKE '% Stringcannotbecastto %')/(SELECT count (ID) from t_apperror) as 'string transformation error (most switched to json) '/** 0.0103 **/SELECT (SELECT count (Id) From t_apperror WHERE Context LIKE 'exception: Invalidint % ') /(SELECT count (ID) From t_apperror) as 'json parsing error'/** 0.0229 **/SELECT (SELECT count (Id) From t_apperror WHERE Context LIKE '% Exception: null _ % ')/(SELECT count (ID) From t_apperror) + (SELECT count (Id) From t_apperror WHERE Context LIKE' % Exception: java. lang. nullPointer % ')/(SELECT count (ID) From t_apperror) as "Null Pointer"/* 0.3932 **/SELECT (SELECT count (ID) from t_apperror WHERE Context LIKE 'exception: Fragmentalreadyadded % ')/(SELECT count (ID) From t_apperror) as 'exception: fragmentalreadyadded '/** 0.0063 **/SELECT (SELECT count (ID) From t_apperror WHERE Context LIKE 'exception: Unabletoaddwindow %')/(SELECT count (ID) From t_apperror) as 'exception: unabletoaddwindow'/** 0.1263 **/SELECT (SELECT count (ID) From t_apperror WHERE Context LIKE 'exception: Unabletodestroyactivity % ')/(SELECT count (ID) from t_apperror) as 'unabletodestroyactive'/** 0.0276 **/SELECT (SELECT count (ID) From t_apperror WHERE Context LIKE 'exception: BinaryXMLfile % ')/(SELECT count (ID) from t_apperror) as 'xml layout error'/** 0.0053 **/SELECT (SELECT count (ID) From t_apperror WHERE Context LIKE 'exception: Invalidindex % ') /(SELECT count (ID) From t_apperror) as "exceeds Index"/** 0.0103 **/
Statistical results:
Statistical conclusion:
1. NULL pointer errors are the most common.
2. the compiler will be silly, and binaryxml and syntaxerror errors will occur.
3. There are many fragment errors in coding, which may be caused by insufficient understanding of fragment.
The above statistics are not comprehensive and are for reference only.