-
Notifications
You must be signed in to change notification settings - Fork 1
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
feat: add schema definition for project keys table #169
Conversation
Getting a test failure for https://github.com/digidem/mapeo-core-next/blob/38ab9de01c83f99cd161c0a76317c395209b097c/tests/schema.js#L87 Does there need to be a backlink table for this new table? |
No, that test needs updated. There only need to be backlink tables for tables that index data types from Mapeo Schema. This test is a bit fragile and more of a reminder - open to ideas about a sensible way to exclude a table like this from needing a backlink table. |
Yes, I think name is
We're naming all our other tables in camelcase. Don't think we need to stick with any conventions here, just what is easy and consistent. I think plural makes sense (e.g.
Yes, let's rename it
Yes, good idea. Or dynamically generate the table schema based on that constant?
|
I don't have any elegant ideas here. Only ones I have are:
then update the test to only import from the EDIT: looks like (2) doesn't work well with Drizzle's CLI (i.e. when re-exporting like EDIT 2: decided to update the tests to filter using |
Might be better if I create a separate issue for this since nothing in this PR is actually going to affect that EDIT: add any thoughts on this to #171 |
06ec2f3
to
4a2b140
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me
Going to merge without addressing this here. There's an issue opened in the schema repo to track and eventually address: https://github.com/digidem/mapeo-schema/issues/114 |
Closes #165
Questions:
project
table to something likeproject_info
? Didn't think it was highly necessary so only updated the associated variable name for nowprojectKeys
(consistent with our naming conventions) vsproject_keys
(consistent with sqlite table naming conventions. also, singular or plural here?projectKey
column be namedprojectId
instead? Should it be more specific i.e.projectPublicKey
?