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

Invenio indexer task process_bulk_queue fails with extended user profile #2198

Open
f-osorio opened this issue Apr 19, 2023 · 6 comments · May be fixed by inveniosoftware/invenio-communities#1069
Assignees
Labels
bug Something isn't working stale No activity for more than 60 days.

Comments

@f-osorio
Copy link

Package version (if known): v.10

Describe the bug

Invenio indexer fails when a user with custom profile belongs to a community. If a user with a custom profile is part of a community, further editing of the profile will cause the following:

ERROR/ForkPoolWorker-3] Task invenio_indexer.tasks.process_bulk_queue[d45d5785-3dea-45f1-9239-81b2f9c39c73] raised unexpected: BulkIndexError('4 document(s) failed to index.', [{'index': {'_index': 'berd-nfdi-communitymembers-members-member-v1.0.0-1681215677', '_id': '889b6c03-2021-4e20-83d7-63eca830dd80', 'status': 400, 'error': {'type': 'strict_dynamic_mapping_exception', 'reason': 'mapping set to strict, dynamic introduction of [...] within [user.profile] is not allowed'}

Steps to Reproduce

  1. Create a custom user profile
  2. Create a user with that profile
  3. Add the account to a community / create a community with the account
  4. Update the profile from /account/settings/profile
  5. See error

Expected behavior

The indexer works without issue.

Additional context

We are adding some custom fields for the user profile. Everything seems to be working great except when the indexer tries to run. It only happens with accounts that belong to a community. If there is no community, there is no problem.

It looks like the schema for users and the schema for community members are at odds. The user schema has the a dynamic profile and the community member does not. At least, this is a best guess about what is happening

There is a test for a custom profile but it only checks that the new field is added.

Everything else seems to be working fine with the expanded profile.

@f-osorio f-osorio added the bug Something isn't working label Apr 19, 2023
@github-actions
Copy link
Contributor

This issue was automatically marked as stale.

@github-actions github-actions bot added the stale No activity for more than 60 days. label Jun 19, 2023
@daglueck
Copy link

This issue still prevents us from customizing user profiles on our platform. Is there anything we can do to help resolve it?

@tmorrell tmorrell removed the stale No activity for more than 60 days. label Sep 15, 2023
@egabancho egabancho self-assigned this Nov 10, 2023
Copy link
Contributor

This issue was automatically marked as stale.

@github-actions github-actions bot added the stale No activity for more than 60 days. label Jan 10, 2024
@Samk13 Samk13 removed the stale No activity for more than 60 days. label Jan 16, 2024
Copy link
Contributor

This issue was automatically marked as stale.

@github-actions github-actions bot added the stale No activity for more than 60 days. label Mar 17, 2024
@egabancho egabancho removed the stale No activity for more than 60 days. label Apr 17, 2024
Copy link
Contributor

This issue was automatically marked as stale.

@github-actions github-actions bot added the stale No activity for more than 60 days. label Jun 17, 2024
@egabancho egabancho removed the stale No activity for more than 60 days. label Jun 18, 2024
Copy link
Contributor

This issue was automatically marked as stale.

@github-actions github-actions bot added the stale No activity for more than 60 days. label Aug 23, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working stale No activity for more than 60 days.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants