fayasnoushad / gofile-bot Goto Github PK
View Code? Open in Web Editor NEWA telegram media to gofile bot
License: MIT License
A telegram media to gofile bot
License: MIT License
It seems like pip is unable to import those three packages.
I think it might have been removed from your repo.
Sometimes file are getting downloaded on the server but when it starts to upload on gofile.io it throughs the below error.
pyrogram.errors.exceptions.bad_request_400.MessageNotModified: Telegram says: [400 MESSAGE_NOT_MODIFIED] - The message was not modified because you tried to edit it using the same content (caused by "messages.EditMessage")
Showing attribute error
2021-12-07T09:07:13.995166+00:00 app[worker.1]: 'NoneType' object has no attribute 'startswith'
2021-12-07T09:07:13.995174+00:00 app[worker.1]: Traceback (most recent call last):
2021-12-07T09:07:13.995174+00:00 app[worker.1]: File "/app/.heroku/python/lib/python3.9/site-packages/pyrogram/dispatcher.py", line 217, in handler_worker
2021-12-07T09:07:13.995175+00:00 app[worker.1]: await handler.callback(self.client, *args)
2021-12-07T09:07:13.995175+00:00 app[worker.1]: File "/app/main.py", line 33, in filter
2021-12-07T09:07:13.995175+00:00 app[worker.1]: if not update.text.startswith("http://") or not update.text.startswith("https://"):
2021-12-07T09:07:13.995176+00:00 app[worker.1]: AttributeError: 'NoneType' object has no attribute 'startswith'
2021-12-07T09:08:07.259086+00:00 app[worker.1]: 'NoneType' object has no attribute 'startswith'
2021-12-07T09:08:07.259096+00:00 app[worker.1]: Traceback (most recent call last):
2021-12-07T09:08:07.259098+00:00 app[worker.1]: File "/app/.heroku/python/lib/python3.9/site-packages/pyrogram/dispatcher.py", line 217, in handler_worker
2021-12-07T09:08:07.259098+00:00 app[worker.1]: await handler.callback(self.client, *args)
2021-12-07T09:08:07.259098+00:00 app[worker.1]: File "/app/main.py", line 33, in filter
2021-12-07T09:08:07.259105+00:00 app[worker.1]: if not update.text.startswith("http://") or not update.text.startswith("https://"):
2021-12-07T09:08:07.259106+00:00 app[worker.1]: AttributeError: 'NoneType' object has no attribute 'startswith'
2021-12-07T09:08:48.501101+00:00 app[worker.1]: 'NoneType' object has no attribute 'startswith'
2021-12-07T09:08:48.501109+00:00 app[worker.1]: Traceback (most recent call last):
This issue hasnt fixed yet.still getting the same error after i deployed the latest code(Just tried now)
I tried to upload a 1Gb file from bot to gofile but the Heroku server is getting crashed it consumes a high amount of RAM and the server gets crashed check the log file. I think it happens due to editing the message it takes too much time to download and upload as compared to the previous version.
Line 98 in 91e78c1
maybe gofile api issue. Please check it.
If you can kindly add https://fex.net support.they are best free reliable host from a longtime
When remote upload:
/upload http://ipv4.download.thinkbroadband.com/5MB.zip
Bot Return Msg:
name 'requests' is not defined
Might need to define an "import requests"
When remote upload:
/upload http://ipv4.download.thinkbroadband.com/5MB.zip
Bot Return Msg:
name 'name' is not defined
main.py - Line 90: "with open(name, "wb") as file"
When Issue 1 & 2 is fixed,
Bot Return Msg:
API Error (Not Vaild JSON Data Received)
I think it have to do with gofile.py, might not have receive the correct response although logs indicate the download link/page.
Logs indicates:
[info] {"status":"ok","data":{"guestToken":"grUiVlrJ2Z44pPCmY3B4c5p4EmNEnY2u","downloadPage":"https://gofile.io/d/wkpU1F","code":"wkpU1F","parentFolder":"fd8caac3-1e6b-415b-958f-f7ec95158c28","fileId":"1e2893ff-5673-4ada-b189-37aa21e9efd9","fileName":"5MB.zip","md5":"b3215c06647bc550406a9c8ccc378756"}}
Unable to upload normal file. Stuck at processing.
/upload -attached file-
Bot Return Msg:
Processing...
Logs indicates:
'NoneType' object has no attribute 'replace'
File "/workspace/main.py", line 58, in filter
[info] text = update.text.replace("\n", " ")
[info] ^^^^^^^^^^^^^^^^^^^
[info] AttributeError: 'NoneType' object has no attribute 'replace'
Check this log from Heroku given below:
'directLink'
2022-05-02T04:51:40.174770+00:00 app[worker.1]: Traceback (most recent call last):
2022-05-02T04:51:40.174779+00:00 app[worker.1]: File "/app/.heroku/python/lib/python3.10/site-packages/pyrogram/dispatcher.py", line 240, in handler_worker
2022-05-02T04:51:40.174779+00:00 app[worker.1]: await handler.callback(self.client, *args)
2022-05-02T04:51:40.174779+00:00 app[worker.1]: File "/app/main.py", line 62, in filter
2022-05-02T04:51:40.174780+00:00 app[worker.1]: text += f"Direct Download Link: {response['directLink']}
" + "\n"
2022-05-02T04:51:40.174780+00:00 app[worker.1]: KeyError: 'directLink'
if i want to use this bot for myself,what should i do ? can you add an env var for private use ?
like AUTH_USERS = 6764788555
if env var doesnt filled,everyone can use the bot.something like that..
Please add deploy to heroku
Bot not responding check logs
2022-05-05T07:52:53.491005+00:00 heroku[worker.1]: State changed from starting to up
�2022-05-05T07:53:18.424092+00:00 app[worker.1]: cannot unpack non-iterable NoneType object
2022-05-05T07:53:18.424131+00:00 app[worker.1]: Traceback (most recent call last):
2022-05-05T07:53:18.424134+00:00 app[worker.1]: File "/app/.heroku/python/lib/python3.10/site-packages/pyrogram/dispatcher.py", line 240, in handler_worker
2022-05-05T07:53:18.424134+00:00 app[worker.1]: await handler.callback(self.client, *args)
2022-05-05T07:53:18.424134+00:00 app[worker.1]: File "/app/main.py", line 46, in filter
2022-05-05T07:53:18.424137+00:00 app[worker.1]: url, token, folderId = None
2022-05-05T07:53:18.424140+00:00 app[worker.1]: TypeError: cannot unpack non-iterable NoneType object
�2022-05-05T07:53:37.512081+00:00 app[worker.1]: cannot unpack non-iterable NoneType object
2022-05-05T07:53:37.512104+00:00 app[worker.1]: Traceback (most recent call last):
2022-05-05T07:53:37.512106+00:00 app[worker.1]: File "/app/.heroku/python/lib/python3.10/site-packages/pyrogram/dispatcher.py", line 240, in handler_worker
2022-05-05T07:53:37.512106+00:00 app[worker.1]: await handler.callback(self.client, *args)
2022-05-05T07:53:37.512107+00:00 app[worker.1]: File "/app/main.py", line 46, in filter
2022-05-05T07:53:37.512107+00:00 app[worker.1]: url, token, folderId = None
2022-05-05T07:53:37.512108+00:00 app[worker.1]: TypeError: cannot unpack non-iterable NoneType object
Originally posted by @mjwebhacks in #27 (comment)
Getting the below error while running the bot on heroku
2021-11-25T13:48:24.330967+00:00 heroku[worker.1]: State changed from crashed to starting
2021-11-25T13:48:27.577827+00:00 heroku[worker.1]: Starting process with command `python main.py`
2021-11-25T13:48:28.218109+00:00 heroku[worker.1]: State changed from starting to up
2021-11-25T13:48:28.736325+00:00 app[worker.1]: Traceback (most recent call last):
2021-11-25T13:48:28.736345+00:00 app[worker.1]: File "/app/main.py", line 8, in <module>
2021-11-25T13:48:28.736398+00:00 app[worker.1]: import urldl
2021-11-25T13:48:28.736418+00:00 app[worker.1]: ModuleNotFoundError: No module named 'urldl'
2021-11-25T13:48:28.848036+00:00 heroku[worker.1]: Process exited with status 1
2024-03-29T07:44:49.642843+00:00 heroku[worker.1]: Process running mem=576M(112.5%)
2024-03-29T07:44:49.645899+00:00 heroku[worker.1]: Error R14 (Memory quota exceeded)
2024-03-29T07:45:09.225544+00:00 heroku[worker.1]: Process running mem=690M(134.8%)
2024-03-29T07:45:09.227430+00:00 heroku[worker.1]: Error R14 (Memory quota exceeded)
2024-03-29T07:45:29.101064+00:00 heroku[worker.1]: Process running mem=807M(157.8%)
2024-03-29T07:45:29.102705+00:00 heroku[worker.1]: Error R14 (Memory quota exceeded)
2024-03-29T07:45:49.417152+00:00 heroku[worker.1]: Process running mem=1022M(199.7%)
2024-03-29T07:45:49.419070+00:00 heroku[worker.1]: Error R14 (Memory quota exceeded)
2024-03-29T07:46:09.722737+00:00 heroku[worker.1]: Process running mem=1189M(232.4%)
2024-03-29T07:46:09.724617+00:00 heroku[worker.1]: Error R15 (Memory quota vastly exceeded)
2024-03-29T07:46:09.726312+00:00 heroku[worker.1]: Stopping process with SIGKILL
2024-03-29T07:46:09.878167+00:00 heroku[worker.1]: Process exited with status 137
2024-03-29T07:46:09.905294+00:00 heroku[worker.1]: State changed from up to crashed
2024-03-29T07:46:09.908669+00:00 heroku[worker.1]: State changed from crashed to starting
2024-03-29T07:46:12.386945+00:00 heroku[worker.1]: Starting process with command python main.py
2024-03-29T07:46:12.984054+00:00 heroku[worker.1]: State changed from starting to up
I have taken laest code, but after that bot not responding not even showing any message like downloading or uploading like previously shown.
just only /start command is working
(Note:- I have not added any token in code)
Please add a download and upload percentage showing progress bar it will really help us to understand how much percentage of file is getting downloaded or uploaded.
Thanks for your Repo it is really helpful.
And one more doubt I have If I purchased a premium plan of gofile, Can I add my token in code and upload videos to my gofile account through bot?
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.