- 🇪🇸Spain Francisco Sierra Madrid
I have updated my website (http://estiloguadarrama.com/) to Drupal 10. Apparently, the module works alright. I have had to use mglaman/composer-drupal-lenient, as indicated in https://stackoverflow.com/questions/74885881/how-to-install-patched-modu... to be able to upgrade Drupal while having gpx_track_elevation installed.
I have also had to cheat composer by changing the indicated module version, saying it is 1.1 (although the real code is not). If not, the installed module is considered as outdated or not recommended.
It would be nice if other users can test the patch I provided. And finally, it would be great if the new code can make its way to the recommended version, so as to avoid these pitfalls in using it in Drupal 10.
- 🇧🇪Belgium Jan Moris
Dear Francisco,
I updated my site to Drupal 10, but I'm not able to get GPX_track_elevation-module working properly.
I'm trying to apply your patch (gpx_track_elevation-D10compatibility-3287794-4.patch) but I'm getting an error.[u85125p79776@web0125 demertmp]$ composer update Gathering patches for root package. Removing package drupal/gpx_track_elevation so that it can be re-installed and re-patched. - Removing drupal/gpx_track_elevation (1.1.0) Deleting modules/contrib/gpx_track_elevation - deleted Loading composer repositories with package information Updating dependencies Nothing to modify in lock file Installing dependencies from lock file (including require-dev) Package operations: 1 install, 0 updates, 0 removals Gathering patches for root package. Gathering patches for dependencies. This might take a minute. - Installing drupal/gpx_track_elevation (1.1.0): Extracting archive - Applying patches for drupal/gpx_track_elevation https://www.drupal.org/files/issues/2023-01-08/gpx_track_elevation-D10compatibility-3287794-4.patch (gpx_track_elevation) Could not apply patch! Skipping. The error was: Cannot apply patch https://www.drupal.org/files/issues/2023-01-08/gpx_track_elevation-D10compatibility-3287794-4.patch
What am I doing wrong?
Any help would be appreciated!! - 🇪🇸Spain Francisco Sierra Madrid
Dear Jan,
I am not very skilled in using composer. I have not tried to apply the patch through composer. I would suggest to patch the module first (for example, using the patch command in Linux), and then install the module.
Remember to install mglaman module before installing gpx_track_elevation, as I mention above. The version number in the module (in gpx_track_elevation.info.yml) has to be tricked as well, to make composer believe it is the recommended version. This might be more difficult now, since the 8.x branch has been removed. When I updated my installation, it was still online.
I could provide the patched module code to you in the way you suggest, out of the official places (this space and the GitLab space).
By the way, do you know anything about the plans for this module, why the 8.x branch has been removed, etc.? Everything is more cumbersome now, with the module out of maintenance.
I would offer to contribute maintaining the module if I had enough knowledge of Drupal module structure, but that is not the case.
I hope this helps somehow. Please let me know what you get.