techdivision / import

This is a library that provides generic functionalities for the implementation of imports. In addition to maximum performance and optimized memory consumption, Pacemaker can also be used to implement imports in distributed scenarios that place the highest demands on speed and stability.
https://pacemaker.techdivision.com
MIT License
128 stars 23 forks source link

Properly support slashes in Category names #209

Closed amenk closed 3 years ago

amenk commented 3 years ago

See #194 #198

We have slashes in category names (something like Valves 1/2")

Describe the solution you'd like

In https://github.com/techdivision/import/blame/master/src/Assembler/CategoryAssembler.php#L152 we should use a CSV implode instead of a simple implode.

Describe alternatives you've considered

Removing slashes? but that is not an option :)

Additional context

If we have such a category tree

tree

This would lead twice to the key Foo/Bar, for ID = 2 as well as ID = 3, so the array indexes collide and the ID = 2 will be overwritten.

amenk commented 3 years ago

@danielimi will try to use the csvSerializier here to add escaping