Skip to content

Fixed the previous fix of the anti-nag hook #6095

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Draft
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

imcrazytwkr
Copy link
Contributor

@imcrazytwkr imcrazytwkr commented Jul 20, 2025

✍️ Description

Yesterday's fix of the anti-nag apt hook had some unintended side effects as reported today by @memesalot and @vsc55 in #6078. This PR fixes this. What is being done in particular:

  • && chaining is replaced back with an if-condition because otherwise the hook returns with a non-0 exit code when JS patching is not needed and apt scares users with an error message
  • dpkg -V check has been replaced with a grep -F check to avoid stdout leaking ??5?????? /usr/share/javascript/proxmox-widget-toolkit/proxmoxlib.js (I couldn't reproduce that on my installs, glad others helped with testing)

Draft until this concern by @vsc55 is resolved:

I mean that the new sed syntax is not compatible with older versions of the pve js file.

🔗 Related PR / Issue

Link: #6078
Link: #6084

✅ Prerequisites (X in brackets)

  • Self-review completed – Code follows project standards.
  • Tested thoroughly – Changes work as expected. This time also tested by @vsc55: message link
  • No security risks – No hardcoded secrets, unnecessary privilege escalations, or permission issues.

🛠️ Type of Change (X in brackets)

  • 🐞 Bug fix – Resolves an issue without breaking functionality.
  • New feature – Adds new, non-breaking functionality.
  • 💥 Breaking change – Alters existing functionality in a way that may require updates.
  • 🆕 New script – A fully functional and tested script or script set.
  • 🌍 Website update – Changes to website-related JSON files or metadata.
  • 🔧 Refactoring / Code Cleanup – Improves readability or maintainability without changing functionality.
  • 📝 Documentation update – Changes to README, AppName.md, CONTRIBUTING.md, or other docs.

@github-actions github-actions bot added pve-tool update script A change that updates a script labels Jul 20, 2025
@memesalot
Copy link

Fixes the ??5?????? issue for me! Thanks!

@vsc55
Copy link

vsc55 commented Jul 21, 2025

Hi @imcrazytwkr,
I have tried it with the oldest version of proxmox 8.0.3 and it breaks when applying.
imagen
Change const subscription = ! ( to const subscription = = ( generating an error in the browser.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
pve-tool update script A change that updates a script
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants