Skip to content

b4b-dev: Allow file paths with length 512 #3042

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

Merged
merged 9 commits into from
Apr 15, 2025

Conversation

samsrabin
Copy link
Collaborator

@samsrabin samsrabin commented Mar 29, 2025

Description of changes

Changes some input file paths to be of length SHR_KIND_CX (512) instead of SHR_KIND_CL (256). Also deletes some unused uses of SHR_KIND_CL that were annoying during this work.

Specific notes

Contributors other than yourself, if any: None

CTSM Issues Fixed:

Are answers expected to change (and if so in what way)? No

Any User Interface Changes (namelist or namelist defaults changes)? No

Does this create a need to change or add documentation? Did you do so? No

Testing performed, if any:

  • ERS_D_Ld20.5x5_amazon.I2000Clm50FatesRs.derecho_gnu.clm-FatesColdSeedDisp passes (as of 404b3ca)
  • Unit tests pass (as of 1e488d8)
  • aux_clm passes (as of 1e488d8)

@samsrabin samsrabin added code health improving internal code structure to make easier to maintain (sustainability) bfb bit-for-bit labels Mar 29, 2025
@samsrabin samsrabin self-assigned this Mar 29, 2025
@samsrabin samsrabin changed the base branch from master to b4b-dev March 29, 2025 16:09
@samsrabin samsrabin added the next this should get some attention in the next week or two. Normally each Thursday SE meeting. label Mar 29, 2025
@samsrabin samsrabin marked this pull request as draft March 29, 2025 16:15
@samsrabin samsrabin changed the base branch from b4b-dev to master March 29, 2025 21:50
@samsrabin samsrabin force-pushed the fix-FatesColdSeedDisp-race branch from d04e2dd to b5a043e Compare March 29, 2025 22:19
@ekluzek
Copy link
Collaborator

ekluzek commented Mar 31, 2025

Awesome. Hopefully, this can happen without a hitch. I ran into problems last time I worked on this once we got to 256. But, tons have changed since then and I hope this will just work now.

@wwieder wwieder removed the next this should get some attention in the next week or two. Normally each Thursday SE meeting. label Apr 3, 2025
@github-project-automation github-project-automation bot moved this to Ready to start (or start again) in CTSM: Upcoming tags Apr 3, 2025
@wwieder wwieder moved this from Ready to start (or start again) to In progress - master/b4b-dev in CTSM: Upcoming tags Apr 3, 2025
@samsrabin samsrabin changed the base branch from master to b4b-dev April 3, 2025 19:40
@samsrabin samsrabin requested a review from ekluzek April 3, 2025 19:41
@samsrabin samsrabin marked this pull request as ready for review April 3, 2025 19:41
@samsrabin samsrabin added the PR status: awaiting review Work on this PR is paused while waiting for review. label Apr 6, 2025
ekluzek
ekluzek previously approved these changes Apr 9, 2025
Copy link
Collaborator

@ekluzek ekluzek left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is awesome. Thanks for working on this and bringing it in. I'm glad we can lengthen our filenames lengths and you got it to work without problems.

I also didn't realize we had a fname_len variable that we should've been using all along, and you made that change. I also like your rename of it to FL, similar to other shr_kind renames.

@samsrabin samsrabin added PR status: needs testing and removed PR status: awaiting review Work on this PR is paused while waiting for review. labels Apr 9, 2025
@samsrabin
Copy link
Collaborator Author

@ekluzek Unfortunately I run into this error in the PEM_D_Ld20.5x5_amazon.I2000Clm50FatesRs.derecho_gnu.clm-FatesColdSeedDisp test:

WARNING: Test case setup failed. Case2 has been removed, but the main case may be in an inconsistent state. If you want to rerun this test, you should create a new test rather than trying to rerun this one.
ERROR: Command /glade/work/samrabin/ctsm_fix-FatesColdSeedDisp-race/cime/../bld/build-namelist failed rc=255
out=
err=ERROR : CLM build-namelist::CLMBuildNamelist::process_namelist_infile() : Invalid namelist variable in '-infile' /glade/derecho/scratch/samrabin/tests_0409-170738de/PEM_D_Ld20.5x5_amazon.I2000Clm50FatesRs.derecho_gnu.clm-FatesColdSeedDisp.C.0409-170738de_gnu/case2/PEM_D_Ld20.5x5_amazon.I2000Clm50FatesRs.derecho_gnu.clm-FatesColdSeedDisp.C.0409-170738de_gnu/Buildconf/clmconf/namelist.
 ERROR: in validate_variable_value (package Build::Namelist): Variable name fates_paramfile has a string element that is too long: '/glade/derecho/scratch/samrabin/tests_0409-170738de/PEM_D_Ld20.5x5_amazon.I2000Clm50FatesRs.derecho_gnu.clm-FatesColdSeedDisp.C.0409-170738de_gnu/case2/PEM_D_Ld20.5x5_amazon.I2000Clm50FatesRs.derecho_gnu.clm-FatesColdSeedDisp.C.0409-170738de_gnu/fates_params_seeddisp_4x5.nc'

I can't figure out how to increase the maximum string length in the perl, so I'll need your help here.

@samsrabin samsrabin added the bug something is working incorrectly label Apr 10, 2025
@ekluzek
Copy link
Collaborator

ekluzek commented Apr 10, 2025

@samsrabin I pushed a change that should resolve the problem. The character lengths in the namelist_definition_ctsm.xml file for the filenames just needed to be updated. I didn't do anything beyond making the changes that I saw. So you'll need to test and validate, and make sure I didn't screw up syntax or miss something.

@ekluzek ekluzek changed the title Allow file paths with length 512 b4b-dev: Allow file paths with length 512 Apr 14, 2025
@samsrabin samsrabin merged commit 9942645 into ESCOMP:b4b-dev Apr 15, 2025
2 checks passed
@github-project-automation github-project-automation bot moved this from In progress - master/b4b-dev to Done (non release/external) in CTSM: Upcoming tags Apr 15, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bfb bit-for-bit bug something is working incorrectly code health improving internal code structure to make easier to maintain (sustainability)
Projects
Status: Done (non release/external)
3 participants