Cloud commands with --push do not upload referenced libraries

Aperta
#719 0 commenti 0 reazioni 0 assegnatari Vedi su GitHub

I maintainer di solito rispondono entro 1 giorno

@pcbeingused333 ci sta già lavorando.

Dal 14/11/2026.

  • #725 di @pcbeingused333 — aperta
  • #749 di @quantconnect-kronos — chiusa senza merge

Valutazione

Difficoltà
3/5
Tempo stimato
1-2 giorni
Idoneità per principianti
25/100
Tipo di issue
Bug
Chiarezza
Specificata chiaramente
Stato di attività
Ferma
Stack tecnologico
python
Ambito
cli, cloud

Direzione di ricerca

Start in lean/components/cloud/cloud_project_manager.py, where the --push branches call push_projects([local_path]) without libraries, and compare with PushManager.push_project, which discovers project libraries first. Pull request #725 is already open against this issue, so check it before starting. Done means a changed referenced library is uploaded with the main project, and a failed required library upload stops compilation or execution.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

priority:P1

Problem

The cloud commands' --push path uploads the main project but does not upload its referenced local libraries. If a library already has a cloud ID, the main project update succeeds and the command can compile and run against the older cloud library contents without a push failure.

Reproduction

  1. Create a Python project Example referencing a local Python library Library/Helpers.
  2. Run lean cloud push --project Example once so both projects have cloud IDs.
  3. Change a function in Library/Helpers without separately pushing it.
  4. Run lean cloud backtest Example --push.

The resolver uploads Example and sends its existing library ID, but does not upload the changed library. The shared resolver is also used by lean cloud optimize --push and lean cloud live deploy --push.

Evidence

In lean/components/cloud/cloud_project_manager.py, both push branches call push_projects([local_path]) without supplying associated libraries. PushManager.push_projects uses only the supplied project and library lists. By contrast, PushManager.push_project first calls get_project_libraries and passes those libraries to push_projects.

A local regression probe using the real resolver, push manager, project configuration and library reference handling, with a mocked API, reproduced this on master commit f3deb21: the main project had ID 20 and its library had ID 21; resolution returned successfully, projects.update was called only for ID 20, and that update contained libraries=[21]. No update for ID 21 occurred.

Expected behavior

When a cloud command requests a push, referenced local libraries should be synchronized along with the main project, and a required library upload failure should prevent compilation/execution.

Suggestion: reuse the library-discovery path used by push_project and propagate the aggregate push result. Add coverage for changed libraries and failed library uploads. Explicitly running lean cloud push --project Example first is a workaround.

Lingua principale
Python
Stelle
335
Fork
172
Merge medio
6h 54m
PR unite (30g)
37

Preparare l'ambiente

Questo progetto non fornisce container di sviluppo, Dockerfile né guida per i contributori, quindi l'ambiente è a tuo carico: parti dal suo README e consulta la nostra guida al primo contributo per i passaggi generali.

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di QuantConnect/lean-cli

Tutte le issue di QuantConnect/lean-cli

Issue simili

Altre issue su Python

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.