Empresas
Empregos
  • Sobre nós
  • Soluções
    • Publicação de vagas
      Publique sua vaga e receba candidatos qualificados em 48h.
    • Avaliações de candidatos
      Mais de 500 testes técnicos e psicológicos, mais anti-fraude.
    • Headhunting
      Busca executiva personalizada do início ao fim.
    • Folha de Pagamento + EOR
      Dispersão de folha e EOR em mais de 15 países da LATAM.
  • Preços
  • Empregos

0

293
Visualizações
iPyKernel throwing "TypeError: object NoneType can't be used in 'await' expression"

I know that several similar questions exist on this topic, but to my knowledge all of them concern an async code (wrongly) written by the user, while in my case it comes from a Python package.

I have a Jupyter notebook whose first cell is

! pip install numpy
! pip install pandas

and I want to automatically play the notebook using Papermill. No problem on my local machine (Windows 11 with Python 3.7): I install iPyKernel and Papermill and everything is fine.

The problem is when I try to do the same on my BitBucket pipeline (Python image 3-alpine, but it happens under different others); the first cell throws the following error:

Traceback (most recent call last):
  File "/usr/local/lib/python3.7/site-packages/ipykernel/kernelbase.py", line 461, in dispatch_queue
    await self.process_one()
  File "/usr/local/lib/python3.7/site-packages/ipykernel/kernelbase.py", line 450, in process_one
    await dispatch(*args)
TypeError: object NoneType can't be used in 'await' expression

that makes the script stop at the 2nd cell, where I import numpy.

If it can be relevant, I've "papermilled" under the GitLab CI without any problem in the past.

over 4 years ago · Santiago Trujillo
1 Respostas
Responde à pergunta

0

Seems to be a bug in ipykernel 6.9.0 - options that worked for me:

  • upgrade to 6.9.1 (latest version as of 2022-02-22); e.g. via pip install ipykernel --upgrade
  • downgrade to 6.8.0 (if upgrading messes with other dependencies you might have); e.g. via pip install ipykernel==6.8.0
over 4 years ago · Santiago Trujillo Relatório
Responde à pergunta
Encontrar trabalhos remotos

Descubra a nova forma de encontrar um emprego!

melhores empregos
Principais categorias de trabalho
Empresas
Postar vaga Preços Comercial
Jurídico
Termos e Condições Política de privacidade
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomende algumas ofertas para mim
Preciso de ajuda