Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow loading more code into the trace_info box #370

Open
zedtux opened this issue Apr 25, 2017 · 5 comments
Open

Allow loading more code into the trace_info box #370

zedtux opened this issue Apr 25, 2017 · 5 comments

Comments

@zedtux
Copy link

zedtux commented Apr 25, 2017

The trace_info box is nice but miss a way to load some more code.

The ideal world would be that the trace_info shows the current method definitions, the hidden code replaced with suspension points, then the current code as it is now, the rest of the method code hidden with suspension points and then end of the current method.

The suspension points could be replaced by an expand icon, be clickable so that the reste of the code is loaded. This is the way github do in diff

screen shot 2017-04-25 at 10 44 30

@zedtux
Copy link
Author

zedtux commented Nov 14, 2017

Any news on this issue?

@RobinDaugherty
Copy link
Member

It sounds like an interesting improvement. If you want to open a pull request for it, please go ahead.

On the other hand, since Better Errors includes link to your editor for the specific file and line, this may not be worth the effort. Since the tool is designed to be used only locally in development, I'm not sure of a scenario where the expanding code sections would be much more useful than the editor link.

@RobinDaugherty
Copy link
Member

This may also reinforce the suggestion to improve the visibility of the editor link (#383).

@zedtux
Copy link
Author

zedtux commented Nov 15, 2017

On the other hand, since Better Errors includes link to your editor for the specific file and line, this may not be worth the effort. Since the tool is designed to be used only locally in development, I'm not sure of a scenario where the expanding code sections would be much more useful than the editor link.

Well when you have an error, and better errors shows up, you start to debug and look around, I don't see how it is practical to switch between better errors and your IDE ... Otherwise Github would have the same idea and wouldn't have implemented the feature to see more code.

Regarding the link to the IDE, I need to check but as far as I remember I never got it working with Atom (and I never spent a lot of time).
It's always best to have working solution out-of-the-box :)
And I truly believe that my feature request will improves the way developers work with better errors (the IDE redirection link will be useful when the dev is done with debugging and wants to fix it.)

@zedtux
Copy link
Author

zedtux commented Nov 16, 2017

@RobinDaugherty the Pull Request is now ready, tests and coverage should pass, and I put some screenshots in the PR.

Please feel free to review my code and post your comments and merge it :)

zedtux added a commit to zedtux/better_errors that referenced this issue Nov 24, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants