import spacy on jupyter notebook fails with an error

Input In [23], in <cell line: 1>()
----> 1 import spacy

File ~\anaconda3\lib\site-packages\, in
8 setup_default_warnings() # noqa: E402
10 # These are imported as part of the API
—> 11 from thinc.api import prefer_gpu, require_gpu, require_cpu # noqa: F401
12 from thinc.api import Config
14 from . import pipeline # noqa: F401

File ~\anaconda3\lib\site-packages\, in
2 import numpy
4 from .about import version
----> 5 from .config import registry

File ~\anaconda3\lib\site-packages\thinc\, in
11 from pydantic.main import ModelMetaclass
12 from pydantic.fields import ModelField
—> 13 from wasabi import table
14 import srsly
15 import catalogue

File ~\anaconda3\lib\site-packages\, in
9 from .util import MESSAGES # noqa
10 from .about import version # noqa
—> 12 msg = Printer()

File ~\anaconda3\lib\site-packages\wasabi\, in Printer.init(self, pretty, no_print, colors, icons, line_max, animation, animation_ascii, hide_animation, ignore_warnings, env_prefix, timestamp)
54 self.pretty = pretty and not env_no_pretty
55 self.no_print = no_print
—> 56 self.show_color = supports_ansi() and not env_log_friendly
57 self.hide_animation = hide_animation or env_log_friendly
58 self.ignore_warnings = ignore_warnings

File ~\anaconda3\lib\site-packages\wasabi\, in supports_ansi()
262 if “ANSICON” in os.environ:
263 return True
→ 264 return _windows_console_supports_ansi()
266 return True

File ~\anaconda3\lib\site-packages\wasabi\, in _windows_console_supports_ansi()
233 if not ok:
234 raise ctypes.WinError()
→ 236 console = msvcrt.get_osfhandle(sys.stdout.fileno())
237 try:
238 # Try to enable ANSI output support
239 flags = GetConsoleMode(console)

File ~\anaconda3\lib\site-packages\ipykernel\, in OutStream.fileno(self)
308 return self._original_stdstream_copy
309 else:
→ 310 raise io.UnsupportedOperation(“fileno”)

UnsupportedOperation: fileno

dear hanan_rosenthal.

Thank you for your contribution to the anaconda community.

We welcome you to post your problems in iPython.

Yes, the problem with spyder and jupyter is that they don’t implement fileno (file number) because they don’t know how to handle it.

In the history of computer systems, is it managed as characters? Should it be managed as a file number? As is known, on the mainframe, files are managed by file number (python also works on IBM’s zSeries). And in MS-WINDOWS and APPLE iOS, including UNIX, it is managed by file name.

Since python was born in the latter history, it is not managed by file number. Therefore, I would like to thank you for pointing out that the cause is that you do not have that API.

Best regards.