Merge branch 'hotfix/2.14.1'

This commit is contained in:
Shahram Najm 2019-10-10 12:08:21 +01:00
commit fbdd8b14bc
28 changed files with 187 additions and 68 deletions

View File

@ -2,7 +2,7 @@
# general configuration #
#---------------------------------#
version: 2.14.0-{build}-{branch}
version: 2.14.1-{build}-{branch}
branches:
only:

View File

@ -1 +1 @@
set( ${PROJECT_NAME}_VERSION_STR "2.14.0" )
set( ${PROJECT_NAME}_VERSION_STR "2.14.1" )

View File

@ -18,6 +18,7 @@
17 dctb DCTB Duct base height (m)
18 tplb TPLB Trapping layer base height (m)
19 tplt TPLT Trapping layer top height (m)
20 degm10l -10 degrees C isothermal level (m)
21 fdir FDIR Total sky direct solar radiation at surface (J m**-2)
22 cdir CDIR Clear-sky direct solar radiation at surface (J m**-2)
23 cbh CBH Cloud base height (m)

View File

@ -9519,6 +9519,11 @@
table2Version = 221 ;
indicatorOfParameter = 56 ;
}
#-10 degrees C isothermal level (atm)
'degm10l' = {
table2Version = 228 ;
indicatorOfParameter = 20 ;
}
#Total sky direct solar radiation at surface
'fdir' = {
table2Version = 228 ;
@ -9534,7 +9539,7 @@
table2Version = 228 ;
indicatorOfParameter = 23 ;
}
#Zero degree level
#0 degrees C isothermal level (atm)
'deg0l' = {
table2Version = 228 ;
indicatorOfParameter = 24 ;

View File

@ -9519,6 +9519,11 @@
table2Version = 221 ;
indicatorOfParameter = 56 ;
}
#-10 degrees C isothermal level (atm)
'-10 degrees C isothermal level (atm)' = {
table2Version = 228 ;
indicatorOfParameter = 20 ;
}
#Total sky direct solar radiation at surface
'Total sky direct solar radiation at surface' = {
table2Version = 228 ;
@ -9534,8 +9539,8 @@
table2Version = 228 ;
indicatorOfParameter = 23 ;
}
#Zero degree level
'Zero degree level' = {
#0 degrees C isothermal level (atm)
'0 degrees C isothermal level (atm)' = {
table2Version = 228 ;
indicatorOfParameter = 24 ;
}

View File

@ -9519,6 +9519,11 @@
table2Version = 221 ;
indicatorOfParameter = 56 ;
}
#-10 degrees C isothermal level (atm)
'228020' = {
table2Version = 228 ;
indicatorOfParameter = 20 ;
}
#Total sky direct solar radiation at surface
'228021' = {
table2Version = 228 ;
@ -9534,7 +9539,7 @@
table2Version = 228 ;
indicatorOfParameter = 23 ;
}
#Zero degree level
#0 degrees C isothermal level (atm)
'228024' = {
table2Version = 228 ;
indicatorOfParameter = 24 ;

View File

@ -9519,6 +9519,11 @@
table2Version = 221 ;
indicatorOfParameter = 56 ;
}
#-10 degrees C isothermal level (atm)
'degm10l' = {
table2Version = 228 ;
indicatorOfParameter = 20 ;
}
#Total sky direct solar radiation at surface
'fdir' = {
table2Version = 228 ;
@ -9534,7 +9539,7 @@
table2Version = 228 ;
indicatorOfParameter = 23 ;
}
#Zero degree level
#0 degrees C isothermal level (atm)
'deg0l' = {
table2Version = 228 ;
indicatorOfParameter = 24 ;

View File

@ -9519,6 +9519,11 @@
table2Version = 221 ;
indicatorOfParameter = 56 ;
}
#-10 degrees C isothermal level (atm)
'm' = {
table2Version = 228 ;
indicatorOfParameter = 20 ;
}
#Total sky direct solar radiation at surface
'J m**-2' = {
table2Version = 228 ;
@ -9534,7 +9539,7 @@
table2Version = 228 ;
indicatorOfParameter = 23 ;
}
#Zero degree level
#0 degrees C isothermal level (atm)
'm' = {
table2Version = 228 ;
indicatorOfParameter = 24 ;

View File

@ -549,6 +549,24 @@
typeOfFirstFixedSurface = 1 ;
aerosolType = 62003 ;
}
#-10 degrees C isothermal level (atm)
'degm10l' = {
discipline = 0 ;
parameterCategory = 3 ;
parameterNumber = 6 ;
typeOfFirstFixedSurface = 20 ;
scaledValueOfFirstFixedSurface = 26315 ;
scaleFactorOfFirstFixedSurface = 2 ;
}
#0 degrees C isothermal level (atm)
'deg0l' = {
discipline = 0 ;
parameterCategory = 3 ;
parameterNumber = 6 ;
typeOfFirstFixedSurface = 20 ;
scaledValueOfFirstFixedSurface = 27315 ;
scaleFactorOfFirstFixedSurface = 2 ;
}
#10 metre wind gust in the last 3 hours
'fg310' = {
discipline = 0 ;

View File

@ -13283,12 +13283,6 @@
parameterCategory = 228 ;
parameterNumber = 23 ;
}
#Zero degree level
'deg0l' = {
discipline = 192 ;
parameterCategory = 228 ;
parameterNumber = 24 ;
}
#Horizontal visibility
'hvis' = {
discipline = 192 ;

View File

@ -13283,12 +13283,6 @@
parameterCategory = 228 ;
parameterNumber = 23 ;
}
#Zero degree level
'Zero degree level' = {
discipline = 192 ;
parameterCategory = 228 ;
parameterNumber = 24 ;
}
#Horizontal visibility
'Horizontal visibility' = {
discipline = 192 ;

View File

@ -13283,12 +13283,6 @@
parameterCategory = 228 ;
parameterNumber = 23 ;
}
#Zero degree level
'228024' = {
discipline = 192 ;
parameterCategory = 228 ;
parameterNumber = 24 ;
}
#Horizontal visibility
'228025' = {
discipline = 192 ;

View File

@ -13283,12 +13283,6 @@
parameterCategory = 228 ;
parameterNumber = 23 ;
}
#Zero degree level
'deg0l' = {
discipline = 192 ;
parameterCategory = 228 ;
parameterNumber = 24 ;
}
#Horizontal visibility
'hvis' = {
discipline = 192 ;

View File

@ -13283,12 +13283,6 @@
parameterCategory = 228 ;
parameterNumber = 23 ;
}
#Zero degree level
'm' = {
discipline = 192 ;
parameterCategory = 228 ;
parameterNumber = 24 ;
}
#Horizontal visibility
'm' = {
discipline = 192 ;

View File

@ -101,8 +101,8 @@
parameterCategory = 1 ;
parameterNumber = 205 ;
}
#Water equivalent of accumulated snow depth
'Water equivalent of accumulated snow depth' = {
#Water equivalent of accumulated snow depth (deprecated)
'Water equivalent of accumulated snow depth (deprecated)' = {
discipline = 0 ;
parameterCategory = 1 ;
parameterNumber = 11 ;
@ -1648,4 +1648,4 @@
discipline = 0 ;
parameterCategory = 1 ;
parameterNumber = 8 ;
}
}

View File

@ -101,7 +101,7 @@
parameterCategory = 1 ;
parameterNumber = 205 ;
}
#Water equivalent of accumulated snow depth
#Water equivalent of accumulated snow depth (deprecated)
'260056' = {
discipline = 0 ;
parameterCategory = 1 ;
@ -1648,4 +1648,4 @@
discipline = 0 ;
parameterCategory = 1 ;
parameterNumber = 8 ;
}
}

View File

@ -101,7 +101,7 @@
parameterCategory = 1 ;
parameterNumber = 205 ;
}
#Water equivalent of accumulated snow depth
#Water equivalent of accumulated snow depth (deprecated)
'sdwe' = {
discipline = 0 ;
parameterCategory = 1 ;
@ -1648,4 +1648,4 @@
discipline = 0 ;
parameterCategory = 1 ;
parameterNumber = 8 ;
}
}

View File

@ -101,7 +101,7 @@
parameterCategory = 1 ;
parameterNumber = 205 ;
}
#Water equivalent of accumulated snow depth
#Water equivalent of accumulated snow depth (deprecated)
'kg m**-2' = {
discipline = 0 ;
parameterCategory = 1 ;

View File

@ -549,6 +549,24 @@
typeOfFirstFixedSurface = 1 ;
typeOfSecondFixedSurface = 8 ;
}
#-10 degrees C isothermal level (atm)
'-10 degrees C isothermal level (atm)' = {
discipline = 0 ;
parameterCategory = 3 ;
parameterNumber = 6 ;
typeOfFirstFixedSurface = 20 ;
scaledValueOfFirstFixedSurface = 26315 ;
scaleFactorOfFirstFixedSurface = 2 ;
}
#0 degrees C isothermal level (atm)
'0 degrees C isothermal level (atm)' = {
discipline = 0 ;
parameterCategory = 3 ;
parameterNumber = 6 ;
typeOfFirstFixedSurface = 20 ;
scaledValueOfFirstFixedSurface = 27315 ;
scaleFactorOfFirstFixedSurface = 2 ;
}
#10 metre wind gust in the last 3 hours
'10 metre wind gust in the last 3 hours' = {
discipline = 0 ;

View File

@ -549,6 +549,24 @@
aerosolType = 62003 ;
is_aerosol = 1 ;
}
#-10 degrees C isothermal level (atm)
'228020' = {
discipline = 0 ;
parameterCategory = 3 ;
parameterNumber = 6 ;
typeOfFirstFixedSurface = 20 ;
scaledValueOfFirstFixedSurface = 26315 ;
scaleFactorOfFirstFixedSurface = 2 ;
}
#0 degrees C isothermal level (atm)
'228024' = {
discipline = 0 ;
parameterCategory = 3 ;
parameterNumber = 6 ;
typeOfFirstFixedSurface = 20 ;
scaledValueOfFirstFixedSurface = 27315 ;
scaleFactorOfFirstFixedSurface = 2 ;
}
#10 metre wind gust in the last 3 hours
'228028' = {
discipline = 0 ;

View File

@ -549,6 +549,24 @@
typeOfFirstFixedSurface = 1 ;
aerosolType = 62003 ;
}
#-10 degrees C isothermal level (atm)
'degm10l' = {
discipline = 0 ;
parameterCategory = 3 ;
parameterNumber = 6 ;
typeOfFirstFixedSurface = 20 ;
scaledValueOfFirstFixedSurface = 26315 ;
scaleFactorOfFirstFixedSurface = 2 ;
}
#0 degrees C isothermal level (atm)
'deg0l' = {
discipline = 0 ;
parameterCategory = 3 ;
parameterNumber = 6 ;
typeOfFirstFixedSurface = 20 ;
scaledValueOfFirstFixedSurface = 27315 ;
scaleFactorOfFirstFixedSurface = 2 ;
}
#10 metre wind gust in the last 3 hours
'10fg3' = {
discipline = 0 ;

View File

@ -549,6 +549,24 @@
typeOfFirstFixedSurface = 1 ;
typeOfSecondFixedSurface = 8 ;
}
#-10 degrees C isothermal level (atm)
'm' = {
discipline = 0 ;
parameterCategory = 3 ;
parameterNumber = 6 ;
typeOfFirstFixedSurface = 20 ;
scaledValueOfFirstFixedSurface = 26315 ;
scaleFactorOfFirstFixedSurface = 2 ;
}
#0 degrees C isothermal level (atm)
'm' = {
discipline = 0 ;
parameterCategory = 3 ;
parameterNumber = 6 ;
typeOfFirstFixedSurface = 20 ;
scaledValueOfFirstFixedSurface = 27315 ;
scaleFactorOfFirstFixedSurface = 2 ;
}
#10 metre wind gust in the last 3 hours
'm s**-1' = {
discipline = 0 ;

View File

@ -244,7 +244,7 @@ int pack_long_unsigned_helper(grib_accessor* a, const long* val, size_t *len, in
}
if (nbits < 33) {
unsigned long maxval = (1UL << nbits)-1;
if (v > maxval) {
if (maxval > 0 && v > maxval) { /* See ECC-1002 */
grib_context_log(a->context, GRIB_LOG_ERROR,
"Key \"%s\": Trying to encode value of %ld but the maximum allowable value is %ld (number of bits=%ld)\n",
a->name, v, maxval, nbits);

View File

@ -56,7 +56,6 @@ list( APPEND tests_no_data_reqd
grib_2nd_order_numValues
grib_ecc-136
grib_ecc-967
grib_ecc-979
julian
bufr_dump_samples
bufr_json_samples
@ -113,7 +112,9 @@ list( APPEND tests_data_reqd
grib_ecc-873
grib_ecc-600
grib_ecc-923
grib_ecc-979
grib_ecc-984
grib_ecc-1001
bufr_ecc-556
gts_get
gts_ls

43
tests/grib_ecc-1001.sh Executable file
View File

@ -0,0 +1,43 @@
#!/bin/sh
# Copyright 2005-2019 ECMWF.
#
# This software is licensed under the terms of the Apache Licence Version 2.0
# which can be obtained at http://www.apache.org/licenses/LICENSE-2.0.
#
# In applying this licence, ECMWF does not waive the privileges and immunities granted to it by
# virtue of its status as an intergovernmental organisation nor does it submit to any jurisdiction.
#
. ./include.sh
set -u
# ---------------------------------------------------------
# This is the test for the JIRA issue ECC-1001
# grib_ls -j -l command (JSON for nearest)
# ---------------------------------------------------------
label="grib_ecc-1001-test"
tempOut=temp.${label}.out
# Decide if we have the JSON verifier commandline utility
JSON_VERIF="json_xs"
JSON_CHECK=""
if command -v $JSON_VERIF >/dev/null 2>&1; then
JSON_CHECK=$JSON_VERIF
fi
inputs="
$ECCODES_SAMPLES_PATH/GRIB1.tmpl
$ECCODES_SAMPLES_PATH/GRIB2.tmpl
${data_dir}/high_level_api.grib2
"
for f in $inputs; do
rm -f $tempOut
${tools_dir}/grib_ls -m -j -l 51.0,1.0,1 $f > $tempOut
if test "x$JSON_CHECK" != "x"; then
$JSON_VERIF -t none < $tempOut
fi
done
# Clean up
rm -f $tempOut

View File

@ -333,7 +333,7 @@ int grib_tool_new_handle_action(grib_runtime_options* options, grib_handle* h)
}
}
if (options->json_output) {
if (!json_latlon && options->json_output) {
if (!first_handle && options->handle_count>1) {
fprintf(stdout,",\n");
}
@ -392,7 +392,7 @@ int grib_tool_finalise_action(grib_runtime_options* options)
}
}
if (options->json_output) fprintf(stdout,"\n]}\n");
if (!json_latlon && options->json_output) fprintf(stdout,"\n]}\n");
if (nearest) grib_nearest_delete(nearest);
if (json_latlon) printf("\n]\n");

View File

@ -248,7 +248,7 @@ static int grib_tool_with_orderby(grib_runtime_options* options)
continue;
}
if (options->json_output == 0)
if (options->json_output == 0 || options->latlon)
grib_print_header(options,h);
else
grib_tools_set_print_keys(options,h,options->name_space);
@ -351,7 +351,7 @@ static int grib_tool_without_orderby(grib_runtime_options* options)
continue;
}
if (options->json_output == 0)
if (options->json_output == 0 || options->latlon)
grib_print_header(options,h);
else
grib_tools_set_print_keys(options,h,options->name_space);
@ -619,7 +619,7 @@ static void grib_print_header(grib_runtime_options* options,grib_handle* h)
size_t strlenkey=0;
int width;
int written_to_dump = 0; /* boolean */
if (options->json_output)
if (options->json_output && !options->latlon)
return; /* For JSON output we do not print a single header for all msgs */
if (options->handle_count!=1)
return;
@ -969,7 +969,7 @@ void grib_print_key_values(grib_runtime_options* options, grib_handle* h)
if (!options->verbose) return;
if (options->json_output) {
if (options->json_output && !options->latlon) {
/* fprintf(dump_file, "\"message %d\" : {\n", options->handle_count); */
fprintf(dump_file, " {\n");
for (i=0;i<options->print_keys_count;i++) {
@ -1151,7 +1151,7 @@ void grib_print_file_statistics(grib_runtime_options* options,grib_tools_file* f
{
grib_failed* failed=NULL;
Assert(file);
if (options->json_output)
if (options->json_output && !options->latlon)
return;
failed=file->failed;
@ -1179,7 +1179,7 @@ void grib_print_file_statistics(grib_runtime_options* options,grib_tools_file* f
void grib_print_full_statistics(grib_runtime_options* options)
{
if (options->json_output)
if (options->json_output && !options->latlon)
return;
if (options->print_statistics && options->verbose)
fprintf(dump_file,"%d of %d total messages in %d files\n",

View File

@ -1,21 +1,10 @@
# Copyright 2005-2019 ECMWF.
#
# This software is licensed under the terms of the Apache Licence Version 2.0
# which can be obtained at http://www.apache.org/licenses/LICENSE-2.0.
#
# In applying this licence, ECMWF does not waive the privileges and immunities granted to it by
# virtue of its status as an intergovernmental organisation nor does it submit to any jurisdiction.
#
# Package name and versioning information
#
#
# Package base name
PACKAGE_NAME='eccodes'
# Package version
ECCODES_MAJOR_VERSION=2
ECCODES_MINOR_VERSION=14
ECCODES_REVISION_VERSION=0
ECCODES_REVISION_VERSION=1
ECCODES_CURRENT=1
ECCODES_REVISION=0