View previous topic :: View next topic |
Author |
Message |
wahorger
Joined: 13 Oct 2014 Posts: 1239 Location: Morrison, CO, USA
|
Posted: Wed Nov 13, 2024 4:24 pm Post subject: NAMELIST - second or subsequent time reading, fails |
|
|
I am reading a single files that contains two namelists, written as:
Code: | write(i_donor,donor_parms)
write(i_donor,envelope_parms)
|
On a subsequent execution of the program, I read that file with the same namelists, the first time works fine. If I then attempt to read it again, the first namelist of the pair fails with an error code of 204. If I read a different file (created the same way), it errs with a code=202. Go back to the original failing file, code=204.
I placed a REWIND between the two reads, and (ignoring the first error), can read the second namelist successfully.
I don't quite know what these error codes mean, nor why a second (or any subsequent) attempt to read causes a failure. |
|
Back to top |
|
|
PaulLaidler Site Admin
Joined: 21 Feb 2005 Posts: 8071 Location: Salford, UK
|
Posted: Wed Nov 13, 2024 6:47 pm Post subject: |
|
|
Bill
I will need a working program that illustrates the failure.
It might be the same fault that has now been fixed. |
|
Back to top |
|
|
wahorger
Joined: 13 Oct 2014 Posts: 1239 Location: Morrison, CO, USA
|
Posted: Wed Nov 13, 2024 8:52 pm Post subject: |
|
|
Paul,
The data does not contain any TYPE'd data elements, FWIW.
That said, I will attempt to re-create in a smaller form the problem and place it in a PLATO project, than share the link on DropBox.
As always, your help is much appreciated!
Bill |
|
Back to top |
|
|
wahorger
Joined: 13 Oct 2014 Posts: 1239 Location: Morrison, CO, USA
|
Posted: Wed Nov 13, 2024 9:28 pm Post subject: |
|
|
The following simple program recreates the issue.
Note that the included file is identical to the one with which I encountered the problem.
Bill
This is a DropBox transfer link: https://www.dropbox.com/t/aH1IMPFWVXOVLZfq |
|
Back to top |
|
|
PaulLaidler Site Admin
Joined: 21 Feb 2005 Posts: 8071 Location: Salford, UK
|
Posted: Thu Nov 14, 2024 9:27 am Post subject: |
|
|
Bill
I have had a brief look at this but it looks like it would take a few hours to track down the fault which at this point may not be in the compiler.
I notice that one of the NAMELISTs has its tail commented out.
I guess I would start with shorter lists and add one item at a time until the fault occurs.
The input file "default.doner" contains NULL characters which is a complicating factor.
Maybe your test program should begin by writing simple data to default.donor. |
|
Back to top |
|
|
wahorger
Joined: 13 Oct 2014 Posts: 1239 Location: Morrison, CO, USA
|
Posted: Thu Nov 14, 2024 2:17 pm Post subject: |
|
|
Paul, thanks for the feedback. I will do a single item at a time and see. I have another name list that is all floating point (envelopes), and it has never failed.
The commented out portions are the TYPE'd variables that caused the other problem. |
|
Back to top |
|
|
wahorger
Joined: 13 Oct 2014 Posts: 1239 Location: Morrison, CO, USA
|
Posted: Thu Nov 14, 2024 3:35 pm Post subject: |
|
|
Paul, I have another transfer available:
https://www.dropbox.com/t/et75ZxZurWEaoXKZ
This time, I initialized all the variables at the beginning, wrote a temp file, next set all the items to a new value, then read the file, causing the error on the first read (=202). I then print all the variables to see which ones it actually processed.
The third item in the list ("PRINT_NAME") is not changed. This is the only item in the NAMELIST that is in a different named COMMON.
Examining the file itself (temp.donor), I can find no obvious issues |
|
Back to top |
|
|
PaulLaidler Site Admin
Joined: 21 Feb 2005 Posts: 8071 Location: Salford, UK
|
Posted: Thu Nov 14, 2024 6:31 pm Post subject: |
|
|
Bill
I probably won't be able to look at this until sometime next week. |
|
Back to top |
|
|
wahorger
Joined: 13 Oct 2014 Posts: 1239 Location: Morrison, CO, USA
|
Posted: Thu Nov 14, 2024 10:29 pm Post subject: |
|
|
Thanks for the heads up, Paul.
I have (temporarily) chosen the "hard way" so I can finish development. I can certainly wait! |
|
Back to top |
|
|
PaulLaidler Site Admin
Joined: 21 Feb 2005 Posts: 8071 Location: Salford, UK
|
Posted: Wed Nov 27, 2024 4:51 pm Post subject: |
|
|
Bill
This second issue with NAMELIST has now been fixed for the next release of the DLLs. |
|
Back to top |
|
|
wahorger
Joined: 13 Oct 2014 Posts: 1239 Location: Morrison, CO, USA
|
Posted: Wed Nov 27, 2024 5:57 pm Post subject: |
|
|
Thank you very much, Paul! I look forward to the DLL release and incorporation into the code!
A Happy Thanksgiving (US) gift!
And I thank you for all you do for this group!
Bill Horger |
|
Back to top |
|
|
|