Author Topic: error  (Read 6463 times)

0 Members and 1 Guest are viewing this topic.

edgi

  • Jr. Member
  • **
  • Posts: 4
error
« on: June 16, 2015, 08:25:41 AM »
I changed the config file here that he wrote:
# Plugins
plugins:
      "Mibew: emoji":


then immediately got an error when entering the admin panel:

Fatal error: Uncaught exception 'Symfony\Component\Yaml\Exception\ParseException' with message 'Malformed inline YAML string [ at line 81 (near "plugins: [")' in /home/virtwww/w_evrokaskad-ru_e5d26541/http/Mibew/vendor/symfony/yaml/Symfony/Component/Yaml/Inline.php:331 Stack trace: #0 /home/virtwww/w_evrokaskad-ru_e5d26541/http/Mibew/vendor/symfony/yaml/Symfony/Component/Yaml/Inline.php(63): Symfony\Component\Yaml\Inline::parseSequence('[', 1, Array) #1 /home/virtwww/w_evrokaskad-ru_e5d26541/http/Mibew/vendor/symfony/yaml/Symfony/Component/Yaml/Parser.php(467): Symfony\Component\Yaml\Inline::parse('[', false, false, false, Array) #2 /home/virtwww/w_evrokaskad-ru_e5d26541/http/Mibew/vendor/symfony/yaml/Symfony/Component/Yaml/Parser.php(223): Symfony\Component\Yaml\Parser->parseValue('[', false, false, false) #3 /home/virtwww/w_evrokaskad-ru_e5d26541/http/Mibew/libs/common/configurations.php(35): Symfony\Component\Yaml\Parser->parse('# IMPORTANT: Be...') #4 /home/virtwww/w_evrokaskad-ru_e5d26541/http/Mibew/libs/init.php(32) in /home/virtwww/w_evrokaskad-ru_e5d26541/http/Mibew/vendor/symfony/yaml/Symfony/Component/Yaml/Inline.php on line 331

Dmitriy Simushev

  • Moderator
  • Native
  • *****
  • Posts: 345
Re: error
« Reply #1 on: June 16, 2015, 08:33:13 AM »
You have a syntax error in config.yml, so you have to double check this file.

Also, there are many docs about YAML syntax over the Internet. I recommend to take a look at one of these docs.

edgi

  • Jr. Member
  • **
  • Posts: 4
Re: error
« Reply #2 on: June 16, 2015, 09:02:50 AM »
Can you see the lines connecting the correct spelling of a plug-in configuration file from the demo version mibew.
I'm not a programmer. I did everything as it is written in the documentation:
Lets assume you are trying to install "FooCorp: Connector" plugin that requires timeout and reconnects options. The plugins array from configs / config.yml file becomes:

Code: [Select]
plugins:
     "FooCorp: Connector":
         timeout: 200
         reconnects: 3

I wrote this:
Code: [Select]
plugins:
     "Mibew: Emoji"
« Last Edit: June 16, 2015, 09:05:27 AM by edgi »

Dmitriy Simushev

  • Moderator
  • Native
  • *****
  • Posts: 345
Re: error
« Reply #3 on: June 16, 2015, 09:41:31 AM »
First of all, YAML format is very simple, you don't need to be a programmer to use it. I strongly recommend you to take a look at one of plenty format descriptions.

Second of all, there must not be a space between vendor name ("FooCorp") and plugin name ("Connector"):
Code: [Select]
plugins:
     "FooCorp:Connector":
         timeout: 200
         reconnects: 3

Next, example of correct Emoji plugin configuration is provided in plugin's README file. Let me quote it for you (I removed the comment to make the reading easier):
Code: [Select]
plugins:
    "Mibew:Emoji":
        ignore_emoticons: false

edgi

  • Jr. Member
  • **
  • Posts: 4
Re: error
« Reply #4 on: June 16, 2015, 10:50:20 AM »
lowercase or uppercase letters in the names of folders in the config file has a value?

my config file is now as follows:
Code: [Select]
plugins:
    "Mibew:Emoji":
        ignore_emoticons: false
    "Mibew:GeoIp":
        database_path: "/opt/GeoIP/GeoLite2-City.mmdb"
    "Mibew:GoogleMaps":
        api_key: "Google_Maps_Javascript_v3_API_key"
    "Mibew:TitleNotification":
        new_thread: true
        new_message: "both"
    "Mibew:PurgeHistory":
        timeout: 172800

but in the admin panel plugins do not appear.
I can not plug in those subdirectories copied?
I have attached a screen directory tree.

Dmitriy Simushev

  • Moderator
  • Native
  • *****
  • Posts: 345
Re: error
« Reply #5 on: June 16, 2015, 10:57:21 AM »
Why don't you read README file that shipped with plugins?!

If we talk about "Mibew:Emoji" pluign the directories structure should be as follows:

Code: [Select]

mibew/
    cache/
    configs/
    files/
    js/
    libs/
    locales/
    plugins/
        Mibew/
            Mibew/
                Plugin/
                    Emoji/
                        css/
                        js/
                        LICENSE
                        Plugin.php
                        README.md

...


edgi

  • Jr. Member
  • **
  • Posts: 4
Re: error
« Reply #6 on: June 16, 2015, 11:25:58 AM »
Thanks it worked. The problem was in symbols all directories and files are copied from the small letters. Example: Emoji (works) emoji (not working) it refers to the name of the file and directory names.
Thread can be closed