Convert mobileInstall to artifact_processor (LAVA, context form); 729 lines -> 4 functions#1564
Merged
Conversation
… -> 4 functions The big pre-iOS-17 mobile_installation.log parser. Was a single old-style function building 6 HTML reports via a temp SQLite db (mib.db) and per-bundle linked .txt files. Rewritten into four clean @artifact_processor functions: - Apps - Installed / Apps - Uninstalled: most-recent event per bundle id, partitioned by whether the latest action is a destroy/uninstall (computed in Python, no temp db). - Apps - Historical Combined: all parsed events (Timestamp, Event, Bundle ID, Event Path) -- this is the flat data the old per-bundle HTML-linked 'Apps - Historical' report indexed, so the linked version (and its .txt files written into the report folder) is dropped. - State - Reboots. Other changes: - Context single-arg form; pylint 10.00. - LOCAL time artifact: timestamps stored as-is (no UTC), local-time noted in every artifact's notes; output_types excludes timeline. - context.get_relative_path() on the returned source. - Preserve all 7 event-type regexes (drop the redundant 'Destroying container with identifier' block that double-matched the plain one) and the sysdiagnose tar extraction; harden timestamp parsing (skip unparseable lines) + file/tar closing. - Remove the dead/commented 'Strings - SQLite Journal' report and ~500 lines of commented-out temp-db INSERTs and debug logging. - Drop sqlite3/os/textwrap/sys/string/html.escape/ArtifactHtmlReport/tsv/ timeline/logfunc/is_platform_windows.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
The big pre-iOS-17
mobile_installation.logparser (729 lines). Was a single old-style function building 6 HTML reports via a temp SQLite db (mib.db) and per-bundle linked.txtfiles. Rewritten into four clean@artifact_processorfunctions.What changed
mib.db)..txtfiles it wrote into the report folder) is dropped.notes;output_typesexcludestimeline.context.get_relative_path()on the returned source.Destroying container with identifierblock that double-matched the plain one) and the sysdiagnose-tar extraction; hardened timestamp parsing + file/tar closing.Strings - SQLite Journalreport and ~500 lines of commented-out temp-db INSERTs/debug logging.Validation
ast.parseOK; 0 legacy refs (no sqlite3/mib.db); no cross-module imports; all 4 reserved-word audits clean.