Further testing with partial data runs
This commit is contained in:
parent
e37d9757ec
commit
784471c5ce
2
Adaptation/.vscode/tasks.json
vendored
2
Adaptation/.vscode/tasks.json
vendored
@ -78,7 +78,7 @@
|
|||||||
"args": [
|
"args": [
|
||||||
"/target:Build",
|
"/target:Build",
|
||||||
"/restore:True",
|
"/restore:True",
|
||||||
"/p:RestoreSources=https://artifactory.intra.infineon.com/artifactory/api/nuget/ngt-fi-package-main-vir/%3Bhttps://packagemanagement.eu.infineon.com:4430/api/v2/%3Bhttps://tfs.intra.infineon.com/tfs/FactoryIntegration/_packaging/EAF/nuget/v3/index.json%3Bhttps://tfs.intra.infineon.com/tfs/FactoryIntegration/_packaging/EAF%40Local/nuget/v3/index.json%3Bhttps://api.nuget.org/v3/index.json",
|
"/p:RestoreSources=https://artifactory.intra.infineon.com/artifactory/api/nuget/ngt-fi-package-main-vir/%3Bhttps://tfs.intra.infineon.com/tfs/FactoryIntegration/_packaging/EAF/nuget/v3/index.json%3Bhttps://tfs.intra.infineon.com/tfs/FactoryIntegration/_packaging/EAF%40Local/nuget/v3/index.json%3Bhttps://api.nuget.org/v3/index.json",
|
||||||
"/detailedsummary",
|
"/detailedsummary",
|
||||||
"/consoleloggerparameters:PerformanceSummary;ErrorsOnly;",
|
"/consoleloggerparameters:PerformanceSummary;ErrorsOnly;",
|
||||||
"/property:Configuration=Debug;TargetFrameworkVersion=v4.8",
|
"/property:Configuration=Debug;TargetFrameworkVersion=v4.8",
|
||||||
|
@ -119,22 +119,26 @@ public class FileRead : Shared.FileRead, IFileRead
|
|||||||
throw new Exception(string.Concat("A) No Data - ", dateTime.Ticks));
|
throw new Exception(string.Concat("A) No Data - ", dateTime.Ticks));
|
||||||
IProcessData iProcessData = new ProcessData(this, _Logistics, results.Item4, pages, run);
|
IProcessData iProcessData = new ProcessData(this, _Logistics, results.Item4, pages, run);
|
||||||
if (iProcessData is not ProcessData processData)
|
if (iProcessData is not ProcessData processData)
|
||||||
throw new Exception(string.Concat("B) No Data - ", dateTime.Ticks));
|
results = new(string.Concat("B) No Data - ", dateTime.Ticks), Array.Empty<Test>(), Array.Empty<JsonElement>(), results.Item4);
|
||||||
string mid;
|
|
||||||
if (!string.IsNullOrEmpty(processData.Lot) && string.IsNullOrEmpty(processData.Reactor) && string.IsNullOrEmpty(processData.RDS) && string.IsNullOrEmpty(processData.PSN))
|
|
||||||
mid = processData.Lot;
|
|
||||||
else if (!string.IsNullOrEmpty(processData.Employee) && string.IsNullOrEmpty(processData.Reactor) && string.IsNullOrEmpty(processData.RDS) && string.IsNullOrEmpty(processData.PSN))
|
|
||||||
mid = processData.Employee;
|
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
mid = string.Concat(processData.Reactor, "-", processData.RDS, "-", processData.PSN);
|
string mid;
|
||||||
mid = Regex.Replace(mid, @"[\\,\/,\:,\*,\?,\"",\<,\>,\|]", "_").Split('\r')[0].Split('\n')[0];
|
if (!string.IsNullOrEmpty(processData.Lot) && string.IsNullOrEmpty(processData.Reactor) && string.IsNullOrEmpty(processData.RDS) && string.IsNullOrEmpty(processData.PSN))
|
||||||
|
mid = processData.Lot;
|
||||||
|
else if (!string.IsNullOrEmpty(processData.Employee) && string.IsNullOrEmpty(processData.Reactor) && string.IsNullOrEmpty(processData.RDS) && string.IsNullOrEmpty(processData.PSN))
|
||||||
|
mid = processData.Employee;
|
||||||
|
else
|
||||||
|
{
|
||||||
|
mid = string.Concat(processData.Reactor, "-", processData.RDS, "-", processData.PSN);
|
||||||
|
mid = Regex.Replace(mid, @"[\\,\/,\:,\*,\?,\"",\<,\>,\|]", "_").Split('\r')[0].Split('\n')[0];
|
||||||
|
}
|
||||||
|
SetFileParameterLotID(mid);
|
||||||
|
_Logistics.Update(mid, processData.Reactor);
|
||||||
|
if (iProcessData.Details.Count > 0)
|
||||||
|
results = iProcessData.GetResults(this, _Logistics, results.Item4);
|
||||||
|
else
|
||||||
|
results = new(string.Concat("C) No Data - ", dateTime.Ticks), Array.Empty<Test>(), Array.Empty<JsonElement>(), results.Item4);
|
||||||
}
|
}
|
||||||
SetFileParameterLotID(mid);
|
|
||||||
_Logistics.Update(mid, processData.Reactor);
|
|
||||||
if (iProcessData.Details.Count == 0)
|
|
||||||
throw new Exception(string.Concat("C) No Data - ", dateTime.Ticks));
|
|
||||||
results = iProcessData.GetResults(this, _Logistics, results.Item4);
|
|
||||||
}
|
}
|
||||||
return results;
|
return results;
|
||||||
}
|
}
|
||||||
|
@ -641,7 +641,7 @@ public class ProcessData : IProcessData
|
|||||||
slots[dataFile.Slot].Add(dataFile);
|
slots[dataFile.Slot].Add(dataFile);
|
||||||
}
|
}
|
||||||
string checkFileName = string.Concat(sourcePath, @"\", sourceFileNameWithoutExtension, "_data.pdf");
|
string checkFileName = string.Concat(sourcePath, @"\", sourceFileNameWithoutExtension, "_data.pdf");
|
||||||
if (!File.Exists(checkFileName))
|
if (fileRead.IsEAFHosted && !File.Exists(checkFileName))
|
||||||
{
|
{
|
||||||
File.Move(headerFileName, checkFileName);
|
File.Move(headerFileName, checkFileName);
|
||||||
_ = sourceFiles.Remove(headerFileName);
|
_ = sourceFiles.Remove(headerFileName);
|
||||||
@ -653,7 +653,7 @@ public class ProcessData : IProcessData
|
|||||||
if (!string.IsNullOrEmpty(pageMapping[i].Item2))
|
if (!string.IsNullOrEmpty(pageMapping[i].Item2))
|
||||||
{
|
{
|
||||||
checkFileName = pageMapping[i].Item2;
|
checkFileName = pageMapping[i].Item2;
|
||||||
if (!File.Exists(checkFileName))
|
if (fileRead.IsEAFHosted && !File.Exists(checkFileName))
|
||||||
{
|
{
|
||||||
File.Move(pageMapping[i].Item1, checkFileName);
|
File.Move(pageMapping[i].Item1, checkFileName);
|
||||||
_ = sourceFiles.Remove(pageMapping[i].Item1);
|
_ = sourceFiles.Remove(pageMapping[i].Item1);
|
||||||
@ -662,16 +662,13 @@ public class ProcessData : IProcessData
|
|||||||
}
|
}
|
||||||
else if (!string.IsNullOrEmpty(checkFileName))
|
else if (!string.IsNullOrEmpty(checkFileName))
|
||||||
{
|
{
|
||||||
//if (i == 0 || !string.IsNullOrEmpty(pageMapping[i - 1].Item2))
|
|
||||||
//{
|
|
||||||
checkFileName = checkFileName.Replace("_data.pdf", "_image.pdf");
|
checkFileName = checkFileName.Replace("_data.pdf", "_image.pdf");
|
||||||
if (!File.Exists(checkFileName))
|
if (fileRead.IsEAFHosted && !File.Exists(checkFileName))
|
||||||
{
|
{
|
||||||
File.Move(pageMapping[i].Item1, checkFileName);
|
File.Move(pageMapping[i].Item1, checkFileName);
|
||||||
_ = sourceFiles.Remove(pageMapping[i].Item1);
|
_ = sourceFiles.Remove(pageMapping[i].Item1);
|
||||||
sourceFiles.Add(checkFileName);
|
sourceFiles.Add(checkFileName);
|
||||||
}
|
}
|
||||||
//}
|
|
||||||
checkFileName = string.Empty;
|
checkFileName = string.Empty;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -68,9 +68,6 @@ internal class Run
|
|||||||
return results.AsReadOnly();
|
return results.AsReadOnly();
|
||||||
}
|
}
|
||||||
|
|
||||||
private static ReadOnlyCollection<string> GetLines(JsonElement jsonElement) =>
|
|
||||||
GetLines(new JsonElement[] { jsonElement });
|
|
||||||
|
|
||||||
private static void WriteTabSeparatedValues(Logistics logistics, List<FileInfo> fileInfoCollection, Run run)
|
private static void WriteTabSeparatedValues(Logistics logistics, List<FileInfo> fileInfoCollection, Run run)
|
||||||
{
|
{
|
||||||
List<Row> results = new();
|
List<Row> results = new();
|
||||||
@ -89,10 +86,12 @@ internal class Run
|
|||||||
fileInfoCollection.Add(fileInfo);
|
fileInfoCollection.Add(fileInfo);
|
||||||
}
|
}
|
||||||
|
|
||||||
private static void WriteException(Logistics logistics, Exception ex)
|
private static ReadOnlyCollection<string> GetWaferIds(Header header)
|
||||||
{
|
{
|
||||||
FileInfo fileInfo = new($"{logistics.ReportFullPath}.{nameof(Exception)}.txt");
|
List<string> results = new();
|
||||||
File.WriteAllText(fileInfo.FullName, $"{ex.Message}{Environment.NewLine}{ex.StackTrace}");
|
foreach (WaferSummary waferSummary in header.WaferSummary)
|
||||||
|
results.Add(waferSummary.Id);
|
||||||
|
return results.AsReadOnly();
|
||||||
}
|
}
|
||||||
|
|
||||||
internal static Run? Get(Logistics logistics, List<FileInfo> fileInfoCollection, ReadOnlyDictionary<string, string> pages)
|
internal static Run? Get(Logistics logistics, List<FileInfo> fileInfoCollection, ReadOnlyDictionary<string, string> pages)
|
||||||
@ -105,35 +104,12 @@ internal class Run
|
|||||||
result = null;
|
result = null;
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
ReadOnlyCollection<Wafer> wafers = Wafer.Get(pages, constant, headerFileName);
|
ReadOnlyCollection<string> waferIds = GetWaferIds(header);
|
||||||
if (wafers.Count == 0)
|
ReadOnlyDictionary<string, Wafer> keyValuePairs = Wafer.Get(pages, constant, headerFileName);
|
||||||
result = null;
|
ReadOnlyCollection<Wafer> wafers = Wafer.Get(waferIds, keyValuePairs);
|
||||||
else
|
result = new(header, wafers);
|
||||||
{
|
WriteJson(logistics, fileInfoCollection, result);
|
||||||
result = new(header, wafers);
|
WriteTabSeparatedValues(logistics, fileInfoCollection, result);
|
||||||
WriteJson(logistics, fileInfoCollection, result);
|
|
||||||
for (int i = 0; i < wafers.Count; i++)
|
|
||||||
{
|
|
||||||
if (wafers[i].Id != header.WaferSummary[i].Id)
|
|
||||||
{
|
|
||||||
header = null;
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
if (header is null || wafers.Count != header.WaferSummary.Count)
|
|
||||||
result = null;
|
|
||||||
else
|
|
||||||
{
|
|
||||||
try
|
|
||||||
{
|
|
||||||
WriteTabSeparatedValues(logistics, fileInfoCollection, result);
|
|
||||||
}
|
|
||||||
catch (Exception ex)
|
|
||||||
{
|
|
||||||
WriteException(logistics, ex);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
|
@ -46,6 +46,40 @@ public class Wafer
|
|||||||
Recipe = recipe;
|
Recipe = recipe;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private static Wafer? Get(string id) =>
|
||||||
|
new(date: string.Empty,
|
||||||
|
id: id,
|
||||||
|
comments: string.Empty,
|
||||||
|
sort: string.Empty,
|
||||||
|
lPDCount: string.Empty,
|
||||||
|
lPDCM2: string.Empty,
|
||||||
|
bin1: string.Empty,
|
||||||
|
bin2: string.Empty,
|
||||||
|
bin3: string.Empty,
|
||||||
|
bin4: string.Empty,
|
||||||
|
bin5: string.Empty,
|
||||||
|
bin6: string.Empty,
|
||||||
|
bin7: string.Empty,
|
||||||
|
bin8: string.Empty,
|
||||||
|
mean: string.Empty,
|
||||||
|
stdDev: string.Empty,
|
||||||
|
areaCount: string.Empty,
|
||||||
|
areaTotal: string.Empty,
|
||||||
|
scratchCount: string.Empty,
|
||||||
|
scratchTotal: string.Empty,
|
||||||
|
sumOfDefects: string.Empty,
|
||||||
|
hazeRegion: string.Empty,
|
||||||
|
hazeAverage: string.Empty,
|
||||||
|
hazePeak: string.Empty,
|
||||||
|
laser: string.Empty,
|
||||||
|
gain: string.Empty,
|
||||||
|
diameter: string.Empty,
|
||||||
|
thresh: string.Empty,
|
||||||
|
exclusion: string.Empty,
|
||||||
|
hazeRng: string.Empty,
|
||||||
|
thruput: string.Empty,
|
||||||
|
recipe: string.Empty);
|
||||||
|
|
||||||
public string Date { get; }
|
public string Date { get; }
|
||||||
public string Id { get; }
|
public string Id { get; }
|
||||||
public string Comments { get; }
|
public string Comments { get; }
|
||||||
@ -79,9 +113,9 @@ public class Wafer
|
|||||||
public string Thruput { get; }
|
public string Thruput { get; }
|
||||||
public string Recipe { get; }
|
public string Recipe { get; }
|
||||||
|
|
||||||
internal static ReadOnlyCollection<Wafer> Get(ReadOnlyDictionary<string, string> pages, Constant constant, string headerFileName)
|
internal static ReadOnlyDictionary<string, Wafer> Get(ReadOnlyDictionary<string, string> pages, Constant constant, string headerFileName)
|
||||||
{
|
{
|
||||||
List<Wafer> results = new();
|
Dictionary<string, Wafer> results = new();
|
||||||
Wafer wafer;
|
Wafer wafer;
|
||||||
string? text;
|
string? text;
|
||||||
List<string> stringList;
|
List<string> stringList;
|
||||||
@ -105,6 +139,8 @@ public class Wafer
|
|||||||
if (id.Length > 5)
|
if (id.Length > 5)
|
||||||
id = string.Concat(id.Substring(0, 5), "... - ***");
|
id = string.Concat(id.Substring(0, 5), "... - ***");
|
||||||
id = id.Replace("*", "");
|
id = id.Replace("*", "");
|
||||||
|
if (results.ContainsKey(id))
|
||||||
|
continue;
|
||||||
Header.ScanPast(text, i, "Comments:");
|
Header.ScanPast(text, i, "Comments:");
|
||||||
string comments = Header.GetToEOL(text, i);
|
string comments = Header.GetToEOL(text, i);
|
||||||
Header.ScanPast(text, i, "Sort:");
|
Header.ScanPast(text, i, "Sort:");
|
||||||
@ -186,6 +222,23 @@ public class Wafer
|
|||||||
hazeRng: hazeRng,
|
hazeRng: hazeRng,
|
||||||
thruput: thruput,
|
thruput: thruput,
|
||||||
recipe: recipe);
|
recipe: recipe);
|
||||||
|
results.Add(id, wafer);
|
||||||
|
}
|
||||||
|
return new(results);
|
||||||
|
}
|
||||||
|
|
||||||
|
internal static ReadOnlyCollection<Wafer> Get(ReadOnlyCollection<string> waferIds, ReadOnlyDictionary<string, Wafer> keyValuePairs)
|
||||||
|
{
|
||||||
|
List<Wafer> results = new();
|
||||||
|
string id;
|
||||||
|
Wafer? wafer;
|
||||||
|
for (int i = 0; i < waferIds.Count; i++)
|
||||||
|
{
|
||||||
|
id = waferIds[i];
|
||||||
|
if (!keyValuePairs.TryGetValue(id, out wafer))
|
||||||
|
wafer = Get(id);
|
||||||
|
if (wafer is null)
|
||||||
|
break;
|
||||||
results.Add(wafer);
|
results.Add(wafer);
|
||||||
}
|
}
|
||||||
return results.AsReadOnly();
|
return results.AsReadOnly();
|
||||||
|
@ -55,5 +55,23 @@ public class TENCOR3
|
|||||||
NonThrowTryCatch();
|
NonThrowTryCatch();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#if DEBUG
|
||||||
|
[Ignore]
|
||||||
|
#endif
|
||||||
|
[TestMethod]
|
||||||
|
[ExpectedException(typeof(MissingMethodException))]
|
||||||
|
public void Production__v2_57_0__TENCOR3__pcl638725158781216195__Parital()
|
||||||
|
{
|
||||||
|
string check = "*.pcl";
|
||||||
|
bool validatePDSF = false;
|
||||||
|
_TENCOR3.Production__v2_57_0__TENCOR3__pcl();
|
||||||
|
MethodBase methodBase = new StackFrame().GetMethod();
|
||||||
|
string[] variables = _TENCOR3.AdaptationTesting.GetVariables(methodBase, check, validatePDSF);
|
||||||
|
IFileRead fileRead = _TENCOR3.AdaptationTesting.Get(methodBase, sourceFileLocation: variables[2], sourceFileFilter: variables[3], useCyclicalForDescription: false);
|
||||||
|
Logistics logistics = new(fileRead);
|
||||||
|
_ = Shared.AdaptationTesting.ReExtractCompareUpdatePassDirectory(variables, fileRead, logistics, validatePDSF);
|
||||||
|
NonThrowTryCatch();
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
@ -88,6 +88,8 @@ public partial class FileRead : FileReaderHandler, ISMTP
|
|||||||
try
|
try
|
||||||
{
|
{
|
||||||
extractResults = _FileRead.GetExtractResult(reportFullPath, eventName);
|
extractResults = _FileRead.GetExtractResult(reportFullPath, eventName);
|
||||||
|
if (extractResults.Item3.Length == 0 && !string.IsNullOrEmpty(extractResults.Item1) && !extractResults.Item1.Contains(Environment.NewLine))
|
||||||
|
throw new Exception(extractResults.Item1);
|
||||||
TriggerEvents(extractResults);
|
TriggerEvents(extractResults);
|
||||||
_FileRead.Move(extractResults);
|
_FileRead.Move(extractResults);
|
||||||
FilePathGeneratorInfoMove(extractResults);
|
FilePathGeneratorInfoMove(extractResults);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user