Skip to content

Commit

Permalink
Merge pull request #39 from Chronolens/db_fix
Browse files Browse the repository at this point in the history
  • Loading branch information
afonsofrancof authored Nov 10, 2024
2 parents 9e509fc + 6163094 commit f54a2f4
Show file tree
Hide file tree
Showing 10 changed files with 14 additions and 13 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/api_publish.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ env:

# There is a single job in this workflow. It's configured to run on the latest available version of Ubuntu.
jobs:
build-and-push-image:
build-and-push-api-image:
runs-on: ubuntu-latest
# Sets the permissions granted to the `GITHUB_TOKEN` for the actions in this job.
permissions:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/libheif_publish.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ env:

# There is a single job in this workflow. It's configured to run on the latest available version of Ubuntu.
jobs:
build-and-push-image:
build-and-push-libheif-image:
runs-on: ubuntu-latest
# Sets the permissions granted to the `GITHUB_TOKEN` for the actions in this job.
permissions:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/preview_publish.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ env:

# There is a single job in this workflow. It's configured to run on the latest available version of Ubuntu.
jobs:
build-and-push-image:
build-and-push-preview-image:
runs-on: ubuntu-latest
# Sets the permissions granted to the `GITHUB_TOKEN` for the actions in this job.
permissions:
Expand Down
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -33,3 +33,4 @@ Cargo.lock

.env
.session.vim
.secrets
2 changes: 1 addition & 1 deletion api/src/routes/upload_image.rs
Original file line number Diff line number Diff line change
Expand Up @@ -196,7 +196,7 @@ pub async fn upload_image(
}
}
}
return (StatusCode::OK,file_uuid.to_string()).into_response();
return (StatusCode::OK, file_uuid.to_string()).into_response();
}
(StatusCode::BAD_REQUEST).into_response()
}
8 changes: 4 additions & 4 deletions database/migration/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@ mod m001_setup;
mod m002_user;
mod m003_media;
mod m004_face;
mod m005_media_face;
mod m006_cluster;
mod m005_cluster;
mod m006_media_face;
mod m007_log;

pub struct Migrator;
Expand All @@ -18,8 +18,8 @@ impl MigratorTrait for Migrator {
Box::new(m002_user::Migration),
Box::new(m003_media::Migration),
Box::new(m004_face::Migration),
Box::new(m005_media_face::Migration),
Box::new(m006_cluster::Migration),
Box::new(m005_cluster::Migration),
Box::new(m006_media_face::Migration),
Box::new(m007_log::Migration),
]
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,5 +36,5 @@ impl MigrationTrait for Migration {
pub enum Cluster {
Table,
Id,
FaceId
FaceId,
}
File renamed without changes.
2 changes: 1 addition & 1 deletion database/src/schema/media_face.rs
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ pub struct Model {
pub media_id: String,
pub embedding: Vec<f32>,
pub face_bounding_box: Vec<f32>,
pub cluster_id: i32
pub cluster_id: i32,
}

#[derive(Copy, Clone, Debug, EnumIter, DeriveRelation)]
Expand Down
6 changes: 3 additions & 3 deletions database/src/schema/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@
pub mod prelude;

pub mod user;
pub mod media;
pub mod media_face;
pub mod cluster;
pub mod face;
pub mod log;
pub mod media;
pub mod media_face;
pub mod user;

0 comments on commit f54a2f4

Please sign in to comment.