• Welcome to the Chevereto User Community!

    Here, users from all over the world come together to learn, share, and collaborate on everything related to Chevereto. It's a place to exchange ideas, ask questions, and help improve the software.

    Please keep in mind:

    • This community is user-driven. Always be polite and respectful to others.
    • Support development by purchasing a Chevereto license, which also gives you priority support.
    • Go further by joining the Community Subscription for even faster response times and to help sustain this space

Chevereto requires to setup cron (opens new window)to run background jobs.

snalans66

Chevereto Member
1、When the scheduled task is started, email messages are always sent. Is this normal?1665730002124.png


2、There is another question I want to ask. I want to write a class under /app/src/Legacy/Own. When referenced by Chevereto\Legacy\Own\Limiting::test(), it prompts that the class does not exist. What is the reason?
 
1、When the scheduled task is started, email messages are always sent. Is this normal?
Yes, because your cron supervisor is doing that. You need to silence the output by adding this at the end of the cron:

Code:
> /dev/null 2>&1

Following the example in the docs:

Code:
* * * * * www-data php /var/www/html/app/bin/legacy -C cron > /dev/null 2>&1
 
2、There is another question I want to ask. I want to write a class under /app/src/Legacy/Own. When referenced by Chevereto\Legacy\Own\Limiting::test(), it prompts that the class does not exist. What is the reason?
Because at app/composer.json it defines to use Authoritative class maps.

JSON:
    "config": {
        "classmap-authoritative": true
    }

So if this is your class:

1665758775204.png

You need to run from the project folder:

Code:
composer --working-dir=app dump-autoload

Here, this is the full procedure, at the bottom I spawn the repl to create an object for the above class.

Code:
www-data@fd6606916392:~/html$ composer --working-dir=app dump-autoload
Generating optimized autoload files (authoritative)
Generated optimized autoload files (authoritative) containing 22743 classes
www-data@fd6606916392:~/html$ app/bin/repl
Psy Shell v0.11.8 (PHP 8.1.10 — cli) by Justin Hileman
      __                        __
 ____/ /  ___ _  _____ _______ / /____
/ __/ _ \/ -_) |/ / -_) __/ -_) __/ _ \
\__/_//_/\__/|___/\__/_/  \__/\__/\___/

💫 This is a REPL (Read-Eval-Print-Loop) environment.
>>> new Chevereto\Legacy\Own\Limiting;

vdd()
------------------------------------------------------------
/var/www/html/app/src/Legacy/Own/Limiting.php:18

Arg•0 string Hay un límite the rompe el deseo, algo nuevo que va mas allá (length=60)
------------------------------------------------------------
www-data@fd6606916392:~/html$
 
Back
Top