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

Sometimes template code changes not detected in windows wls ubuntu22.04. #4987

Closed
quroom opened this issue Apr 12, 2024 · 4 comments
Closed
Labels

Comments

@quroom
Copy link
Contributor

quroom commented Apr 12, 2024

What happened?

With default runserver_plus reloader_type, when django template code changes, sometimes doens't detect changes.
sometimes happens three times detected with once code change.

What should've happened instead?

When code change, it should be detected immediately at once.

Additional details

  • Host system configuration:

    • Version of cookiecutter CLI (get it with cookiecutter --version):
      Cookiecutter 2.6.0 from /home/ubuntu/.pyenv/versions/3.12.2/lib/python3.12/site-packages (Python 3.12.2 (main, Apr 6 2024, 15:39:34) [GCC 11.4.0])

    • OS name and version:
      windows wsl2 ubuntu

Distributor ID: Ubuntu
Description:    Ubuntu 22.04.3 LTS
Release:        22.04
Codename:       jammy
  • Python version,: Python 3.12.2

  • Docker version (if using Docker): Docker version 25.0.3, build 4debf41

  • docker compose version (if using Docker), run docker compose --version: Docker Compose version v2.24.6-desktop.1

  • ...

  • Options selected and/or replay file:
    On Linux and macOS: cat ${HOME}/.cookiecutter_replay/cookiecutter-django.json
    (Please, take care to remove sensitive information)

{
  "cookiecutter": {
    "project_name": "shorts-obible",
    "project_slug": "shorts_obible",
    "description": "Curation shorts for bible",
    "author_name": "quroom",
    "domain_name": "shorts.obible.kr",
    "email": "quroom@naver.com",
    "version": "0.0.1",
    "open_source_license": "MIT",
    "username_type": "username",
    "timezone": "Asia/Seoul",
    "windows": "n",
    "editor": "VS Code",
    "use_docker": "y",
    "postgresql_version": "16",
    "cloud_provider": "None",
    "mail_service": "Other SMTP",
    "use_async": "n",
    "use_drf": "n",
    "frontend_pipeline": "None",
    "use_celery": "y",
    "use_mailpit": "n",
    "use_sentry": "n",
    "use_whitenoise": "y",
    "use_heroku": "n",
    "ci_tool": "Github",
    "keep_local_envs_in_vcs": "y",
    "debug": "n",
    "_template": "gh:cookiecutter/cookiecutter-django",
    "_output_dir": "/home/ubuntu",
    "_repo_dir": "/home/ubuntu/.cookiecutters/cookiecutter-django",
    "_checkout": null
  }

I found a workaround.
When I changed RUNSERVERPLUS_POLLER_RELOADER_TYPE to stat.
It works properly. It might be related to wsl2 issue #4970

Logs:
$ cookiecutter https://github.com/cookiecutter/cookiecutter-django
project_name [Project Name]: ...
@quroom quroom added the bug label Apr 12, 2024
@browniebroke
Copy link
Member

Is that still an issue now that #4971 is merged?

@browniebroke browniebroke added the waiting Waiting for an answer and auto-close after 10 days label Apr 16, 2024
@quroom
Copy link
Contributor Author

quroom commented Apr 17, 2024

Is that still an issue now that #4971 is merged?

With that option, It isn't issue.
But I guess we need some explanations, because someone thinks wsl ubuntu env is not related windows.
So they might check windows as n.
In document or creating template instruction with cookiecutter command, I guess it's better to announce.
How do you think?

@github-actions github-actions bot removed the waiting Waiting for an answer and auto-close after 10 days label Apr 17, 2024
@browniebroke
Copy link
Member

Not sure... I don't use Windows/WSL. Feel free to send a pull request to mention that under the windows option: https://cookiecutter-django.readthedocs.io/en/latest/project-generation-options.html

@quroom
Copy link
Contributor Author

quroom commented May 18, 2024

Not sure... I don't use Windows/WSL. Feel free to send a pull request to mention that under the windows option: https://cookiecutter-django.readthedocs.io/en/latest/project-generation-options.html

Thanks for answer :)
Nowadays I am working legacy project without cookiecutter.
So when I use cookiecutter again, if the patch needs I will make PR.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants