Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allowed memory in reset-dev #857

Closed
pvsaintpe opened this issue Jun 14, 2019 · 3 comments
Closed

Allowed memory in reset-dev #857

pvsaintpe opened this issue Jun 14, 2019 · 3 comments

Comments

@pvsaintpe
Copy link

pvsaintpe commented Jun 14, 2019

Hi, I have a problem with loading demo-data

Describe the bug

bin/console Kimai:reset-dev
N
Y

   > loading App\DataFixtures\TimesheetFixtures

 // Clearing the cache for the dev environment with debug true                                                          

PHP Fatal error:  Allowed memory size of 134217728 bytes exhausted (tried to allocate 20480 bytes) in /Users/pvsaintpe/test/symfony4-app/vendor/twig/twig/src/Node/Expression/ConstantExpression.php on line 21
PHP Stack trace:

Additional info

  1. MacBook Pro + MariaDB (brew) + php 7.3.6

Solution (Huck)

php -d memory_limit=2G bin/console kimai:reset-dev

It's worked.

But is not a right way, maybe....

@kevinpapst
Copy link
Member

Hi @pvsaintpe !
128MB seems to be a lot of memory on the on hand, but on the other hand this is a developer command: creating a lot of in-memory data, especially the TimesheetFixtures and I can't change the way Doctrine is handling the fixtures.

The memory consumption will stop at one point and not rise, but I never cared to researched where that point is. But I can tell you, that I recently created a database with 1.5 million timesheet records and the memory never went above a certain threshold - so there is no "real memory leak".

@kevinpapst
Copy link
Member

Thanks for sharing your experience! I don't think there is much to do here, so I close the issue.
Hopefully it will someone else with the same problem in the future.

@lock
Copy link

lock bot commented Aug 18, 2019

This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. If you use Kimai on a daily basis, please consider donating to support further development of Kimai.

@lock lock bot locked and limited conversation to collaborators Aug 18, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Development

No branches or pull requests

2 participants