diff --git a/CHANGELOG.md b/CHANGELOG.md index 2b78a951ab3..50106201d1e 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -11,6 +11,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ### Changed +- Made the POSITIVE field attribute defaults to "down" in case it is not found +- VLOCATION is not querried in MAPL_VerticalMethods.F90 for rank 2 fields - Fixed time print in Cap GC (from slashes to colons) - Added ability to read the attribute with explicit type "string" of a netcdf variable. - Start to implement changes for vertical regridding in ExtData diff --git a/base/MAPL_VerticalMethods.F90 b/base/MAPL_VerticalMethods.F90 index 205e3c6416f..2627297bdd1 100644 --- a/base/MAPL_VerticalMethods.F90 +++ b/base/MAPL_VerticalMethods.F90 @@ -490,17 +490,21 @@ subroutine append_vertical_metadata(this,metadata,bundle,rc) do i=1,numVars call ESMF_FieldBundleGet(bundle,i,field,_RC) - call ESMF_AttributeGet(field,name="POSITIVE", value=positive, _RC) + positive = 'down' + call ESMF_AttributeGet(field,NAME="POSITIVE",isPresent=isPresent,_RC) + if (isPresent) then + call ESMF_AttributeGet(field,name="POSITIVE", value=positive, _RC) + end if if (i .eq. 1) this%positive=positive if (i .gt. 1) then _ASSERT(this%positive==positive,"Fields have mistmatched positive attributes") this%positive=positive end if call ESMF_FieldGet(field,dimCount=FieldRank,_RC) - call ESMF_AttributeGet(field,name="VLOCATION", value=location(i),_RC) if (fieldRank==2) then varDims(i)=0 else if (fieldRank==3) then + call ESMF_AttributeGet(field,name="VLOCATION", value=location(i),_RC) call ESMF_FieldGet(field,farrayPtr=ptr3d,_RC) varDims(i)=size(ptr3d,3) if (location(i) == MAPL_VLocationNone) then