MacOS Permissions
Nobody has claimed this yet.
- Dominant language
- JavaScript
- Stars
- 43.3k
- Forks
- 2.7k
- PR merge metrics
- No merged PRs in 30d
Description
What's going wrong?
Cannot grant PM2 the correct MacOS permissions, camera and microphone, as the popup dialogue is supressed, or doesn't appear.
How could we reproduce this issue?
By running a shell script that launches a python library that uses the camera through OpenCV
Supporting information
Mac OS's incredibly stupid permissions structure doesn't allow for manually adding applications to Camera/Microphone access. There's no way of triggering this, so there's no way of using PM2 to launch shell scripts that need access.
$ pm2 report
/Users/av/.pm2/pm2.log last 20 lines:
PM2 | 2023-11-07T14:09:05: PM2 log: Stopping app:run_video id:2
PM2 | 2023-11-07T14:09:05: PM2 log: pid=5116 msg=failed to kill - retrying in 100ms
PM2 | 2023-11-07T14:09:05: PM2 log: App [run_video:2] exited with code [1] via signal [SIGINT]
PM2 | 2023-11-07T14:09:05: PM2 log: pid=5116 msg=process killed
PM2 | 2023-11-07T14:09:13: PM2 log: Stopping app:run_audio id:1
PM2 | 2023-11-07T14:09:13: PM2 log: pid=4894 msg=failed to kill - retrying in 100ms
PM2 | 2023-11-07T14:09:13: PM2 log: pid=4894 msg=failed to kill - retrying in 100ms
PM2 | 2023-11-07T14:09:13: PM2 log: App [run_audio:1] exited with code [1] via signal [SIGINT]
PM2 | 2023-11-07T14:09:13: PM2 log: pid=4894 msg=process killed
PM2 | 2023-11-07T14:23:36: PM2 log: App [run_video:3] starting in -fork mode-
PM2 | 2023-11-07T14:23:36: PM2 log: App [run_video:3] online
PM2 | 2023-11-07T14:23:40: PM2 log: App [run_video:3] exited with code [134] via signal [SIGINT]
PM2 | 2023-11-07T14:23:40: PM2 log: App [run_video:3] starting in -fork mode-
PM2 | 2023-11-07T14:23:40: PM2 log: App [run_video:3] online
PM2 | 2023-11-07T14:23:44: PM2 log: App [run_video:3] exited with code [134] via signal [SIGINT]
PM2 | 2023-11-07T14:23:44: PM2 log: App [run_video:3] starting in -fork mode-
PM2 | 2023-11-07T14:23:44: PM2 log: App [run_video:3] online
PM2 | 2023-11-07T14:23:48: PM2 log: App [run_video:3] exited with code [134] via signal [SIGINT]
PM2 | 2023-11-07T14:23:48: PM2 log: App [run_video:3] starting in -fork mode-
PM2 | 2023-11-07T14:23:48: PM2 log: App [run_video:3] online
And this relevant error
3|run_vide | /var/folders/80/2h4x2sv537n_xjdgbdt_tyfm0000gn/T/tmpl3kjhh8v: line 3: 6020 Abort trap: 6 python main.py --device 1 --fps 0.5 --videoOutput True --GPU True --capture False
3|run_vide | ERROR conda.cli.main_run:execute(49): `conda run python main.py --device 1 --fps 0.5 --videoOutput True --GPU True --capture False` failed. (See above for error)
0|app | connected
3|run_video | OpenCV: not authorized to capture video (status 0), requesting...
3|run_video | /var/folders/80/2h4x2sv537n_xjdgbdt_tyfm0000gn/T/tmp8gm0lryl: line 3: 6050 Abort trap: 6 python main.py --device 1 --fps 0.5 --videoOutput True --GPU True --capture False
3|run_video | ERROR conda.cli.main_run:execute(49): `conda run python main.py --device 1 --fps 0.5 --videoOutput True --GPU True --capture False
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
No repository file or test is named. Start by reproducing the shell script that launches main.py through PM2 and inspect the PM2 report alongside OpenCV's camera-permission error on macOS. Done means establishing whether PM2 can trigger or propagate the required camera and microphone permissions, with the supported behavior clearly identified.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript, macos, opencv, python, shell
- Domain
- cli, operating-systems
- Issue type
- Bug
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100