-
Notifications
You must be signed in to change notification settings - Fork 591
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
sqlalchemy.exc.StatementError when adding new sketch from ui #886
Comments
I tried to modify /usr/local/lib/python3.6/dist-packages/timesketch-20190207-py3.6.egg/timesketch/models/acl.py in this way:
Now I am able to create the sketch but only the first one created is shown in gui (the others are accessible specifying the direct url in path, like ..../sketch/7/) Any suggestion? |
Hi, Maybe the last update of sqlalchemy/lib/sqlalchemy/orm/relationships.py: timesketch_1 | /usr/local/lib/python2.7/dist-packages/sqlalchemy/sql/sqltypes.py:268: SAWarning: Unicode type received non-unicode bind param value 'read'. (this warning may be suppressed after 10 occurrences) |
I was using sqlalchemy==1.3.3 |
This is now fixed (#897) - We were setting the ACL before the index was committed to the DB. This broke in recent SQLAlchemy updates. |
If you end up here searching for this error message, it's likely that you're querying a relationship for objects that have not yet been added to a session, so they have no primary key. This is newly an error in SQLAlchemy 1.3; previously it would just return no results. See abrt/faf#764 (comment) for details. |
I'm getting
`
sqlalchemy.exc.StatementError
sqlalchemy.exc.StatementError: (sqlalchemy.exc.InvalidRequestError) Can't resolve value for column sketch.id on object <Sketch at 0x7f675e9aeb38>; no value has been set for this column
[SQL: SELECT sketch_accesscontrolentry.id AS sketch_accesscontrolentry_id, sketch_accesscontrolentry.created_at AS sketch_accesscontrolentry_created_at, sketch_accesscontrolentry.updated_at AS sketch_accesscontrolentry_updated_at, sketch_accesscontrolentry.permission AS sketch_accesscontrolentry_permission, sketch_accesscontrolentry.parent_id AS sketch_accesscontrolentry_parent_id, sketch_accesscontrolentry.user_id AS sketch_accesscontrolentry_user_id, sketch_accesscontrolentry.group_id AS sketch_accesscontrolentry_group_id
FROM sketch_accesscontrolentry
WHERE %(param_1)s = sketch_accesscontrolentry.user_id AND sketch_accesscontrolentry.group_id IS NULL AND sketch_accesscontrolentry.permission = %(permission_1)s AND %(param_2)s = sketch_accesscontrolentry.parent_id]
[parameters: [{}]]
`
when try to add new sketch.
I already dropped postgresql DB and recreated withtout success.
Everything was working until I deleted last sketch from ui.
I tried to install again from git (keeping current config file) with both python2 and pyton3 but same error.
Any help?
The text was updated successfully, but these errors were encountered: