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

Option --hack-translations not work #185

Open
Apkawa opened this issue Aug 10, 2018 · 0 comments
Open

Option --hack-translations not work #185

Apkawa opened this issue Aug 10, 2018 · 0 comments

Comments

@Apkawa
Copy link

Apkawa commented Aug 10, 2018

I got exception

Traceback (most recent call last):
  File "manage.py", line 22, in <module>
    execute_from_command_line(sys.argv)
  File "/usr/local/lib/python3.6/dist-packages/django/core/management/__init__.py", line 364, in execute_from_command_line
    utility.execute()
  File "/usr/local/lib/python3.6/dist-packages/django/core/management/__init__.py", line 356, in execute
    self.fetch_command(subcommand).run_from_argv(self.argv)
  File "/usr/local/lib/python3.6/dist-packages/django/core/management/base.py", line 283, in run_from_argv
    self.execute(*args, **cmd_options)
  File "/usr/local/lib/python3.6/dist-packages/django/core/management/base.py", line 330, in execute
    output = self.handle(*args, **options)
  File "/usr/local/lib/python3.6/dist-packages/cities_light/management/commands/cities_light.py", line 226, in handle
    pickle.dump(self.translation_data, f)
TypeError: write() argument must be str, not bytes

django-cities-light==3.5.0
python-3.6

with open(translation_hack_path, 'w+') as f:

'w+' -> 'wb+'

with open(translation_hack_path, 'r') as f:

'r' -> 'rb'

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