Bug#939022: [#939022] Re: pyresample: autopkgtest failure with PROJ 6 (epsg data file removed)

Antonio Valentino antonio.valentino at tiscali.it
Sun Sep 1 18:44:35 BST 2019


Hi Sebastiaan,
after the workaround committed in [1], remaining issues are:

======================================================================
ERROR: test_create_area_def
(pyresample.test.test_geometry.TestStackedAreaDefinition)
Test create_area_def and the four sub-methods that call it in
AreaDefinition.
----------------------------------------------------------------------
Traceback (most recent call last):
  File
"/home/antonio/debian/git/pyresample/pyresample/test/test_geometry.py",
line 1657, in test_create_area_def
    radius=essentials[1], description=description, units=units,
rotation=45))
  File "/home/antonio/debian/git/pyresample/pyresample/area_config.py",
line 444, in create_area_def
    center = _convert_units(center, 'center', units, p, proj_dict)
  File "/home/antonio/debian/git/pyresample/pyresample/area_config.py",
line 577, in _convert_units
    var = _round_poles(var, units, p)
  File "/home/antonio/debian/git/pyresample/pyresample/area_config.py",
line 517, in _round_poles
    center = p(*center, inverse=True, errcheck=True)
  File "/home/antonio/debian/git/pyresample/pyresample/_spatial_mp.py",
line 157, in __call__
    radians=radians, errcheck=errcheck)
  File "/usr/lib/python3/dist-packages/pyproj/proj.py", line 183, in
__call__
    self._inv(inx, iny, errcheck=errcheck)
  File "pyproj/_proj.pyx", line 165, in pyproj._proj.Proj._inv
pyproj.exceptions.ProjError: generic error of unknown origin: (Internal
Proj Error: proj_crs_get_sub_crs: Object is not a CompoundCRS)

======================================================================
ERROR: test_area_parser_yaml (pyresample.test.test_utils.TestYAMLAreaParser)
Test YAML area parser.
----------------------------------------------------------------------
Traceback (most recent call last):
  File
"/home/antonio/debian/git/pyresample/pyresample/test/test_utils.py",
line 96, in test_area_parser_yaml
    'test_latlong')
  File "/home/antonio/debian/git/pyresample/pyresample/area_config.py",
line 104, in parse_area_file
    return _parse_yaml_area_file(area_file_name, *regions)
  File "/home/antonio/debian/git/pyresample/pyresample/area_config.py",
line 157, in _parse_yaml_area_file
    res.append(create_area_def(**params))
  File "/home/antonio/debian/git/pyresample/pyresample/area_config.py",
line 444, in create_area_def
    center = _convert_units(center, 'center', units, p, proj_dict)
  File "/home/antonio/debian/git/pyresample/pyresample/area_config.py",
line 577, in _convert_units
    var = _round_poles(var, units, p)
  File "/home/antonio/debian/git/pyresample/pyresample/area_config.py",
line 517, in _round_poles
    center = p(*center, inverse=True, errcheck=True)
  File "/home/antonio/debian/git/pyresample/pyresample/_spatial_mp.py",
line 157, in __call__
    radians=radians, errcheck=errcheck)
  File "/usr/lib/python3/dist-packages/pyproj/proj.py", line 183, in
__call__
    self._inv(inx, iny, errcheck=errcheck)
  File "pyproj/_proj.pyx", line 165, in pyproj._proj.Proj._inv
pyproj.exceptions.ProjError: generic error of unknown origin: (Internal
Proj Error: proj_crs_get_sub_crs: Object is not a CompoundCRS)


It seems that the problem can be fixed by upgrading pyproj to v2.3.1
(see [2]).
I made a quick test with python3-pyproj 2.3.1+ds-1~exp1 (available in
experimental) and I can confirm that all tests pass now.

I0m going to add a versioned dependency in pyresample but the upload can
only happen once pyproj 2.3.1 is available in unstable.

There seems to be still some warning regarding proj initialization but
as far as I can understand there is some activity upstream on this front
so I think all details will be fully fixed in the next upstream version
of pyresample.


[1]
https://salsa.debian.org/debian-gis-team/pyresample/commit/55eab16e711ff56bac48aee6920840d8ff6e86f0
[2] https://github.com/pyproj4/pyproj/issues/413


kind regards
antonio

On Sun, 1 Sep 2019 17:48:01 +0200 Antonio Valentino
<antonio.valentino at tiscali.it> wrote:
> Hi Sebastiaan,
> I have a workaround for the basemap issue but there are still a couple
> of tests failing.
> 
> cheers
> antonio
> 
> Il 01/09/19 15:05, Sebastiaan Couwenberg ha scritto:
> > On 8/31/19 7:14 PM, Sebastiaan Couwenberg wrote:
> >>> I'm going to reassign.
> >>
> >> That doesn't seem appropriate, pyresample needs to be updated too. It
> >> does things like this:
> >>
> >>  pyresample/test/test_geometry.py:
> >>         projections = {'+init=epsg:3006': 'init: epsg:3006'}
> >>
> >> Note the explicit use of init files, this is not going to work correctly
> >> with PROJ 6.
> > 
> > As sort term workaround may be to skip these tests when
> > /usr/share/proj/epsg doesn't exist (or when /usr/share/proj/proj.db does
> > exist).
> > 
> > Kind Regards,
> > 
> > Bas
> > 
> 
> -- 
> Antonio Valentino
> 
> 

-- 
Antonio Valentino



More information about the Pkg-grass-devel mailing list