Welcome Guest! To enable all features please Login or Register.

Notification

Icon
Error

exception running tests on the grid
samholder
#1 Posted : Friday, January 10, 2020 2:40:32 PM(UTC)
Rank: Advanced Member

Groups: Registered
Joined: 5/11/2012(UTC)
Posts: 72

Thanks: 23 times
Was thanked: 9 time(s) in 9 post(s)
When running tests we sometimes get all tests pass but the run fails with this exception

[14:17:49][Step 8/12] [?-14] ERROR (Internal): System.IO.IOException: The process cannot access the file 'C:\Users\username\AppData\Local\NCrunch\hashcache' because it is being used by another process.
[14:17:49][Step 8/12] [?-14] at System.IO.__Error.WinIOError(Int32 errorCode, String maybeFullPath)
[14:17:49][Step 8/12] [?-14] at System.IO.FileStream.Init(String path, FileMode mode, FileAccess access, Int32 rights, Boolean useRights, FileShare share, Int32 bufferSize, FileOptions options, SECURITY_ATTRIBUTES secAttrs, String msgPath, Boolean bFromProxy, Boolean useLongPath, Boolean checkHost)
[14:17:49][Step 8/12] [?-14] at System.IO.FileStream..ctor(String path, FileMode mode, FileAccess access, FileShare share)
[14:17:49][Step 8/12] [?-14] at nCrunch.Core.Hashing.HashCacheIOManager. . ()
[14:17:49][Step 8/12] [?-14] at nCrunch.Core.Threading.PooledWorkItem.Start()
[14:17:49][Step 8/12] [?-14] at nCrunch.Core.Threading.ThreadFactory. (Object )

ANy way we can prevent this from failing the test run?
Remco
#2 Posted : Friday, January 10, 2020 10:55:15 PM(UTC)
Rank: NCrunch Developer

Groups: Administrators
Joined: 4/16/2011(UTC)
Posts: 5,982

Thanks: 781 times
Was thanked: 1008 time(s) in 960 post(s)
This looks to be an internal concurrency issue caused by a race condition.

It'll take a deep code review to figure out exactly what is happening here.

How is this error being reported for you? Does it appear on one of the test tasks or in the Tests Window? Is it happening locally or on a grid node?
samholder
#3 Posted : Friday, January 17, 2020 5:08:24 PM(UTC)
Rank: Advanced Member

Groups: Registered
Joined: 5/11/2012(UTC)
Posts: 72

Thanks: 23 times
Was thanked: 9 time(s) in 9 post(s)
Sorry, missed the notification about the response.

This is happening on a grid node, so we see it in the build log on teamcity.
1 user thanked samholder for this useful post.
Remco on 1/17/2020(UTC)
michaelkroes
#4 Posted : Friday, February 7, 2020 7:00:08 PM(UTC)
Rank: NCrunch Developer

Groups: Registered
Joined: 9/22/2017(UTC)
Posts: 208
Location: Netherlands

Thanks: 94 times
Was thanked: 44 time(s) in 42 post(s)
1 user thanked michaelkroes for this useful post.
samholder on 2/28/2020(UTC)
samholder
#5 Posted : Thursday, February 27, 2020 10:23:03 AM(UTC)
Rank: Advanced Member

Groups: Registered
Joined: 5/11/2012(UTC)
Posts: 72

Thanks: 23 times
Was thanked: 9 time(s) in 9 post(s)
I'll try and do this but not super easy as lots of machines to update, and happens infrequently. Will this speculative fix be included in the main NCrunch release? It might be easier to schedule the update at some later date with a released version
Remco
#6 Posted : Thursday, February 27, 2020 9:56:46 PM(UTC)
Rank: NCrunch Developer

Groups: Administrators
Joined: 4/16/2011(UTC)
Posts: 5,982

Thanks: 781 times
Was thanked: 1008 time(s) in 960 post(s)
samholder;14473 wrote:
I'll try and do this but not super easy as lots of machines to update, and happens infrequently. Will this speculative fix be included in the main NCrunch release? It might be easier to schedule the update at some later date with a released version


Yes. We have some level of confidence behind this fix. The reason it's considered speculative is because the nature of the problem (race condition) makes it hard to reproduce reliably, so we don't have a way to completely confirm that the fix works. Given that it's probably not a critical issue, I'd say it's fine for you to just wait until the next version to update your NCrunch.
1 user thanked Remco for this useful post.
samholder on 2/28/2020(UTC)
Users browsing this topic
Guest
Forum Jump  
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.

YAF | YAF © 2003-2011, Yet Another Forum.NET
This page was generated in 0.044 seconds.