-
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
What's the best way to know if you're still only on the initial project? #751
Comments
Solutions in order of preference:
I prefer to store this in
Footnotes |
@EvanHahn yeah i think what you've outlined makes sense. there's probably a way to add support for this in core without it being too tied to application-purposes but agree that we're already kind of deep in it in terms of how tied to comapeo it is, so probably doesn't matter too much overall. i guess then the basic ask here is where does this kind of information live? my guess is that this would live in the client or project database |
Yeah, maybe on that |
There's two places on the top of my head where we could add this:
I should check how we set projectSettings. e.g. if when starting mapeo, before joining a project, we call if we add it to |
My gut says to put it on |
could you have multiple "lonely" projects? I'm wondering if that means multiple and unrelated |
I think there's a 1:1 relationship between |
I imagine there's a reason, but couldn't help wonder why is there a need for a user to always be in a project? Couldn't just like, not be in a project when starting the app? Or is there some reason for that being hard?? |
I don't think there's a technical requirement. I think we want people to be able to use the app on a "lonely" project before inviting others.
|
Just found this now when reviewing mapeo schema code. The problem with this is that this data syncs. The concept of "isInitialProject" only makes sense on the device that created the project. I know currently we do not allow the initial project to sync, but that could always change. The concept of "initial project" is device specific, not project specific. Two ways forward:
I think option (1) is probably preferable at this stage. Re-opening for now, we can close when we agree on a way forward and open another issue for that. |
I think the issue behind this problem needs resolved in a UX change. I'm not sure when exactly the concept of a new user needing to "create" a project, rather than just inviting users to their current project, came in, and it would benefit from a review at some point. |
Good point, this is a bug waiting to happen. I agree that I think the best path forward would be to leave it as is, even though it's imperfect. If the MVP were farther away, I'd say do it now, but we plan to release very soon. |
I assumed, wrongly, that the frontend was already using this value. I'll plan to remove it tomorrow and have the frontend store the value instead. |
[Gregor rightly pointed out that this value is synced][0]. Given that this value is currently unused on the frontend, we should remove it. [0]: digidem/comapeo-core#751 (comment)
Removed in https://github.com/digidem/mapeo-schema/pull/253. |
[Gregor rightly pointed out that this value is synced][0]. Given that this value is currently unused on the frontend, we should remove it. [0]: digidem/comapeo-core#751 (comment)
We currently do a rather fragile check to determine if the user hasn't explicitly created a new project and they're still on the "initial" project:
https://github.com/digidem/comapeo-mobile/blob/d2cae1759edb7c63d8a0c6ae8168ee1720d7fd9a/src/frontend/screens/Sync/index.tsx#L59-L66
This will eventually break when we introduce the ability to properly leave the "initial" project (UI introduced via digidem/comapeo-mobile#162 but actual functionality will be introduced via digidem/comapeo-mobile#525).
There are a couple of ways to go about this off the top of my head:
client-side approach: store the project id of the initial project in client-side storage (e.g. MMKV, secure storage, etc). what happens if the relevant entry is deleted or lost?
server-side approach: expose some kind of option in the core api when creating a project to essentially label a project as a "private" project i.e. not intended or possible to share with others. Not sure how keen i am on this approach because ideally core shouldn't really care about this, as it's kind of application-specific.
The text was updated successfully, but these errors were encountered: