question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Describe the bug Unhandled exception in browser.

To Reproduce Steps to reproduce the behavior: While following the concepts in Chapter 5 of Blazor in action, I am getting this error:

[2021-03-29T21:44:03.980Z] Error: System.MissingMethodException: Method not found: 'System.Collections.Generic.IList`1<FluentValidation.Results.ValidationFailure> FluentValidation.Results.ValidationResult.get_Errors()'.
   at Blazored.FluentValidation.EditContextFluentValidationExtensions.ValidateModel(EditContext editContext, ValidationMessageStore messages, IServiceProvider serviceProvider, Boolean disableAssemblyScanning, FluentValidationValidator fluentValidationValidator, IValidator validator)
   at System.Runtime.CompilerServices.AsyncMethodBuilderCore.Start[TStateMachine](TStateMachine& stateMachine)
   at Blazored.FluentValidation.EditContextFluentValidationExtensions.ValidateModel(EditContext editContext, ValidationMessageStore messages, IServiceProvider serviceProvider, Boolean disableAssemblyScanning, FluentValidationValidator fluentValidationValidator, IValidator validator)
   at Blazored.FluentValidation.EditContextFluentValidationExtensions.<>c__DisplayClass3_0.<AddFluentValidation>b__0(Object sender, ValidationRequestedEventArgs eventArgs)
   at Microsoft.AspNetCore.Components.Forms.EditContext.Validate()
   at Microsoft.AspNetCore.Components.Forms.EditForm.HandleSubmitAsync()
   at Microsoft.AspNetCore.Components.ComponentBase.CallStateHasChangedOnAsyncCompletion(Task task)
   at Microsoft.AspNetCore.Components.RenderTree.Renderer.GetErrorHandledTask(Task taskToHandle)

Frankly, I don’t know where to look to find out why a method would be missing. 😦

Here’s the beginning of the Edit Form.

  <EditForm Model="@objNewPerson" OnValidSubmit="@HandleValidSubmit">
        <FluentValidationValidator />
        <FormSection Title="Personal Info">

Using <DataAnnotationsValidator /> works fine (except I thought it would be easier to use fluent for the child records).

Expected behavior No errors in JS console. Validation error in markup (“Surname is required”)

Hosting Model (is this issue happening with a certain hosting model?):

  • Blazor Server

Additional context Following the steps from Blazor in Action, with my own model, that includes a “child” record (Person and PhoneNumbers, rather than Trails and Steps).

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:5 (4 by maintainers)

github_iconTop GitHub Comments

1reaction
JeremySkinnercommented, Apr 8, 2021

Sounds good. 10.0 is actually released now, so you may want to publish a new major version release that targets it. I think the only thing you should need to do is recompile against it, but let me know if you run into any issues upgrading.

0reactions
chrissaintycommented, Apr 8, 2021

Thanks for the info @JeremySkinner. I’ll get a limit added for the package and hopefully it should sort things out 👍

Read more comments on GitHub >

github_iconTop Results From Across the Web

Bug (2006)
An unhinged war veteran holes up with a lonely woman in a spooky Oklahoma motel room. The line between reality and delusion is...
Read more >
bug - Wiktionary, the free dictionary
(entomology) An insect of the order Hemiptera (the “true bugs”). Any of various species of marine or freshwater crustaceans; e.g. a Moreton Bay...
Read more >
Bug Definition & Meaning
bug · a hidden microphone or other electronic eavesdropping device. · any of various small mechanical or electrical gadgets, as one to influence...
Read more >
Bug (2006 film)
Bug is a 2006 psychological thriller film directed by William Friedkin and written by Tracy Letts, based on his 1996 play of the...
Read more >
BUG | definition in the Cambridge English Dictionary
a mistake or problem in the way something works: He said they had eliminated all the bugs in the software, and we hoped...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found