Container doesn't start by indentation

Hello, I’m building my app without any trouble by months. I’m using Docker version of Tryton. Everything was fine until I add some @classmethods to my classes.
But I made a mistake, and my server instance doesn’t start. I mean, it starts but shortly after some seconds stops.


How I could correct the error? I used docker CP to upload the right *.py but I tryton ignores the change.

@raserize
Looks like a simple error with spaces. Check this docs to get an idea of the error:

Yeah, I know it’s an error with spaces. But I can’t correct it if web server instance shutdown and I can’t upload the right class.

You should not copy file to running docker image but build a new image based on the published tryton/tryton image using a Dockerfile.

1 Like

FWIW, Emacs can still access files in docker containers even if they are not started. Otherwise, you are forced to manipulate the docker filesystem (not recommended) or to use docker commit to save your container as an image; from there, you can start the image with a different run command, e.g. a shell, then modify the file as needed.

1 Like

This sounds like you are not having at least a minimal test-suite for your module or your are not running it prior to putting it into the container.
If so, I strongly suggest implementing a minimal test-suite as it helps you finding these kind or errors early. Have a look at

or Tryton Community / cookiecutter-module · GitLab.

2 Likes