Eric Wieser

Results 440 comments of Eric Wieser

> Perhaps we should restore them using `sys.__stdout__`/`sys.__stderr__` on failure? If that function failed, then there is nothing to restore - the very last operation is `setattr`.

> This is likely a Windows, or a Windows + Modelsim issue. Windows 10 + modelsim was how this manifested for me in the past.

It looks to me like the difference between good vs bad is whether modelsim prints the following before or after our logging starts: ``` # Loading std.standard # Loading std.textio(body)...

@ktbarrett, I think we could perhaps learn something by checking the return code of `fprintf` here: https://github.com/cocotb/cocotb/blob/d566d19a8a400e99ab5a298844e9fa7b86940a68/cocotb/share/lib/gpi_log/gpi_logging.cpp#L120-L136 If these fail, we could try `fprintf(stderr, "Could not write to stdout!")`

Not a huge fan of this change. `request` is a nice way to pass session state (ie current user) into templates, without having to forward it at every call to...

I'm trying to cover this situation, using STPL: `main.tpl` ``` include('components/user-image.tpl') ``` `components/user-image` ``` % if request.user: % else: For privacy reasons, images are not shown for anonymous users %...

Caused by these lines: https://github.com/nschloe/tikzplotlib/blob/cd04740b0125b2ecd8c3d0f4aee9958ff762ccda/tikzplotlib/_patch.py#L116-L122

As of #374 it's possible to set the `sep` options from python.

> I suspect that's because Python sequences are heterogeneous — and it would make sense for an ndarray-of-objects to similarly refuse to perform string formatting if we wanted strict symmetry....

Any chance you could split this into a simple PR that adds `quantile`, and a more complex one that adds the weights?