Skip to content
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

FEAT - allow setting of custom csv engine via context #10

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

axcochrane
Copy link

@axcochrane axcochrane commented Apr 26, 2023

This PR allows for the passing of a Custom CSV class (aka a CSV Engine) to replace the custom ruby stdlib CSV class. The initial reason for requiring this feature is that so we can pass a custom CSV Engine which extends the stdlib version to do some pre-processing of the csv object. In our case that is handling issues relating to byte_order_prefixes.

I have made the custom CSV Engine an option via the context hash as I wanted to avoid breaking existing code which expects the positional arguments in a certain order. I also thought using a keyword arguments might be a bit confusing on top of having a context hash.

@axcochrane axcochrane marked this pull request as ready for review April 27, 2023 12:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant