-
Setup Environment:
git clone [email protected]:BlockScience/koi-net-gdrive-sensor-node.git cd koi-net-gdrive-sensor-node # Optional: Create Virtual Environment # python -m venv ./venv # source ./venv/bin/activate git checkout dev python -m pip install --upgrade pip pip install -r requirements.txt # location of all metadata including caches and identities mkdir net/metadata
-
Authentication Options:
-
Setup Developement Environment:
a. User Authentication - Quickstart / Testing Environment: Quickstart with Personal Google Account authentication and authorization flow - Following the steps in Google API Quickstart
b. Service Account Authentication: A User Account dedicated to the GDrive Sensor Full
Node web application -
Execute the following to download credentials:
# Run GDrive API python -m experiments.gdrive_api_exp
-
-
Setup Google Drive (KOI) Sensor Net:
- Coordinator Terminal:
python -m net.basic_coordinator_node
- Full Node Terminal(s):
python -m gdrive_sensor
Testing:
- Integration Test Backfill by asserting Cache & Drive Equivalence as a result of a Backfill for mimetTypes defiend as RIDs:
- Should Pass for Types are defined as RIDs:
pytest -v test_backfill.py::Test_TypedCachesAndTypedDriveAreEquivalent
- Should Fail until ALL Types are defined as RIDs:
pytest -v test_backfill.py