autopkg / keeleysam-recipes

Recipes for autopkg!
Apache License 2.0
21 stars 49 forks source link

FileZilla.munki.recipe - Processor: URLTextSearcher: Error: No match found on URL #174

Open Stette opened 8 months ago

Stette commented 8 months ago

My autopkg-jobs fail due to (most likely) changed URL for FileZilla.

Error:

 'RE_PATTERN': '<a '
               'href=\\"(?P<url>http[s]?.*?(?P<filename>FileZilla_(?P<version>[\\d.]+)_macosx-x86.*?\\.tar\\.bz2).*?)\\"',
 'pkginfo': {'catalogs': ['testing'],
             'category': 'File Sharing',
             'description': 'FileZilla is a fast and reliable cross-platform '
                            'FTP, FTPS and SFTP client.',
             'developer': 'FileZilla',
             'display_name': 'FileZilla',
             'name': 'FileZilla',
             'unattended_install': True},
 'verbose': 3}
URLTextSearcher
{'Input': {'re_pattern': '<a '
                         'href=\\"(?P<url>http[s]?.*?(?P<filename>FileZilla_(?P<version>[\\d.]+)_macosx-x86.*?\\.tar\\.bz2).*?)\\"',
           'url': 'https://filezilla-project.org/download.php?show_all=1'}}
URLTextSearcher: No value supplied for result_output_var_name, setting default value of: match
Traceback (most recent call last):
  File "/Library/AutoPkg/autopkglib/__init__.py", line 840, in process
    self.env = processor.process()
  File "/Library/AutoPkg/autopkglib/__init__.py", line 626, in process
    self.main()
  File "/Library/AutoPkg/autopkglib/URLTextSearcher.py", line 122, in main
    groupmatch, groupdict = self.re_search(content)
  File "/Library/AutoPkg/autopkglib/URLTextSearcher.py", line 109, in re_search
    raise ProcessorError(f"{NO_MATCH_MESSAGE}: {self.env['url']}")
autopkglib.ProcessorError: No match found on URL: https://filezilla-project.org/download.php?show_all=1
  File "/Library/AutoPkg/autopkglib/__init__.py", line 840, in process
    self.env = processor.process()
No match found on URL: https://filezilla-project.org/download.php?show_all=1
Failed.
Receipt written to /Users/stette/Library/AutoPkg/Cache/local.munki.FileZilla/receipts/FileZilla.munki-receipt-20240103-140211.plist

The following recipes failed:
    FileZilla.munki.recipe
        Error in local.munki.FileZilla: Processor: URLTextSearcher: Error: No match found on URL: https://filezilla-project.org/download.php?show_all=1

Nothing downloaded, packaged or imported.
trugsc commented 8 months ago

+1

iannels commented 8 months ago

+1

gregneagle commented 7 months ago

Fixed by #172

trugsc commented 7 months ago

still get no match :(

gregneagle commented 7 months ago

:shrug: works for me!

qu1gl3s commented 7 months ago

Receiving an error on the updated pull request as well, including a snippet of the error from the Autopkg Log

 'RE_PATTERN': '<a '
               'href=\\"(?P<url>http[s]?.*?(?P<filename>FileZilla_(?P<version>[\\d.]+)_macosx-x86.*?\\.tar\\.bz2).*?)\\"',
 'pkginfo': {'blocking_applications': ['FileZilla.app'],
             'catalogs': ['production'],
             'category': 'Utilities',
             'description': 'FileZilla is a fast and reliable cross-platform '
                            'FTP, FTPS and SFTP client.',
             'display_name': 'FileZilla',
             'name': 'FileZilla',
             'unattended_install': True},
 'verbose': 4}
URLTextSearcher
{'Input': {'re_pattern': '<a '
                         'href=\\"(?P<url>http[s]?.*?(?P<filename>FileZilla_(?P<version>[\\d.]+)_macosx-x86.*?\\.tar\\.bz2).*?)\\"',
           'url': 'https://filezilla-project.org/download.php?show_all=1'}}
URLTextSearcher: No value supplied for result_output_var_name, setting default value of: match
URLTextSearcher: Curl command: ['/usr/bin/curl', '--compressed', '--location', 'https://filezilla-project.org/download.php?show_all=1']
Traceback (most recent call last):
  File "/Library/AutoPkg/autopkglib/__init__.py", line 840, in process
    self.env = processor.process()
  File "/Library/AutoPkg/autopkglib/__init__.py", line 626, in process
    self.main()
  File "/Library/AutoPkg/autopkglib/URLTextSearcher.py", line 122, in main
    groupmatch, groupdict = self.re_search(content)
  File "/Library/AutoPkg/autopkglib/URLTextSearcher.py", line 109, in re_search
    raise ProcessorError(f"{NO_MATCH_MESSAGE}: {self.env['url']}")
autopkglib.ProcessorError: No match found on URL: https://filezilla-project.org/download.php?show_all=1
  File "/Library/AutoPkg/autopkglib/__init__.py", line 840, in process
    self.env = processor.process()
No match found on URL: https://filezilla-project.org/download.php?show_all=1
Failed.
Receipt written to /Users/autopkg/Library/AutoPkg/Cache/local.munki.FileZilla/receipts/Filezilla-receipt-20240202-110023.plist
trugsc commented 7 months ago

in the pattern you still have the "x": "macosx-x86"

I have corrected the overwrite by hand and now it is working for me.

gregneagle commented 7 months ago

I am confused by your claim.

https://github.com/autopkg/keeleysam-recipes/blob/master/FileZilla/FileZilla.download.recipe#L14 and https://github.com/autopkg/keeleysam-recipes/blob/master/FileZilla/FileZilla.munki.recipe#L31

Did you actually do a repo-update after this fix, and more importantly, did you make sure your overrides don't have the old regex patterns?

qu1gl3s commented 6 months ago

Yep, this one is my fault, the regex patterns didn't update correctly. I've resolved this one on my end and made notes to check in future.

No further issues here.