MoneyPrinterV2 icon indicating copy to clipboard operation
MoneyPrinterV2 copied to clipboard

FileNotFoundError: MoneyPrinterV2/venv/TTS/.models.json

Open omozousha opened this issue 10 months ago • 3 comments

i got an error while selecting this options.

Image

Traceback (most recent call last): File "D:\dari-github\MoneyPrinterV2\src\main.py", line 436, in main() File "D:\dari-github\MoneyPrinterV2\src\main.py", line 151, in main tts = TTS() File "D:\dari-github\MoneyPrinterV2\src\classes\Tts.py", line 41, in init self.model_manager = ModelManager(models_json_path) File "D:\dari-github\MoneyPrinterV2\venv\lib\site-packages\TTS\utils\manage.py", line 56, in init self.read_models_file(models_file) File "D:\dari-github\MoneyPrinterV2\venv\lib\site-packages\TTS\utils\manage.py", line 68, in read_models_file self.models_dict = read_json_with_comments(file_path) File "D:\dari-github\MoneyPrinterV2\venv\lib\site-packages\TTS\config_init.py", line 17, in read_json_with_comments with fsspec.open(json_path, "r", encoding="utf-8") as f: File "D:\dari-github\MoneyPrinterV2\venv\lib\site-packages\fsspec\core.py", line 105, in enter f = self.fs.open(self.path, mode=mode) File "D:\dari-github\MoneyPrinterV2\venv\lib\site-packages\fsspec\spec.py", line 1310, in open f = self._open( File "D:\dari-github\MoneyPrinterV2\venv\lib\site-packages\fsspec\implementations\local.py", line 200, in _open return LocalFileOpener(path, mode, fs=self, **kwargs) File "D:\dari-github\MoneyPrinterV2\venv\lib\site-packages\fsspec\implementations\local.py", line 364, in init self._open() File "D:\dari-github\MoneyPrinterV2\venv\lib\site-packages\fsspec\implementations\local.py", line 369, in _open self.f = open(self.path, mode=self.mode) FileNotFoundError: [Errno 2] No such file or directory: 'D:/dari-github/MoneyPrinterV2/venv/TTS/.models.json'

what should i do ? please anyone.

omozousha avatar Feb 17 '25 09:02 omozousha

Error in latest PR. I'm never accepting new PRs ever again.

Will figure it out ASAP.

FujiwaraChoki avatar Feb 17 '25 11:02 FujiwaraChoki

Rolled back the PR that caused this. Could you please pull from main and try again?

FujiwaraChoki avatar Feb 17 '25 21:02 FujiwaraChoki

getting the same issue still

Image

Traceback (most recent call last): File "C:\MoneyPrinterV2\src\main.py", line 395, in main() File "C:\MoneyPrinterV2\src\main.py", line 130, in main tts = TTS() File "C:\MoneyPrinterV2\src\classes\Tts.py", line 41, in init self.model_manager = ModelManager(models_json_path) File "C:\MoneyPrinterV2.venv\lib\site-packages\TTS\utils\manage.py", line 56, in init self.read_models_file(models_file) File "C:\MoneyPrinterV2.venv\lib\site-packages\TTS\utils\manage.py", line 68, in read_models_file self.models_dict = read_json_with_comments(file_path) File "C:\MoneyPrinterV2.venv\lib\site-packages\TTS\config_init.py", line 17, in read_json_with_comments with fsspec.open(json_path, "r", encoding="utf-8") as f: File "C:\MoneyPrinterV2.venv\lib\site-packages\fsspec\core.py", line 105, in enter f = self.fs.open(self.path, mode=mode) File "C:\MoneyPrinterV2.venv\lib\site-packages\fsspec\spec.py", line 1310, in open f = self._open( File "C:\MoneyPrinterV2.venv\lib\site-packages\fsspec\implementations\local.py", line 200, in _open return LocalFileOpener(path, mode, fs=self, **kwargs) File "C:\MoneyPrinterV2.venv\lib\site-packages\fsspec\implementations\local.py", line 364, in init self._open() File "C:\MoneyPrinterV2.venv\lib\site-packages\fsspec\implementations\local.py", line 369, in _open self.f = open(self.path, mode=self.mode) FileNotFoundError: [Errno 2] No such file or directory: 'C:/MoneyPrinterV2/.venv/TTS/.models.json'

thaalescosta avatar Feb 17 '25 22:02 thaalescosta

Rolled back the PR that caused this. Could you please pull from main and try again?

I've tried it before, and still can't

omozousha avatar Feb 18 '25 06:02 omozousha

mine too, still can't

magicwarms avatar Feb 18 '25 06:02 magicwarms

Hi, I'm using virtual environment. I had check on code and found an bug that in src/classes/Tts.py line 29, the variable "site_packages" does not include "Lib/site-packages". So i have to add it in code like this: models_json_path = os.path.join( site_packages, "Lib", "site-packages", "TTS", ".models.json", ) And it works fine P/s: Sorry for my bad English

theanhbr01 avatar Feb 18 '25 07:02 theanhbr01

Hi, I'm using virtual environment. I had check on code and found an bug that in src/classes/Tts.py line 29, the variable "site_packages" does not include "Lib/site-packages". So i have to add it in code like this: models_json_path = os.path.join( site_packages, "Lib", "site-packages", "TTS", ".models.json", ) And it works fine P/s: Sorry for my bad English

how can you get model.json? because I don't have it

magicwarms avatar Feb 18 '25 07:02 magicwarms

If you installed all dependencies/libraries in requirements.txt, .model.json should be in .venv/Lib/site-packages/TTS My python version: 3.9.13

theanhbr01 avatar Feb 18 '25 07:02 theanhbr01

Hi, I'm using virtual environment. I had check on code and found an bug that in src/classes/Tts.py line 29, the variable "site_packages" does not include "Lib/site-packages". So i have to add it in code like this: models_json_path = os.path.join( site_packages, "Lib", "site-packages", "TTS", ".models.json", ) And it works fine P/s: Sorry for my bad English

thanks its working for me

omozousha avatar Feb 18 '25 08:02 omozousha

Hi, I'm using virtual environment. I had check on code and found an bug that in src/classes/Tts.py line 29, the variable "site_packages" does not include "Lib/site-packages". So i have to add it in code like this: models_json_path = os.path.join( site_packages, "Lib", "site-packages", "TTS", ".models.json", ) And it works fine P/s: Sorry for my bad English

how can you get model.json? because I don't have it

Try to change that line 29 from what he suggests. Then, it will work without having .model.json .

manutzsong avatar Feb 20 '25 08:02 manutzsong