Coder Social home page Coder Social logo

Comments (14)

fabiopelosin avatar fabiopelosin commented on May 26, 2024

Closed by 6c7f6b3

from claide.

AliSoftware avatar AliSoftware commented on May 26, 2024

๐Ÿ‘

from claide.

kylef avatar kylef commented on May 26, 2024

Sorry guys, missed something with the yellow warning:

screen shot 2014-05-20 at 15 44 26

from claide.

fabiopelosin avatar fabiopelosin commented on May 26, 2024

That happens during class evaluation much earlier than CLAide::Command::run

from claide.

fabiopelosin avatar fabiopelosin commented on May 26, 2024

I don't have a well formed opinion about this yet... the options that I see are:

  • Remove the colour form the warning
  • Do nothing as it is a temporary problem
  • Refactor to print the warnings in CLAide::Command::run

None of those look optimal to me.

from claide.

fabiopelosin avatar fabiopelosin commented on May 26, 2024

I think that we shouldn't fix this as it is a temporary problem

from claide.

fabiopelosin avatar fabiopelosin commented on May 26, 2024

Closing until someone weight-ins expressing a reason about why we should fix.

from claide.

alloy avatar alloy commented on May 26, 2024

Itโ€™s temporary now, but other warnings will be introduced at some point, so itโ€™s a recurring problem.

from claide.

fabiopelosin avatar fabiopelosin commented on May 26, 2024

This problem doesn't affect all warnings but specifically this one because the warning is presented during the initialization of the concrete CLAide sub-classes: https://github.com/CocoaPods/CLAide/blob/master/lib/claide/command.rb#L502-L503

This happens before the machinery to handle the ANSI flag is setup. It is very unlikely that we encounter a similar warning. Moreover, handling it properly would require extensive changes to the architecture of CLAide (i.e. to parse and handle the --no-ansi flag before loading the classes of the concrete CLAide commands).

from claide.

fabiopelosin avatar fabiopelosin commented on May 26, 2024

Another important thing to keep in mind is that the --no-ansi has been introduced to not pollute the standard output of the executables when used by a script (not for visual preference). The warnings are printed to the standard error stream and thus it is less relevant to strip the ANSI codes from them, although still desiderable for visual consistency.

from claide.

alloy avatar alloy commented on May 26, 2024

I was actually thinking more of buffering such early warnings in a simple array and displaying them as soon as the options were parsed and evaluated. That might still be too much, but I think that an app like AppCode does not like ANSI, ever?

from claide.

fabiopelosin avatar fabiopelosin commented on May 26, 2024

Good alternative. A bit annoying that we already do that in CocoaPods (to show warnings at the end of the output so the are more visible to the user). If we decided to go that route I would be tempted to move that logic here.

I think that an app like AppCode does not like ANSI, ever?

Why? If you don't know hot to interpret them they just look like any other stream of characters... no?

from claide.

alloy avatar alloy commented on May 26, 2024

Why? If you don't know hot to interpret them they just look like any other stream of characters... no?

Yeah I have actually no clue, so never mind that :D

Iโ€™m on the fence about all of this. @kylef is right from a purist point of view of course.

from claide.

fabiopelosin avatar fabiopelosin commented on May 26, 2024

I'm generally on the purist side on this things, but is really too and edge case for me.

from claide.

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.