Type provider doesn't work with Azurite
Description
When working locally, AzureStorageTypeProvider works wit the deprecated Azure Storage Emulator, but not with its replacement for the future (Azurite)
Repro steps
- Start Azurite with default parameters
- Create F# console app (F# 6, .NET 6)
- Replace Program.fs content with
open FSharp.Azure.StorageTypeProvider
type Local = AzureTypeProvider<"UseDevelopmentStorage=true">
Expected behavior
No errors
Actual behavior
This error is generated:
Error FS3033 The type provider 'ProviderImplementation.AzureTypeProvider' reported an error: An error occurred during initial type generation for tables: Microsoft.WindowsAzure.Storage.StorageException: Unexpected response code, Expected:OK or NotFound, Received:BadRequest at FSharp.Azure.StorageTypeProvider.Table.TableMemberFactory.|BlobOnlyAccount|FullAccount|[a,b](FSharpResult
2 _arg1) at FSharp.Azure.StorageTypeProvider.Table.TableMemberFactory.getTableStorageMembers@44-2.Invoke(FSharpResult2 _arg1) at Microsoft.FSharp.Control.AsyncPrimitives.CallThenInvokeNoHijackCheck[a,b](AsyncActivation1 ctxt, b result1, FSharpFunc2 userCode) in D:\a_work\1\s\src\fsharp\FSharp.Core\async.fs:line 464 at [email protected](AsyncActivation1 ctxt) at Microsoft.FSharp.Control.Trampoline.Execute(FSharpFunc2 firstAction) in D:\a_work\1\s\src\fsharp\FSharp.Core\async.fs:line 105--- End of stack trace from previous location where exception was thrown --- at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw() at Microsoft.FSharp.Control.AsyncResult1.Commit() in D:\a\_work\1\s\src\fsharp\FSharp.Core\async.fs:line 393 at Microsoft.FSharp.Control.AsyncPrimitives.QueueAsyncAndWaitForResultSynchronously[a](CancellationToken token, FSharpAsync1 computation, FSharpOption1 timeout) in D:\a\_work\1\s\src\fsharp\FSharp.Core\async.fs:line 1044 at Microsoft.FSharp.Control.AsyncPrimitives.RunSynchronously[T](CancellationToken cancellationToken, FSharpAsync1 computation, FSharpOption1 timeout) in D:\a\_work\1\s\src\fsharp\FSharp.Core\async.fs:line 1070 at Microsoft.FSharp.Control.FSharpAsync.RunSynchronously[T](FSharpAsync1 computation, FSharpOption1 timeout, FSharpOption1 cancellationToken) in D:\a_work\1\s\src\fsharp\FSharp.Core\async.fs:line 1364 at FSharp.Azure.StorageTypeProvider.Table.TableMemberFactory.getTableStorageMembers(FSharpOption1 optionalStaticSchema, Int32 schemaInferenceRowCount, Boolean humanize, String connectionString, ProvidedTypeDefinition domainType) at <StartupCode$FSharp-Azure-StorageTypeProvider>[email protected](Tuple2 tupledArg) at <StartupCode$FSharp-Azure-StorageTypeProvider>[email protected](Tuple`2 tupledArg)Request InformationRequestID:bf8de900-b9b2-466f-97c4-c13d53464349RequestDate:Tue, 28 Dec 2021 19:57:38 GMTStatusMessage:Bad RequestErrorCode:ErrorMessage:The specified resource name length is not within the permissible limits.RequestId:bf8de900-b9b2-466f-97c4-c13d53464349Time:2021-12-28T08:57:38.485Z <Unknown> C:\Root\Work\Horth\Work\HF\Config\Types.fs 6 N/A
Known workarounds
No workarounds are known. This error doesn't occur if the deprecated Azure Storage Emulator is running in place of Azurite.
Related information
- Windows 10
- .NET 6