Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: Wrong order of libraries info in instrumentation #1196

Merged
merged 1 commit into from
Nov 15, 2022
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -163,8 +163,7 @@ private static ListValue generateLibrariesList(
}
Struct libraryInfo = createInfoStruct(libraryName, libraryVersion);
ListValue.Builder libraryList = ListValue.newBuilder();
// Append first the library info for this library
libraryList.addValues(Value.newBuilder().setStructValue(libraryInfo).build());
// First add instrumentation data of other libraries to a list if any
if (existingLibraryList != null) {
for (Value val : existingLibraryList.getValuesList()) {
if (val.hasStructValue()) {
Expand All @@ -190,6 +189,8 @@ private static ListValue generateLibrariesList(
}
}
}
// At last, append this library info to a list
libraryList.addValues(Value.newBuilder().setStructValue(libraryInfo).build());
return libraryList.build();
}

Expand Down