Skip to content

Commit e383bc3

Browse files
committed
chore: Update Android build configs, Map providers, and OSRM services
1 parent 6d83060 commit e383bc3

14 files changed

Lines changed: 86 additions & 23 deletions

File tree

backend/app/main.py

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,9 +17,12 @@
1717
logger = logging.getLogger(__name__)
1818

1919
app = FastAPI(
20-
title=settings.PROJECT_NAME,
20+
title="OpenRescue API",
2121
version=settings.VERSION,
2222
description="OpenRescue Decentralized Emergency System API",
23+
docs_url="/docs",
24+
redoc_url="/redoc",
25+
openapi_url="/openapi.json"
2326
)
2427

2528
app.add_middleware(
@@ -148,6 +151,10 @@ async def shutdown_event() -> None:
148151
def health_check():
149152
return {"status": "ok", "service": settings.PROJECT_NAME}
150153

154+
@app.get("/")
155+
def root():
156+
return {"status": "ok"}
157+
151158
class XMLPayload(BaseModel):
152159
xml_data: str
153160

backend/main.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
from app.main import app

backend/p2p-node/p2p-node

31.5 MB
Binary file not shown.

mobile_app/android/app/build.gradle.kts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ plugins {
77

88
android {
99
namespace = "com.example.mobile_app"
10-
compileSdk = flutter.compileSdkVersion
10+
compileSdk = 34
1111
ndkVersion = flutter.ndkVersion
1212

1313
compileOptions {

mobile_app/android/build.gradle.kts

Lines changed: 26 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,23 +1,37 @@
11
buildscript {
2-
val kotlin_version by extra("1.9.0")
2+
val kotlin_version by extra("2.0.0")
33
repositories {
44
google()
55
mavenCentral()
66
}
77
dependencies {
8-
classpath("com.android.tools.build:gradle:8.3.2")
8+
classpath("com.android.tools.build:gradle:8.4.0")
99
classpath("org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version")
1010
}
1111
}
1212

1313
allprojects {
14-
extra.set("kotlin_version", "1.9.0")
14+
configurations.all {
15+
resolutionStrategy {
16+
eachDependency {
17+
if (requested.group == "androidx.core" && requested.name.startsWith("core")) {
18+
useVersion("1.12.0")
19+
}
20+
if (requested.group == "org.jetbrains.kotlin") {
21+
useVersion("2.0.0")
22+
}
23+
}
24+
}
25+
}
26+
extra.set("kotlin_version", "2.0.0")
1527
repositories {
1628
google()
1729
mavenCentral()
1830
}
1931
}
2032

33+
apply(from = "java17.gradle")
34+
2135
val newBuildDir: Directory =
2236
rootProject.layout.buildDirectory
2337
.dir("../../build")
@@ -35,3 +49,12 @@ subprojects {
3549
tasks.register<Delete>("clean") {
3650
delete(rootProject.layout.buildDirectory)
3751
}
52+
53+
subprojects {
54+
tasks.withType<org.jetbrains.kotlin.gradle.tasks.KotlinCompile>().configureEach {
55+
kotlinOptions {
56+
jvmTarget = "17"
57+
freeCompilerArgs += listOf("-Xskip-metadata-version-check")
58+
}
59+
}
60+
}

mobile_app/android/gradle/wrapper/gradle-wrapper.properties

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,4 +2,4 @@ distributionBase=GRADLE_USER_HOME
22
distributionPath=wrapper/dists
33
zipStoreBase=GRADLE_USER_HOME
44
zipStorePath=wrapper/dists
5-
distributionUrl=https\://services.gradle.org/distributions/gradle-8.4-all.zip
5+
distributionUrl=https\://services.gradle.org/distributions/gradle-8.6-all.zip

mobile_app/android/java17.gradle

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
subprojects {
2+
afterEvaluate { project ->
3+
if (project.hasProperty('android')) {
4+
project.android {
5+
compileOptions {
6+
sourceCompatibility JavaVersion.VERSION_17
7+
targetCompatibility JavaVersion.VERSION_17
8+
}
9+
}
10+
}
11+
}
12+
}

mobile_app/android/settings.gradle.kts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ pluginManagement {
2020
plugins {
2121
id("dev.flutter.flutter-plugin-loader") version "1.0.0"
2222
id("com.android.application") version "8.3.2" apply false
23-
id("org.jetbrains.kotlin.android") version "1.9.0" apply false
23+
id("org.jetbrains.kotlin.android") version "1.9.22" apply false
2424
}
2525

2626
include(":app")

mobile_app/lib/controllers/responder_controller.dart

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -55,12 +55,13 @@ class ResponderController {
5555
debugPrint('Starting tile prefetch for radius');
5656

5757
try {
58-
await _prefetchService.prefetchAroundLocation(
59-
location,
60-
5000.0, // 5km radius
61-
14, // minZoom
62-
16, // maxZoom
63-
);
58+
// Temp disable tile prefetch auto-trigger for isolation test
59+
// await _prefetchService.prefetchAroundLocation(
60+
// location,
61+
// 5000.0, // 5km radius
62+
// 14, // minZoom
63+
// 16, // maxZoom
64+
// );
6465
} catch (e) {
6566
debugPrint('ResponderController: Failed to start prefetch: $e');
6667
}

mobile_app/lib/controllers/route_controller.dart

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,7 @@ class RouteController {
4545
required LatLng start,
4646
required LatLng end,
4747
}) async {
48+
print("Requesting route from $start to $end");
4849
// Clear previous route immediately
4950
_routeStreamController.add(null);
5051

0 commit comments

Comments
 (0)