Giter Club home page Giter Club logo

Comments (8)

deads avatar deads commented on July 23, 2024

Can you do swig -version and paste the output?

from paratext.

jengelman avatar jengelman commented on July 23, 2024
SWIG Version 3.0.10

Compiled with g++ [x86_64-apple-darwin11.4.2]

Configured options: +pcre

from paratext.

deads avatar deads commented on July 23, 2024

The -> arrow notation is Python 3 syntax. The most likely reason for this error is you compiled paratext with Python 3 and imported it with Python 2.

Another thing to note: the stack trace indicates you are pulling from the current directory rather than the prefix where you installed Paratext.

from paratext.

jengelman avatar jengelman commented on July 23, 2024

@deads Tried recompiling with Python2, cd'd to the tests folder, and ran the following

import paratext
df = paratext.load_csv_to_pandas("hepatitis.csv")

and got the following error:

Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/Users/joshengelman/miniconda2/envs/paratext/lib/python2.7/site-packages/paratext/core.py", line 403, in load_csv_to_pandas
    return pandas.DataFrame.from_items(expanded)
  File "/usr/local/lib/python2.7/site-packages/pandas/core/frame.py", line 1158, in from_items
    keys, values = lzip(*items)
  File "/Users/joshengelman/miniconda2/envs/paratext/lib/python2.7/site-packages/paratext/core.py", line 355, in load_csv_to_expanded_columns
    for name, col, semantics, levels in load_raw_csv(filename, *args, **kwargs):
  File "/Users/joshengelman/miniconda2/envs/paratext/lib/python2.7/site-packages/paratext/core.py", line 298, in load_raw_csv
    loader = internal_create_csv_loader(filename, *args, **kwargs)
  File "/Users/joshengelman/miniconda2/envs/paratext/lib/python2.7/site-packages/paratext/core.py", line 188, in internal_create_csv_loader
    loader.load(_make_posix_filename(filename), params)
  File "/Users/joshengelman/miniconda2/envs/paratext/lib/python2.7/site-packages/paratext_internal.py", line 530, in load
    return _paratext_internal.ColBasedLoader_load(self, filename, params)
RuntimeError: locale::facet::_S_create_c_locale name not valid

from paratext.

deads avatar deads commented on July 23, 2024

Does the solution suggested here work?

from paratext.

jengelman avatar jengelman commented on July 23, 2024

It did not. I checked the language settings, and they look correct:

(paratext) Joshs-MacBook-Pro:tests joshengelman$ locale
LANG="en_US.UTF-8"
LC_COLLATE="en_US.UTF-8"
LC_CTYPE="en_US.UTF-8"
LC_MESSAGES="en_US.UTF-8"
LC_MONETARY="en_US.UTF-8"
LC_NUMERIC="en_US.UTF-8"
LC_TIME="en_US.UTF-8"
LC_ALL="en_US.UTF-8"`

from paratext.

deads avatar deads commented on July 23, 2024

Does export LC_ALL="C" work for you?

from paratext.

jengelman avatar jengelman commented on July 23, 2024

Yup, thanks!

from paratext.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.