-
Notifications
You must be signed in to change notification settings - Fork 21
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
CustomTkinter kullanarak GUI ekledim. #75
base: master
Are you sure you want to change the base?
Conversation
anime listing, episode listing, and episode streaming through mpv to-do: watch history better gui anime list pagination downloading
no more simultaneous streaming bug. fixed how pages work
…ith Fetch API Previously, the `fetch_info` method in the `Anime` class used `execute_script` with `$.get` to fetch anime information. This approach caused a `JavascriptException` because: - The `$.get` method is asynchronous, but `execute_script` expects synchronous execution. - jQuery (`$`) might not be defined on the page, leading to an undefined reference. To resolve this issue, the `fetch_info` method has been modified to use `execute_async_script` with the Fetch API, which handles asynchronous operations properly. **Changes Made:** - Replaced the use of `execute_script` with `execute_async_script` to accommodate asynchronous execution. - Utilized the Fetch API to perform a GET request to `/anime/{self.slug}`. - Implemented a callback function to return the fetched data back to the Python code. - Added error handling to catch any exceptions during the fetch operation and return `null` if the fetch fails. - Checked if the returned data is `None` and raised an exception if necessary. **Benefits:** - Fixes the `JavascriptException` caused by the improper handling of asynchronous JavaScript code. - Eliminates the dependency on jQuery, ensuring compatibility even if jQuery is not loaded on the page. - Enhances the reliability of fetching anime information by correctly handling asynchronous requests. **Tested By:** - Running the application and selecting various anime to ensure that the episode lists load correctly without errors. - Verifying that the error no longer occurs and that the application functions as expected. **References:** - Selenium documentation on `execute_async_script`: https://selenium-python.readthedocs.io/api.html#selenium.webdriver.remote.webdriver.WebDriver.execute_async_script - Fetch API documentation: https://developer.mozilla.org/en-US/docs/Web/API/Fetch_API/Using_Fetch This commit ensures that the anime information is fetched reliably and resolves the issues related to asynchronous JavaScript execution.
Çaban için teşekkürler, üstünde baya vakit harcamışsın gibi görünüyor. Repo'nu çalıştıramadım:
Eğer ufak sorunları giderip çalışır vaziyete getirirsen bu repo'nun README kısmına yönlendirici bir link koyabilirim. Senin fork'ta bir de pek çok silinmesi gereken dosya var .zip, .toc, .pyc, .pkg, .html uzantılı Tekrardan eforların için teşekkür ederim ama, kulağa güzel geliyor. |
Bu fork ile projeye ctk kullanarak projeye gui ekledim. cli ile yapılabilen çoğu şey gui üzerinden yapılabiliyor. gelecekte ayarlar sekmesi ekleyeceğim