-
Notifications
You must be signed in to change notification settings - Fork 201
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
Fixes #312 : Added solution for ModuleNotFoundError #427
Fixes #312 : Added solution for ModuleNotFoundError #427
Conversation
Signed-off-by: Pushpit <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There's a better solution to solve all such problems, see my comment inline.
README.rst
Outdated
@@ -106,6 +106,12 @@ compose. For this you need to have the following installed. | |||
Use ``sudo docker-compose up`` to start VulnerableCode. Then access | |||
VulnerableCode at http://localhost:8000/ or at http://127.0.0.1:8000/ | |||
|
|||
If you run into a ``ModuleNotFoundError: No module named '<module>'``, run:: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
let's make this more general.
The root cause of problem here is that after upgrading the code, the docker setup is not synced ie new migrations, deps are not applied.
So a better solution to fix all such problems would be to do
sudo docker-compose up -d --no-deps --build web
So I would change this to something like
Don't forget to run `sudo docker-compose up -d --no-deps --build web` to sync your instance after every `git pull`.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
oh, great. Running this will sync the docker environment each time the codebase updates
Signed-off-by: Pushpit <[email protected]>
README.rst
Outdated
@@ -106,6 +106,9 @@ compose. For this you need to have the following installed. | |||
Use ``sudo docker-compose up`` to start VulnerableCode. Then access | |||
VulnerableCode at http://localhost:8000/ or at http://127.0.0.1:8000/ | |||
|
|||
**Important**: Don't forget to run `sudo docker-compose up -d --no-deps --build web` to sync your instance after every `git pull`. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You need to enclose the command in 2 tildes
Signed-off-by: Pushpit <[email protected]>
Added commands to run in case of running into a ModuleNotFoundError
Signed-off-by: Pushpit [email protected]