Giter VIP home page Giter VIP logo

Comments (2)

sleeptightAnsiC avatar sleeptightAnsiC commented on September 15, 2024

This is a general problem with Utility class which does a bunch of I/O operations but does not catch any exceptions related to them. These for sure shouldn't be treated as success, including KeyboardInterrupt.

Interrupting a process is considered as fatal error, imagine the following case: ue4 gen && ue4 build && ue4 run Interrupting gen or build would mean that the chain is broken. If ue4cli was returning 0 in this case, that would be very unexpected.

Though, I agree these cases should be catch, since current behavior is too confusing.

Probably the easiest way to fix it is creating custom Exception for Utility class, then wrapping every I/O call with try/except block - if it fails, it should raise said custom Exception, which then can be catch inside of cli::main. This is how UnrealManagerException is being used right now to handle similar problems.

from ue4cli.

sleeptightAnsiC avatar sleeptightAnsiC commented on September 15, 2024

Proposed fix #65

With said change you should get something like this:

$ ue4 run
# logging from Engine...
^C
(ue4cli) Error: (KeyboardInterrupt)
# return code 1

from ue4cli.

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.