Closed homebysix closed 3 years ago
I've reproduced issue, got exactly the same results as you. I did notice an extra "--" gets passed in arguments from the GUI, but that doesn't seem to be related to the problem. I've run out of useful skills though so can't offer anything constructive about why.
Fixed by #163 — thanks @sheagcraig!
Recipe Robot's transition to Python 3 has been delayed due to a problem with the way the
Notifying*
object types interact with the Swift UI app wrapper. The code at issue is on the 2.0.0-dev branch, and I would welcome another pair of eyes on it.Requirements:
Steps to reproduce the behavior:
Clone the repo locally and switch to the 2.0.0-dev branch.
Run this command and note that it succeeds building recipes:
Open ./app/Recipe Robot.xcodeproj in Xcode
Build and run the app.
Hold option to reveal the "Ignore existing" checkbox, and check it.
Enter the same input URL as you provided to the command line tool:
https://coconut-flavour.com/updates/coconutBattery.xml
Click the Do It button and observe:
Expected behavior would be for the app output and the script output to match, given the same input.
I've traced the source of this error to the best of my (non
pdb
-savvy) ability, and it looks to be an issue with how theNotifyingList
,NotifyingString
, and other objects useNSDistributedNotificationCenter
(e.g. https://github.com/homebysix/recipe-robot/blob/2.0.0-dev/scripts/recipe_robot_lib/facts.py#L116). This would explain why it's an issue in the app and not at the command line; these notifications are how the app receives status information from the command line tool. If the notifications aren't working, no output would be displayed.My theory: the version of PyObjC included in AutoPkg 2.x's Python 3 framework requires changes for these notifying objects in order to make them communicate to the Recipe Robot app in Python 3.
Thanks in advance if you're able to reproduce this issue and provide any suggestions.