Giter VIP home page Giter VIP logo

Comments (17)

cool-RR avatar cool-RR commented on May 19, 2024 1

Oh, I forgot to close this issue when i implemented this functionality. I'm closing it now.

@skjerns can you please open a separate issue for implementing this functionality on Windows? And link these two issues to each other.

if you'll be interested in working on it, then you should know two things: 1. I'll want it done with no dependencies, so if you use anything from Colorama, you'll have to copy-paste some code. And 2. If you'll be interested in implementing, I'll try to figure out what was the original reason I didn't implement on Windows.

Let me know.

from pysnooper.

LeetaoGoooo avatar LeetaoGoooo commented on May 19, 2024

Hey, i'd like to work on this one,any good advice for me?

from pysnooper.

cool-RR avatar cool-RR commented on May 19, 2024

from pysnooper.

LeetaoGoooo avatar LeetaoGoooo commented on May 19, 2024

I hava already fix this one,you can see my last commit #1, but got no idea about how to test color. would you mind giving me some help,thx~

from pysnooper.

cool-RR avatar cool-RR commented on May 19, 2024

Great, can you submit a pull request to this repo? I tried making sense of your code but couldn't separate your commits from mine on your repo.

from pysnooper.

LeetaoGoooo avatar LeetaoGoooo commented on May 19, 2024

i made the pr~~O(∩_∩)O

from pysnooper.

cool-RR avatar cool-RR commented on May 19, 2024

This PR is up for grabs again. It's a good one, I hope someone takes it.

from pysnooper.

Mark-Jung avatar Mark-Jung commented on May 19, 2024

I'll give it a shot.

from pysnooper.

AtHeartEngineer avatar AtHeartEngineer commented on May 19, 2024

What about doing this with pycolorama? @Mark-Jung lemme know if you want help, definitely looking forward to this PR.

from pysnooper.

Mark-Jung avatar Mark-Jung commented on May 19, 2024

I haven't looked into this yet, but I will asap. Have been swamped with work this week.

from pysnooper.

alexmojaki avatar alexmojaki commented on May 19, 2024

Before jumping into a PR with colorama you should be aware that there is a reluctance here to use any dependencies, see #48 and #68

from pysnooper.

cool-RR avatar cool-RR commented on May 19, 2024

@AtHeartEngineer : Alex is correct, I prefer to avoid dependencies for this project.

from pysnooper.

AtHeartEngineer avatar AtHeartEngineer commented on May 19, 2024

@AtHeartEngineer : Alex is correct, I prefer to avoid dependencies for this project.

Definitely understand that. It could be an optional dependency, if you want color. Just a thought, figured colorama did a lot of the cross-compatibility work.

from pysnooper.

alexmojaki avatar alexmojaki commented on May 19, 2024

It could be an optional dependency, if you want color

I know @cool-RR is not interested in maintaining optional dependencies either, I tried that too in #71

I tried to make this project extensible in #103 so that another project could be built on top of it with extra features through dependencies, but that's been rejected. I'd already written some code using Pygments which added syntax highlighting in the terminal.

from pysnooper.

cool-RR avatar cool-RR commented on May 19, 2024

Anyone reading this: This feature is up for grabs for anyone interested in implementing it.

from pysnooper.

alexmojaki avatar alexmojaki commented on May 19, 2024

My version of PySnooper is out and it is colorful! I'd love to hear people's thoughts about the design and use of color here.

It seems that colorama is not needed for Windows support after all, which is good because it only supports a few colors anyway. Windows 10 has had support for ANSI codes in cmd for two years now, you just have to enable it: https://stackoverflow.com/a/36760881/2482744 That's what I'm doing. I don't know what happens in other terminals, I'm not a Windows user.

So PySnooper can still accomplish this without dependencies. If you want syntax highlighting, maybe check what https://github.com/Qix-/better-exceptions is doing for ideas.

from pysnooper.

skjerns avatar skjerns commented on May 19, 2024

It would be great to have color coding under windows as well!

colorama supports windows, as I have just tested and confirmed, so implementing it in the same way would be possible :)

from pysnooper.

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.