Ask Different (Apple)
Q&A for power users of Apple hardware and software
Latest Questions
3
votes
1
answers
1443
views
Yet another issue with a homebrew update => python upgrade => "No module named 'praw'" (missing site-packages)
I ran through a few upgrades of homebrew, in the past, and all python scripts I used to use were running fine, post python updates, meaning the upgrades got all necessary site-packages properly accounted for. Today my luck ended using the same mechanism: `brew update && brew upgrade && brew cleanup...
I ran through a few upgrades of homebrew, in the past, and all python scripts I used to use were running fine, post python updates, meaning the upgrades got all necessary site-packages properly accounted for.
Today my luck ended using the same mechanism:
brew update && brew upgrade && brew cleanup --prune=all
), and I see my new python version at 3.12.2 having replaced my previous 3.11, but missing tons of stuff in /usr/local/lib/python3.12/site-packages
(as compared to 3.11). Some of them are the praw ones, thus the obvious "No module named 'praw'"
when trying to run a python script dependent on it.
I do recall having had a similar issue, a while ago, which I thought I fixed with some simple pip install --upgrade praw
or python -m pip install --upgrade praw
, but these are now coming back with the "error: externally-managed-environment"
.
Any ideas how I could fix this?
Papi Antoniadis
(31 rep)
Feb 27, 2024, 12:56 PM
• Last activity: Jun 10, 2025, 12:25 AM
1
votes
1
answers
116
views
Manage python environments with MacPorts
In *win* I was using anaconda and with `conda activate` I could easily manage isolated python environments that I can then used in any IDE etc. How can I do the same with MacPorts? I know anaconda is also for macOS bui I read is quite incompatible with MacPorts. What about [virtualenv][1] package fo...
In *win* I was using anaconda and with
conda activate
I could easily manage isolated python environments that I can then used in any IDE etc.
How can I do the same with MacPorts? I know anaconda is also for macOS bui I read is quite incompatible with MacPorts. What about virtualenv package for MacPorts? what is the standard way to do this?
myradio
(113 rep)
Jun 11, 2024, 05:25 PM
• Last activity: Jun 11, 2024, 08:28 PM
39
votes
6
answers
24257
views
Auto-updating Homebrew
i'm currently using the Homebrew package manager and my question is: is possibile to write a bash's script in order to execute `brew update` and eventually `brew upgrade` whenever opening a shell for the first time? I'm using iTerm at the moment.
i'm currently using the Homebrew package manager and my question is: is possibile to write a bash's script in order to execute
brew update
and eventually brew upgrade
whenever opening a shell for the first time? I'm using iTerm at the moment.
g_rmz
(563 rep)
Sep 19, 2015, 04:37 PM
• Last activity: Jun 1, 2024, 07:13 AM
2
votes
1
answers
1930
views
Can I reinstall Homebrew while keeping all my packages?
I had reinstalled Homebrew because I had trouble installing packages from taps. If I ever have to do so again I'd like to without removing my packages. Running the [Homebrew uninstall script][1] `NONINTERACTIVE=1 /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/unin...
I had reinstalled Homebrew because I had trouble installing packages from taps. If I ever have to do so again I'd like to without removing my packages. Running the Homebrew uninstall script
NONINTERACTIVE=1 /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/uninstall.sh)"
and then installing it again : /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
deletes all my packages.
Oneechan69
(249 rep)
Apr 22, 2024, 03:17 PM
• Last activity: Apr 22, 2024, 10:17 PM
1
votes
0
answers
318
views
Upgrading via brew temurin unable to update
I'm trying to update temurin, I don't even know why it's installed, but I think it's needed for some support program for java. Can you help me update it? [![enter image description here][1]][1] [![enter image description here][2]][2] [![enter image description here][3]][3] ``` brew upgrade ==> Casks...
I'm trying to update temurin, I don't even know why it's installed, but I think it's needed for some support program for java.
Can you help me update it?



brew upgrade
==> Casks with 'auto_updates true' or 'version :latest'
will not be upgraded; pass --greedy
to upgrade them.
==> Upgrading 1 outdated package:
temurin 21,35 -> 21.0.1,12
==> Upgrading temurin
==> Downloading
https://github.com/adoptium/temurin21-binaries/releases/download
/jdk-21.0.1%2B12/OpenJDK21U-jdk_x64_mac_hotspot_21.0.1_12.pkg
==> Uninstalling packages with sudo; the password may be necessary:
==> Purging files for version 21.0.1,12 of Cask temurin
Error: temurin: No such file or directory @ rb_file_s_rename -
(/usr/local/Caskroom/temurin/21,35, /usr/local/Caskroom/temurin/21,35.upgrading)
Paul
(111 rep)
Dec 16, 2023, 08:39 PM
• Last activity: Dec 26, 2023, 11:38 AM
0
votes
1
answers
48
views
How does Intune know about custom macOS developer certificates
We (an organization) want to start with (re-)packaging of macOS applications and distribution with Intune. I am aware that I will need to sign a .pkg file with a Developer Certificate for distribution as an LOB-Application. **Question:** Do I (or the customer) need to install our developer certifica...
We (an organization) want to start with (re-)packaging of macOS applications and distribution with Intune. I am aware that I will need to sign a .pkg file with a Developer Certificate for distribution as an LOB-Application.
**Question:**
Do I (or the customer) need to install our developer certificate in Intune such that it knows the certificate for checking the package prior distribution or are all developer certificates of Apple are known to Intune?
PS: If you have any official document which answers this question, I would also appreciate it.
thinkingeye
(103 rep)
Aug 28, 2023, 06:38 AM
• Last activity: Aug 28, 2023, 10:09 AM
0
votes
2
answers
1980
views
Install a package with an expired certificate
I just noticed I can double-clik, open and install a .pkg package installer that has an expired certificate **without any popup** like *"This package is from an developer whose certificate has expired"* or *"This package has expired"*. Instead there is no alert at all. If I click on the top right "L...
I just noticed I can double-clik, open and install a .pkg package installer that has an expired certificate **without any popup** like *"This package is from an developer whose certificate has expired"* or *"This package has expired"*. Instead there is no alert at all.
If I click on the top right "Lock" symbol, in the details of the certificate, I see a green tick mark with *"This certificate is valid"*.
Is it the normal behaviour?
Is it true on all recent Mac OS X version that I can install old installers from a few years ago (for which the developer certificate has expired), **without having an alarming popup**?
I have myself a few old .pkg installers (the program itself has not been updated), and I don't know if it's mandatory for me to rebuild the installer with my new certificate, or if everyone can still install the old installer (with expired certificate) without any alarm.

Basj
(183 rep)
Mar 11, 2022, 03:48 PM
• Last activity: Aug 5, 2023, 07:48 AM
0
votes
0
answers
449
views
MacPorts installs all ports during installation, resulting in a lengthy installation
What I did: I initiated the installation of MacPorts on macOS Monterey and waited for some time. Then, the installer displayed the message: "Installer:PHRASE:Running package scripts..." Afterwards, I decided to check the installer's system logs (/private/var/logs/installer.log) and came across the f...
What I did:
I initiated the installation of MacPorts on macOS Monterey and waited for some time.
Then, the installer displayed the message: "Installer:PHRASE:Running package scripts..."
Afterwards, I decided to check the installer's system logs (/private/var/logs/installer.log) and came across the following entries:
2023-07-03 06:20:47-07 Virtual-Machine installer: ./postinstall: Adding subport py39-re2
2023-07-03 06:20:47-07 Virtual-Machine installer: ./postinstall: Adding subport py310-re2
There are several thousand such lines (but with other ports). I also tried on other virtual machines with different versions of macOS, and the issue occurred on macOS Monterey & macOS Big Sur, but not on macOS Ventura.
How can I resolve this problem, and what could be the cause?
Aleksandr
(51 rep)
Jul 3, 2023, 02:24 PM
• Last activity: Jul 3, 2023, 02:31 PM
2
votes
0
answers
145
views
How can I look for software on my machine which could be installed from Homebrew, but currently isn't?
So assume there are various apps on my machine which I installed manually at some point WITHOUT using brew. Reasons for that could include: 1. I specifically decided *not* to use brew, even though I could have. 1. This software wasn't included in brew yet at that time. 1. It was before I even *start...
So assume there are various apps on my machine which I installed manually at some point WITHOUT using brew. Reasons for that could include:
1. I specifically decided *not* to use brew, even though I could have.
1. This software wasn't included in brew yet at that time.
1. It was before I even *started* using brew altogether.
Now, let's say I'd like to look for software on my computer, which now *does* exist on Homebrew, but I don't have that version installed. Is there some streamlined, automatic way to find and list these? Or would I need to go through all my apps and check, one-by-one?
isametry
(131 rep)
Mar 10, 2023, 01:17 PM
• Last activity: Mar 10, 2023, 04:31 PM
0
votes
1
answers
101
views
Mac not letting me install 'Packages" by Stephan Sudre
I am trying to install "Packages", to create an installation package for an App I am developing. After I mount the disk image file, I am trying to start the installation process by launching the .pkg file. However, this only opens the encoding. [![enter image description here][1]][1] [

fibonacci_ostrich
(13 rep)
Mar 8, 2023, 01:38 PM
• Last activity: Mar 8, 2023, 03:19 PM
0
votes
1
answers
2468
views
How to install package without administrator password?
For example i am installing ms teams. It is definitly known that it does not require admin permissions. But package requests it. Of course they could install some backdoor even for user, but for admin that is dangerous twice. The same with pkg and with brew (because it installs cask which is that pk...
For example i am installing ms teams. It is definitly known that it does not require admin permissions. But package requests it. Of course they could install some backdoor even for user, but for admin that is dangerous twice.
The same with pkg and with brew (because it installs cask which is that pkg).
So, is there a way to install for user but avoid entering password?
may be there is a sandboxing way?
kyb
(131 rep)
Feb 3, 2023, 11:22 AM
• Last activity: Feb 3, 2023, 11:59 AM
1
votes
1
answers
243
views
How to sign an application bundle with the same display name as the installer package?
I can sign a bundle with "Mac Developer" identity which is connected to my Apple account user name (ie a "person"). I can sign the package (.pkg) that contains the bundle with a "3rd Party Mac Developer Installer" identity (ie an "organization"). This results in the signature on the package (the org...
I can sign a bundle with "Mac Developer" identity which is connected to my Apple account user name (ie a "person").
I can sign the package (.pkg) that contains the bundle with a "3rd Party Mac Developer Installer" identity (ie an "organization").
This results in the signature on the package (the organization) being different than the signature on the component (the developer that built the component).
It seems the "Mac Developer" name is hard linked to the Apple developer account and it is not possible to slide in the organization name instead.
How to sign components (applications, executables) with an organization name instead of a human person name?
FuzzyWuzzy
(113 rep)
Jan 30, 2023, 11:11 PM
• Last activity: Jan 31, 2023, 01:26 PM
3
votes
2
answers
2317
views
Fink, Homebrew, MacPorts, pkgsrc — can I run them in parallel on the same machine?
I've been using Homebrew on my Mac forever, but sometimes I run into situations where a package is not available. For maximum choice, which of the 4 major package managers (am I missing any?) can be installed alongside each other, without undefined behavior? I assume it gets ugly unless one picks a...
I've been using Homebrew on my Mac forever, but sometimes I run into situations where a package is not available.
For maximum choice, which of the 4 major package managers (am I missing any?) can be installed alongside each other, without undefined behavior?
I assume it gets ugly unless one picks a primary package manager, and then just uses other ones for very targeted, narrow installs that don't duplicate dependencies etc.
nisc
(261 rep)
Jul 26, 2021, 06:30 PM
• Last activity: Dec 19, 2022, 11:03 PM
3
votes
1
answers
2236
views
No package manager on brand new macOS Catalina
I'm sorry if this is a stupid question, but I've been searching for days with no results. What is the default package manager for macOS Catalina terminal? ```zsh % brew zsh: command not found: brew ``` I've tried others (apt, apt-get, yum, etc.) but none of them are pre-installed. Any help is greatl...
I'm sorry if this is a stupid question, but I've been searching for days with no results.
What is the default package manager for macOS Catalina terminal?
% brew
zsh: command not found: brew
I've tried others (apt, apt-get, yum, etc.) but none of them are pre-installed. Any help is greatly appreciated!
retrovius
(153 rep)
Feb 5, 2020, 10:48 PM
• Last activity: Dec 19, 2022, 10:12 AM
0
votes
2
answers
2286
views
How should I install software from source so that I can make my configuration manageable and reproducible?
Related question on Unix/Linux: [How should I install software from source so that I can make my configuration manageable and reproducible?](https://unix.stackexchange.com/questions/40467/how-should-i-install-software-from-source-so-that-i-can-make-my-configuration-ma) However, I've tailored this qu...
Related question on Unix/Linux: [How should I install software from source so that I can make my configuration manageable and reproducible?](https://unix.stackexchange.com/questions/40467/how-should-i-install-software-from-source-so-that-i-can-make-my-configuration-ma) However, I've tailored this question more towards the Mac OS X ecosystem.
I work with a lot of scientific software on Mac OS X (currently 10.7, but also 10.6). In order to maximize performance and get access to the latest features, it's often preferable to compile software from source.
However, doing so is messy, and can lead to configuration problems. Since I also develop in Linux, I looked at all of the suggestions in the [Unix & Linux question "How to compile and install programs from source"](https://unix.stackexchange.com/questions/173/how-to-compile-and-install-programs-from-source) and the [Unix & Linux question Where should I put software I compile from source?](https://unix.stackexchange.com/questions/30/where-should-i-put-software-i-compile-myself) for some guidance. These questions are a good place to start, but it's not clear to me how I can manage dependencies and the configuration easily. For example, if I build the development branch of NumPy from source, how should I detect, manage, and resolve dependencies so that I can manage my configuration? A package manager like MacPorts, Homebrew, or Fink is one option, but if I go that route to manage my configuration, how do I compile packages so that I can use those package managers to manage dependencies? Is there something like something like [checkinstall](https://asic-linux.com.mx/~izto/checkinstall/) for these package managers? My goal here is to make installing and uninstalling software relatively painless without cluttering my configuration.
I'd also like to make my configuration reproducible. By that, I mean I'd like to set up a workflow for installing software on my machine so that I could repeat it exactly on a fresh OS install. Is there a best practice for that? When it comes to standard packages in a Linux package manager, the simplest method for repeating a software install is to make a script containing the appropriate
apt-get install
(or equivalents). However, when installing software from source, I could see this method getting very complicated. Is there a better way?
Furthermore, for Mac OS X, many applications are installed by copying a *.app
file to /Applications
, or by double-clicking on a *.pkg
file. Can I install these from a command line and script the installation of these packages? Furthermore, is there a good way to uninstall these packages?
Geoff Oxberry
(489 rep)
Jun 11, 2012, 12:43 AM
• Last activity: Dec 2, 2022, 04:42 PM
1
votes
1
answers
890
views
Uninstalling useless dependencies from a partially-installed failed MacPorts package
I tried to install the `xfce` package on MacPorts, which has about a hundred dependencies. It got pretty far, but ultimately the install failed due to whatever reason, about 85 dependencies in. So I'd like to uninstall the entire thing, in particular the 85 useless dependencies which I no longer nee...
I tried to install the
xfce
package on MacPorts, which has about a hundred dependencies. It got pretty far, but ultimately the install failed due to whatever reason, about 85 dependencies in. So I'd like to uninstall the entire thing, in particular the 85 useless dependencies which I no longer need.
The problem is that if I try port uninstall xfce
, it doesn't do anything. Neither does port uninstall --follow-dependencies xfce
, port uninstall --follow-dependents xfce
and so on. From what I can tell, this seems to be because MacPorts doesn't think that xfce is installed at all, since the installation never finished, so it doesn't try to uninstall anything. I've also tried port clean --all installed
and it didn't seem to do much.
What *did* do something is scrolling up to the beginning, when I tried to install the package, and looking at the list of dependencies it said it was going to install and manually uninstalling each one. For instance, I scrolled up to this:
$ sudo port install xfce
---> Computing dependencies for xfce
The following dependencies will be installed:
Thunar
apr
apr-util
at-spi2-atk
at-spi2-core
atk
...
And then typed
port uninstall Thunar apr apr-util at-spi2-atk at-spi2-core atk ...
which did it. But is there some better way to do this?
Mike Battaglia
(181 rep)
Jul 29, 2022, 02:06 AM
• Last activity: Jul 29, 2022, 08:38 PM
0
votes
0
answers
134
views
Gummi via pkgsrc on mac?
On the TeX editor Gummi's Github page https://github.com/alexandervdm/gummi/wiki/Installing-Gummi#install-for-your-platform, there is a link to pkgsource to get the package for macOS. But when I run `sudo pkgin install gummi` I get `gummi is not available in the repository`. **What is the proper way...
On the TeX editor Gummi's Github page https://github.com/alexandervdm/gummi/wiki/Installing-Gummi#install-for-your-platform , there is a link to pkgsource to get the package for macOS.
But when I run
sudo pkgin install gummi
I get gummi is not available in the repository
.
**What is the proper way to install it?**
Ma Joad
(461 rep)
Jul 19, 2022, 09:29 AM
1
votes
1
answers
312
views
pkg installer error in macOS 12.3: rights in /Library/Application Support
Are there any changes in the rights of the folder `/Library/Application Support` starting with macOS 12.3? Our application refuses to install, our postinstall script fails to create a folder (and files in it) in `/Library/Application Support`. Our `installer-gui-script` specifies `auth="Root"` and o...
Are there any changes in the rights of the folder
/Library/Application Support
starting with macOS 12.3?
Our application refuses to install, our postinstall script fails to create a folder (and files in it) in /Library/Application Support
.
Our installer-gui-script
specifies auth="Root"
and our postinstall script (postflight python) triggers this: os.system('mkdir /Library/Application\ Support/***')
I don't find anything about this in the release change log for macOS 12.3. Everything was fine in previous macOS versions.
Thanks
Whiletrue
(121 rep)
Mar 31, 2022, 09:45 AM
• Last activity: Apr 6, 2022, 12:19 PM
17
votes
4
answers
16853
views
How to update some application to latest version with homebrew-cask?
I noticed some packages provided by homebrew-cask uses a url of the latest version and a version number of "latest" such as [dropbox](https://github.com/phinze/homebrew-cask/blob/master/Casks/dropbox.rb) and [chrome](https://github.com/phinze/homebrew-cask/blob/master/Casks/google-chrome.rb). Thus t...
I noticed some packages provided by homebrew-cask uses a url of the latest version and a version number of "latest" such as [dropbox](https://github.com/phinze/homebrew-cask/blob/master/Casks/dropbox.rb) and [chrome](https://github.com/phinze/homebrew-cask/blob/master/Casks/google-chrome.rb) . Thus they will never be upgraded with
brew upgrade
. Is there any simple way to update such packages using homebrew-cask?
And if I call brew cask install dropbox
again, it shows there already exist some cache of old version, which I feel so dumb.
xgdgsc
(761 rep)
Oct 21, 2013, 04:43 PM
• Last activity: Feb 6, 2022, 11:43 AM
2
votes
1
answers
883
views
Save all macports packages of Big Sur and install them or upgrade them into new macport packages manager of Monterey OS
I have just upgraded my macBook pro 16" from Big Sur to Monterey. The issue is that I have tried to save all the macports that I had previously on Big Sur but I get an error : $ sudo port -qv installed > myports.txt Error: Current platform "darwin 21" does not match expected platform "darwin 20" Err...
I have just upgraded my macBook pro 16" from Big Sur to Monterey.
The issue is that I have tried to save all the macports that I had previously on Big Sur but I get an error :
$ sudo port -qv installed > myports.txt
Error: Current platform "darwin 21" does not match expected platform "darwin 20"
Error: If you upgraded your OS, please follow the migration instructions: https://trac.macports.org/wiki/Migration
Error: /opt/local/bin/port: Failed to initialize MacPorts, OS platform mismatch
port selfupdate
Error: Current platform "darwin 21" does not match expected platform "darwin 20"
Error: If you upgraded your OS, please follow the migration instructions: https://trac.macports.org/wiki/Migration
OS platform mismatch
while executing
"mportinit ui_options global_options global_variations"
Error: /opt/local/bin/port: Failed to initialize MacPorts, OS platform mismatch
I would like to install the new version of
macport
for Monterey but I don't know how to save all the /opt/local/* packages of previous macOS Big Sur macports.
Could anyone see a fix to keep all my macports packages with Monterey OS ?
user256573
Jan 17, 2022, 05:29 PM
• Last activity: Jan 17, 2022, 09:33 PM
Showing page 1 of 20 total questions