Giter Site home page Giter Site logo

pluralsight_scrapper's Introduction

Pluralsight Scraper

GitHub issues GitHub forks GitHub stars

Allows you to fetch & download the courses on PluralSight - MUST HAVE AN ACCOUNT IN ORDER TO DOWNLOAD

Setup

  1. Clone the repository
  git clone https://github.com/Stormiix/pluralsight_scraper.git

Installation

  1. Install Python

  2. Install pip

  3. Install packages from requirements.txt

  pip install -r requirements.txt

Configure the tool

  1. Create a new file config.py and add the following:
    Username = "Your PluralSight Email/Username"
    Password = "Your PluralSight Password"
  1. Modify pluralsight.py and change both lines 10 & 11:
    title = "COURSE TITLE"
    link = "COURSE PLAYER URL"

P.S : You can also change the scraper's delay time, by default it's 3sec

Run the tool

  python pluralsight.py

pluralsight_scrapper's People

Contributors

stormix avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

pluralsight_scrapper's Issues

Cannot find element (?)

Browser Initiated !
('Loading .. https://app.pluralsight.com/player?course=ng-big-picture&author=joe-eames&name=ef9637a3-aa5b-42cd-a068-bf216ba15a3d&clip=1&mode=live',)
✓
('Logging in ...',)
✓
<Download> folder created !
<Download/course-overview> folder created !
<Download/course-overview/course-overview> folder created !
('Downloading : ', 'course-overview.mp4')
[################################] 1148/1148 - 00:00:01
<Download/introduction> folder created !
<Download/introduction/introduction> folder created !
('Downloading : ', 'introduction.mp4')
[################################] 1148/1148 - 00:00:01
<Download/introduction/angular-what-and-why> folder created !
Traceback (most recent call last):
  File "pluralsight.py", line 16, in <module>
    log = course.downloadEpisodes()
  File "/home/davidemaglio/Scaricati/pluralsight_scraper/scraper.py", line 106, in downloadEpisodes
    self.browser.find_element_by_xpath("//*[contains(text(), '"+ModuleEpisodesList[j]+"')]").click()
  File "/usr/lib/python2.7/site-packages/selenium/webdriver/remote/webdriver.py", line 309, in find_element_by_xpath
    return self.find_element(by=By.XPATH, value=xpath)
  File "/usr/lib/python2.7/site-packages/selenium/webdriver/remote/webdriver.py", line 787, in find_element
    'value': value})['value']
  File "/usr/lib/python2.7/site-packages/selenium/webdriver/remote/webdriver.py", line 252, in execute
    self.error_handler.check_response(response)
  File "/usr/lib/python2.7/site-packages/selenium/webdriver/remote/errorhandler.py", line 194, in check_response
    raise exception_class(message, screen, stacktrace)
selenium.common.exceptions.NoSuchElementException: Message: no such element: Unable to locate element: {"method":"xpath","selector":"//*[contains(text(), 'Angular, What, and Why')]"}
  (Session info: chrome=69.0.3497.81)
  (Driver info: chromedriver=2.38 (0),platform=Linux 4.17.19-200.fc28.x86_64 x86_64)

UnboundLocalError: local variable 'chrome_driver' referenced before assignment

Error I'm getting

(pluralsight_scraper) $ python pluralsight.py
Traceback (most recent call last):
  File "pluralsight.py", line 14, in <module>
    course.launchBrowser()
  File "/Users/dhavalsavalia/Dev/Python/pluralsight_scraper/pluralsight_scraper/scraper.py", line 44, in launchBrowser
    self.browser = webdriver.Chrome(chrome_driver)
UnboundLocalError: local variable 'chrome_driver' referenced before assignment

I don't what wrong am I doing.

i got this problem

DevTools listening on ws://127.0.0.1:65117/devtools/browser/a9f4e72d-470e-41ae-a
19a-9b8e32223aea
[5472:3104:1123/013249.096:ERROR:gpu_process_transport_factory.cc(980)] Lost UI
shared context.
[1123/013249.129:ERROR:command_buffer_proxy_impl.cc(119)] ContextResult::kTransi
entFailure: Failed to send GpuChannelMsg_CreateCommandBuffer.
Traceback (most recent call last):
File "pluralsight.py", line 14, in
course.launchBrowser()
File "C:\Users\USER\Downloads\Compressed\Stormiix_pluralsight_scraper-master\p
luralsight_scraper-master\scraper.py", line 48, in launchBrowser
Browser.get(Website)
File "C:\Python37-32\lib\site-packages\selenium\webdriver\remote\webdriver.py"
, line 264, in get
self.execute(Command.GET, {'url': url})
File "C:\Python37-32\lib\site-packages\selenium\webdriver\remote\webdriver.py"
, line 252, in execute
self.error_handler.check_response(response)
File "C:\Python37-32\lib\site-packages\selenium\webdriver\remote\errorhandler.
py", line 194, in check_response
raise exception_class(message, screen, stacktrace)
selenium.common.exceptions.TimeoutException: Message: timeout
(Session info: chrome=70.0.3538.102)
(Driver info: chromedriver=2.44.609538 (b655c5a60b0b544917107a59d4153d4bf78e1b
90),platform=Windows NT 6.1.7601 SP1 x86)

error during running

after doing all instructions and run pluralsight.py and all files in same folder this the error that appear

C:\Users"userfolder"\level1>pluralsight.py
Traceback (most recent call last):
File "C:\Users"userfolder"\AppData\Local\Programs\Python\Python36\lib\site-packages\selenium\webdriver\common\service.py", line 76, in start
stdin=PIPE)
File "C:\Users"userfolder"\AppData\Local\Programs\Python\Python36\lib\subprocess.py", line 709, in init
restore_signals, start_new_session)
File "C:\Users"userfolder"\AppData\Local\Programs\Python\Python36\lib\subprocess.py", line 997, in _execute_child
startupinfo)
FileNotFoundError: [WinError 2] The system cannot find the file specified

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "C:\Users"userfolder"\level1\pluralsight.py", line 14, in
course.launchBrowser()
File "C:\Users"userfolder"\level1\scraper.py", line 44, in launchBrowser
self.browser = webdriver.Chrome(chrome_driver)
File "C:\Users"userfolder"\AppData\Local\Programs\Python\Python36\lib\site-packages\selenium\webdriver\chrome\webdriver.py", line 73, in init
self.service.start()
File "C:\Users"userfolder"\AppData\Local\Programs\Python\Python36\lib\site-packages\selenium\webdriver\common\service.py", line 83, in start
os.path.basename(self.path), self.start_error_message)
selenium.common.exceptions.WebDriverException: Message: 'chromedriver.exe' executable needs to be in PATH. Please see https://sites.google.com/a/chromium.org/chromedriver/home

Missing Chrome Driver.

C:\Users\USER\Desktop\pluralsight_scraper-master\pluralsight_scraper-master>pyth
on pluralsight.py
Traceback (most recent call last):
File "C:\Python37-32\lib\site-packages\selenium\webdriver\common\service.py",
line 74, in start
stdout=self.log_file, stderr=self.log_file)
File "C:\Python37-32\lib\subprocess.py", line 769, in init
restore_signals, start_new_session)
File "C:\Python37-32\lib\subprocess.py", line 1172, in _execute_child
startupinfo)
FileNotFoundError: [WinError 2] The system cannot find the file specified

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "pluralsight.py", line 14, in
course.launchBrowser()
File "C:\Users\USER\Desktop\pluralsight_scraper-master\pluralsight_scraper-mas
ter\scraper.py", line 44, in launchBrowser
self.browser = webdriver.Chrome(chrome_driver)
File "C:\Python37-32\lib\site-packages\selenium\webdriver\chrome\webdriver.py"
, line 62, in init
self.service.start()
File "C:\Python37-32\lib\site-packages\selenium\webdriver\common\service.py",
line 81, in start
os.path.basename(self.path), self.start_error_message)
selenium.common.exceptions.WebDriverException: Message: 'chromedriver.exe' execu
table needs to be in PATH. Please see https://sites.google.com/a/chromium.org/ch
romedriver/home

C:\Users\USER\Desktop\pluralsight_scraper-master\pluralsight_scraper-master>

download error in ubuntu

I am getting below error

root@account:/upload/pluralsight_scraper# python pluralsight.py
Traceback (most recent call last):
File "pluralsight.py", line 8, in
import scraper as ps
File "/root/upload/pluralsight_scraper/scraper.py", line 50
print("Loading .. " + Website, end =' ')
^
SyntaxError: invalid syntax
root@account:
/upload/pluralsight_scraper#

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.