Skip to content

[Review Stack] #872 on #857#7

Open
akira69 wants to merge 1 commit intoreview/857-on-860from
review/872-on-857
Open

[Review Stack] #872 on #857#7
akira69 wants to merge 1 commit intoreview/857-on-860from
review/872-on-857

Conversation

@akira69
Copy link
Copy Markdown
Owner

@akira69 akira69 commented Mar 13, 2026

This is a fork-only stacked review PR for upstream Donkie/Spoolman#872.

Use this PR for true stacked review diff only.

Chain:

  • Base upstream foundation: #846
  • Prior stacked review layer: review/857-on-860
  • This review branch: review/872-on-857

Notes:

  • The code/content matches the current canonical feat/manufacturer-logo-github-sync-upstream-split branch tree.
  • The canonical upstream PR branch remains flat against master so the upstream PR stays clean.
  • This review PR exists only to render the stacked diff cleanly.

Copy link
Copy Markdown

@chatgpt-codex-connector chatgpt-codex-connector bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 0f1ba3e09d

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread spoolman/vendor_logos.py Outdated
Comment on lines +608 to +609
if len(web_files) == 0:
raise RuntimeError("ZIP archive did not contain any supported logo image files.")
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Allow ZIP imports that only contain print logos

The importer currently raises an error whenever no web/logo files are found, even if the archive contains valid images under print/ or logos/ that were already parsed into print_files. This makes print-only logo packs impossible to import, despite the surrounding import flow explicitly supporting print-targeted assets, so users with label-only packs will always get a hard failure.

Useful? React with 👍 / 👎.

Comment thread spoolman/vendor_logos.py Outdated
print_files: list[str] = []

if source_web_dir is not None:
for source_file in sorted(source_web_dir.rglob("*.png")):
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Match PNG extension case-insensitively during GitHub sync

The remote tree scan treats .png case-insensitively (path.lower().endswith(".png")), but the archive copy step uses rglob("*.png"), which is case-sensitive on Linux. Repos that contain files like LOGO.PNG will be counted in the signature and remote counts but never copied locally, leaving the runtime pack incomplete while later sync checks still report it as current.

Useful? React with 👍 / 👎.

Comment thread spoolman/vendor_logos.py Outdated
Comment on lines +479 to +480
dest_file = web_dir / source_file.name
shutil.copy2(source_file, dest_file)
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Avoid overwriting same-named files from nested logo folders

When syncing from GitHub, every source file is flattened to source_file.name, so two different paths like web/brandA/logo.png and web/brandB/logo.png will overwrite each other in the runtime pack. This silently drops logos and can make suggestions point to the wrong image for repositories that organize assets in subdirectories.

Useful? React with 👍 / 👎.

@akira69 akira69 force-pushed the review/857-on-860 branch from b555eaa to 837aafe Compare March 15, 2026 14:36
@akira69 akira69 force-pushed the review/872-on-857 branch 2 times, most recently from dea6ca6 to 3910c1f Compare March 16, 2026 02:49
@akira69 akira69 force-pushed the review/857-on-860 branch from 06c9825 to d127692 Compare March 17, 2026 15:15
@akira69 akira69 force-pushed the review/872-on-857 branch from 3910c1f to 992a00e Compare March 17, 2026 15:15
@akira69 akira69 force-pushed the review/857-on-860 branch from fda598b to 741d993 Compare March 18, 2026 22:44
@akira69 akira69 force-pushed the review/872-on-857 branch from b541a65 to 69de241 Compare March 18, 2026 22:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant