fix(linkedin): conservative settings merge, mkdir guard, split dockerfile playwright layer
This commit is contained in:
parent
6b59804d35
commit
f3617abb6b
2 changed files with 10 additions and 5 deletions
|
|
@ -10,9 +10,12 @@ RUN apt-get update && apt-get install -y --no-install-recommends \
|
|||
&& rm -rf /var/lib/apt/lists/*
|
||||
|
||||
COPY requirements.txt .
|
||||
RUN pip install --no-cache-dir -r requirements.txt && \
|
||||
playwright install chromium && \
|
||||
playwright install-deps chromium
|
||||
# Install Python dependencies
|
||||
RUN pip install --no-cache-dir -r requirements.txt
|
||||
|
||||
# Install Playwright browser (cached separately from Python deps so requirements
|
||||
# changes don't bust the ~600–900 MB Chromium layer and vice versa)
|
||||
RUN playwright install chromium && playwright install-deps chromium
|
||||
|
||||
# Bundle companyScraper (company research web scraper)
|
||||
COPY scrapers/ /app/scrapers/
|
||||
|
|
|
|||
|
|
@ -592,9 +592,11 @@ with tab_resume:
|
|||
# ── LinkedIn import ───────────────────────────────────────────────────────
|
||||
_li_data = st.session_state.pop("_linkedin_extracted", None)
|
||||
if _li_data:
|
||||
# Merge imported data into resume YAML
|
||||
# Merge imported data into resume YAML — only bootstrap empty fields,
|
||||
# never overwrite existing detail with sparse LinkedIn data
|
||||
existing = load_yaml(RESUME_PATH)
|
||||
existing.update({k: v for k, v in _li_data.items() if v})
|
||||
existing.update({k: v for k, v in _li_data.items() if v and not existing.get(k)})
|
||||
RESUME_PATH.parent.mkdir(parents=True, exist_ok=True)
|
||||
save_yaml(RESUME_PATH, existing)
|
||||
st.success("LinkedIn data applied to resume profile.")
|
||||
st.rerun()
|
||||
|
|
|
|||
Loading…
Reference in a new issue