mirror of
https://github.com/Microsoft/vscode
synced 2024-09-13 13:46:13 +00:00
Merge remote-tracking branch 'origin/master' into tyriar/puppeteer
This commit is contained in:
commit
6915947c76
|
@ -1,7 +1,7 @@
|
|||
{
|
||||
"name": "code-oss-dev",
|
||||
"version": "1.38.0",
|
||||
"distro": "c70929f01c8688bf05a58fc514f649309e9d45a5",
|
||||
"distro": "6ce1c040c0d555b998dba62dd333f437a7b2d44f",
|
||||
"author": {
|
||||
"name": "Microsoft Corporation"
|
||||
},
|
||||
|
|
|
@ -129,6 +129,10 @@ export interface MarkerStatistics {
|
|||
export namespace IMarkerData {
|
||||
const emptyString = '';
|
||||
export function makeKey(markerData: IMarkerData): string {
|
||||
return makeKeyOptionalMessage(markerData, true);
|
||||
}
|
||||
|
||||
export function makeKeyOptionalMessage(markerData: IMarkerData, useMessage: boolean): string {
|
||||
let result: string[] = [emptyString];
|
||||
if (markerData.source) {
|
||||
result.push(markerData.source.replace('¦', '\¦'));
|
||||
|
@ -145,7 +149,10 @@ export namespace IMarkerData {
|
|||
} else {
|
||||
result.push(emptyString);
|
||||
}
|
||||
if (markerData.message) {
|
||||
|
||||
// Modifed to not include the message as part of the marker key to work around
|
||||
// https://github.com/microsoft/vscode/issues/77475
|
||||
if (markerData.message && useMessage) {
|
||||
result.push(markerData.message.replace('¦', '\¦'));
|
||||
} else {
|
||||
result.push(emptyString);
|
||||
|
|
|
@ -278,9 +278,14 @@ export abstract class AbstractProblemCollector implements IDisposable {
|
|||
markersPerResource = new Map<string, IMarkerData>();
|
||||
markersPerOwner.set(resourceAsString, markersPerResource);
|
||||
}
|
||||
let key = IMarkerData.makeKey(marker);
|
||||
let key = IMarkerData.makeKeyOptionalMessage(marker, false);
|
||||
let existingMarker;
|
||||
if (!markersPerResource.has(key)) {
|
||||
markersPerResource.set(key, marker);
|
||||
} else if (((existingMarker = markersPerResource.get(key)) !== undefined) && existingMarker.message.length < marker.message.length) {
|
||||
// Most likely https://github.com/microsoft/vscode/issues/77475
|
||||
// Heuristic dictates that when the key is the same and message is smaller, we have hit this limitation.
|
||||
markersPerResource.set(key, marker);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue