beyondcode / invoker-community

74 stars 2 forks source link

Unknown database type _int4 requested #293

Closed dwightwatson closed 1 year ago

dwightwatson commented 2 years ago

I don't appear to be able to preview any notifications - I get this error. I'm not sure what _int4 is specifically though I do have some custom array columns that don't use Laravel blueprints:

DB::statement('ALTER TABLE listings ADD COLUMN location_ids integer[]');
DB::statement('ALTER TABLE listings ADD COLUMN coordinates geometry[]');

OS: darwin Invoker Version: 2.9.0 Laravel Version: 9.14.1 Local project: true PHP Binary: /opt/homebrew/bin/php Route: /notifications/details?class=App%5CNotifications%5CSupport&project=local-rERxSXhdd8Mf2Nzx5crYrU

Error:

Doctrine\DBAL\Exception 

  Unknown database type _int4 requested, Doctrine\DBAL\Platforms\PostgreSQL100Platform may not support it.

  at phar:/Applications/Invoker.app/Contents/Resources/invoker.phar/vendor/doctrine/dbal/lib/Doctrine/DBAL/Platforms/AbstractPlatform.php:178
    174▕             $this->initializeAllDoctrineTypeMappings();
    175▕         }
    176▕         $dbType = \strtolower($dbType);
    177▕         if (!isset($this->doctrineTypeMapping[$dbType])) {
  ➜ 178▕             throw new \Doctrine\DBAL\Exception('Unknown database type ' . $dbType . ' requested, ' . static::class . ' may not support it.');
    179▕         }
    180▕         return $this->doctrineTypeMapping[$dbType];
    181▕     }
    182▕     public function hasDoctrineTypeMappingFor($dbType)

      +3 vendor frames 
  4   phar:/Applications/Invoker.app/Contents/Resources/invoker.phar/src/Factories/AttributeCollection.php:25
      Doctrine\DBAL\Schema\AbstractSchemaManager::listTableColumns("listings")

  5   phar:/Applications/Invoker.app/Contents/Resources/invoker.phar/src/Factories/AttributeCollection.php:15
      _HumbugBoxf4b902e0e9ad\Invoker\Factories\AttributeCollection::getColumns("App\Models\Listing")
mpociot commented 1 year ago

Not really sure what's causing this, but this will be fixed in the next version