express-list-endpoints icon indicating copy to clipboard operation
express-list-endpoints copied to clipboard

Ensure compatibility with latest versions of Express

Open nwalters512 opened this issue 1 year ago • 7 comments

The most recent versions of Express (4.20.0 and above) changed the way that route patterns are compiled to regular expressions. This PR introduces compatibility with these new versions, while retaining compatibility with older versions. To prove this to myself, I updated the test suite to run against both old and new versions of Express. I recommend reviewing these changes with whitespace changes hidden so that you can see what actually changed in the tests.

nwalters512 avatar Sep 12 '24 22:09 nwalters512

@nwalters512 when will this be merged an a new version released?

timd73 avatar Sep 16 '24 05:09 timd73

@timd73 I don't know; I don't maintain this library. I'm just someone who uses it and decided to file this PR to fix the compatibility issues I was experiencing in my own project. You'll have to ask @AlbertoFdzM.

nwalters512 avatar Sep 16 '24 16:09 nwalters512

@AlbertoFdzM ?

timd73 avatar Sep 16 '24 18:09 timd73

@nwalters512 so what are we thinking? Has @AlbertoFdzM ceased maintaining this library?

timd73 avatar Sep 22 '24 07:09 timd73

I won't make assumptions about the maintainer or when he may be able to review this. I'm leaning towards forking this package and will likely do so if I don't hear anything by the end of this week. I hate to do this since there are a variety of other packages that rely on express-list-endpoints.

nwalters512 avatar Sep 24 '24 20:09 nwalters512

I ultimately forked this package, applied the changes from this PR, and released it as @prairielearn/express-list-endpoints. It's an ESM-only package and only officially supports express@^4.21.0.

I'm leaving this PR open in the sincere hope that the maintainer is ultimately able to merge it, as I don't think having a fork is the best long-term solution for the ecosystem.

nwalters512 avatar Oct 09 '24 21:10 nwalters512

@AlbertoFdzM Is there any chance you might be able to review and merge this request? It's quite fundamental. Really appreciate this project and your help here! 🙇

btiernay avatar Oct 21 '24 14:10 btiernay