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

Scrape account which begins with a hyphen? #27

Open
PetroSOC opened this issue Jun 2, 2022 · 7 comments
Open

Scrape account which begins with a hyphen? #27

PetroSOC opened this issue Jun 2, 2022 · 7 comments

Comments

@PetroSOC
Copy link

PetroSOC commented Jun 2, 2022

Is there a way to get images from an account which begins with a hyphen ("-username")? So far I've tried encapsulating in double-quotes, single-quotes, and also escaping the "-" character like \-username, but no joy. All attempts result in a JSON key error.

@intothevoid33
Copy link

Have the same issue. Doesn't seem like any additions / changes to the string helps.

@mvabdi
Copy link
Owner

mvabdi commented Jun 3, 2022

This is a cool edge case. Do you guys have an account I can test it with until I fix it?

@intothevoid33
Copy link

Sure, thanks for looking into it.

-mik

@amastis
Copy link

amastis commented Jul 28, 2022

Here is an account with a hyphen
https://vsco.co/-username-/gallery

@mvabdi
Copy link
Owner

mvabdi commented Jul 31, 2022

I'll add this in probably within the next week.

@billyklubb
Copy link

Hello, not sure if people are still having an issue with profiles that start with a dash, the fix is in the way you initiate the command.

you need to construct the command like this:
vsco-scraper -i -- -username (note the double dashes between the command and the hyphened username)

-- (double-dash) in a shell command indicates the end of options and incapacitates further option processing for the Unix or Linux command.

Coincidentally, the same is true on the command line when you try to change into a directory that has a leading dash.

"cd -- -folder_name" will tell the preceding command to ignore any following dashes as input, failure to add the double dashes will prevent you from cd'ing into the folder then you will get an error.

I hope this helps... =)

@bebunw
Copy link

bebunw commented Dec 13, 2023

Hello, not sure if people are still having an issue with profiles that start with a dash, the fix is in the way you initiate the command.

you need to construct the command like this: vsco-scraper -i -- -username (note the double dashes between the command and the hyphened username)

-- (double-dash) in a shell command indicates the end of options and incapacitates further option processing for the Unix or Linux command.

Coincidentally, the same is true on the command line when you try to change into a directory that has a leading dash.

"cd -- -folder_name" will tell the preceding command to ignore any following dashes as input, failure to add the double dashes will prevent you from cd'ing into the folder then you will get an error.

I hope this helps... =)

It worked, thanks

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

6 participants