Page 1 of 1

Error Template text-salutation-header-default.php not availa

Posted: 16 Aug 2016, 23:41
by jossnaz
i am getting this error when trying to run the cronjob for the emails.


Code: Select all

#16 {main} Error while trying to send payment e-mail for order ID "9" and status "6": Template "email/common/text-salutation-header-default.php" not available

Trace: #0 /var/www/html/myapp/vendor/aimeos/aimeos-core/lib/mwlib/src/MW/View/Standard.php(219): Aimeos\MW\View\Standard->resolve(Array)
#1 /var/www/html/myapp/ext/ai-client-html/client/html/src/Client/Html/Email/Payment/Text/Salutation/Standard.php(167): Aimeos\MW\View\Standard->render(Array)
#2 /var/www/html/myapp/ext/ai-client-html/client/html/src/Client/Html/Email/Payment/Text/Standard.php(187): Aimeos\Client\Html\Email\Payment\Text\Salutation\Standard->getHeader('', Array, NULL)
#3 /var/www/html/myapp/ext/ai-client-html/client/html/src/Client/Html/Email/Payment/Standard.php(152): Aimeos\Client\Html\Email\Payment\Text\Standard->getHeader('', Array, NULL)
#4 /var/www/html/myapp/ext/ai-client-html/controller/jobs/src/Controller/Jobs/Order/Email/Payment/Standard.php(159): Aimeos\Client\Html\Email\Payment\Standard->getHeader()
#5 /var/www/html/myapp/vendor/aimeos/aimeos-laravel/src/Aimeos/Shop/Command/JobsCommand.php(60): Aimeos\Controller\Jobs\Order\Email\Payment\Standard->run()
#6 [internal function]: Aimeos\Shop\Command\JobsCommand->fire()
#7 /var/www/html/myapp/vendor/laravel/framework/src/Illuminate/Container/Container.php(507): call_user_func_array(Array, Array)
#8 /var/www/html/myapp/vendor/laravel/framework/src/Illuminate/Console/Command.php(150): Illuminate\Container\Container->call(Array)
#9 /var/www/html/myapp/vendor/symfony/console/Command/Command.php(256): Illuminate\Console\Command->execute(Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))
#10 /var/www/html/myapp/vendor/laravel/framework/src/Illuminate/Console/Command.php(136): Symfony\Component\Console\Command\Command->run(Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))
#11 /var/www/html/myapp/vendor/symfony/console/Application.php(841): Illuminate\Console\Command->run(Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))
#12 /var/www/html/myapp/vendor/symfony/console/Application.php(189): Symfony\Component\Console\Application->doRunCommand(Object(Aimeos\Shop\Command\JobsCommand), Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))
#13 /var/www/html/myapp/vendor/symfony/console/Application.php(120): Symfony\Component\Console\Application->doRun(Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))
#14 /var/www/html/myapp/vendor/laravel/framework/src/Illuminate/Foundation/Console/Kernel.php(107): Symfony\Component\Console\Application->run(Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))
#15 /var/www/html/myapp/artisan(35): Illuminate\Foundation\Console\Kernel->handle(Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))

i run the cronjobs from the scheduler:

Code: Select all

<?php

namespace Ffix\Console;

use Illuminate\Console\Scheduling\Schedule;
use Illuminate\Foundation\Console\Kernel as ConsoleKernel;

class Kernel extends ConsoleKernel
{
  /**
   * The Artisan commands provided by your application.
   *
   * @var array
   */
  protected $commands = [
    Commands\Inspire::class,
  ];

  /**
   * Define the application's command schedule.
   *
   * @param  \Illuminate\Console\Scheduling\Schedule $schedule
   * @return void
   */
  protected function schedule(Schedule $schedule)
  {

    $minuteCronJobLog = base_path() . '/storage/logs/cronjob_minute.log';
    $hourCronJobLog = base_path() . '/storage/logs/cronjob_hour.log';
    $dayCronJobLog = base_path() . '/storage/logs/cronjob_day.log';
    $outPutDateTimeFn = function () {
      $date = date('Y-m-d H:i:s');
      echo $date . ': ';
    };
    $schedule->command('aimeos:jobs "order/email/delivery order/email/payment order/service/delivery"')
      ->everyMinute()
      ->before($outPutDateTimeFn)
      ->appendOutputTo($minuteCronJobLog);

    $schedule->command('aimeos:jobs "customer/email/watch order/cleanup/unfinished order/service/async order/service/payment"')
      ->hourly()
      ->before($outPutDateTimeFn)
      ->appendOutputTo($hourCronJobLog);

    $schedule->command('aimeos:jobs "admin/cache admin/log order/cleanup/unpaid product/bought index/rebuild index/optimize"')
      ->daily()
      ->before($outPutDateTimeFn)
      ->appendOutputTo($dayCronJobLog);

  }
}
any idea why it cannot find the template file?

it certainly is there

`ff-laravel/ext/ai-client-html/client/html/templates/email/common/text-salutation-header-default.php` exists


my shop.php

Code: Select all

  'client' => array(
    'html' => array(
      'common' => array(
        'content' => array(
          'baseurl' => 'http://ffix.local/',

        ),
        'template' => array(
          'baseurl' => public_path('packages/aimeos/shop/elegance'),
        ),
      ),
      'email' => array(
        'from-email' => 'hithere+testaimeos@gmail.com',
        'from-name' => 'Test Aimeos',
      ),
    ),
  ),

just another debug:

`ff-laravel/vendor/aimeos/aimeos-core/lib/mwlib/src/MW/View/Standard.php`

$this->path is:

Code: Select all

array (
  '/var/www/html/fixturefix/ext/ai-controller-jobs' => 
  array (
    0 => 'controller/jobs/templates',
  ),
)
hope it helps

so the folder aimeos is trying to access is this: (debug from resolve() function of the View)

`/home/myuser/IdeaProjects/myapp/ff-laravel/ext/ai-controller-jobs/controller/jobs/templates/email/payment/5/text-salutation-header-default.php`

this is obviously wrong. Even though i call it from a controller, it should look in a different folder.... someone can shed some light into this?

Re: Error Template text-salutation-header-default.php not av

Posted: 18 Aug 2016, 10:19
by aimeos
Which Aimeos version are you using? Do you use the latest stable one (~2016.07)?

Re: Error Template text-salutation-header-default.php not av

Posted: 18 Aug 2016, 19:38
by jossnaz
exactly 2016.07.2

Re: Error Template text-salutation-header-default.php not av

Posted: 18 Aug 2016, 22:35
by jossnaz
solution: downgrade to 2016.4.03

i must say, I am not very impressed.


after downgrading and seeing it work, i upgraded again

no, stops working again.

Re: Error Template text-salutation-header-default.php not av

Posted: 19 Aug 2016, 01:26
by jossnaz
there was another error even that i didnt even dared to mention.

It said something like

'service provider has no function process'

that is, in 2016.07.2

in 2014.04.3 it seems to work

Re: Error Template text-salutation-header-default.php not av

Posted: 19 Aug 2016, 19:35
by aimeos
jossnaz wrote:after downgrading and seeing it work, i upgraded again
There was a mismatch between the new outsourcedt ai-client-html extension and the Laravel integration. We've fixed that and have released a new minor version of the HTML client.
jossnaz wrote:i must say, I am not very impressed.
Aimeos is a community project and lives from its contributors. Like Laravel, we release often to get new versions early to the users. This may lead to bugs that are quickly fixed and compared to Laravel, the number of bugfix releases is quite small. If you need a rock solid version, you should use the Aimeos LTS version.

Cheers

Andi

Re: Error Template text-salutation-header-default.php not av

Posted: 19 Aug 2016, 19:37
by aimeos
jossnaz wrote:'service provider has no function process'
Can you post more information about the error, maybe a stack trace?

Re: Error Template text-salutation-header-default.php not av

Posted: 19 Aug 2016, 20:54
by jossnaz
aimeos wrote: If you need a rock solid version, you should use the Aimeos LTS version.

Cheers

Andi
i thought stable somehow means that someone at least tested it once. For people wondering about LTS... it would be good if you leave a note about it on the installation page. I didn't know there exists LTS for aimeos

https://aimeos.org/project/roadmap/

so we can expect LTS at 2016.09?


another recommendation:

Change the name of the forum link to "forum" and not "help"

go to https://www.amazon.com/ and click on help. That is what one expects from a help link. I never knew the forum existed until i found a post for an error i had. And i was like "oh there is a forum, so i don't have to post issues to github..."

Re: Error Template text-salutation-header-default.php not av

Posted: 19 Aug 2016, 21:50
by jossnaz
i continue this thread here

post3226.html#p3225

Re: Error Template text-salutation-header-default.php not av

Posted: 20 Aug 2016, 21:07
by aimeos
jossnaz wrote: i thought stable somehow means that someone at least tested it once. For people wondering about LTS... it would be good if you leave a note about it on the installation page. I didn't know there exists LTS for aimeos
You ran into a problem that only surfaces when using the demo data. In real projects nobody noticed that up to now because this combination isn't used there.

We have unit tests for 90% of the code but sadly, that doesn't say that it's bug free. Some areas are hard to test automatically because there are too much dependencies like in this case (create an order in the frontend, run the Laravel jobs on the console). Our tests always include frontend and backend but not always the jobs. This is something where we may need to get better.

We will add a hint about this. The current LTS version is Aimeos 1.2 for Laravel from October last year.
jossnaz wrote:so we can expect LTS at 2016.09?
The next LTS release will be 2016.10 in the first half of October. The new big features has been implemented in the first half of this year so we are mainly polishing the current stable version to get it as bug free as possible and update the documentation.
jossnaz wrote:Change the name of the forum link to "forum" and not "help"
OK, that's a good hint. Thanks!