wanghaisheng / tiktoka-studio-uploader

Schedule and Publish contents erverywhere.Bulk auto video upload and Scheduling & Publishing Effortless for You & Your Entire Team. batch headless upload all major social networks using this ultimate social media scheduler. Fret less, save time, and generate more leads!
https://www.tiktokastudio.com
MIT License
288 stars 53 forks source link

Error: Message: Unable to locate element: //input[@type='file'] #1

Closed Jainu-s closed 3 years ago

Jainu-s commented 3 years ago

selenium.common.exceptions.NoSuchElementException: Message: Unable to locate element: //input[@type='file'] I think input tag has changed in Youtube Upload so it can't locate it. Can you please check it once? Thanks for the for amazing library.

wanghaisheng commented 3 years ago

can you set to verify you can login into https://studio.youtube.com/channel/xxxxx headless=True,

Jainu-s commented 3 years ago

When I set headless=True still the same error.

wanghaisheng commented 3 years ago

I can not reproduce your issue.

Jainu-s commented 3 years ago

Screenshot (34)

This is the error that occurred.

wanghaisheng commented 3 years ago
starting upload process
already upload videos: 0
awaiting upload videos: 112
checking whether need proxy setting
we need for proxy 
DEBUG: Firefox is now running
loading existing cookies from D:/Download/audio-visual/make-reddit-video/autovideo/assets/cookies/harrypotter.json
cookies file D:/Download/audio-visual/make-reddit-video/autovideo/assets/cookies/harrypotter.json
start change locale to english
Click your profile picture . <selenium.webdriver.remote.webelement.WebElement (session="8b12700a-45d4-4fd8-9ddb-c1d0a5c33302", element="bf84896e-0e9c-4eb3-8df5-8d518f1d7bd6")>
 Click Language or Location.
Click the language or location you’d like to use.
finish change locale to english
DEBUG: Trying to upload "D:/Download/audio-visual/UCBBj-A2EqL5pNApsLhoeM6w/BiliBili\[NA] 咚咚咚 
咚mmm\[20211031] 4K影&优菈 - 酒醉的蝴蝶 [421430570_part1].mp4" to YouTube...

this is my test log

Jainu-s commented 3 years ago

Yup, it's executed for you but I don't know what's happening with my code. Can you please check these few lines of code and suggest to me if anything is wrong.

from opplast import Upload

upload = Upload(r'C:\Users\abdul\AppData\Roaming\Mozilla\Firefox\Profiles\gwgvdchr.Selenium')

was_uploaded, video_id = upload.upload(r"C:\Users\abdul\PycharmProjects\Amazonapi\individual\new\folder0\thumbnail0.mp4",
    title="Testing",
    description="This for testing purpose only",
    thumbnail=r"C:\Users\abdul\PycharmProjects\Amazonapi\individual\new\folder0\thumbnail0.png",
    tags=["Testing", "My", "First", "Video"]
)

if was_uploaded:
    print(f"{video_id} has been uploaded to YouTube")

upload.close()
wanghaisheng commented 3 years ago
from opplast import Upload

it is from opplast not ytb_up and you should try https://github.com/wanghaisheng/autovideo

Jainu-s commented 3 years ago

It's working. Thank You @wanghaisheng