DivanteLtd / pimcore-translation-bundle

MIT License
10 stars 7 forks source link

how to configure #5

Closed ismetsener closed 3 years ago

ismetsener commented 3 years ago

I installed this bundle/extension on my Pimcore 6.8.8 in which file can I configure: divante_google_translate: api_key: xxx source_lang: xxx

with kind regards, Ismet

prugala commented 3 years ago

Hi @ismetsener in every config file loaded by Symfony container. In Pimcore 6.8 and Symfony 4.x default config file is: app/config/config.yml

ismetsener commented 3 years ago

so I have to add this:

divante_google_translate:

api_key: 12334 source_lang: EN

to app/config/config.yml ??

ismetsener commented 3 years ago

I get this error: There is no extension able to load the configuration for "api_key" (in "/opt/pimcore-6/apps/pimcore/htdocs/app/config/config.yml"). Looked for namespace "api_key", found ""framework", "twig", "monolog", "swiftmailer", "doctrine", "sensio_framework_extra", "cmf_routing", "presta_sitemap", "scheb_two_factor", "fos_js_routing", "security", "debug", "web_profiler", "pimcore_admin", "pimcore", "pimcore_generator", "pimcore_ecommerce_framework", "pimcore_customer_management_framework", "output_data_config_toolkit", "web2_print_tools", "pimcore_data_hub", "number_sequence_generator", "workflow_gui", "app", "httplug", "hwi_oauth"" in /opt/pimcore-6/apps/pimcore/htdocs/app/config/config.yml (which is being imported from "/opt/pimcore-6/apps/pimcore/htdocs/app/config/config_dev.yml").

mischief24 commented 3 years ago

Did you remove the commented fragment (####divante_google_translate: )? This is necessary, please have a look here https://github.com/DivanteLtd/pimcore-google-translate/blob/master/src/GoogleTranslateBundle/Service/ConfigurationService.php

ismetsener commented 3 years ago

divante_google_translate: api_key: 12334 source_lang: EN

still not work

ismetsener commented 3 years ago

The file "/opt/pimcore-6/apps/pimcore/htdocs/app/config/config.yml" does not contain valid YAML: Unable to parse in "/opt/pimcore-6/apps/pimcore/htdocs/app/config/config.yml" at line 22 (near "divante_google_translate") in /opt/pimcore-6/apps/pimcore/htdocs/app/config/config.yml (which is being imported from "/opt/pimcore-6/apps/pimcore/htdocs/app/config/config_dev.yml").

ismetsener commented 3 years ago

ivante_google_translate api_key: source_lang: EN

line 21: divante_google_translate line 22 :api_key: line 23: source_lang: EN

prugala commented 3 years ago
divante_google_translate:
    api_key: xxx
    source_lang: xxx

Check indents, api_key and source_lang are under divante_google_translate key.

ismetsener commented 3 years ago

where can I find these values: api_key: ???? source_lang -> should be English (en_EN or EN)

prugala commented 3 years ago

You can follow this guide to generate API Key: https://github.com/eddiesigner/sketch-translate-me/wiki/Generate-a-Google-API-Key

ismetsener commented 3 years ago

I created a API KEY, but still same error divante_google_translate api_key: AI..........ss -> here i put my API_KEY source_lang: en_US

error: The file "/opt/pimcore-6/apps/pimcore/htdocs/app/config/config.yml" does not contain valid YAML: Unable to parse in "/opt/pimcore-6/apps/pimcore/htdocs/app/config/config.yml" at line 22 (near "divante_google_translate") in /opt/pimcore-6/apps/pimcore/htdocs/app/config/config.yml (which is being imported from "/opt/pimcore-6/apps/pimcore/htdocs/app/config/config_dev.yml").

ismetsener commented 3 years ago

do I have add some other things to the config.yml file: imports:

divante_google_translate api_key: AI..........ss source_lang: en_US

prugala commented 3 years ago

You have clear information that your yml file isnt valid. Use validator example: https://codebeautify.org/yaml-validator

ismetsener commented 3 years ago

Error : Unable to parse. Line : 14 divante_google_translate

prugala commented 3 years ago

You have missing colon character on the end. Should be:

divante_google_translate:
ismetsener commented 3 years ago

OK I DID now I got other error:

There is no extension able to load the configuration for "divante_google_translate" (in "/opt/pimcore-6/apps/pimcore/htdocs/app/config/config.yml"). Looked for namespace "divante_google_translate", found ""framework", "twig", "monolog", "swiftmailer", "doctrine", "sensio_framework_extra", "cmf_routing", "presta_sitemap", "scheb_two_factor", "fos_js_routing", "security", "debug", "web_profiler", "pimcore_admin", "pimcore", "pimcore_generator", "pimcore_ecommerce_framework", "pimcore_customer_management_framework", "output_data_config_toolkit", "web2_print_tools", "pimcore_data_hub", "number_sequence_generator", "workflow_gui", "app", "httplug", "hwi_oauth"" in /opt/pimcore-6/apps/pimcore/htdocs/app/config/config.yml (which is being imported from "/opt/pimcore-6/apps/pimcore/htdocs/app/config/config_dev.yml").

ismetsener commented 3 years ago

https://github.com/DivanteLtd/pimcore-google-translate/issues/2

prugala commented 3 years ago

You didnt enabled bundle, check readme and section: "Installing/Getting started"

ismetsener commented 3 years ago

Enable the Bundle:

./bin/console pimcore:bundle:enable GoogleTranslateBundle

and I get

Fatal error: Uncaught Symfony\Component\DependencyInjection\Exception\InvalidArgumentException: There is no extension able to load the configuration for "divante_google_translate" (in "/opt/pimcore-6/apps/pimcore/htdocs/app/config/config.yml"). Looked for namespace "divante_google_translate", found ""framework", "twig", "monolog", "swiftmailer", "doctrine", "sensio_framework_extra", "cmf_routing", "presta_sitemap", "scheb_two_factor", "fos_js_routing", "security", "debug", "web_profiler", "pimcore_admin", "pimcore", "pimcore_generator", "pimcore_ecommerce_framework", "pimcore_customer_management_framework", "output_data_config_toolkit", "web2_print_tools", "pimcore_data_hub", "number_sequence_generator", "workflow_gui", "app", "httplug", "hwi_oauth"". in /opt/pimcore-6/apps/pimcore/htdocs/vendor/symfony/symfony/src/Symfony/Component/Config/Loader/FileLoader.php on line 180

Symfony\Component\Config\Exception\LoaderLoadException: There is no extension able to load the configuration for "divante_google_translate" (in "/opt/pimcore-6/apps/pimcore/htdocs/app/config/config.yml"). Looked for namespace "divante_google_translate", found ""framework", "twig", "monolog", "swiftmailer", "doctrine", "sensio_framework_extra", "cmf_routing", "presta_sitemap", "scheb_two_factor", "fos_js_routing", "security", "debug", "web_profiler", "pimcore_admin", "pimcore", "pimcore_generator", "pimcore_ecommerce_framework", "pimcore_customer_management_framework", "output_data_config_toolkit", "web2_print_tools", "pimcore_data_hub", "number_sequence_generator", "workflow_gui", "app", "httplug", "hwi_oauth"" in /opt/pimcore-6/apps/pimcore/htdocs/app/config/config.yml (which is being imported from "/opt/pimcore-6/apps/pimcore/htdocs/app/config/config_dev.yml"). in /opt/pimcore-6/apps/pimcore/htdocs/vendor/symfony/symfony/src/Symfony/Component/Config/Loader/FileLoader.php on line 180

Call Stack: 0.6032 23584880 1. Symfony\Component\Debug\ErrorHandler->handleException() /opt/pimcore-6/apps/pimcore/htdocs/vendor/symfony/symfony/src/Symfony/Component/Debug/ErrorHandler.php:0

prugala commented 3 years ago

Read error, first remove your configuration next enable bundle and add configuration again.

ismetsener commented 3 years ago

I DID:

here is no extension able to load the configuration for "divante_google_translate" (in "/opt/pimcore-6/apps/pimcore/htdocs/app/config/config.yml"). Looked for namespace "divante_google_translate", found ""framework", "twig", "monolog", "swiftmailer", "doctrine", "sensio_framework_extra", "cmf_routing", "presta_sitemap", "scheb_two_factor", "fos_js_routing", "security", "debug", "web_profiler", "pimcore_admin", "pimcore", "pimcore_generator", "pimcore_ecommerce_framework", "pimcore_customer_management_framework", "output_data_config_toolkit", "web2_print_tools", "pimcore_data_hub", "number_sequence_generator", "workflow_gui", "app", "httplug", "hwi_oauth"" in /opt/pimcore-6/apps/pimcore/htdocs/app/config/config.yml (which is being imported from "/opt/pimcore-6/apps/pimcore/htdocs/app/config/config_dev.yml").

prugala commented 3 years ago

No you didnt. Error says that you have still bundle configuration in file app/config/config.yml

ismetsener commented 3 years ago

I have deleted the bundle in app/config/config.yml: i removed 👍 divante_google_translate: api_key: AI...s source_lang: en_US

after I enabled: Enable the Bundle:

./bin/console pimcore:bundle:enable GoogleTranslateBundle

after I added the 👍 divante_google_translate: api_key: AI...s source_lang: en_US

again in the config file, but still get the SAME error

there is no extension able to load the configuration for "divante_google_translate" (in "/opt/pimcore-6/apps/pimcore/htdocs/app/config/config.yml")

ismetsener commented 3 years ago

maybe I miss a config.yml file of divante-google-translate: when I look for config.yml (locate config.yml)

/opt/pimcore-6/apps/pimcore/htdocs/app/config/config.yml /opt/pimcore-6/apps/pimcore/htdocs/vendor/hwi/oauth-bundle/Tests/App/config.yml /opt/pimcore-6/apps/pimcore/htdocs/vendor/pimcore/customer-management-framework-bundle/frontend-samples/sso_client/src/AppBundle/Resources/config/pimcore/config.yml /opt/pimcore-6/apps/pimcore/htdocs/vendor/pimcore/customer-management-framework-bundle/src/Resources/config/pimcore/config.yml /opt/pimcore-6/apps/pimcore/htdocs/vendor/pimcore/data-hub/src/Resources/config/config.yml /opt/pimcore-6/apps/pimcore/htdocs/vendor/pimcore/output-data-config-toolkit-bundle/src/Resources/config/pimcore/config.yml /opt/pimcore-6/apps/pimcore/htdocs/vendor/pimcore/pimcore/.github/ci/files/app/config/config.yml /opt/pimcore-6/apps/pimcore/htdocs/vendor/pimcore/pimcore/bundles/CoreBundle/Resources/config/pimcore/config.yml /opt/pimcore-6/apps/pimcore/htdocs/vendor/pimcore/pimcore/bundles/EcommerceFrameworkBundle/Resources/config/pimcore/config.yml /opt/pimcore-6/apps/pimcore/htdocs/vendor/pimcore/pimcore/bundles/InstallBundle/Resources/config/config.yml /opt/pimcore-6/apps/pimcore/htdocs/vendor/pimcore/web2print-tools-bundle/src/Resources/config/pimcore/config.yml /opt/pimcore-6/apps/pimcore/htdocs/vendor/symfony-cmf/routing-bundle/tests/Fixtures/App/config/config.yml /opt/pimcore-6/apps/pimcore/htdocs/vendor/symfony-cmf/routing-bundle/tests/Fixtures/fixtures/config/config.yml

I do not see the config file of Divante-Google-Translate

ismetsener commented 3 years ago

i followed this advice: "first remove your configuration next enable bundle and add configuration again."

i removed this from config.yml: divante_google_translate: api_key: AI...s source_lang: en_US

I enabled the bundle

after I put this configuration to config.yml: divante_google_translate: api_key: AI...s source_lang: en_US

BUT AGAIN ERROR: here is no extension able to load the configuration for "divante_google_translate" (in "/opt/pimcore-6/apps/pimcore/htdocs/app/config/config.yml"). Looked for namespace "divante_google_translate", found ""framework", "twig", "monolog", "swiftmailer", "doctrine", "sensio_framework_extra", "cmf_routing", "presta_sitemap", "scheb_two_factor", "fos_js_routing", "security", "debug", "web_profiler", "pimcore_admin", "pimcore", "pimcore_generator", "pimcore_ecommerce_framework", "pimcore_customer_management_framework", "output_data_config_toolkit", "web2_print_tools", "pimcore_data_hub", "number_sequence_generator", "workflow_gui", "app", "httplug", "hwi_oauth"" in /opt/pimcore-6/apps/pimcore/htdocs/app/config/config.yml (which is being imported from "/opt/pimcore-6/apps/pimcore/htdocs/app/config/config_dev.yml").

ismetsener commented 3 years ago

PLEASE HELP. What I have to do?

ismetsener commented 3 years ago

/opt/pimcore-6/apps/pimcore/htdocs/app/config/config.yml

imports:
    - { resource: parameters.yml }
    - { resource: security.yml }
    - { resource: services.yml }
    - { resource: 'local/' }

    - { resource: ecommerce/base-ecommerce.yml }
    - { resource: cmf.yml }
    - { resource: /opt/pimcore-6/apps/pimcore/htdocs/var/bundles/workflow-gui/workflow.yml }

pimcore:

# IMPORTANT Notice!
# Following there are only some examples listed, for a full list of possible options, please run the following command:
# ./bin/console debug:config pimcore
# you can also filter them by path, eg.
# ./bin/console debug:config pimcore assets
# or even more specific:
# ./bin/console debug:config pimcore assets.image

divante_google_translate:
api_key: "A...LN"
source_lang: "en_US"

#### TRANSLATIONS
#    translations:
#        case_insensitive: true

#### REDIS CACHE
#    cache:
#        pools:
#            redis:
#                enabled: true
#                connection:
#                    server: localhost
#                    database: 14

#### FEATURE FLAGS
#    flags:
#        zend_date: true

#### CLASS OVERRIDES EXAMPLES
#    models:
#        class_overrides:
#            'Pimcore\Model\DataObject\News': 'AppBundle\Model\DataObject\News'
#            'Pimcore\Model\DataObject\News\Listing': 'AppBundle\Model\DataObject\News\Listing'
#            'Pimcore\Model\DataObject\Folder': 'AppBundle\Model\DataObject\Folder'
#            'Pimcore\Model\Asset\Folder': 'AppBundle\Model\Asset\Folder'
#            'Pimcore\Model\Asset\Image': 'AppBundle\Model\Asset\Image'
#            'Pimcore\Model\Document\Page': 'AppBundle\Model\Document\Page'
#            'Pimcore\Model\Document\Link': 'AppBundle\Model\Document\Link'
#            'Pimcore\Model\Document\Listing': 'AppBundle\Model\Document\Listing'

#### CUSTOM DOCUMENT EDITABLES
#    documents:
#        tags:
#            map:
#                markdown: \AppBundle\Model\Document\Tag\Markdown

#### CUSTOM OBJECT DATA TYPES
#    objects:
#        class_definitions:
#            data:
#                map:
#                  myDataType: \AppBundle\Model\DataObject\Data\MyDataType

#### ASSET CUSTOM SETTINGS
#    assets:
#        versions:
#            use_hardlinks: false
#        image:
#            low_quality_image_preview:
#                enabled: false
#                generator: imagick
#            thumbnails:
#                webp_auto_support: false

#### SYMFONY OVERRIDES
framework:

#### USE SESSION HANDLER CONFIGURED IN php.ini
#    session:
#        handler_id: null
ismetsener commented 3 years ago

my config file looks like: what is wrong? /opt/pimcore-6/apps/pimcore/htdocs/app/config/config.yml

imports:

pimcore:

IMPORTANT Notice!

Following there are only some examples listed, for a full list of

possible options, please run the following command:

./bin/console debug:config pimcore

you can also filter them by path, eg.

./bin/console debug:config pimcore assets

or even more specific:

./bin/console debug:config pimcore assets.image

divante_google_translate: api_key: "A...LN" source_lang: "en_US"

TRANSLATIONS

translations:

case_insensitive: true

REDIS CACHE

cache:

pools:

redis:

enabled: true

connection:

server: localhost

database: 14

FEATURE FLAGS

flags:

zend_date: true

CLASS OVERRIDES EXAMPLES

models:

class_overrides:

'Pimcore\Model\DataObject\News':

'AppBundle\Model\DataObject\News'

'Pimcore\Model\DataObject\News\Listing':

'AppBundle\Model\DataObject\News\Listing'

'Pimcore\Model\DataObject\Folder':

'AppBundle\Model\DataObject\Folder'

'Pimcore\Model\Asset\Folder': 'AppBundle\Model\Asset\Folder'

'Pimcore\Model\Asset\Image': 'AppBundle\Model\Asset\Image'

'Pimcore\Model\Document\Page': 'AppBundle\Model\Document\Page'

'Pimcore\Model\Document\Link': 'AppBundle\Model\Document\Link'

'Pimcore\Model\Document\Listing':

'AppBundle\Model\Document\Listing'

CUSTOM DOCUMENT EDITABLES

documents:

tags:

map:

markdown: \AppBundle\Model\Document\Tag\Markdown

CUSTOM OBJECT DATA TYPES

objects:

class_definitions:

data:

map:

myDataType: \AppBundle\Model\DataObject\Data\MyDataType

ASSET CUSTOM SETTINGS

assets:

versions:

use_hardlinks: false

image:

low_quality_image_preview:

enabled: false

generator: imagick

thumbnails:

webp_auto_support: false

SYMFONY OVERRIDES

framework:

USE SESSION HANDLER CONFIGURED IN php.ini

session:

handler_id: null

Op wo 17 feb. 2021 om 22:01 schreef Piotr Rugala notifications@github.com:

No you didnt. Error says that you have still bundle configuration in file app/config/config.yml

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/DivanteLtd/pimcore-google-translate/issues/5#issuecomment-780850407, or unsubscribe https://github.com/notifications/unsubscribe-auth/ARJXO3A56YKJ7VMIYJCTAPLS7QVDDANCNFSM4XYPG2QQ .

ismetsener commented 3 years ago

This my error:

There is no extension able to load the configuration for "divante_google_translate" (in "/opt/pimcore-6/apps/pimcore/htdocs/app/config/config.yml"). Looked for namespace "divante_google_translate", found ""framework", "twig", "monolog", "swiftmailer", "doctrine", "sensio_framework_extra", "cmf_routing", "presta_sitemap", "scheb_two_factor", "fos_js_routing", "security", "debug", "web_profiler", "pimcore_admin", "pimcore", "pimcore_generator", "pimcore_ecommerce_framework", "pimcore_customer_management_framework", "output_data_config_toolkit", "web2_print_tools", "pimcore_data_hub", "number_sequence_generator", "workflow_gui", "app", "httplug", "hwi_oauth"" in /opt/pimcore-6/apps/pimcore/htdocs/app/config/config.yml (which is being imported from "/opt/pimcore-6/apps/pimcore/htdocs/app/config/config_dev.yml").

From: Ismet Sener ismet.sener@gmail.com Sent: zondag 21 februari 2021 01:29 To: DivanteLtd/pimcore-google-translate reply@reply.github.com Subject: Re: [DivanteLtd/pimcore-google-translate] how to configure (#5)

my config file looks like: what is wrong?

/opt/pimcore-6/apps/pimcore/htdocs/app/config/config.yml

imports:

pimcore:

IMPORTANT Notice!

Following there are only some examples listed, for a full list of possible options, please run the following command:

./bin/console debug:config pimcore

you can also filter them by path, eg.

./bin/console debug:config pimcore assets

or even more specific:

./bin/console debug:config pimcore assets.image

divante_google_translate: api_key: "A...LN" source_lang: "en_US"

TRANSLATIONS

translations:

case_insensitive: true

REDIS CACHE

cache:

pools:

redis:

enabled: true

connection:

server: localhost

database: 14

FEATURE FLAGS

flags:

zend_date: true

CLASS OVERRIDES EXAMPLES

models:

class_overrides:

'Pimcore\Model\DataObject\News': 'AppBundle\Model\DataObject\News'

'Pimcore\Model\DataObject\News\Listing': 'AppBundle\Model\DataObject\News\Listing'

'Pimcore\Model\DataObject\Folder': 'AppBundle\Model\DataObject\Folder'

'Pimcore\Model\Asset\Folder': 'AppBundle\Model\Asset\Folder'

'Pimcore\Model\Asset\Image': 'AppBundle\Model\Asset\Image'

'Pimcore\Model\Document\Page': 'AppBundle\Model\Document\Page'

'Pimcore\Model\Document\Link': 'AppBundle\Model\Document\Link'

'Pimcore\Model\Document\Listing': 'AppBundle\Model\Document\Listing'

CUSTOM DOCUMENT EDITABLES

documents:

tags:

map:

markdown: \AppBundle\Model\Document\Tag\Markdown

CUSTOM OBJECT DATA TYPES

objects:

class_definitions:

data:

map:

myDataType: \AppBundle\Model\DataObject\Data\MyDataType

ASSET CUSTOM SETTINGS

assets:

versions:

use_hardlinks: false

image:

low_quality_image_preview:

enabled: false

generator: imagick

thumbnails:

webp_auto_support: false

SYMFONY OVERRIDES

framework:

USE SESSION HANDLER CONFIGURED IN php.ini

session:

handler_id: null

Op wo 17 feb. 2021 om 22:01 schreef Piotr Rugala <notifications@github.com mailto:notifications@github.com >:

No you didnt. Error says that you have still bundle configuration in file app/config/config.yml

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/DivanteLtd/pimcore-google-translate/issues/5#issuecomment-780850407 , or unsubscribe https://github.com/notifications/unsubscribe-auth/ARJXO3A56YKJ7VMIYJCTAPLS7QVDDANCNFSM4XYPG2QQ . https://ci3.googleusercontent.com/proxy/QKJr9XPkNxG1C1F7BrpC9OldEXCOg4VNM9HXceuZlc9VTx5VV_STfwTwGxpmtil1dQ0uUrGzgYsV6gKgBYDJq8updZqmGXeeUUpXe8Fi9F0IcM6iZYZ-g40mjhw7FhAZp2_lHP3XGpr0xZsZkrKmJKeuvDyDFHdaQArg4aHNeGcE0uSOKlRONWDFj4_0-OZWw-Td-U7va6odNFa2hjSWwvS

bramalho commented 3 years ago

From your last message, the error is clear that the bundle is not correctly configured/installed

1st you should run the command: ./bin/console pimcore:bundle:enable GoogleTranslateBundle

Then you should add the configurations

divante_google_translate:
    api_key: "A...LN"
    source_lang: "en_US"

See that the indentation is important for your YAML configuration file to be valid

prugala commented 3 years ago

I've tried to install this bundle and unfortunately it doesn't work. If I will find some free time in week, I will fix bundle. Problem is with loading configuration (wrong Extension file name).

ismetsener commented 3 years ago

THANKS Prugala, any news?

ismetsener commented 3 years ago

https://github.com/DivanteLtd/pimcore-google-translate/issues/5#issuecomment-782893356 any news??

prugala commented 3 years ago

@ismetsener hi, please download version 1.0.0. :)

I merged my Merge Request which included:

Remember to use new configuration options (you can find info in readme).

If all will work please close issue. Thanks

ismetsener commented 3 years ago

Dear Prugala,

I installed, when I translate I get the next error:No alive nodes found in your cluster


Timestamp: Mon Apr 05 2021 21:21:45 GMT+0200 (Midden-Europese zomertijd) Status: 500 | Internal Server Error URL: /admin/object/save?task=publish Method: PUT Message: No alive nodes found in your cluster Trace: in /opt/pimcore-6/apps/pimcore/htdocs/vendor/elasticsearch/elasticsearch/src/Elasticsearch/ConnectionPool/StaticNoPingConnectionPool.php:64

0 /opt/pimcore-6/apps/pimcore/htdocs/vendor/elasticsearch/elasticsearch/src/Elasticsearch/Transport.php(82): Elasticsearch\ConnectionPool\StaticNoPingConnectionPool->nextConnection()

1 /opt/pimcore-6/apps/pimcore/htdocs/vendor/elasticsearch/elasticsearch/src/Elasticsearch/Transport.php(99): Elasticsearch\Transport->getConnection()

2 /opt/pimcore-6/apps/pimcore/htdocs/vendor/elasticsearch/elasticsearch/src/Elasticsearch/Client.php(1671): Elasticsearch\Transport->performRequest()

3 /opt/pimcore-6/apps/pimcore/htdocs/vendor/elasticsearch/elasticsearch/src/Elasticsearch/Client.php(850): Elasticsearch\Client->performRequest()

4 /opt/pimcore-6/apps/pimcore/htdocs/vendor/pimcore/advanced-object-search/src/Service.php(425): Elasticsearch\Client->index()

5 /opt/pimcore-6/apps/pimcore/htdocs/vendor/pimcore/advanced-object-search/src/EventListener/IndexUpdateListener.php(45): AdvancedObjectSearchBundle\Service->doUpdateIndexData()

6 /opt/pimcore-6/apps/pimcore/htdocs/vendor/symfony/symfony/src/Symfony/Component/EventDispatcher/Debug/WrappedListener.php(126): AdvancedObjectSearchBundle\EventListener\IndexUpdateListener->updateObject()

7 /opt/pimcore-6/apps/pimcore/htdocs/vendor/symfony/symfony/src/Symfony/Component/EventDispatcher/EventDispatcher.php(264): Symfony\Component\EventDispatcher\Debug\WrappedListener->__invoke()

8 /opt/pimcore-6/apps/pimcore/htdocs/vendor/symfony/symfony/src/Symfony/Component/EventDispatcher/EventDispatcher.php(239): Symfony\Component\EventDispatcher\EventDispatcher->doDispatch()

9 /opt/pimcore-6/apps/pimcore/htdocs/vendor/symfony/symfony/src/Symfony/Component/EventDispatcher/EventDispatcher.php(73): Symfony\Component\EventDispatcher\EventDispatcher->callListeners()

10 /opt/pimcore-6/apps/pimcore/htdocs/vendor/symfony/symfony/src/Symfony/Component/EventDispatcher/Debug/TraceableEventDispatcher.php(168): Symfony\Component\EventDispatcher\EventDispatcher->dispatch()

11 /opt/pimcore-6/apps/pimcore/htdocs/vendor/pimcore/pimcore/models/DataObject/AbstractObject.php(716): Symfony\Component\EventDispatcher\Debug\TraceableEventDispatcher->dispatch()

12 /opt/pimcore-6/apps/pimcore/htdocs/vendor/pimcore/pimcore/models/DataObject/Concrete.php(748): Pimcore\Model\DataObject\AbstractObject->save()

13 /opt/pimcore-6/apps/pimcore/htdocs/vendor/pimcore/pimcore/bundles/AdminBundle/Controller/Admin/DataObject/DataObjectController.php(1260): Pimcore\Model\DataObject\Concrete->save()

14 /opt/pimcore-6/apps/pimcore/htdocs/vendor/symfony/symfony/src/Symfony/Component/HttpKernel/HttpKernel.php(158): Pimcore\Bundle\AdminBundle\Controller\Admin\DataObject\DataObjectController->saveAction()

15 /opt/pimcore-6/apps/pimcore/htdocs/vendor/symfony/symfony/src/Symfony/Component/HttpKernel/HttpKernel.php(80): Symfony\Component\HttpKernel\HttpKernel->handleRaw()

16 /opt/pimcore-6/apps/pimcore/htdocs/vendor/symfony/symfony/src/Symfony/Component/HttpKernel/Kernel.php(201): Symfony\Component\HttpKernel\HttpKernel->handle()

17 /opt/pimcore-6/apps/pimcore/htdocs/web/app.php(36): Symfony\Component\HttpKernel\Kernel->handle()

18 {main}


prugala commented 3 years ago

@ismetsener error isnt related with this bundle. You have problem with connection to Elastic Search. Check your Elastic Search connection.

ismetsener commented 3 years ago

but it does not translate also

prugala commented 3 years ago

Open Browser developer tools (F12) > tab: Network. Click on translate and show me response from translate request.

ismetsener commented 3 years ago

{success: false, message: "Something went wrong"} message: "Something went wrong" success: fals

prugala commented 3 years ago

Do you use Xdebug? If yes please add breaking point on line 56: https://github.com/DivanteLtd/pimcore-translation-bundle/blob/master/src/DivanteTranslationBundle/Controller/ObjectController.php#L56 and after click translate get $exception->getMessage() when xDebug stops.

if not, add before return in line 56: var_dump($exception->getMessage());

and copy var dump value from response after translate.

ismetsener commented 3 years ago
/opt/pimcore-6/apps/pimcore/htdocs/vendor/divante-ltd/pimcore-google-translate/src/DivanteTranslationBundle/Controller/ObjectController.php:56:string 'Provider default google_translate is not implemented.' (length=53)
{"success":false,"message":"Something went wrong"}
ismetsener commented 3 years ago

I see, I have to add new provider but how?


How to add new provider Create Provider and implement interface

DivanteTranslationBundle\Provider\ProviderInterface

prugala commented 3 years ago

ok :)

So in your config remove provider: default google_translate or change it on provider: google_translate

You set wrong provider name. I wrote that default value for provider is google_translate

ismetsener commented 3 years ago

I did, it seems to work, but strange translation: english text: The Aston Martin DB5 is a British luxury grand tourer (GT) that was made by Aston Martin and designed by the Italian coachbuilder Carrozzeria Touring Superleggera. Released in 1963, it was an evolution of the final series of DB4. The DB series was named honouring Sir David Brown (the owner of Aston Martin from 1947 to 1972).

Although not the first in the DB series, the DB5 is the best-known cinematic James Bond car, first appearing in the James Bond film Goldfinger (1964).

translated in German: % 3Cp% 3Die% 20Aston% 20Martin% 20DB5% 20is% 20a% 20British% 20luxury% 20grand% 20tourer% 20% 28GT% 29% 20at% 20was% 20made% 20by% 20Aston% 20Martin% 20und% 20designed% 20by% 20the% 20Italian % 20coachbuilder% 20Carrozzeria% 20Touring% 20Superleggera.% 20Released% 20in% 201963% 2C% 20it% 20was% 20an% 20evolution% 20of% 20the% 20final% 20series% 20of% 20DB4.% 20The% 20DB% 20series% 20was% % 20Sir% 20David% 20Brown% 20% 28the% 20owner% 20of% 20Aston% 20Martin% 20from% 201947% 20to% 201972% 29.% 3C% 2Fp% 3E% 0A% 0A% 3Cp% 3Abwohl% 20not% 20the% 20first% 20in% 20the% 20DB% 20series% 2C% 20the% 20DB5% 20is% 20the% 20best-% 20cinematic% 20James% 20Bond% 20car% 2C% 20first% 20appearing% 20in% 20the% 20James% 20Bond% 20film% 20Goldfinger% 20% 281964% 29.% 3C% 2Fp% 3E% 0A

prugala commented 3 years ago

OK I will close this issue. Please open one new about wrong translation.

Provider in new issue:

ismetsener commented 3 years ago

ok,, thanks for helping at this time at :) I wil open new issue