wkaisertexas / tiktok-uploader

Automatically ⬆️ upload TikTok videos
https://pypi.org/project/tiktok-uploader/
360 stars 84 forks source link

Ability to provide a profile #100

Closed FujiwaraChoki closed 8 months ago

FujiwaraChoki commented 8 months ago

Would it be possible to implement a feature, to provide the path to a profile where I'm logged into TikTok already?

If I remember correctly, selenium==4.9.0 supports this.

This is how I implemented it in my own project:

    # Instantiate Firefox Options
    options = Options()

    # Bypass the bug in Selenium using this method
    # More Information: https://github.com/SeleniumHQ/selenium/issues/11028
    options.add_argument("-profile")
    options.add_argument(firefox_profile_location)

    # Instantiate Firefox Service
    service = Service(GECKODRIVER_PATH)

    # Instantiate Firefox Driver
    driver = webdriver.Firefox(service=service, options=options)
paulvl commented 8 months ago

@FujiwaraChoki you can use cookie_list based on your profile cookies. Please check the Authentication section on the documentation.

FujiwaraChoki commented 8 months ago

I understand, however, I was thinking for some users this may be faster.

Overall just optimization, not required for this app to be functional.

Also thanks for this!