Commit ef48399
committed
fix: crash due to config packages key with missing value
- Treat empty 'packages:' entry as empty array to prevent NPE.
Ensures consistent behavior with when no 'package:' entry or
'package: []' is specified.
- Log and return null instead of System.exit(1) on 'load',
since System.exit(1) is already done in 'initialize'
Added tests to verify:
- Loading config with 'packages' key having no value.
- Error message for scalar 'packages' value.1 parent 011a645 commit ef48399
File tree
2 files changed
+23
-1
lines changed- agent/src
- main/java/com/appland/appmap/config
- test/java/com/appland/appmap/config
2 files changed
+23
-1
lines changedLines changed: 5 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
131 | 131 | | |
132 | 132 | | |
133 | 133 | | |
| 134 | + | |
| 135 | + | |
| 136 | + | |
| 137 | + | |
134 | 138 | | |
135 | 139 | | |
136 | | - | |
| 140 | + | |
137 | 141 | | |
138 | 142 | | |
139 | 143 | | |
| |||
Lines changed: 18 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
100 | 100 | | |
101 | 101 | | |
102 | 102 | | |
| 103 | + | |
| 104 | + | |
| 105 | + | |
| 106 | + | |
| 107 | + | |
| 108 | + | |
| 109 | + | |
| 110 | + | |
| 111 | + | |
| 112 | + | |
| 113 | + | |
| 114 | + | |
| 115 | + | |
| 116 | + | |
| 117 | + | |
| 118 | + | |
| 119 | + | |
| 120 | + | |
103 | 121 | | |
104 | 122 | | |
105 | 123 | | |
0 commit comments