0 votes

Hello there,

currently testing the trial version - i'm stuck to test the application because my symfony2 doctrine2 application implemented this type which is not recognized by skipper - is there a way to manuelly add a type or at least ignore a field before importing existings ORM files ?

This annotation is used for the fulltext search in postgresql

/**
* @var string
*
* @ORM\Column(name="fullnamefts",
* type="tsvector",
* options={"customSchemaOptions": {"searchFields": {"nom", "prenom"}}},
* nullable=true
* )
*/

Evaluate script function [Doctrine2Import] failed with error [Error: axLibraries/axProgramParser2/extensions/xmlExtensions/annotationXmlHelper.cpp(687): Throw in function static void ProgramParser2::CAnnotationXmlHelper::ThrowInvalidAstDocumentException(Atomix::CXmlElement &, XString)
Dynamic exception type: boost::exception_detail::clone_impl<Atomix::exception>
std::exception::what: std::exception
Unknown annotation type to convert it to string: annotation-array - in element [/ast/class[name='Prospects']/variable[name='fullNameFts']/annotations/annotation[name='ORM\Column']/annotation-key-value[name='options']/annotation-array/annotation-key-value[name='customSchemaOptions']/annotation-array]]

Thanx in advance for your help

asked in Solved by (120 points)
recategorized by

Hi, thanks for report. It seems that you're using some non-usual definition and because of that Skipper isn't able to import it correctly.

The problem seems to be caused with "options" array becuse by default "options" array should be string. Can I ask you for any documentation link where is this "customSchemaOptions" defined?

Hello,

Thanx for quick answer
I'm using this bundle https://github.com/1on/postgres-search-bundle

Here is the declared @var in the doctrine/DBAL repo

Thanks for links. The problem is caused with the extension and their usage "arrays of arrays of arrays". This is currently not supported by Skipper mechanism and because of that you're receiving these exceptions.

I will discuss it with my colleagues at Monday what we can do to support also definitions like this.

Hi Ludek,

Have you - by chance - found a solution for my problem ?

Or a way to ignore an annotation for one particular field to use the software even if this annotation is not recognized ?

thanx in advance
nico

Hi Nico, my colleague already working on this problem but it's not one-line change so it will take some tome. Regarding your question to ingore one specific annotation/field, this is unfotunately not possible.

Ok thanx
I can easily imagine it's not a one line change :)

1 Answer

0 votes

Hi Nico,

we finally implemented all changes necessary to allow you to use your extension and fixed all issues raised after all libraries were upgraded to latest version (this time upgrade to Qt 5.7.0 wasn't easy).

To be able to use your plugin you have to download latest beta - http://support.skipper18.com/402/downloads-skipper-beta

and define following custom configuration:

<skipper-configuration>
  <orm-configuration name="Doctrine2">
    <attribute-types>
      <struct name="Field" section="orm">
        <struct name="options">
          <struct name="custom-schema-options">
            <ordered name="search-fields">
              <attribute name="item" type="string"/>
            </ordered>
          </struct>
        </struct>
      </struct>
    </attribute-types>
  </orm-configuration>
</skipper-configuration>

It's not possible to support your extension completely automatically because of very complex structure (array-of-array-of-array) and because original Doctrine2 options are only key-value based. So you have to tell Skipper how your extension use options and this is done with this XML.

You can store this configuration in file *.skipper.cfl.xml, for example mycfg.skipper.cfg.xml. Plase this file anywhere in Skipper search paths (app directory, user files, project directory,... ) and fill it with content from above.

For more info about configuration file locations check this manual page https://help.skipper18.com/expert-usage/customization/configuration-files

For info about configuration file content check following page https://help.skipper18.com/expert-usage/customization/configuration-file-structure

In case that you had only trial version and need new one to be able to test it feel free to let me know to my email [email protected] and I will generate you the new one.

Please let me know if everything works as expected.

answered by Skipper developer (131k points)