Git Product home page Git Product logo

Comments (2)

Detegr avatar Detegr commented on July 23, 2024

I don't know what volta.sh does internally, but it does not make sense to me that flags for a fd that is created with pipe2 could have anything to do with the Python process' stderr. Can you provide a smaller example to narrow down the variables? Maybe some simple Rust program with ctrlc and some interface to Python, which is then called from Python?

from rust-ctrlc.

NotSqrt avatar NotSqrt commented on July 23, 2024

I've managed to reproduce the issue, and by simplifying it, I got to a point where Rust and ctrlc were no longer involved...

I was misdirected by strace, because the only call using F_SETFL was inside ctrlc, but it seems instead that it is directly inside the node binary that something strange happens.

2 successive calls F_GETFL (one from node, one from python) give different flags without any calls using F_SETFD

 > ~/.volta/tools/image/node/10.24.1/bin/node(v8::internal::Builtin_HandleApiCall(int, v8::internal::Object**, v8::internal::Isolate*)+0xb9) [0x792319]
 > unexpected_backtracing_error [0x2cceceedbf1d]
[pid 69819] fcntl(2, F_GETFL)           = 0x1 (flags O_WRONLY)
--
 > ~/.pyenv/versions/3.10.1/bin/python3.10(_start+0x25) [0x64e45]
[pid 69814] fcntl(2, F_GETFL)           = 0x801 (flags O_WRONLY|O_NONBLOCK)

This bug was present in node 10.24.1, but is no longer present in node 14.18.3, so.. problem solved..

from rust-ctrlc.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.