Bug 258038 - REGRESSION(264798@main): Archive-minified-built-product is failing due to extra argument "archive"
Summary: REGRESSION(264798@main): Archive-minified-built-product is failing due to ext...
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Tools / Tests (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Aakash Jain
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2023-06-13 11:54 PDT by Robert Jenner
Modified: 2023-06-13 12:55 PDT (History)
5 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Robert Jenner 2023-06-13 11:54:39 PDT
We are failing open source builds because archive-minified-built-product is being invoked incorrectly.

On the first failure it is running the script as: 

'python3 Tools/CISupport/built-product-archive --platform=mac-ventura --release archive --minify archive'

https://build.webkit.org/#/builders/706/builds/7107

Whereas on the last time it was passing it was running as:

'python3 Tools/CISupport/built-product-archive --platform=mac-ventura --release archive --minify'

So it basically looks like "archive" got added after minify, and it's causing it to fail as: 

Traceback (most recent call last):
  File "/Volumes/Data/worker/Apple-Ventura-Release-Build/build/Tools/CISupport/built-product-archive", line 368, in <module>
    sys.exit(main())
  File "/Volumes/Data/worker/Apple-Ventura-Release-Build/build/Tools/CISupport/built-product-archive", line 54, in main
    options, (action, ) = parser.parse_args()
ValueError: too many values to unpack (expected 1)
Comment 1 Radar WebKit Bug Importer 2023-06-13 11:56:43 PDT
<rdar://problem/110724385>
Comment 2 Aakash Jain 2023-06-13 12:02:36 PDT
Command from old successful run:
https://build.webkit.org/#/builders/706/builds/7007/steps/13/logs/stdio

python3 Tools/CISupport/built-product-archive --platform=mac-ventura --release archive --minify


Command from recent failing run:
https://build.webkit.org/#/builders/706/builds/7107/steps/13/logs/stdio

python3 Tools/CISupport/built-product-archive --platform=mac-ventura --release archive --minify archive

There is extra argument 'archive'. This seems to be regression from https://commits.webkit.org/264798@main
Comment 3 Sam Sneddon [:gsnedders] 2023-06-13 12:06:57 PDT
This change (264798@main) changed ArchiveBuiltProduct but not its subclass ArchiveMinifiedBuiltProduct, leaving the subclass both with its existing "archive" and the one added in ArchiveBuiltProduct.run (https://github.com/WebKit/WebKit/blob/964948660ae097f883e12408b84dea3efd98a7ae/Tools/CISupport/build-webkit-org/steps.py#L434).

It's not clear to me why it needs to be added in ArchiveBuiltProduct.run at all? Python's optparse doesn't care if arguments and options are intermixed, so there's no need for the run method to add it explicitly to the end as far as I can see?
Comment 4 Aakash Jain 2023-06-13 12:07:36 PDT
Pull request: https://github.com/WebKit/WebKit/pull/14931
Comment 5 EWS 2023-06-13 12:55:38 PDT
Committed 265131@main (328332879f73): <https://commits.webkit.org/265131@main>

Reviewed commits have been landed. Closing PR #14931 and removing active labels.