netcdf4-python icon indicating copy to clipboard operation
netcdf4-python copied to clipboard

Fix test_tocdl to pass on Windows.

Open ELundby45 opened this issue 10 months ago • 2 comments

Fixes test_tocdl on Windows.

The expected output is:

netcdf ubyte {
dimensions:
        d = 2 ;
variables:
        byte ub(d) ;
                ub:_Unsigned = "true" ;
        byte sb(d) ;
        byte sb2(d) ;
                sb2:_Unsigned = "false" ;

// global attributes:
                :_Format = "classic" ;
}

But when the full path is provided, the output is something like:

netcdf C\:\\Users\\dev-admin\\Desktop\\netcdf\\netcdf4_1737132718267\\test_tmp\\test\\ubyte {
dimensions:
        d = 2 ;
variables:
        byte ub(d) ;
                ub:_Unsigned = "true" ;
        byte sb(d) ;
        byte sb2(d) ;
                sb2:_Unsigned = "false" ;

// global attributes:
                :_Format = "classic" ;
}

Using the basename fixes this.

ELundby45 avatar Jan 17 '25 17:01 ELundby45

CLA assistant check
All committers have signed the CLA.

CLAassistant avatar Jan 17 '25 17:01 CLAassistant

Looks like this issue might be isolated to my environment. Feel free to close this if it's not helpful.

ELundby45 avatar Jan 18 '25 17:01 ELundby45