ajdamico / lodown

locally download and prepare publicly-available microdata
GNU General Public License v3.0
97 stars 47 forks source link

dhs error #124

Closed majazaloznik closed 6 years ago

majazaloznik commented 7 years ago

Hi Anthony! I'm trying to download dhs files and I get the following: Error: length(project.line) == 1 is not TRUE Any ideas? Thanks!

ajdamico commented 6 years ago

hi, i need more detail to troubleshoot this bug. could you send the lines of code that trigger the error (with your password squelched), and then the traceback() after it occurs? thanks

majazaloznik commented 6 years ago

Here's what I have, hope this helps: > traceback() 5: stop(msg, call. = FALSE, domain = NA) 4: stopifnot(length(project.line) == 1) 3: dhs_authenticate(your_email, your_password, your_project) 2: cat_fun(data_name = data_name, output_dir = output_dir, ...) 1: get_catalog("dhs", your_email = "maja.zaloznik@gmail.com", your_password = "XXXXXX", your_project = "Cross-cultural variation in contraceptive decision making")

ajdamico commented 6 years ago

hmm i bet the your_project line is causing the problem. i don't really have a way to test out the authentication on any project other than my own, which is simply your_project = "asdfree"

majazaloznik commented 6 years ago

you're thinking spaces and special characters? I'll try that, cheers!

majazaloznik commented 6 years ago

Interesting, has to do with length of the project name, I didn't do exhaustive test, but here are the ones I tried: Cross-cultural variation in contraceptive decision making - Error Cross cultural variation in contraceptive decision making - Error Cross cultural variation in contraceptive decision - Error Cross cultural variation in - OK contraceptive decision - OK I can close this as far as I am concerned, thanks for your prompt responses!