bugraoz93 commented on code in PR #64124:
URL: https://github.com/apache/airflow/pull/64124#discussion_r2983146794


##########
scripts/ci/prek/ts_compile_lint_ui.py:
##########
@@ -50,8 +52,20 @@
         all_ts_files.append("src/vite-env.d.ts")
     print("All TypeScript files:", all_ts_files)
 
-    run_command(["pnpm", "config", "set", "store-dir", ".pnpm-store"], cwd=dir)
-    run_command(["pnpm", "install", "--frozen-lockfile", 
"--config.confirmModulesPurge=false"], cwd=dir)
+    hash_file = AIRFLOW_ROOT_PATH / ".build" / "ui" / "pnpm-install-hash.txt"

Review Comment:
   Small nit, we are utilising another common file here for UI directory 
hashes. It is totally okay to follow different since these are standalone 
scripts. 
   It could be useful if let's say compile write the hash from `breeze 
start-airflow` or build the prod image locally and while doing `prek run` this 
can leverage what is already generated as well. Both using the sha and 
hexdigest but it could require full matching hashes to be work.
   
   How there hash generated
   
https://github.com/apache/airflow/blob/c8ad7a9851596c499c57839fdf306ef80bc7d1c6/scripts/ci/prek/compile_ui_assets.py#L45-L54
    
   
   Where we are using hash files
   
https://github.com/apache/airflow/blob/c8ad7a9851596c499c57839fdf306ef80bc7d1c6/scripts/ci/prek/compile_ui_assets.py#L35
   
   
https://github.com/apache/airflow/blob/c8ad7a9851596c499c57839fdf306ef80bc7d1c6/scripts/ci/prek/compile_ui_assets_dev.py#L37-L41



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to