Skip to content
This repository has been archived by the owner on Nov 24, 2020. It is now read-only.

NPOI version 1.2.2 not working with alpine 2.2 #165

Open
leandromoh opened this issue Feb 18, 2020 · 0 comments
Open

NPOI version 1.2.2 not working with alpine 2.2 #165

leandromoh opened this issue Feb 18, 2020 · 0 comments

Comments

@leandromoh
Copy link

after add in docker file
RUN echo "http://dl-cdn.alpinelinux.org/alpine/edge/community" >> /etc/apk/repositories
as suggested on README of this repository and receive the bellow exception.

environment
.Net core 2.2
Alpine | Self Contained | mcr.microsoft.com/dotnet/core/runtime-deps:2.2-alpine |

 [ArgumentException: Font '?' cannot be found.]
Source: System.Drawing.Common
StackTrace:
at System.Drawing.FontFamily.GetGdipGenericSansSerif()
   at System.Drawing.FontFamily.get_GenericSansSerif()
   at System.Drawing.Font.CreateFont(String familyName, Single emSize, FontStyle style, GraphicsUnit unit, Byte charSet, Boolean isVertical)
   at NPOI.SS.Util.SheetUtil.IFont2Font(IFont font1)
   at NPOI.SS.Util.SheetUtil.getDefaultCharWidth(IWorkbook wb)
   at NPOI.SS.Util.SheetUtil.GetColumnWidth(ISheet sheet, Int32 column, Boolean useMergedCells)
   at NPOI.XSSF.UserModel.XSSFSheet.AutoSizeColumn(Int32 column, Boolean useMergedCells)
   at StoneCo.Treasury.AssetsTrader.Apis.Formatter.ExcelConverterExtensions.ToExcel[T](IEnumerable`1 source, String sheetName, IReadOnlyList`1 header, Action`2 fillRow) in /vsts/agent/_work/5/s/src/StoneCo.Treasury.AssetsTrader.Api/Apis/Formatter/ExcelConverterExtensions.cs:line 31
   at StoneCo.Treasury.AssetsTrader.Apis.Formatter.ExcelOutputFormatter.WriteResponseBodyAsync(OutputFormatterWriteContext context) in /vsts/agent/_work/5/s/src/StoneCo.Treasury.AssetsTrader.Api/Apis/Formatter/ExcelOutputFormatter.cs:line 30
   at Microsoft.AspNetCore.Mvc.Internal.ResourceInvoker.InvokeResultAsync(IActionResult result)
   at Microsoft.AspNetCore.Mvc.Internal.ResourceInvoker.InvokeNextResultFilterAsync[TFilter,TFilterAsync]()
   at Microsoft.AspNetCore.Mvc.Internal.ResourceInvoker.Rethrow(ResultExecutedContext context)
   at Microsoft.AspNetCore.Mvc.Internal.ResourceInvoker.ResultNext[TFilter,TFilterAsync](State& next, Scope& scope, Object& state, Boolean& isCompleted)
   at Microsoft.AspNetCore.Mvc.Internal.ResourceInvoker.InvokeResultFilters()
   at Microsoft.AspNetCore.Mvc.Internal.ResourceInvoker.InvokeNextResourceFilter()
   at Microsoft.AspNetCore.Mvc.Internal.ResourceInvoker.Rethrow(ResourceExecutedContext context)
   at Microsoft.AspNetCore.Mvc.Internal.ResourceInvoker.Next(State& next, Scope& scope, Object& state, Boolean& isCompleted)
   at Microsoft.AspNetCore.Mvc.Internal.ResourceInvoker.InvokeFilterPipelineAsync()
   at Microsoft.AspNetCore.Mvc.Internal.ResourceInvoker.InvokeAsync()
   at Microsoft.AspNetCore.Routing.EndpointMiddleware.Invoke(HttpContext httpContext)
@leandromoh leandromoh changed the title notworking with 2.2-alpine NPOI version 1.2.2 not working with alpine 2.2 Feb 18, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant