SWAT Error: KeyNotFoundException in OutputRchParser

138 views
Skip to first unread message

Mirza Muhammad Muzzamil Mughal

unread,
Sep 19, 2024, 3:53:31 PM9/19/24
to arc...@googlegroups.com
Dear SWAT Support Team,

I hope this message finds you well. I am currently using the SWAT Error Checker (Version 1.2.0.10) and encountered an issue during the model output analysis. Below is the relevant error message:

********** Starting Analysis *************
Reading output.std...
Finished reading output.std in 00h:00m:00.20s. Reading output.rch...The given key was not present in the dictionary.

If you cannot resolve the error, please contact technical support with the message listed below.
----------------------------------------------------------------------
Type: System.Collections.Generic.KeyNotFoundException
Message: The given key was not present in the dictionary.
Source: mscorlib
Location: System.Collections.Generic.Dictionary`2, line 0, column 0
StackTrace: 
   at System.Collections.Generic.Dictionary`2.get_Item(TKey key)
   at SWAT.OutputProcessor.Parsers.OutputRchParser.ReadFile()
   at SWAT.Check.Desktop.SWATCheck.backgroundWorker_DoWork(Object sender, DoWorkEventArgs e)
   at System.ComponentModel.BackgroundWorker.OnDoWork(DoWorkEventArgs e)
   at System.ComponentModel.BackgroundWorker.WorkerThreadStart(Object argument)

The error occurs when reading the output.rch file, and it mentions that "The given key was not present in the dictionary." I have tried troubleshooting but was unable to resolve the issue.

Could you please advise on how to resolve this error or provide guidance on how to fix this? I am attaching a screenshot of the error for your reference.

Thank you for your assistance.

Best regards,
Mirza Muhammad Muzzamil
PhD scholar 



Nancy B. Sammons

unread,
Sep 20, 2024, 7:24:09 AM9/20/24
to Mirza Muhammad Muzzamil Mughal, arc...@googlegroups.com

Mirza:

Have you tried to install the latest SWAT Checker software? 

I have included the link below.  I hope this helps.

Nancy

https://swat.tamu.edu/software/swat-check/

 

 

From: arc...@googlegroups.com <arc...@googlegroups.com> On Behalf Of Mirza Muhammad Muzzamil Mughal
Sent: Tuesday, September 17, 2024 3:42 PM
To: arc...@googlegroups.com
Subject: [ArcSWAT:13632] SWAT Error: KeyNotFoundException in OutputRchParser

 

You don't often get email from mirzamuz...@gmail.com. Learn why this is important

--
You received this message because you are subscribed to the Google Groups "ArcSWAT" group.
To unsubscribe from this group and stop receiving emails from it, send an email to arcswat+u...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/arcswat/CAJZ6P%3DOU-dcd72Hvbju7gvrqkPp6O5NDVhZh0dLBOY7Uh5WXmg%40mail.gmail.com.

anaclar...@gmail.com

unread,
Apr 2, 2025, 10:49:28 AM4/2/25
to ArcSWAT
Had the same error. It suggests that some key on output.rch is not found, which lead me to check if all variables on the output.rch are listed on the tblRchDef of the output.mdb, and they werent. So I deleted the extra columns (Salt1,2,3,...) and it worked.
SWATOutput.sqlite has a list of variables for each output. Those salt variables are missing there, I think that may be the problem.
Reply all
Reply to author
Forward
0 new messages