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

Support indexes, add Index and Unique annotation #123

Merged
merged 16 commits into from
Nov 29, 2020

Conversation

greenrobot-team
Copy link
Member

@greenrobot-team greenrobot-team commented Oct 6, 2020

Continuation of #120

Making progress.

Overall I'm not sure if there should be separate annotations vs. using flags on the existing @Property annotation.

Buggaboo and others added 14 commits September 27, 2020 00:08
…roperty)

The tests keep exploding with this though:

ObjectBoxException: failed to create store: 10501 No index ID/UID assigned for indexed property: Property uByte (15, Byte)

Even objectbox-model.json seems normal.
After turning them off this popped beautiful gem up:
ObjectBoxException: failed to create store: 10001 State condition failed in assignIdsForProperty:476: indexId <= catalog.lastIndexId()
@greenrobot-team greenrobot-team self-assigned this Oct 6, 2020
@Buggaboo
Copy link
Contributor

Buggaboo commented Oct 6, 2020

Unrequested review: I think my isIndexer extension, needs updating to include the other types.

@greenrobot-team
Copy link
Member Author

@Buggaboo Yeah, thanks. This is not done, yet. Hence the draft status.

# Conflicts:
#	generator/lib/src/entity_resolver.dart
#	lib/src/annotations.dart
#	lib/src/bindings/bindings.dart
#	lib/src/bindings/signatures.dart
#	lib/src/modelinfo/modelentity.dart
#	lib/src/modelinfo/modelproperty.dart
#	lib/src/util.dart
#	test/entity.dart
@vaind vaind force-pushed the Buggaboo-feature/annotation-candy branch from 7577849 to 859ba5d Compare November 29, 2020 09:41
@vaind
Copy link
Contributor

vaind commented Nov 29, 2020

Fixed issues, added tests and cleaned up. fast-tracking this to get on with other PRs but please have a look at the changes @greenrobot-team

@vaind vaind marked this pull request as ready for review November 29, 2020 09:53
@vaind vaind merged commit 89bf491 into main Nov 29, 2020
@vaind vaind mentioned this pull request Nov 29, 2020
@greenrobot-team
Copy link
Member Author

@vaind Invalid usages of the annotations and index type are not tested, otherwise LGTM. Thanks for finishing this! (You even caught all TODOs and left-over code removals!)

@vaind vaind deleted the Buggaboo-feature/annotation-candy branch December 31, 2020 09:42
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

Successfully merging this pull request may close these issues.

3 participants