- Merge request !11Issue #3111456: Unable to resolve path on node in other language than default → (Open) created by rajeshreeputra
- 🇯🇴Jordan yahyaalhamad Palestine
There is a problem with not being able to resolve the redirect and the default language, I expected that if you don't provide a language prefix, the current language will be used instead of only 'und'. This patch addresses the problem, but I think there will be slight problems if the prefix is also found in 'und' langcode. interdiff included.
- e0ipso Can Picafort
I updated the test config so we can run tests on #61.
Looking forward to see an RTBC here.
- Issue was unassigned.
- 🇮🇳India abhisekmazumdar India
The patch in #61 looks good apply in D10. But I did only see one issue with whitespaces warning throwing up. So created a new patch.
Also remove the Assigned to Unassigned so that people can find and review issue which are open to review.
- last update
over 1 year ago 1 pass, 1 fail - 🇮🇹Italy robertom
The patch in #3111456-63: Unable to resolve path on node in other language than default → seems to work fine, but RedirectPathTranslatorSubscriber does not correctly take into account the language of the selected redirect.
Attached a modified version of the patch and the interdiff
The last submitted patch, 64: decouple_router-3111456-resolve-language-issue-64--get-translation.patch, failed testing. View results →
- codesniffer_fixes.patch Interdiff of automated coding standards fixes only.- last update
about 1 year ago 1 pass, 1 fail - last update
about 1 year ago 1 pass, 1 fail - 🇦🇺Australia Deciphered
Issue reported by Druxt user:
it's failing when there's a URL like: "/fr/test?query=value"
Patch attached cleans additional query string from resolver.
The last submitted patch, 66: decoupled_router-3111456-resolve_lang-66.patch, failed testing. View results →
- codesniffer_fixes.patch Interdiff of automated coding standards fixes only.- Status changed to Needs work
about 1 year ago 10:46am 27 October 2023 - 🇸🇬Singapore vhin0210
Added the patch from Unable to resolve path on path with fragments 🐛 Unable to resolve path on path with fragments Needs review in patch #66 🐛 Unable to resolve path on node in other language than default Needs work
- last update
about 1 year ago 1 pass, 1 fail - 🇺🇸United States mglaman WI, USA
#63 was the last green run. With #64 to support RedirectPathTranslatorSubscriber the tests started to fail, in what looks like a valid failure. #66 looks like a valid addition to the patch, but tests still fail. #66 looks irrelevant because it adds another issue into this patch.
Can someone confirm is the test failure is positive not?
- 🇺🇸United States apmsooner
Not sure why test is failing but #66 works great for me.
- 🇸🇬Singapore vhin0210
Updated patch #68 🐛 Unable to resolve path on node in other language than default Needs work
So this patch has all the fixes from
RouterPathTranslatorSubscriber uses wrong param when resolving the url #2 🐛 RouterPathTranslatorSubscriber uses wrong param when resolving the url Active
Unable to resolve path on path with fragments #2 🐛 Unable to resolve path on path with fragments Needs reviewand #66 🐛 Unable to resolve path on node in other language than default Needs work
- 🇺🇸United States jeffschuler Boulder, Colorado
@vhin0210 is there a reason to add the patches from 🐛 RouterPathTranslatorSubscriber uses wrong param when resolving the url Active and 🐛 Unable to resolve path on path with fragments Needs review to this?
Mixing issues generally makes the individual issues a lot more challenging to test, fix, and get merged by the maintainer.
- 🇩🇪Germany a.dmitriiev
Uploading re-rolled #63, as it was the last one with not failing tests.
- First commit to issue fork.
- 🇮🇳India ankitv18
Rebased the MR!11 with 2.x-dev and pushed minor changes.
Now gitlab pipeline is executing so avoid creating anymore patches, lets try to fix the tests in the MR only. - 🇫🇷France Naim BELKAIED
Updated patch to retrieve the redirect URL corresponding to the language specified in the query parameter path.
eg : http://URL/fr/router/translate-path?path=/en/products/electronics/laptop...
response :{ "resolved": "http://example.com/en/products/electronics/laptops/dell-xps", "isHomePath": false, "entity": { "canonical": "http://example.com/en/products/electronics/laptops/dell-xps", "type": "node", "bundle": "product", "id": "789", "uuid": "def45678-abc1-2345-6789-0abcde123456", "langcode": "en", "path": "/en/products/electronics/laptops/dell-xps" }, "label": "Dell XPS", "jsonapi": { "individual": "http://example.com/en/jsonapi/node/product/def45678-abc1-2345-6789-0abcde123456", "resourceName": "node--product", "pathPrefix": "en/jsonapi", "basePath": "/en/jsonapi", "entryPoint": "http://example.com/en/jsonapi" }, "meta": { }, "redirect": [ { "from": "/en/products/electronics/laptops/dell-xps-15", "to": "/en/products/electronics/laptops/dell-xps", "status": "301" } ] }
- 🇺🇸United States steve.elkins
Updated patch to add support for external redirects borrowing similar changes from #3133681: No information for external redirects → .
Before:
Path Examples
/router/translate-path?path=/external-redirect
/router/translate-path?path=/es/external-redirect{ "message": "Unable to resolve path /external-redirect.", "details": "None of the available methods were able to find a match for this path." }
After:
Path Example: /router/translate-path?path=/external-redirect{ "resolved": "https://google.com", "redirect": [ { "from": "/external-redirect", "to": "https://google.com", "status": "301" } ] }
Path Example: /router/translate-path?path=/es/external-redirect
{ "resolved": "https://google.com", "redirect": [ { "from": "/es/external-redirect", "to": "https://google.com", "status": "301" } ] }
Attached a modified version of the patch and the interdiff.
- 🇫🇮Finland iamfredrik
Patch does not work correctly for me.
In my case the default language is Swedish.
I have a node with path /sv/aktiviteter
/router/translate-path?path=/en/aktiviteter
correctly returns the resolved path /en/activities
but it's unable to translate back and /sv/activities returns:
{"message":"Unable to resolve path \/sv\/activities.","details":"None of the available methods were able to find a match for this path."}