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

Doesn't work with "file" option #7

Open
nigelhorne opened this issue Sep 19, 2017 · 2 comments
Open

Doesn't work with "file" option #7

nigelhorne opened this issue Sep 19, 2017 · 2 comments

Comments

@nigelhorne
Copy link

$self->{'data'} = Text::CSV::Slurp->load(file => $slurp_file, %options);

gives:

Can't call method "getline" on an undefined value at /Users/hornenj/perl5/perlbrew/perls/perl-5.26.0/lib/site_perl/5.26.0/Text/CSV/Slurp.pm line 97.

Also looks like you don't check if the Text::CSV->new() fails.

@nigelhorne
Copy link
Author

nigelhorne commented Sep 19, 2017

		my %options = (
			allow_loose_quotes => 1,
			blank_is_undef => 1,
			empty_is_undef => 1,
                            f_file => $slurp_file,
			binary => 1,
			escape_char => '\\',
			sep_char => '!',
		);

@nigelhorne
Copy link
Author

Update:

The problem is caused by the f_file entry in options.

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

No branches or pull requests

1 participant