Skip to content

software_center_download: Improved logic for skipping existing files and getting valid filename #40

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

Merged
merged 1 commit into from
May 26, 2025

Conversation

marcelmamula
Copy link
Contributor

Description

Module software_center_download and its supporting plugins were updated to improve handling:

Similar files was not skipping when files were present

Issue

Pattern for similar files was not working correctly and it was not recognizing file extensions.

Solution

Function _check_similar_files was enhanced to follow this logic:

  1. Function is executed only if file with exact name is not found
  2. If filename has extension, then search for similar files without considering extension.
  3. If filename has no extension, then search for filename + any extension.

Function for updating filename from description was not working well for database files

Issue

Database files contain description with empty spaces, resulting in broken Linux commands during sap_install_media_detect role execution.
Example:
changed: [e04nwas] => (item=51057961_1 : Successfully downloaded SAP software: SAP ASE 16.0.04.06 HF1 RDBMS Linux on x86_64 64bit)

Solution

Function _get_valid_filename will now execute only for purely numerical filenames and it will use Description only if it is present and does not contain empty spaces.

@marcelmamula marcelmamula self-assigned this May 13, 2025
@marcelmamula marcelmamula added bug Something isn't working enhancement New feature or request labels May 13, 2025
Copy link
Member

@sean-freeman sean-freeman left a comment

Choose a reason for hiding this comment

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

Verified code, lgtm 👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants