Unplanned
Last Updated: 22 May 2024 13:00 by Nate
Nate
Created on: 27 Apr 2023 19:19
Category: Grid
Type: Bug Report
4
Grid inline edit exception on double-click - TelerikValidationComponent requires a cascading parameter of type EditContext

In this example.  Select a cell in column C.  Then double click on another cell in column C.  The unhandled exception will show up and a null reference exception is logged in the console.  

https://blazorrepl.telerik.com/QHuSQBlj170zO4u130

The exception message is:

System.InvalidOperationException: TelerikValidationComponent requires a cascading parameter of type EditContext. You can use Telerik.Blazor.Components.TelerikValidationTooltip`1[System.String] inside a EditForm or TelerikForm.

7 comments
Nate
Posted on: 22 May 2024 13:00

This error has become much more frequent after a recent chrome update (version 125.0.6422.61)

I can now get this error to occur even with just single clicks to move from cell to cell, and with no code at all in the OnUpdate event

 

https://blazorrepl.telerik.com/mekzwYle22YMZSVh26

ADMIN
Dimo
Posted on: 20 Feb 2024 06:51

Hi Brad,

Hm, that's strange, as your example works flawlessly on my side.

My only idea at this point is to increase the Task.Delay() duration and see if this makes a difference. Other than that. I am afraid I have no other ideas at this point.

Regards,
Dimo
Progress Telerik

Stay tuned by visiting our public roadmap and feedback portal pages! Or perhaps, if you are new to our Telerik family, check out our getting started resources!
Brad
Posted on: 19 Feb 2024 18:54

Unfortunately, no it did not prevent the error on my side.   

I was able to reproduce the issue in REPL(See Screenshot).  However, it was harder to reproduce in REPL than in my local environment. 

Note: I added a dropdown to an Editor Template at the time I reproduce it in REPL.

https://blazorrepl.telerik.com/QyEwPNvC46PkxzGN19

Thanks,

Attached Files:
ADMIN
Dimo
Posted on: 16 Feb 2024 12:04

Hi Brad,

I made some experiments and here is another possible workaround - https://blazorrepl.telerik.com/woYQvqlQ03wapPGH01

The app keeps track of the Grid edit state and prevents duplicate entering in edit mode with a double-click.

Does this approach prevent the error on your side?

Regards,
Dimo
Progress Telerik

Stay tuned by visiting our public roadmap and feedback portal pages! Or perhaps, if you are new to our Telerik family, check out our getting started resources!
Brad
Posted on: 15 Feb 2024 19:24
Any progress on this bug?   We are experiencing the same issue.  Nate's suggested workaround is not working for us. 
Nate
Posted on: 28 Apr 2023 18:51
My workaround for now is moving the CPU work into a Task.Run like this: https://blazorrepl.telerik.com/QxEeGWlM51o7JD2r24
ADMIN
Dimo
Posted on: 28 Apr 2023 08:08

Hi Nate,

Thanks for reporting this error in a runnable test page. I am directly converting your ticket to a public bug report, so that other customers can see and follow it.

The problem seems related to a race condition and the double-click action. Single click (which is the usual way to enter edit mode) works fine. The browser also seems to matter, as the error occurs in Chrome, but not Safari.

If your users tend to double-click a lot, then consider switching to inline or popup editing while we investigate and resolve the exception.

Regards,
Dimo
Progress Telerik

Stay tuned by visiting our public roadmap and feedback portal pages! Or perhaps, if you are new to our Telerik family, check out our getting started resources!