-
Notifications
You must be signed in to change notification settings - Fork 212
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
perl namelist should allow both "false" and ".false." #1283
Comments
I assume that this is using the perl old schema with
namelist_definition.xml and namelist_defaults.xml. How is
config_test_case_diag defined in the namelist_definition.xml?
…On Mon, Mar 27, 2017 at 1:04 PM, Robert Jacob ***@***.***> wrote:
The MPAS-CICE buildnml is complaining about a logical a user is trying to
set in using user_nl_mpascice.
config_test_case_diag = false
'ERROR(Build::Namelist::_parse_next): expect a F90 constant for a
namelist instead got: false
If they set it instead to
config_test_case_diag = .false.
But both "false" and ".false." should be allowed.
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
<#1283>, or mute the thread
<https://github.com/notifications/unsubscribe-auth/AHlxE70z7Td6sYpW_gkNgZtald5qm0jlks5rqAgygaJpZM4MqsF7>
.
|
Yes that buildnml is still in perl. In namelist definition:
In namelist_defaults: |
I believe that perl is assuming that a logical will be fortran namelist
logical - i.e. .true. or .false. To get the behavior he wants - I would
make it a character and then give the valid values as "true" or "false".
Hopefully, this will work.
…On Mon, Mar 27, 2017 at 1:20 PM, Robert Jacob ***@***.***> wrote:
Yes that buildnml is still in perl.
In namelist definition:
<entry id="config_test_case_diag" type="logical"
category="io" group="io">
MISSING DESCRIPTION
Valid values: MISSING POSSIBLE VALUES
Default: Defined in namelist_defaults.xml
</entry>
In namelist_defaults: <config_test_case_diag>false</config_test_case_diag>
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
<#1283 (comment)>, or mute
the thread
<https://github.com/notifications/unsubscribe-auth/AHlxE8jH0WsmcthPNCnpKwZWVAT5BtVCks5rqAvtgaJpZM4MqsF7>
.
|
The fortran standard allows both false and .false. as valid fortran in namelists. The standard actually allows the "f" character (or "t" character for true obviously) followed by anything as a valid value. |
I think this is a limitation of our perl modules for namelist parsing.
On Mon, Mar 27, 2017 at 1:33 PM, Mariana Vertenstein <[email protected]>
wrote:
… I believe that perl is assuming that a logical will be fortran namelist
logical - i.e. .true. or .false. To get the behavior he wants - I would
make it a character and then give the valid values as "true" or "false".
Hopefully, this will work.
On Mon, Mar 27, 2017 at 1:20 PM, Robert Jacob ***@***.***>
wrote:
> Yes that buildnml is still in perl.
>
> In namelist definition:
>
> <entry id="config_test_case_diag" type="logical"
> category="io" group="io">
> MISSING DESCRIPTION
>
> Valid values: MISSING POSSIBLE VALUES
> Default: Defined in namelist_defaults.xml
> </entry>
>
> In namelist_defaults: <config_test_case_diag>false</
> config_test_case_diag>
>
> —
> You are receiving this because you commented.
> Reply to this email directly, view it on GitHub
> <#1283 (comment)>, or mute
> the thread
> <https://github.com/notifications/unsubscribe-auth/AHlxE8jH0WsmcthPNCnpKwZWVAT5BtVCks5rqAvtgaJpZM4MqsF7>
> .
>
|
Does the python parser allow both "false" and ".false."? |
Yes python allows both. |
The issue appears to be in the regex used. I am testing a solution now. |
The Namelist.pm only allowed for .false. or .true. in namelist files. I have fixed the regex to allow for dots or no dots. Fixes #1283
…1283) Update config_compilers.xml and config_machinces.xml for ORNL CADES cluster [BFB] Conflicts: cime/cime_config/acme/machines/config_machines.xml
…1283) Update config_compilers.xml and config_machinces.xml for ORNL CADES cluster [BFB] Conflicts: cime/cime_config/acme/machines/config_machines.xml
…1283) Update config_compilers.xml and config_machinces.xml for ORNL CADES cluster [BFB] Conflicts: cime/cime_config/acme/machines/config_machines.xml
The MPAS-CICE buildnml is complaining about a logical a user is trying to set using user_nl_mpascice.
config_test_case_diag = false
'ERROR(Build::Namelist::_parse_next): expect a F90 constant for a namelist instead got: false
If they set it instead to
config_test_case_diag = .false.
There there's no error. But both "false" and ".false." should be allowed.
The text was updated successfully, but these errors were encountered: