Skip to content
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

Support more recent numpy versions #40

Closed
wants to merge 5 commits into from
Closed

Support more recent numpy versions #40

wants to merge 5 commits into from

Conversation

jan-janssen
Copy link
Member

Checklist

  • Used a personal fork of the feedstock to propose changes
  • Bumped the build number (if the version is unchanged)
  • Reset the build number to 0 (if the version changed)
  • Re-rendered with the latest conda-smithy (Use the phrase @conda-forge-admin, please rerender in a comment in this PR for automated rerendering)
  • Ensured the license file is being packaged.

@conda-forge-webservices
Copy link

Hi! This is the friendly automated conda-forge-linting service.

I just wanted to let you know that I linted all conda-recipes in your PR (recipe) and found it was in an excellent condition.

I do have some suggestions for making it better though...

For recipe:

  • License is not an SPDX identifier (or a custom LicenseRef) nor an SPDX license expression.

Documentation on acceptable licenses can be found here.

@jan-janssen
Copy link
Member Author

@conda-forge-admin, please rerender

@github-actions
Copy link
Contributor

Hi! This is the friendly automated conda-forge-webservice.

I tried to rerender for you, but it looks like there was nothing to do.

This message was generated by GitHub actions workflow run https://github.com/conda-forge/f90wrap-feedstock/actions/runs/5383254736.

@jan-janssen
Copy link
Member Author

@conda-forge-admin, please rerender

@github-actions
Copy link
Contributor

Hi! This is the friendly automated conda-forge-webservice.

I tried to rerender for you, but it looks like there was nothing to do.

This message was generated by GitHub actions workflow run https://github.com/conda-forge/f90wrap-feedstock/actions/runs/5383374819.

@jan-janssen
Copy link
Member Author


     62 |   capi_this_tmp = array_from_pyobj(PyArray_INT,this_Dims,this_Rank,capi_this_intent,this_capi);
        |                                    ^~~~~~~~~~~
        |                                    PyArray_CGT
  ../../f90wrap/arraydatamodule.c:62:36: note: each undeclared identifier is reported only once for each function it appears in
  ../../f90wrap/arraydatamodule.c:68:33: error: 'PyArrayObject' {aka 'struct tagPyArrayObject'} has no member named 'data'
     68 |     this = (int *)(capi_this_tmp->data);
        |                                 ^~
  ../../f90wrap/arraydatamodule.c:110:55: error: 'NPY_FORTRAN' undeclared (first use in this function); did you mean 'NPY_SORTKIND'?
    110 |                                                 data, NPY_FORTRAN | NPY_WRITEABLE | NPY_ALIGNED, NULL);
        |                                                       ^~~~~~~~~~~
        |                                                       NPY_SORTKIND
  ../../f90wrap/arraydatamodule.c:110:69: error: 'NPY_WRITEABLE' undeclared (first use in this function); did you mean 'PyBUF_WRITEABLE'?
    110 |                                                 data, NPY_FORTRAN | NPY_WRITEABLE | NPY_ALIGNED, NULL);
        |                                                                     ^~~~~~~~~~~~~
        |                                                                     PyBUF_WRITEABLE
  ../../f90wrap/arraydatamodule.c:110:85: error: 'NPY_ALIGNED' undeclared (first use in this function); did you mean 'Py_ALIGNED'?
    110 |                                                 data, NPY_FORTRAN | NPY_WRITEABLE | NPY_ALIGNED, NULL);
        |                                                                                     ^~~~~~~~~~~
        |                                                                                     Py_ALIGNED
  ../../f90wrap/arraydatamodule.c: At top level:
  ../../f90wrap/arraydatamodule.c:128:197: warning: unknown escape sequence: '\g'
    128 |    "Make an array from integer(sizeof_fortran_t) array containing reference to derived type object,\n and fortran array function.\n\get_array(sizeof_fortran_t, fpointer,array_fobj[,key]) -> array"},
        |                                                                                                                                                                                                     ^
  [3/9] Compiling C object f90wrap/sizeof_fortran_t.cpython-311-x86_64-linux-gnu.so.p/meson-generated_.._sizeof_fortran_tmodule.c.o
  [4/9] Compiling C object lib_fortranobject.a.p/85502f41c28e3018539d54ab33652232af5b0e27_.._.._f2py_src_fortranobject.c.o
  ninja: build stopped: subcommand failed.
  error: subprocess-exited-with-error

@jan-janssen
Copy link
Member Author

@jameskermode I though the numpy restrictions were lifted in the recent release, but at least in the conda-forge build environment it still fails for 1.24 and 1.25.

From c36ac9f636588153e4e76537364e3898d8ac51f3 Mon Sep 17 00:00:00 2001
From: Jan Janssen <jan-janssen@users.noreply.github.com>
Date: Tue, 27 Jun 2023 11:54:45 -0600
Subject: [PATCH] update numpy flags
Copy link
Member Author

Choose a reason for hiding this comment

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

@jan-janssen
Copy link
Member Author

  ../../f90wrap/arraydatamodule.c:62:36: error: 'PyArray_INT' undeclared (first use in this function); did you mean 'PyArray_CGT'?
     62 |   capi_this_tmp = array_from_pyobj(PyArray_INT,this_Dims,this_Rank,capi_this_intent,this_capi);
        |                                    ^~~~~~~~~~~
        |                                    PyArray_CGT
  ../../f90wrap/arraydatamodule.c:62:36: note: each undeclared identifier is reported only once for each function it appears in
  ../../f90wrap/arraydatamodule.c:68:33: error: 'PyArrayObject' {aka 'struct tagPyArrayObject'} has no member named 'data'
     68 |     this = (int *)(capi_this_tmp->data);
        |                                 ^~
  ../../f90wrap/arraydatamodule.c: At top level:
  ../../f90wrap/arraydatamodule.c:128:197: warning: unknown escape sequence: '\g'
    128 |    "Make an array from integer(sizeof_fortran_t) array containing reference to derived type object,\n and fortran array function.\n\get_array(sizeof_fortran_t, fpointer,array_fobj[,key]) -> array"},
        |                                                                                                                                                                                                     ^
  [2/9] Generating f90wrap/sizeof_fortran_tmodule.c with a custom command

@jan-janssen
Copy link
Member Author

PyArray_INT should be replaced by PyTypeNum_ISINTEGER.

@jan-janssen jan-janssen closed this by deleting the head repository Jun 29, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant