TiagoSilvaPereira / vemto2-issues

Repository to track Vemto 2 Issues
5 stars 0 forks source link

schema-reader-mg Error: syntax error, unexpected integer "115", expecting identifier #160

Closed jonathanjua closed 4 months ago

jonathanjua commented 5 months ago

Error Message: schema-reader-mg Error: syntax error, unexpected integer "115", expecting identifier

Stack:

schema-reader-mg Error: #0 phar://C:/Users/jonat/AppData/Local/Programs/Vemto/resources/static/VMTTL1/.box/vendor/composer/ClassLoader.php(428): Composer\Autoload\includeFile('C:\\Users\\jonat\\...')
#1 [internal function]: Composer\Autoload\ClassLoader->loadClass('App\\Providers\\F...')
#2 phar://C:/Users/jonat/AppData/Local/Programs/Vemto/resources/static/VMTTL1/common/ModelRepository.php(308): class_exists('App\\Providers\\F...')
#3 [internal function]: Vemto\ModelRepository->Vemto\{closure}(Array, 414)
#4 C:\Users\jonat\Desktop\flow_be\vendor\laravel\framework\src\Illuminate\Collections\Arr.php(925): array_filter(Array, Object(Closure), 1)
#5 C:\Users\jonat\Desktop\flow_be\vendor\laravel\framework\src\Illuminate\Collections\Collection.php(368): Illuminate\Support\Arr::where(Array, Object(Closure))
#6 phar://C:/Users/jonat/AppData/Local/Programs/Vemto/resources/static/VMTTL1/common/ModelRepository.php(305): Illuminate\Support\Collection->filter(Object(Closure))
#7 phar://C:/Users/jonat/AppData/Local/Programs/Vemto/resources/static/VMTTL1/common/ModelRepository.php(23): Vemto\ModelRepository->get()
#8 phar://C:/Users/jonat/AppData/Local/Programs/Vemto/resources/static/VMTTL1/index.php(108): Vemto\ModelRepository->getFormatted()
#9 phar://C:/Users/jonat/AppData/Local/Programs/Vemto/resources/static/VMTTL1/common/Vemto.php(111): {closure}()
#10 phar://C:/Users/jonat/AppData/Local/Programs/Vemto/resources/static/VMTTL1/index.php(23): Vemto\Vemto::execute('schema-reader-m...', Object(Closure))
#11 C:\Users\jonat\AppData\Local\Programs\Vemto\resources\static\VMTTL1(14): require('phar://C:/Users...')
#12 {main}

Vemto 2.0.14 win32 10.0.22631 Locale: pt-BR App version: 2.0.14

TiagoSilvaPereira commented 5 months ago

Hi @jonathanjua seems there is a problem with a file inside your project. Is this project running correctly?

jonathanjua commented 5 months ago

Yes it is, how can you identify which file has a problem?

TiagoSilvaPereira commented 5 months ago

@jonathanjua I think it would be necessary to inspect your models manually. Is this a new Vemto project or an existing Laravel project?

jonathanjua commented 5 months ago

@TiagoSilvaPereira , was generated using vemto in Laravel 10 version, but was updated to Laravel 11 version to be compatible with the new vemto.

TiagoSilvaPereira commented 5 months ago

@jonathanjua I understand. Generally just by converting the project, this problem should not exist. As you can see in the message, Vemto is failing to read one of the models in your project, as there is probably a syntax problem. I recommend checking all models, including models from third-party packages. Vemto needs to load the models, and if there is any problem with their syntax, it will fail (to avoid inconsistent data in the schema).

TiagoSilvaPereira commented 5 months ago

@jonathanjua, did you find the problematic model?

TiagoSilvaPereira commented 4 months ago

Closing due to inactivity. Please feel free to continue the discussion if necessary