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

Named entities aren't being associated with their sentences #49

Open
reefdog opened this issue Mar 28, 2019 · 0 comments
Open

Named entities aren't being associated with their sentences #49

reefdog opened this issue Mar 28, 2019 · 0 comments
Labels
bug Something isn't working

Comments

@reefdog
Copy link
Contributor

reefdog commented Mar 28, 2019

If you add sentenceId to the GraphQL query for named entities — or go a step further and try to actually include and display the associated sentence content — you aren't able to. If you then check Postgres to see what's up, you'll notice all named entity's sentence_id values are NULL.

Evidently when we create named entities, we aren't associating them with sentences properly.

@reefdog reefdog added the bug Something isn't working label Mar 28, 2019
@reefdog reefdog self-assigned this Mar 28, 2019
reefdog added a commit that referenced this issue Mar 28, 2019
Prior to this change, when named entities were created, their appearing
sentence wasn’t being associated because we were trying to store its ID
in `sentenceId` instead of `sentence_id`, the latter of which is the
actual Postgres column name.

However, by explictly snake-casing at this point, we may be breaking
some of the correct stitching of snake-cased Postgres fields to
camelCased object attributes, and so we need to debug whether this is
all associated together correctly by Sequelize and queryable by GraphQL.

Affects #49
reefdog added a commit that referenced this issue Mar 28, 2019
Prior to this change, when named entities were created, their appearing
sentence wasn’t being associated because we were trying to store its ID
in `sentenceId` instead of `sentence_id`, the latter of which is the
actual Postgres column name.

However, by explicitly snake-casing at this point, we may be breaking
some of the correct stitching of snake-cased Postgres fields to
camelCased object attributes, and so we need to debug whether this is
all associated together correctly by Sequelize and queryable by GraphQL.

Affects #49
@reefdog reefdog removed their assignment Oct 9, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant