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

Freshly cloned Agreement Generator crashes #17

Open
bjoernwe opened this issue Jul 18, 2018 · 0 comments
Open

Freshly cloned Agreement Generator crashes #17

bjoernwe opened this issue Jul 18, 2018 · 0 comments

Comments

@bjoernwe
Copy link

Hi! I wanted to test the Agreement Generator. Clicked NEXT in every dialog but finally it crashes:

Traceback (most recent call last):
  File "/usr/lib/python3.6/tkinter/__init__.py", line 1702, in __call__
    return self.func(*args)
  File "make_agreement.py", line 339, in get_answer
    self.next_decision()
  File "make_agreement.py", line 380, in next_decision
    self.next_decision()
  File "make_agreement.py", line 380, in next_decision
    self.next_decision()
  File "make_agreement.py", line 356, in next_decision
    question_data = self.current_set.pop(0)
IndexError: pop from empty list
/usr/local/lib/python3.6/dist-packages/datapackage-1.3.2-py3.6.egg/datapackage/resource.py:408: UserWarning: Property "resource.table" is deprecated. Please use "resource.iter/read" directly.
  UserWarning)
Traceback (most recent call last):
  File "make_agreement.py", line 564, in <module>
    main()
  File "make_agreement.py", line 558, in main
    create_custom(fp, args.agreement_type)
  File "make_agreement.py", line 176, in create_custom
    base_data[name] = resource.table.read(keyed=True)
  File "/usr/local/lib/python3.6/dist-packages/tableschema-1.1.0-py3.6.egg/tableschema/table.py", line 133, in read
    for count, row in enumerate(rows, start=1):
  File "/usr/local/lib/python3.6/dist-packages/tableschema-1.1.0-py3.6.egg/tableschema/table.py", line 77, in iter
    self.__stream.open()
  File "/usr/local/lib/python3.6/dist-packages/tabulator-1.14.0-py3.6.egg/tabulator/stream.py", line 211, in open
    self.__extract_sample()
  File "/usr/local/lib/python3.6/dist-packages/tabulator-1.14.0-py3.6.egg/tabulator/stream.py", line 353, in __extract_sample
    row_number, headers, row = next(self.__parser.extended_rows)
  File "/usr/local/lib/python3.6/dist-packages/tabulator-1.14.0-py3.6.egg/tabulator/parsers/csv.py", line 97, in __iter_extended_rows
    sample, dialect = self.__prepare_dialect(self.__chars)
  File "/usr/local/lib/python3.6/dist-packages/tabulator-1.14.0-py3.6.egg/tabulator/parsers/csv.py", line 108, in __prepare_dialect
    sample.append(next(stream))
  File "/usr/lib/python3.6/encodings/cp1252.py", line 23, in decode
    return codecs.charmap_decode(input,self.errors,decoding_table)[0]
UnicodeDecodeError: 'charmap' codec can't decode byte 0x90 in position 3229: character maps to <undefined>

It also breaks when trying to run with templates (python3 make_agreement.py -a plain -p ./templates/plain.j2):

  File "make_agreement.py", line 564, in <module>
    main()
  File "make_agreement.py", line 536, in main
    create_custom(args.parse, args.agreement_type)
  File "make_agreement.py", line 166, in create_custom
    base_data = json.load(base_fp)
  File "/usr/lib/python3.6/json/__init__.py", line 299, in load
    parse_constant=parse_constant, object_pairs_hook=object_pairs_hook, **kw)
  File "/usr/lib/python3.6/json/__init__.py", line 354, in loads
    return _default_decoder.decode(s)
  File "/usr/lib/python3.6/json/decoder.py", line 339, in decode
    obj, end = self.raw_decode(s, idx=_w(s, 0).end())
  File "/usr/lib/python3.6/json/decoder.py", line 355, in raw_decode
    obj, end = self.scan_once(s, idx)
json.decoder.JSONDecodeError: Expecting property name enclosed in double quotes: line 1 column 2 (char 1)```
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