Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unable to run in Macos Apple silicon #76

Open
sushantgupta opened this issue Dec 24, 2023 · 9 comments
Open

Unable to run in Macos Apple silicon #76

sushantgupta opened this issue Dec 24, 2023 · 9 comments

Comments

@sushantgupta
Copy link

I am not able to run this code in mac Apple silicon. do you have cli option to start the scrapper.

(venv) ➜  educative.io_scraper git:(v3-master) python3 EducativeScraper.py


                Educative Scraper (v3.2.8 Master Branch), developed by Anilabha Datta
                Project Link: https://github.com/anilabhadatta/educative.io_scraper/tree/v3-dev
                Check out ReadMe for more information about this project.
                Use the GUI to start scraping.
        
DEPRECATION WARNING: The system version of Tk is deprecated and may be removed in a future release. Please don't rely on it. Set TK_SILENCE_DEPRECATION=1 to suppress this warning.
Traceback (most recent call last):
  File "/Users/aaa/workspace/tmp/educative.io_scraper/EducativeScraper.py", line 37, in <module>
    app.run()
  File "/Users/aaa/workspace/tmp/educative.io_scraper/EducativeScraper.py", line 32, in run
    HomeScreen().createHomeScreen(self.version)
  File "/Users/aaa/workspace/tmp/educative.io_scraper/src/UI/HomeScreenGUI.py", line 33, in __init__
    self.app.iconphoto(True, tk.PhotoImage(file=os.path.join(constants.commonFolderPath, "icon.png")))
  File "/Users/aaa/.pyenv/versions/3.9.18/lib/python3.9/tkinter/__init__.py", line 4064, in __init__
    Image.__init__(self, 'photo', name, cnf, master, **kw)
  File "/Users/aaa/.pyenv/versions/3.9.18/lib/python3.9/tkinter/__init__.py", line 4009, in __init__
    self.tk.call(('image', 'create', imgtype, name,) + options)
_tkinter.TclError: couldn't recognize data in image file "/Users/aaa/workspace/tmp/educative.io_scraper/src/Common/icon.png"
(venv) ➜  educative.io_scraper git:(v3-master) 
@anilabhadatta
Copy link
Owner

anilabhadatta commented Jan 6, 2024

@sushantgupta
try installing tkinter from terminal
brew install python-tk
else:
comment line 33 in HomeScreenGui.py

@anilabhadatta
Copy link
Owner

@sushantgupta any update on this?

@donadoio
Copy link

donadoio commented Mar 1, 2024

@anilabhadatta I had the same issue and it worked, I just had to run install again before running.

@anilabhadatta
Copy link
Owner

@donadoio i guess the manual steps is better recommended for linux/MacOS env
Seems like some dependencies like tkinter and few more are required to be installed separately.

@anilabhadatta
Copy link
Owner

@donadoio can you test again, latest pull and clean install again.

@donadoio
Copy link

donadoio commented Mar 5, 2024

@anilabhadatta the installation is succesfull and I'm able to run the Educative Scraper however when I click on Login Account I get this error

 2024-03-05 16:11:14,303 - INFO - LoginAccount - LoginAccount initiated...
                            Login your account in the browser...
                            To Terminate, Click on Logout Button

 2024-03-05 16:11:14,303 - INFO - BrowserUtility - Loading Browser...
 2024-03-05 16:11:14,323 - ERROR - LoginAccount - start: 27: BrowserUtility:loadBrowser: 35: Message: Service /Users/isaacdonado/educative.io_scraper/src/ChromeDrivers/mac/chromedriver-mac-arm64/ucchromedriver unexpectedly exited. Status code was: -9

 2024-03-05 16:11:14,324 - ERROR - BrowserUtility - No Browser was open to close via websocket
 2024-03-05 16:11:14,324 - INFO - BrowserUtility - An error occurred while deleting lock files: [Errno 2] No such file or directory: '/Users/isaacdonado/EducativeScraper/UserData42/ucDriver-True'

@anilabhadatta
Copy link
Owner

@donadoio disable the ucdriver settings and try again. Also do git pull first.
ucdriver is not supported in Mac Arm based chips.
Can you confirm if you are using m1 based mac ?

@donadoio
Copy link

donadoio commented May 15, 2024

@anilabhadatta I was using m3 based mac.

@anilabhadatta
Copy link
Owner

@donadoio use latest pull. Selenium base is integrated so shouldn't cause issues

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants