mirror of
https://github.com/storytold/artcraft.git
synced 2026-10-20 17:02:53 -04:00
don't instrument thumbnails / cover files
This commit is contained in:
+3
-5
@@ -12,7 +12,6 @@ use enums::common::platform_type::PlatformType;
|
||||
use enums::common::visibility::Visibility;
|
||||
use tokens::tokens::anonymous_visitor_tracking::AnonymousVisitorTrackingToken;
|
||||
use tokens::tokens::media_files::MediaFileToken;
|
||||
use tokens::tokens::generic_inference_jobs::InferenceJobToken;
|
||||
use tokens::tokens::prompts::PromptToken;
|
||||
use tokens::tokens::users::UserToken;
|
||||
|
||||
@@ -40,9 +39,6 @@ where
|
||||
pub maybe_prompt_token: Option<&'a PromptToken>,
|
||||
pub maybe_platform_type: Option<PlatformType>,
|
||||
|
||||
/// The generation job the cover belongs to.
|
||||
pub maybe_source_job_token: Option<&'a InferenceJobToken>,
|
||||
|
||||
pub mysql_executor: E,
|
||||
pub phantom: PhantomData<&'c E>,
|
||||
}
|
||||
@@ -99,7 +95,9 @@ where
|
||||
is_user_upload: false,
|
||||
maybe_audio_encoding: None,
|
||||
maybe_batch_token: None,
|
||||
maybe_source_job_token: args.maybe_source_job_token,
|
||||
// NB: Covers/thumbnails never carry a source job token — only the primary
|
||||
// outputs of a job do.
|
||||
maybe_source_job_token: None,
|
||||
maybe_cover_image_media_file_token: None,
|
||||
maybe_creator_category_synthetic_id: None,
|
||||
maybe_creator_file_synthetic_id: None,
|
||||
|
||||
@@ -228,7 +228,6 @@ async fn download_and_upload_thumbnail(
|
||||
.file_size_bytes(thumb_bytes.len() as u64)
|
||||
.checksum_sha2(&checksum)
|
||||
.maybe_prompt_token(job.maybe_prompt_token.as_ref())
|
||||
.maybe_source_job_token(Some(&job.job_token))
|
||||
.maybe_platform_type(job.maybe_platform_type)
|
||||
.public_bucket_directory_hash(&bucket_path)
|
||||
.insert_pool(&deps.mysql_pool)
|
||||
|
||||
@@ -238,7 +238,6 @@ async fn download_and_upload_thumbnail(
|
||||
.file_size_bytes(thumb_bytes.len() as u64)
|
||||
.checksum_sha2(&checksum)
|
||||
.maybe_prompt_token(job.maybe_prompt_token.as_ref())
|
||||
.maybe_source_job_token(Some(&job.job_token))
|
||||
.maybe_platform_type(job.maybe_platform_type)
|
||||
.public_bucket_directory_hash(&bucket_path)
|
||||
.insert_pool(&deps.mysql_pool)
|
||||
|
||||
-1
@@ -128,7 +128,6 @@ pub(crate) async fn attach_cover_image(
|
||||
public_bucket_path: &public_upload_path,
|
||||
maybe_origin_product_category,
|
||||
maybe_prompt_token: job.maybe_prompt_token.as_ref(),
|
||||
maybe_source_job_token: Some(&job.job_token),
|
||||
maybe_platform_type: job.maybe_platform_type,
|
||||
mysql_executor: &server_state.mysql_pool,
|
||||
phantom: Default::default(),
|
||||
|
||||
Reference in New Issue
Block a user