From 774c5ff7707ce6c1753d3944a3f540ac29806bd1 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 6 Oct 2023 00:16:00 +0000 Subject: [PATCH 1/4] Bump YamlDotNet from 13.4.0 to 13.5.2 Bumps [YamlDotNet](https://github.com/aaubry/YamlDotNet) from 13.4.0 to 13.5.2. - [Release notes](https://github.com/aaubry/YamlDotNet/releases) - [Commits](https://github.com/aaubry/YamlDotNet/compare/v13.4.0...v13.5.2) --- updated-dependencies: - dependency-name: YamlDotNet dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- Rdmp.Core/Rdmp.Core.csproj | 2 +- Tools/rdmp/rdmp.csproj | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Rdmp.Core/Rdmp.Core.csproj b/Rdmp.Core/Rdmp.Core.csproj index cc99923472..8d7fa91ebd 100644 --- a/Rdmp.Core/Rdmp.Core.csproj +++ b/Rdmp.Core/Rdmp.Core.csproj @@ -389,7 +389,7 @@ - + diff --git a/Tools/rdmp/rdmp.csproj b/Tools/rdmp/rdmp.csproj index 6cb25ae8c2..f7c580b0de 100644 --- a/Tools/rdmp/rdmp.csproj +++ b/Tools/rdmp/rdmp.csproj @@ -41,7 +41,7 @@ - + From add79de4d9f774cf5df3b56da3c17dac1c7b93ac Mon Sep 17 00:00:00 2001 From: jas88 Date: Tue, 10 Oct 2023 11:16:00 -0500 Subject: [PATCH 2/4] Update Rdmp.Core.csproj Remove some obsolete dependencies --- Rdmp.Core/Rdmp.Core.csproj | 208 ++++++++++++------------------------- 1 file changed, 66 insertions(+), 142 deletions(-) diff --git a/Rdmp.Core/Rdmp.Core.csproj b/Rdmp.Core/Rdmp.Core.csproj index 8d7fa91ebd..0427f63391 100644 --- a/Rdmp.Core/Rdmp.Core.csproj +++ b/Rdmp.Core/Rdmp.Core.csproj @@ -45,10 +45,8 @@ - - + + @@ -57,14 +55,11 @@ - + - + - + @@ -79,17 +74,14 @@ - + - + - + @@ -97,15 +89,13 @@ - + - + @@ -130,25 +120,21 @@ - + - + - + - + @@ -183,109 +169,73 @@ - + Never - - + + - - - - + + + + - - - - + + + + - - - + + + - + - + - - - - + + + + - - - - - + + + + + - - - + + + - - - + + + - - + + - + - - + + @@ -299,37 +249,25 @@ - - - - + + + + - - - + + + - - + + - + - - + + @@ -339,21 +277,17 @@ - + - - + + - + @@ -376,18 +310,8 @@ - - - - - - - - - - From 811414014fb4770bab9614061a2b40b6f8a3761a Mon Sep 17 00:00:00 2001 From: jas88 Date: Tue, 10 Oct 2023 11:32:02 -0500 Subject: [PATCH 3/4] Update ExcelDataFlowSource.cs Syntax tidy --- .../DataFlowSources/ExcelDataFlowSource.cs | 21 +++++++++---------- 1 file changed, 10 insertions(+), 11 deletions(-) diff --git a/Rdmp.Core/DataLoad/Modules/DataFlowSources/ExcelDataFlowSource.cs b/Rdmp.Core/DataLoad/Modules/DataFlowSources/ExcelDataFlowSource.cs index 34ff3248d1..53d458e17b 100644 --- a/Rdmp.Core/DataLoad/Modules/DataFlowSources/ExcelDataFlowSource.cs +++ b/Rdmp.Core/DataLoad/Modules/DataFlowSources/ExcelDataFlowSource.cs @@ -21,6 +21,7 @@ using Rdmp.Core.DataFlowPipeline; using Rdmp.Core.DataFlowPipeline.Requirements; using Rdmp.Core.DataLoad.Modules.Exceptions; +using Rdmp.Core.ReusableLibraryCode.Annotations; using Rdmp.Core.ReusableLibraryCode.Checks; using Rdmp.Core.ReusableLibraryCode.Progress; @@ -198,7 +199,7 @@ public DataTable GetAllData(ISheet worksheet, IDataLoadEventListener listener) /// The cell whose value you want to retrieve /// Leave blank, used in recursion for dealing with Formula cells /// - private object GetCellValue(ICell cell, CellType treatAs = CellType.Unknown) + private object GetCellValue([CanBeNull] ICell cell, CellType treatAs = CellType.Unknown) { if (cell == null) return null; @@ -218,8 +219,8 @@ private object GetCellValue(ICell cell, CellType treatAs = CellType.Unknown) //some numerics are actually dates/times if (cell.CellStyle.DataFormat == 0) return cell.NumericCellValue; + var format = cell.CellStyle.GetDataFormatString(); - var f = new NumberFormat(format); if (IsDateWithoutTime(format)) return cell.DateCellValue.ToString("yyyy-MM-dd"); @@ -230,19 +231,17 @@ private object GetCellValue(ICell cell, CellType treatAs = CellType.Unknown) if (IsTimeWithoutDate(format)) return cell.DateCellValue.ToString("HH:mm:ss"); - return IsDateFormat(format) - ? f.Format(cell.DateCellValue, CultureInfo.InvariantCulture) - : f.Format(cell.NumericCellValue, CultureInfo.InvariantCulture); + return new NumberFormat(format).Format( + IsDateFormat(format) ? cell.DateCellValue : cell.NumericCellValue, CultureInfo.InvariantCulture); case CellType.String: - var v = cell.StringCellValue; - //if it is blank or 'null' then leave it null - if (string.IsNullOrWhiteSpace(v) || v.Trim().Equals("NULL", StringComparison.CurrentCultureIgnoreCase)) - return null; + return string.IsNullOrWhiteSpace(cell.StringCellValue) || + cell.StringCellValue.Trim().Equals("NULL", StringComparison.CurrentCultureIgnoreCase) + ? null + : cell.StringCellValue; - return cell.StringCellValue; case CellType.Formula: return GetCellValue(cell, cell.CachedFormulaResultType); case CellType.Blank: @@ -252,7 +251,7 @@ private object GetCellValue(ICell cell, CellType treatAs = CellType.Unknown) case CellType.Error: return null; default: - throw new ArgumentOutOfRangeException(); + throw new ArgumentOutOfRangeException(nameof(treatAs)); } } From f89187ee08bf20cc9fe48063d47fd6f5c421759c Mon Sep 17 00:00:00 2001 From: James A Sutherland <> Date: Tue, 10 Oct 2023 13:03:04 -0500 Subject: [PATCH 4/4] Update Packages.md --- Documentation/CodeTutorials/Packages.md | 9 --------- 1 file changed, 9 deletions(-) diff --git a/Documentation/CodeTutorials/Packages.md b/Documentation/CodeTutorials/Packages.md index 1ecf3ccd62..44d50761dc 100644 --- a/Documentation/CodeTutorials/Packages.md +++ b/Documentation/CodeTutorials/Packages.md @@ -33,17 +33,8 @@ | YamlDotNet | [GitHub](https://github.com/aaubry/YamlDotNet) | [MIT](https://opensource.org/licenses/MIT) |Loading configuration files| | SixLabors.ImageSharp | [GitHub](https://github.com/SixLabors/ImageSharp) | [Apache 2.0](https://github.com/SixLabors/ImageSharp/blob/main/LICENSE) | Platform-independent replacement for legacy Windows-only System.Drawing.Common | | | SixLabors.ImageSharp.Drawing | [GitHub](https://github.com/SixLabors/ImageSharp.Drawing) | [Apache 2.0](https://github.com/SixLabors/ImageSharp/blob/main/LICENSE) | Font handling for ImageSharp | | -| System.Runtime.Loader | [GitHub](https://github.com/dotnet/corefx) |[MIT](https://opensource.org/licenses/MIT) | Allows loading assemblies in dot net core| | -| System.Diagnostics.Debug | [GitHub](https://github.com/dotnet/corefx) |[MIT](https://opensource.org/licenses/MIT) | Interact with Processes / Debug / Console | | -| System.IO.FileSystem.Primitives | [GitHub](https://github.com/dotnet/corefx) |[MIT](https://opensource.org/licenses/MIT) | Provides common enumerations and exceptions for path-based I/O libraries | | -| System.IO.FileSystem | [GitHub](https://github.com/dotnet/corefx) |[MIT](https://opensource.org/licenses/MIT) | Provides types that allow reading and writing to files | | -| System.Runtime.Extensions | [GitHub](https://github.com/dotnet/corefx) |[MIT](https://opensource.org/licenses/MIT) | Provides commonly-used classes for performing mathematical functions, conversions, string comparisons etc | | -| System.Threading | [GitHub](https://github.com/dotnet/corefx) |[MIT](https://opensource.org/licenses/MIT) | Provides the fundamental synchronization primitives | | | System.Threading.AccessControl | [GitHub](https://github.com/dotnet/runtime) |[MIT](https://opensource.org/licenses/MIT) | Required by Scintilla for sync primitives | | | System.Threading.ThreadPool | [GitHub](https://github.com/dotnet/corefx) |[MIT](https://opensource.org/licenses/MIT) | Required to compile native linux binaries | | -| System.Globalization | [GitHub](https://github.com/dotnet/corefx) |[MIT](https://opensource.org/licenses/MIT) | Provides classes that define culture-related information | | -| System.Net.NameResolution | [GitHub](https://github.com/dotnet/corefx) |[MIT](https://opensource.org/licenses/MIT) | Provides the System.Net.Dns class, which enables developers to perform simple domain name resolution | | -| System.Net.Primitives | [GitHub](https://github.com/dotnet/corefx) |[MIT](https://opensource.org/licenses/MIT) | Provides common types for network-based libraries | | | System.Security.Permissions |[GitHub](https://github.com/dotnet/corefx) |[MIT](https://opensource.org/licenses/MIT) | Provides common types for Xml doc reading in UI code | | | [AutoComplete Console](https://www.codeproject.com/Articles/1182358/Using-Autocomplete-in-Windows-Console-Applications) by Jasper Lammers | Embedded | [CPOL](https://www.codeproject.com/info/cpol10.aspx) | Provides interactive autocomplete in console input | | | System.Resources.Extensions | [GitHub](https://github.com/dotnet/corefx) | [MIT](https://opensource.org/licenses/MIT) | Allows [publishing with dotnet publish on machines with netcoreapp3.0 SDK installed](https://github.com/microsoft/msbuild/issues/4704#issuecomment-530034240) | |