aisingapore / TagUI

Free RPA tool by AI Singapore
Apache License 2.0
5.56k stars 578 forks source link

dyld: Library not loaded error on macOS (OpenSSL missing) #86

Closed kensoh closed 5 years ago

kensoh commented 6 years ago

Welcome to TagUI GitHub page :robot:! TagUI is a free RPA tool by AI Singapore (to automate digital processes). There's a Python package built on TagUI called RPA for Python :snake: with a similar issue and already has an automated fix.

This error is happening because macOS decided to drop OpenSSL and switched to LibreSSL. Furthermore, macOS Homebrew switched from OpenSSL v.1.0 to v1.1, breaking many other apps that are dependent on OpenSSL v1.0. The solution below may or may not work for other apps, be sure to check with their respective maintainers to confirm.

===== PROBLEM =====

I've come across a feedback from a macOS user that below error happens when running TagUI.

dyld: Library not loaded: /usr/local/opt/openssl/lib/libssl.1.0.0.dylib

===== RECOMMENDED SOLUTION =====

Hi Guys, for TagUI @Stwissel may have found the permanent solution. Note that this solution may not help for other projects. Download directly from following link. After unzipping, put contents of unzipped folder into tagui/src/phantomjs folder. https://bitbucket.org/ariya/phantomjs/downloads/phantomjs-2.1.1-macosx.zip

Though above zip is PhantomJS v2.1.1 (same as TagUI packaged PJS), total file size for this zip after extraction is different. It might be Ariya, creator of PhantomJS, put in a fix already just to solve this headache with macOS/OpenSSL/Homebrew.

===== DEPRECATED SOLUTION =====

There is a new dependency in newer versions of macOS. To fix the error do the following. It installs Homebrew (a package manager for macOS) and installs OpenSSL for https connections. There are 2 uninstall commands below to first remove OpenSSL v1.1, then remove any dead OpenSSL v1.0, before installing a custom OpenSSL v1.0 formula which works without having to build with Xcode.

If you don't have Homebrew or don't know what is it

/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install.sh)"
brew uninstall openssl; brew uninstall openssl; brew install https://github.com/tebelorg/Tump/releases/download/v1.0.0/openssl.rb

Or if you already have Homebrew installed

brew uninstall openssl; brew uninstall openssl; brew install https://github.com/tebelorg/Tump/releases/download/v1.0.0/openssl.rb

One last thing... If you encounter problems using brew, try the solution from @mrtoadsc near bottom of this page.

kensoh commented 6 years ago

Closing this issue for time being, and keeping a lookout for more occurrences or clean macOS laptops to identify patterns for root cause.

kensoh commented 6 years ago

internal reference - this issue by other open-source project mentions that in macOS 10.13, it switches away from OpenSSL to LibreSSL - https://github.com/envoyproxy/envoy/issues/2395

kensoh commented 6 years ago

another datapoint the same user fixes the issue with just the following without doing the linking step (he already has Homebrew) so the first line /usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)" is not needed.

# outdated solution in this code block, see updated solution above
https://github.com/kelaberetiv/TagUI/issues/86#issue-303370944

another datapoint where a macos user encounters the same issue. it could be the 10.13 release change in behavior around OpenSSL.

kensoh commented 6 years ago

There is a new dependency possibly in newer versions of macOS. To fix the error do the following. It installs Homebrew (a package manager for macOS) and installs OpenSSL for https connections.

If you do not have Homebrew or don't know what is Homebrew

/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
brew uninstall openssl; brew uninstall openssl; brew install https://github.com/tebelorg/Tump/releases/download/v1.0.0/openssl.rb

Or if you already have Homebrew installed

brew uninstall openssl; brew uninstall openssl; brew install https://github.com/tebelorg/Tump/releases/download/v1.0.0/openssl.rb

  If you encounter problems using brew, try the solution from @mrtoadsc near bottom of this page.

jameschanck commented 6 years ago

Jamess-MacBook-Pro:src jameschan$ ./tagui samples/try1 chrome dyld: Library not loaded: /usr/local/opt/openssl/lib/libssl.1.0.0.dylib Referenced from: /Users/jameschan/Downloads/tagui/src/phantomjs/bin/phantomjs Reason: image not found

i am reading the above can fix but can explain what is wrong?? Thanks

kensoh commented 6 years ago

Hi @jameschanck thanks for sharing that above fix works. From my understanding macOS Sierra is switching away from OpenSSL to LibreSSL as the tool to access secure connections.

The above installs and enables OpenSSL on your macOS so that the part of TagUI (PhantomJS engine) that automates and connects to https:// websites can continue working.

jameschanck commented 6 years ago

Thanks. I am learning TagUI. And reading from the posts, interested to know how to automate applications. You spoke about skuli. But not sure why u want to integrate Roro/AHK.

On Tue, 17 Apr 2018, 17:34 Ken Soh, notifications@github.com wrote:

Hi @jameschanck https://github.com/jameschanck thanks for sharing that above fix works. From my understanding macOS Sierra is switching away from OpenSSL to LibreSSL as the tool to access secure connections.

The above installs and enables OpenSSL on your macOS so that the part of TagUI (PhantomJS engine) that automates and connects to https:// websites can continue working.

β€” You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/kelaberetiv/TagUI/issues/86#issuecomment-381921588, or mute the thread https://github.com/notifications/unsubscribe-auth/AjZE7Mkd8m8Sio3N5YNfHat0tOUThA2hks5tpbdDgaJpZM4SiNIS .

kensoh commented 6 years ago

I see.. This step-by-step tutorial may be useful. Or this video talk at FOSSASIA with demo of TagUI features. Yes TagUI has integration with Sikuli to control UI interactions (including desktop applications) using visual recognition and OCR. But some automation scenarios needs greater control than this.

For example clicking on cell J10 on an Excel spreadsheet. Doing that by specifying a cell image to click on won't find the right cell. Open-source apps such as AHK or Roro can have automation scripts to do such actions. Integrating with them will let TagUI do more types of automation.

Now the run step can be used to call AHK or Roro, thinking if there is a way to make it even easier.

jameschanck commented 6 years ago

Thanks mate. I have ceased my employment with my previous company recently. I am thinking about providing consultancy jobs related to AI. I intend to return to work in 6 to 12 months. I have a request for a robot office reception. Case illustration: a tablet at the office counter. It sense motion near it. Wakes up and say "Hi, are you here to visit an employee or deliver?" It listens for a name and search database & call employee to inform visitor. In the meantime, it will communicate with visitor to register name, contact & purpose of visit. It listens for "deliver" too. If yes, it will trigger a drop box open, and request the deliver person to drop the delivery. As the delivery man drop the item, a few video will be captured as proof of delivery. And the system will communicate with the delivery man for confirmation including generate a signed POD for print.

I am thinking it is somewhat related to your system but require chatbot integration, and ability to integrate with sensors.

Please share any guidance if available.,

On Tue, Apr 17, 2018 at 10:51 PM, Ken Soh notifications@github.com wrote:

I see.. This step-by-step tutorial https://github.com/kelaberetiv/TagUI/blob/master/src/media/RPA%20Workshop.md may be useful. Or this video talk at FOSSASIA https://www.youtube.com/watch?v=u1x2HOV9Jmg with demo of TagUI features. Yes TagUI has integration with Sikuli to control UI interactions (including desktop applications) using visual recognition and OCR. But some automation scenarios needs greater control than this.

For example clicking on cell J10 on an Excel spreadsheet. Doing that by specifying a cell image to click on won't find the right cell. Open-source apps such as AHK or Roro can have automation scripts to do such actions. Integrating with them will let TagUI do more types of automation.

Now the run step can be used to call AHK or Roro, thinking if there is a way to make it even easier.

β€” You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/kelaberetiv/TagUI/issues/86#issuecomment-382021578, or mute the thread https://github.com/notifications/unsubscribe-auth/AjZE7AuvPLTomy_KgKtW_WBfDTEKf6heks5tpgF6gaJpZM4SiNIS .

kensoh commented 6 years ago

Posting as a separate issue as the discussion is not related to this macOS SSL issue - https://github.com/kelaberetiv/TagUI/issues/141

ntoghrama commented 5 years ago

hi! I do not have homebrew but am trying to install it for MacOS Mojave 10.14.3.

Running:

/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"

Returns:

dyld: Library not loaded: @rpath/libssl.1.0.0.dylib Referenced from: /Users/natasha/anaconda3/lib/libssh2.1.dylib Reason: image not found

does anyone have about idea of why this does not work?

kensoh commented 5 years ago

Thanks for heads-up! Strange, I'm running same version of macOS - Mojave 10.14.3. Tried the same command to install on both normal terminal and Anaconda environment without issues.

/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"

This is probably an environment issue but can't find related issues on homebrew github or discourse. Reopening this issue for the time being to see if anyone else can add on their findings.

kensoh commented 5 years ago

Adding on, it looks like there is conflict with Anaconda on your system preventing installation of Homebrew, try changing PATH in ~/.profile and see if that helps - https://discourse.brew.sh/t/ssh-problem-with-install-homebrew/4052

Closing issue for now as the above installation conflict is with Anaconda / Homebrew. Another reference on Homebrew installation issue with Anaconda.

enhering commented 5 years ago

Hi. I'm running Mac OS 10.12.6 (sierra).

After installing mysql connector cpp 8.0.17 this same issue happened:ENH-MBP:build enhering$ ./FJH dyld: Library not loaded: libssl.1.0.0.dylib Referenced from: /usr/local/mysql-connector-c++-8.0.17/lib64/libmysqlcppconn.7.dylib Reason: image not found Abort trap: 6 ENH-MBP:build enhering$

I already had openssl installed by brew. And I was using MySQL connector cpp 1.x.x before this without problems.

The MySQL connector cpp 8.0.17 package was downloaded from mysql website. They provide binaries for many distributions.

kensoh commented 5 years ago

I'm not sure what is the above command FJH that triggers the error message. Do you mean you have problems running MySQL? If yes, you should raise the issue on MySQL issues or community forum page.

If you mean an existing TagUI script now cannot work after installing MySQL, you can try the following to see if it works, by removing and installing OpenSSL again.

# outdated solution in this code block, see updated solution above
https://github.com/kelaberetiv/TagUI/issues/86#issue-303370944
mrtoadsc commented 4 years ago

I stumbled across this thread while trying to resolve my own dyld: Library not loaded libssl issue. In more recent versions of MacOS, they introduced a feature called System Integrity Protection which prevents packages from writing to protected directories like /bin or /usr/lib. Even commands like brew link openssl --force will not work.

You must disable SIP in order to copy/link the open ssl libraries to the correct destination, You can do this by going into Recovery Mode (reboot, Cmd-R at the Apple logo), open a Terminal and execute the command csrutil disable, reboot and then you can copy the files into /usr/lib. This is what worked for me. Perhaps you can copy the libssl, libcrypto files to /usr/loca/lib - which doesn't require disabling SIP - but I didn't try that.

Good luck!

kensoh commented 4 years ago

Thanks Mark for sharing your findings!

Adding on a short article which users can also refer to if they encounter the issue - https://www.imore.com/how-turn-system-integrity-protection-macos

And a longer article with the technical background and screenshots of the steps - https://www.macworld.com/article/2986118/how-to-modify-system-integrity-protection-in-el-capitan.html

hectorb802 commented 4 years ago

I stumbled across this thread while trying to resolve my own dyld: Library not loaded libssl issue. In more recent versions of MacOS, they introduced a feature called System Integrity Protection which prevents packages from writing to protected directories like /bin or /usr/lib. Even commands like brew link openssl --force will not work.

You must disable SIP in order to copy/link the open ssl libraries to the correct destination, You can do this by going into Recovery Mode (reboot, Cmd-R at the Apple logo), open a Terminal and execute the command csrutil disable, reboot and then you can copy the files into /usr/lib. This is what worked for me. Perhaps you can copy the libssl, libcrypto files to /usr/loca/lib - which doesn't require disabling SIP - but I didn't try that.

Good luck!

HI, I am new in the forum, and I am experiencing the exact same issuea after updating to MaOS Mojave, I already Had tunred of System Integrity Protection But can you please tell me where can I get those files that we need to copy to /usr/lib folder.. I am new using MacOS and any advice would be helpful in order to fix this issue.. Thanks in advance..

kensoh commented 4 years ago

Hi Hector, after you turned off SIP, you can restart computer and run below commands from terminal. After installation and verifying TagUI works, then restart computer to turn SIP back to the default on.

If you do not have Homebrew or don't know what is Homebrew

# outdated solution in this code block, see updated solution above
https://github.com/kelaberetiv/TagUI/issues/86#issue-303370944

Or if you already have Homebrew installed

# outdated solution in this code block, see updated solution above
https://github.com/kelaberetiv/TagUI/issues/86#issue-303370944
hectorb802 commented 4 years ago

Hi Hector, after you turned off SIP, you can restart computer and run below commands from terminal. After installation and verifying TagUI works, then restart computer to turn SIP back to the default on.

If you do not have Homebrew or don't know what is Homebrew

# outdated solution in this code block, see updated solution above
https://github.com/kelaberetiv/TagUI/issues/86#issue-303370944

Or if you already have Homebrew installed

# outdated solution in this code block, see updated solution above
https://github.com/kelaberetiv/TagUI/issues/86#issue-303370944

Thanks for your answer Kensoh,

I tried your recommendation and I am still getting the same errors I have several weeks trying uninstallig and reistalling

I have pasted the error just in case you have a chance to check it.. Thanks again.

During handling of the above exception, another exception occurred:

Traceback (most recent call last): File "/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/threading.py", line 926, in _bootstrap_inner self.run() File "/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/threading.py", line 870, in run self._target(*self._args, self._kwargs) File "/Users/Sindira/Documents/ezt/eztve/lib/python3.7/site-packages/django/utils/autoreload.py", line 54, in wrapper fn(*args, *kwargs) File "/Users/Sindira/Documents/ezt/eztve/lib/python3.7/site-packages/django/core/management/commands/runserver.py", line 109, in inner_run autoreload.raise_last_exception() File "/Users/Sindira/Documents/ezt/eztve/lib/python3.7/site-packages/django/utils/autoreload.py", line 77, in raise_last_exception raise _exception[1] File "/Users/Sindira/Documents/ezt/eztve/lib/python3.7/site-packages/django/core/management/init.py", line 337, in execute autoreload.check_errors(django.setup)() File "/Users/Sindira/Documents/ezt/eztve/lib/python3.7/site-packages/django/utils/autoreload.py", line 54, in wrapper fn(args, kwargs) File "/Users/Sindira/Documents/ezt/eztve/lib/python3.7/site-packages/django/init.py", line 24, in setup apps.populate(settings.INSTALLED_APPS) File "/Users/Sindira/Documents/ezt/eztve/lib/python3.7/site-packages/django/apps/registry.py", line 114, in populate app_config.import_models() File "/Users/Sindira/Documents/ezt/eztve/lib/python3.7/site-packages/django/apps/config.py", line 211, in import_models self.models_module = import_module(models_module_name) File "/Users/Sindira/Documents/ezt/eztve/lib/python3.7/importlib/init.py", line 127, in import_module return _bootstrap._gcd_import(name[level:], package, level) File "", line 1006, in _gcd_import File "", line 983, in _find_and_load File "", line 967, in _find_and_load_unlocked File "", line 677, in _load_unlocked File "", line 728, in exec_module File "", line 219, in _call_with_frames_removed File "/Users/Sindira/Documents/ezt/eztve/lib/python3.7/site-packages/django/contrib/auth/models.py", line 2, in from django.contrib.auth.base_user import AbstractBaseUser, BaseUserManager File "/Users/Sindira/Documents/ezt/eztve/lib/python3.7/site-packages/django/contrib/auth/base_user.py", line 47, in class AbstractBaseUser(models.Model): File "/Users/Sindira/Documents/ezt/eztve/lib/python3.7/site-packages/django/db/models/base.py", line 117, in new new_class.add_to_class('_meta', Options(meta, app_label)) File "/Users/Sindira/Documents/ezt/eztve/lib/python3.7/site-packages/django/db/models/base.py", line 321, in add_to_class value.contribute_to_class(cls, name) File "/Users/Sindira/Documents/ezt/eztve/lib/python3.7/site-packages/django/db/models/options.py", line 204, in contribute_to_class self.db_table = truncate_name(self.db_table, connection.ops.max_name_length()) File "/Users/Sindira/Documents/ezt/eztve/lib/python3.7/site-packages/django/db/init.py", line 28, in getattr return getattr(connections[DEFAULT_DB_ALIAS], item) File "/Users/Sindira/Documents/ezt/eztve/lib/python3.7/site-packages/django/db/utils.py", line 201, in getitem backend = load_backend(db['ENGINE']) File "/Users/Sindira/Documents/ezt/eztve/lib/python3.7/site-packages/django/db/utils.py", line 110, in load_backend return import_module('%s.base' % backend_name) File "/Users/Sindira/Documents/ezt/eztve/lib/python3.7/importlib/init.py", line 127, in import_module return _bootstrap._gcd_import(name[level:], package, level) File "/Users/Sindira/Documents/ezt/eztve/lib/python3.7/site-packages/django/db/backends/postgresql/base.py", line 24, in raise ImproperlyConfigured("Error loading psycopg2 module: %s" % e) django.core.exceptions.ImproperlyConfigured: Error loading psycopg2 module: dlopen(/Users/Sindira/Documents/ezt/eztve/lib/python3.7/site-packages/psycopg2/_psycopg.cpython-37m-darwin.so, 2): Library not loaded: libssl.1.1.dylib Referenced from: /Users/Sindira/Documents/ezt/eztve/lib/python3.7/site-packages/psycopg2/_psycopg.cpython-37m-darwin.so Reason: image not found

kensoh commented 4 years ago

It looks like above error messages have nothing to do with TagUI. They are for a Python related Django project or psycopg2 package.

I'm afraid I can't help here, you'll have to check with the respective Python projects GitHub issues page for advice, as the solution to above error that you are facing may be different from what TagUI users are facing.

The error TagUI users are facing comes from the PhantomJS engine trying to access OpenSSL, it's a different source of error message compared to the project that you are using above, which has nothing to do with TagUI.

AnujAroshA commented 4 years ago

Solution give in this link is totally correct. But if still getting the same error, try to remove existing openssl and install it again.

brew remove openssl
brew install openssl
ntoghrama commented 4 years ago

I finally solved this by removing Anaconda3 completely, and reinstalling afresh. This took care of all the dependency issues.

kensoh commented 4 years ago

Thanks @AnujAroshA for sharing your tip!

Thanks @ntoghrama for sharing your experience tackling this problem.

Adding on, I hate to say this (because macOS is my favourite OS), but it seems harder and harder to deploy open-source apps on macOS. First they remove OpenSSL last year, which introduced this issue. Recently they add strict security controls in the macOS Catalina update.

This create additional steps for users to use their apps. For eg, users may need to manually add PhantomJS (execution engine for TagUI) to the list of approved apps, and also manually allow Java (used by SikuliX visual automation engine) to control the mouse and read from the screen.

More details on the solutions at https://github.com/kelaberetiv/TagUI/issues/601 and https://github.com/kelaberetiv/TagUI/issues/598 (have also updated readme)

I don't know how much more inconvenience is there going to be in future macOS releases 😒

senadivya commented 4 years ago

Is enable and disabling SIP required every time? I followed the suggested solution and got mongod started. Now after the restart, my system is back with the same issues with a different reference "Referenced from: /usr/local/bin/php"

PS: Newbie

kensoh commented 4 years ago

For TagUI, this is only required once to install OpenSSL. From your message you mentioned mongod, it looks like you are troubleshooting for MongoDB daemon. Please check MongoDB github page or its support page found from the github page -

https://github.com/mongodb/mongo https://groups.google.com/forum/#!forum/mongodb-user

senadivya commented 4 years ago

Basically irrespective of the action, the issue continues . Any suggestion will be of great help. Here is the snippet: "dyld: Library not loaded:/usr/local/opt/openssl/lib/libcrypto.1.0.0.dylib" dyld: Library not loaded: /usr/local/opt/openssl/lib/libcrypto.1.0.0.dylib Referenced from: /usr/local/Cellar/php/7.2.10/bin/php Reason: image not found Abort trap: 6

I have already completed the steps of SIP disabling and installing openssl and enabling back again.

kensoh commented 4 years ago

Hi Sena, can you show here the exact command you type to reproduce this error?

kensoh commented 4 years ago

Also, cross-linking to https://github.com/kelaberetiv/TagUI/issues/635 on an issue related to Home Brew retiring v1.0 of OpenSSL to v1.1.

kensoh commented 4 years ago

Updated solution to work with newer version of Homebrew which drops OpenSSL v1.0 for v1.1 More details on this updated solution to restore OpenSSL v1.0 at this issue https://github.com/kelaberetiv/TagUI/issues/635


===== S O L U T I O N =====

There is a new dependency in newer versions of macOS. To fix the error do the following. It installs Homebrew (a package manager for macOS) and installs OpenSSL for https connections.

If you do not have Homebrew or don't know what is Homebrew

/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
brew uninstall openssl; brew uninstall openssl; brew install https://github.com/tebelorg/Tump/releases/download/v1.0.0/openssl.rb

Or if you already have Homebrew installed

brew uninstall openssl; brew uninstall openssl; brew install https://github.com/tebelorg/Tump/releases/download/v1.0.0/openssl.rb

===== N O T E =====

If you encounter problems using brew, try the solution from @mrtoadsc here - https://github.com/kelaberetiv/TagUI/issues/86#issuecomment-532462565

pvgdevelop commented 4 years ago

Here's what worked for me

  1. I did what @mrtoadsc had suggested in https://github.com/kelaberetiv/TagUI/issues/86#issuecomment-532462565
  2. I modified the solution of @kensoh https://github.com/kelaberetiv/TagUI/issues/86#issuecomment-560139852
    brew uninstall --ignore-dependencies openssl; brew install https://github.com/tebelorg/Tump/releases/download/v1.0.0/openssl.rb

Hope this helps

Update: Keep in mind, that I had to use --ignore-dependencies flag, because I have other packages installed that depend on OpenSSL.

kensoh commented 4 years ago

Thanks Pavel for sharing! Hate that there is so much user friction around this. @siowyisheng is now working on a POC to evaluate the possibility of overhauling TagUI to be based on NodeJS, instead of the current PhantomJS, as the execution engine.

If that is viable, the future major release would not subject users to these frictions. Also, I noticed that increasingly it becomes more friction for user and developers for macOS. Number of changes this year with macOS that need users and developers to change the way things are done and do extra. Windows does not seem to have similar issues.

PS - adding on, Pavel's version to include --ignore-dependencies option is probably because there are other packages on his macOS that is dependent on OpenSSL. For the time being, I won't put that as the primary method and leave it to user to decide. Because trying to let TagUI run by doing this might break other apps of user that requires OpenSSL v1.1 instead of v1.0.

pvgdevelop commented 4 years ago

That's great! You are absolutely right about dependencies. I have a dozen of other packages relying on openssl. So, if no better solution is found, the one I've posted should be considered only after Ken's and Mark's failed to resolve issue.

mroderick commented 4 years ago

I ran into an issue, possibly the same, that gave the same error message, as did https://github.com/rvm/gem-wrappers/issues/13 ... their solution was to upgrade rvm to latest, which also worked for me.

Perhaps it's more of an rvm issue?

RuudvdvNB commented 4 years ago

Here's what worked for me

  1. I did what @mrtoadsc had suggested in #86 (comment)
  2. I modified the solution of @kensoh #86 (comment)
brew uninstall --ignore-dependencies openssl; brew install https://github.com/tebelorg/Tump/releases/download/v1.0.0/openssl.rb

Hope this helps

Update: Keep in mind, that I had to use --ignore-dependencies flag, because I have other packages installed that depend on OpenSSL.

For what it's worth, i had to use brew intall openssl to make it work.

kensoh commented 4 years ago

I assume @RuudvdvNB is referring to another tool with dependency to OpenSSL. brew install openssl may work for some other tools that uses OpenSSL v1.1. For TagUI and other tools relying on OpenSSL v1.0 it requires a mod, that's why I host above modified brew formula to facilitate.

Without a modified solution, will need users to make their own builds using Xcode, which I think is too much user friction. This issue has more details on that, when Homebrew recently removed OpenSSL v1.0 and replaced with v1.1 - https://github.com/kelaberetiv/TagUI/issues/635

MartinVincent commented 4 years ago

FYI: In my case, the issue was stemming from a conflict betwen OSX (10.11) ssh installed version and a newly installed (via Brew) openssh client. {solution was simply to uninstall openssh: brew uninstall openssh}

brandonsturgeon commented 4 years ago

Should I ignore warnings about extra dependencies?

i.e.

Error: Refusing to uninstall /usr/local/Cellar/openssl@1.1/1.1.1d
because it is required by asciinema, cairo, ffmpeg, freetds, glib, gnupg, gnutls, harfbuzz, imagemagick, libass, libevent, libheif, mysql, python, rbenv, rtmpdump, ruby, shared-mime-info, tmux, unbound, vim and w3m, which are currently installed.
You can override this and force removal with:
  brew uninstall --ignore-dependencies openssl
kensoh commented 4 years ago

It looks like you have some developer tools installed on your laptop, and that OpenSSL v1.1 is also presented, installed through Homebrew. If the reason for uninstalling v1.1 to have v1.0 in order to use TagUI, then yes you can try uninstalling to ignore the dependencies to get v1.0. However, if v1.0 has issues later on for some of those apps above, then you'll have to uninstall v1.0 to put back v1.1 for those apps to work.

Adding on, a permanent fix for this issue is being worked on now. First, PhantomJS has recently started active development, I'm checking with the maintainer on this to see if he can update to using v1.1 OpenSSL as the standard or better still, switch to LibreSSL which comes with macOS. Secondly, a POC on migrating TagUI's execution engine to Node.js is being explored to see if that makes sense for the project and its users.

szhuzenefits commented 4 years ago
    from django.db.backends.mysql.base import DatabaseOperations as _DatabaseOperations
  File "/Users/szhu/Documents/yourPeople3/venv/lib/python2.7/site-packages/django/db/backends/mysql/base.py", line 18, in <module>
    raise ImproperlyConfigured("Error loading MySQLdb module: %s" % e)
django.core.exceptions.ImproperlyConfigured: Error loading MySQLdb module: dlopen(/Users/szhu/Documents/yourPeople3/venv/lib/python2.7/site-packages/_mysql.so, 2): Library not loaded: /usr/local/opt/openssl/lib/libssl.1.0.0.dylib
  Referenced from: /usr/local/opt/mysql/lib/libmysqlclient.20.dylib
  Reason: image not found
unable to load app 0 (mountpoint='') (callable not found or import error)

see this error, any suggestions? uninstall openssl and reinstall doesn't solve this problem

kensoh commented 4 years ago

It looks like the app you are using is still having a dependency for OpenSSL v1.0. You can try -

  1. ideally, if it's possible to get an updated version of the app that uses OpenSSL v1.1
  2. check with the maintainer of the project (Django?) for advice what's the right approach
  3. as a last resort, try the following self-hosted formula which helps to install OpenSSL v1.0 without user having to use XCode to build for macOS (the official method from Homebrew requires user to build (details here on why the self-hosted formula is used - https://github.com/kelaberetiv/TagUI/issues/635)
brew uninstall openssl; brew uninstall openssl; brew install https://github.com/tebelorg/Tump/releases/download/v1.0.0/openssl.rb

  Note that above solution and this thread is to solve a problem faced by users using TagUI tool. Though it may solve similar problems faced by users of other apps, it may not. Do check the docs, issues or mailing list of the app you are using to see if they have found and recommended an official solution for their apps around this OpenSSL issue due to change in macOS (to switch to LibreSSL) and then later on a change in Homebrew (to move from OpenSSL v1.0 to v1.1).

szhuzenefits commented 4 years ago

It looks like the app you are using is still having a dependency for OpenSSL v1.0. You can try -

  1. ideally, if it's possible to get an updated version of the app that uses OpenSSL v1.1
  2. check with the maintainer of the project (Django?) for advice what's the right approach
  3. as a last resort, try the following self-hosted formula which helps to install OpenSSL v1.0 without user having to use XCode to build for macOS (the official method from Homebrew requires user to build (details here on why the self-hosted formula is used - #635)
brew uninstall openssl; brew uninstall openssl; brew install https://github.com/tebelorg/Tump/releases/download/v1.0.0/openssl.rb

  Note that above solution and this thread is to solve a problem faced by users using TagUI tool. Though it may solve similar problems faced by users of other apps, it may not. Do check the docs, issues or mailing list of the app you are using to see if they have found and recommended an official solution for their apps around this OpenSSL issue due to change in macOS (to switch to LibreSSL) and then later on a change in Homebrew (to move from OpenSSL v1.0 to v1.1).

I uninstalled the 1.1 version and installed the v1.0.0 version fixed this issue, seems like my django need a 1.0.0 version but I have 1.1 previously, thank you!

emimarz commented 4 years ago

if you install the current version and after that copy the old version to the folder actually works brew install // install 1.1 version download libcrypto.1.0.0.dylib and libssl.1.0.0.dylib so move them to /usr/local/opt/openssl/lib/libcrypto.1.0.0.dylib and /usr/local/opt/openssl/lib/libssl.1.0.0.dylib I know that is not an elegant way but if it works is better than nothing ah I search but for example this repository have that mentioned files https://github.com/zoom/zoom-sdk-macos/tree/master/ZoomSDK

frakman1 commented 4 years ago

@kensoh

brew uninstall openssl; brew uninstall openssl; brew install https://github.com/tebelorg/Tump/releases/download/v1.0.0/openssl.rb

Why do you uninstall openssl twice?

kensoh commented 4 years ago

@frakman1 the goal for this particular project is to make OpenSSL v1.0 available on macOS. Using uninstall twice is a more foolproof 1-liner to make sure any v1.1 is removed, followed by any dead and not working v1.0 is removed (which can happen and block the installation), before doing the installation from custom formula. More details in this thread - https://github.com/kelaberetiv/TagUI/issues/635#issuecomment-560185670

kelek commented 4 years ago

Just running

# outdated solution in this code block, see updated solution above
https://github.com/kelaberetiv/TagUI/issues/86#issue-303370944

worked for me; no need to uninstall/reinstall OpenSSL.

kensoh commented 4 years ago

(referring to kelek's comment above)

That will install OpenSSL v1.1 which is the version that Homebrew uses since its Nov release. But there are many apps which are still dependent on OpenSSL v1.0, and will not work if there is v1.1 installed instead of v1.0.

There is an official brew method to create personal tap and use extract function to install past releases, but that requires user to have XCode and build OpenSSL v1.0. So I create and host the custom formula above for users to get v1.0 without having to install and build using XCode.

rruiz858 commented 4 years ago

Welcome to TagUI GitHub repository! TagUI is a command-line tool for digital process automation (RPA). This error is happening because macOS decided to drop OpenSSL and switched to LibreSSL. There are many other apps having this error, the solution below may or may not work for other apps, be sure to check with their respective maintainers to confirm.

===== P R O B L E M =====

I've come across a feedback from a macOS user that below error happens when running TagUI.

dyld: Library not loaded: /usr/local/opt/openssl/lib/libssl.1.0.0.dylib

===== S O L U T I O N =====

There is a new dependency in newer versions of macOS. To fix the error do the following. It installs Homebrew (a package manager for macOS) and installs OpenSSL for https connections.

If you do not have Homebrew or don't know what is Homebrew

/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
brew uninstall openssl; brew uninstall openssl; brew install https://github.com/tebelorg/Tump/releases/download/v1.0.0/openssl.rb

  Or if you already have Homebrew installed

brew uninstall openssl; brew uninstall openssl; brew install https://github.com/tebelorg/Tump/releases/download/v1.0.0/openssl.rb

  ===== N O T E =====

If you encounter problems using brew, try the solution from @mrtoadsc near bottom of this page.

OMG. I love you.

capihacendado commented 4 years ago

Thanks so much for this solution. It saves my day in order to use mongodb commands in the terminal. But now, that I want to use jupyter notebook, I realized that my python is dependent of the version 1.1

image

Any solution in order to not be switching among the versions?

kensoh commented 4 years ago

I'm afraid I have not heard of any solution to have 2 different versions of OpenSSL running on the same Mac computer. I know that sucks, especially in situations where you want to use both software at the same time but can't. Will look forward to hearing from other experts how that can be done.