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

Following the setup instructions leads to error #47

Open
Aditya94A opened this issue Nov 29, 2020 · 2 comments
Open

Following the setup instructions leads to error #47

Aditya94A opened this issue Nov 29, 2020 · 2 comments
Labels
bug Something isn't working

Comments

@Aditya94A
Copy link

Traceback (most recent call last):
  File "booking.py", line 214, in <module>
    get_data(args.rooms, args.country, args.out_format, args.startdate, args.enddate)
  File "booking.py", line 153, in get_data
    save_data(hotels_list, out_format=out_format, country=country)
  File "booking.py", line 164, in save_data
    file = writer.output_file()
  File "C:\Projects\bookingscraper\file_writer.py", line 22, in output_file
    json.dump(list(self.data), outfile, indent=2, ensure_ascii=False)
  File "C:\Users\user\AppData\Local\Programs\Python\Python37\lib\json\__init__.py", line 180, in dump
    fp.write(chunk)
  File "C:\Users\user\AppData\Local\Programs\Python\Python37\lib\encodings\cp1252.py", line 19, in encode
    return codecs.charmap_encode(input,self.errors,encoding_table)[0]
UnicodeEncodeError: 'charmap' codec can't encode character '\u01c0' in position 23: character maps to <undefined>

Got this after python booking.py. Does it require any arguments or config changes?

@Aditya94A
Copy link
Author

All the tests are also failing with this same output

@ZoranPandovski
Copy link
Owner

Thanks for reporting this @AdityaAnand1. It's been around 1 year since I've last used this scraper. I will try to fix this when I have free time. If you want to contribute and track the issue feel free to make PR

@ZoranPandovski ZoranPandovski added the bug Something isn't working label Nov 29, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants