PacificEMIS / pacific-emis-education-survey-tool

Pacific EMIS Education Survey Tool is the android app used for survey data collection integrated with the Pacific EMIS
GNU General Public License v3.0
1 stars 4 forks source link

Simple renaming of operating mode #72

Open ghachey opened 4 months ago

ghachey commented 4 months ago

Currently the Education Survey Tool can operate in either of the following mode:

There is a very minor issue with this. The Google Service Account keys used for the Development mode ends with _test (e.g. pacemis-education-survey-tool-test.json). To make this more clear I think the easiest is to simply rename the mode "Development" to "Testing" in the app. The other approach would be to create yet a whole new set of Google Service Accounts and rename it with _dev (e.g. pacemis-education-survey-tool-dev.json) but due to lots of files in those existing service accounts it might be more effort.

The related firebase remote configuration is currently "service_account_key_dev" which should be renamed "service_account_key_test". This way we end up with a clean naming convention:

The production remains the same with the following:

And we now are also in the process of creating a third one called Training.

Of course, the exact same as above is true for all contexts (countries).

For the transition the current Firebase config: service_account_key_dev shall remain there containing the same key as the service_account_key_test so that older app versions continue operating as expected with the same Google Service Account.

A little pain with this easy work now I think will make it more clear for posterity and anybody else working on the project in the future.

ghachey commented 2 months ago

@maratomega OK, this seems mostly done. Some remaining cleanups include:

But now is not the best time for it. Will leave this open until this final cleanup takes place.

ghachey commented 2 months ago

@maratomega Can I just get a confirmation from the developers that the firebase "prod_cert" key is no longer used in the new build provided? That it was completely replaced with "service_account_key_prod" (for the Production mode) and of course also

maratomega commented 2 months ago

@ghachey Clipboard - , 10_07 if it's not enough we can also share the sceensshots were in the code it used

ghachey commented 2 months ago

@ghachey Clipboard - , 10_07 if it's not enough we can also share the sceensshots were in the code it used

That is perfect.

ghachey commented 2 months ago

@maratomega I confirm that I have created all the context and photo folders for all the existing service accounts. A sample is shown below.

Screenshot 2024-05-08 130649

This means there is a CONTEXT and CONTEXT\photos folder in each of the prod, test and train accounts for each country deployment.

In addition to each country deployment there is also the default project Pacific EMIS (context is PACEMIS) which will eventually be used as demo, etc. and it too has the prod, test and train service accounts (and thus modes).

Does this make sense?

ghachey commented 2 months ago

@maratomega And your developers will find me annoying for this but I will request one final related little adjustment to be 100% consistent and clear. To follow the new terminology I would like them to edit the name of the firebase key shown below to "service_account_key_test". This will have to be done in each Firebase project.

image

This will of course then have to be edited at the relevant places in your code (like the one you showed me above).