-
Notifications
You must be signed in to change notification settings - Fork 9.4k
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
CatalogImportExport categoryProcessor does not support escaped delimiter #6948
Comments
I encountered the same issue and I was able to modify the method to make it work. Right when I was about to create a new bug report, I found this one.
Please find my tested and working solution below:
It might be possible to obtain a cleaner version but it is working perfectly as intended. Use Example:
Final Result:
|
Hello, Any news on this issue? Thanks |
Hello, @koenner01. There has been created an internal ticket-MAGETWO-70462 based on Your issue. You'll be informed after it is resolved. Thanks for applying. |
@koenner01, thank you for your report. |
…escaped delimiter
Internal ticket to track issue progress: MAGETWO-83131 |
The issue has been fixed and delivered to 2.3-develop branch |
@okobchenko anyway to get this working in 2.2.x? I have 2.2.7 |
@travis5491811 : you can try to patch #11801 into your installation using this guide (at the moment of writing, this link doesn't appear to work due to some Magento/Zendesk server being down, but hopefully it will work again in the near future) When going for this patch approach, you'll run into a conflict on 2.2.7 with the file But if you don't have much experience with patches, the easiest will be to only patch the files
|
@hostep thanks for the heads up about the article and what to do. I'm trying to proceed without
This is my first time trying to patch. I followed the article and when I run When editing my patch file I used
Assuming I should specify the path relative to project root (
That last command made me realize there is no |
Sorry, I'm a bit busy at the moment, maybe I'll find some time later today to help you figure this out, but no promises. Regarding your last comment, about missing files, that can't be, because they are there in 2.2.7:
As for the paths in the diff file, they should be relative towards the module, so towards Hope you can already try to proceed with this info now :) |
@hostep you're correct. I'm not sure why I wasn't seeing the files yesterday. They are there. Maybe i'm just loosing my mind because composer is saying they are not there. if the paths should start with Thanks for trying to help! The patch guide was helpful and got me close. I changed the path's back to original For now i'm going to write a script that changes all the For anybody else that see's this, here are my exact steps and files summarized and modified after following this.
That should give you the following file:
|
I still have this issue in magento 2.4.2 |
When trying to import a category with an escaped '/' through the import functionality of MG2, the import will create an unwanted extra category because there is no support for escaped delimiters.
Preconditions
Steps to reproduce
Expected result
Actual result
A possible solution would be:
In \Magento\CatalogImportExport\Model\Import\Product\Category there is a function upsertCategory.
The explode on the delimiter does not take into account any escaped delimiters. To create support for categories with the delimiter character in their name, the line should be changed to something like
$pathParts = preg_split('~(?<!\\\)' . preg_quote(self::DELIMITER_CATEGORY, '~') . '~', $categoryPath);
After that the escaped delimiter part should be replaced with the delimiter character.
The text was updated successfully, but these errors were encountered: