Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

511
Views
CHROME-EXTENSION: chrome.runtime.lastError sin pestaña con error de identificación

Estoy trabajando en un proyecto que crea una extensión de Google Chrome y estoy usando las API de Chrome. Ahora, estoy tratando de trabajar con mi función handleTabUpdate cuando se actualiza la pestaña. Sin embargo, recibo Unchecked runtime.lastError: No tab with id: 60

¿Cómo puedo arreglar eso? Aquí está mi código:

 chrome.tabs.onUpdated.addListener(handleTabUpdate)
 function handleTabUpdate(tabId, info) { if (info.status === 'loading') { store.dispatch({ type: 'RESET_TABHOSTS' }) chrome.tabs.get(tabId, (activeTab) => { if (tabId === store.getState().currentTab['id']) { store.dispatch({ type: 'ACTIVE_TAB', payload: activeTab }) } }) } }
about 4 years ago · Juan Pablo Isaza
1 answers
Answer question

0

Supongo que la pestaña que está buscando estaba cerrada, por lo que cuando intenta obtenerla por id , la operación falla.
Para evitar el error, mi sugerencia es primero consultar todas las pestañas y ver si existe una pestaña con una id específica en el resultado. Si es así, ejecute chrome.tabs.get() y con su lógica.

about 4 years ago · Juan Pablo Isaza Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!