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

Non-standard schemas not accepted for lookup_tables #67

Open
jonoyuan opened this issue May 21, 2020 · 2 comments
Open

Non-standard schemas not accepted for lookup_tables #67

jonoyuan opened this issue May 21, 2020 · 2 comments

Comments

@jonoyuan
Copy link
Contributor

If a non-standard schema is specified in config.yaml for the stress lookup_tables, an error is returned when creating a new instance of pybna.Stress().

Default:

pybna/pybna/config.yaml

Lines 211 to 215 in 14a2766

stress:
lookup_tables:
shared: "generated.stress_shared"
bike_lane: "generated.stress_bike_lane"
crossing: "generated.stress_crossing"

Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "pybna\pybna\stress.py", line 60, in __init__
    self._create_lookup_table(*t)
  File "pybna\pybna\stress.py", line 181, in _create_lookup_table
    cur.copy_from(f,table,columns=[c[0] for c in columns],sep=";",null="")
psycopg2.errors.UndefinedTable: relation "stress_shared" does not exist
@spencerrecneps
Copy link
Contributor

Can you attach the config.yaml you used for me? That will help me pinpoint the problem. Thanks.

@jonoyuan
Copy link
Contributor Author

This is the config file I used with the schema 'bna' for all three tables.

config.zip

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

2 participants