TypeError in match_coordinates_sky

Hello all,

I’ve been using match_coordinates_sky for awhile now with no issues in Jupyter Notebook. Suddenly (I’ll detail that a bit below in case it is helpful to anyone), my code started to give the following error:

TypeError: concatenate() got an unexpected keyword argument ‘dtype’

The code and notebook as written works fine on other machines but will not run on mine (even in a virtual environment with the same versions of all packages as it is run on another computer). Very lost on how to resolve this issue and any help is appreciated. My code is below as well as other details.

max_sep = 1 * u.arcsec
idx, d2d, d3d = match_coordinates_sky(cat1_coords, cat2_coords, nthneighbor=1, storekdtree = False)
sep_constraint = d2d < max_sep
cat1_match = cat1[sep_constraint]
cat2_match = cat2[idx[sep_constraint]]

The *_coords files are created using Sky_Coord and the error is highlighted on the match_coordinate_sky.

This started when I had an issue with Jupyter Notebook not loading suddenly. I eventually reinstalled Jupyter Notebook which fixed the issue but then the code that was previously working would not run. Current versions of packages are below but this has been attempted on multiple versions but in virtual environments and on other machines.

Notebook: 6.5.4
Conda: 23.7.2
Astropy: 5.1

update astropy to 5.2
for more info: Astropy units incompatibility with numpy 1.24 · Issue #14210 · astropy/astropy · GitHub