Pull-induced rename leaves an in-project encryption key path pointing at the old directory
Los mantenedores suelen responder en 1 día
Nadie ha tomado este issue todavía.
Evaluación
- Dificultad
- 2/5
- Tiempo estimado
- 1-3 horas
- Aptitud para principiantes
- 76/100
Línea de trabajo
Empieza en lean/components/cloud/pull_manager.py, especialmente en _pull_project y su llamada a ProjectManager.rename_project_and_contents; lee la corrección relacionada con #742 e inspecciona ProjectManager.get_path_after_project_rename. Revisa las pruebas del gestor de pull sobre el comportamiento al cambiar nombres y añade cobertura para una ruta de clave dentro del proyecto y otra fuera de él. Se considera terminado cuando la ruta de clave interna apunta al directorio renombrado y las rutas de claves externas permanecen sin cambios.
Escrito por el modelo de indexación a partir del texto del issue.
Descripción
Problem
When lean cloud pull finds a project on disk under a name the cloud project no longer has, it renames the local directory with ProjectManager.rename_project_and_contents (lean/components/cloud/pull_manager.py, _pull_project). A key file stored inside the project directory moves with it, but the project's encryption-key-path keeps the old location. The next lean cloud push of the project then fails to open the key.
This is the pull side of #742, which fixes the same case for push.
Reproduction
- Create a project
Project A, copy a registered encryption key into it asProject A/key.txt, runlean encrypt "Project A" --key "<abs path>/Project A/key.txt"andlean cloud push --project "Project A". - Rename the cloud project to
Project B(in the web IDE, orprojects/update). lean cloud pull --project "Project B": the local directory becomesProject B, withkey.txtinside, butProject B/config.jsonstill has"encryption-key-path": "<abs path>/Project A/key.txt".lean cloud push --project "Project B"printsCannot push 'Project B': [Errno 2] No such file or directory: '<abs path>/Project A/key.txt'.
Expected result
After the rename, a configured key inside the project directory is found at its new location, so the next push works. Keys outside the project directory keep their path. The fix for #742 adds ProjectManager.get_path_after_project_rename, which pull could reuse (suggestion).
- Lenguaje dominante
- Python
- Estrellas
- 335
- Forks
- 172
- Merge medio
- 6 h 54 min
- PR fusionados (30 d)
- 37
Preparar el entorno
Este proyecto no incluye contenedor de desarrollo, Dockerfile ni guía de contribución, así que la configuración corre por tu cuenta: empieza por su README y consulta nuestra guía para la primera contribución para los pasos generales.
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Más de QuantConnect/lean-cli
-
priority:P2
Dificultad 2/5 1-3 horas Aptitud para principiantes 75/100
QuantConnect/lean-cli#792 ·
Los mantenedores suelen responder en 1 día
-
priority:P2
Dificultad 2/5 1-3 horas Aptitud para principiantes 74/100
QuantConnect/lean-cli#786 ·
Los mantenedores suelen responder en 1 día
-
priority:P2
Dificultad 2/5 1-3 horas Aptitud para principiantes 72/100
QuantConnect/lean-cli#785 ·
Los mantenedores suelen responder en 1 día
-
A partially written live command result aborts polling with JSONDecodeErrorPosiblemente ocupada @pcbeingused333 la tomó hace 3 días. Abiertopriority:P2
Dificultad 2/5 1-3 horas Aptitud para principiantes 72/100
QuantConnect/lean-cli#784 ·
Los mantenedores suelen responder en 1 día
-
Container lookup failures during result polling are masked by UnboundLocalErrorPosiblemente ocupada @pcbeingused333 la tomó hace 5 días. Abiertopriority:P2
Dificultad 2/5 1-3 horas Aptitud para principiantes 80/100
QuantConnect/lean-cli#783 ·
Los mantenedores suelen responder en 1 día
Todos los issues de QuantConnect/lean-cli
Issues similares
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 78/100
pimutils/vdirsyncer#1242 ·
-
bug
Dificultad 2/5 1-3 horas Aptitud para principiantes 82/100
open-webui/open-webui#35360 · 1 comentario ·
Los mantenedores suelen responder en 1 día
-
bug
Dificultad 2/5 1-3 horas Aptitud para principiantes 76/100
-
Suggest link: Destiny Verify (MIT zero-dependency pre-commit security, citation & link hygiene CLI)Abierto
Dificultad 1/5 Menos de una hora Aptitud para principiantes 68/100
-
bug
Dificultad 2/5 1-3 horas Aptitud para principiantes 85/100
Los mantenedores suelen responder en 1 día