codeboot icon indicating copy to clipboard operation
codeboot copied to clipboard

Error line number would be great! :)

Open cyberwings opened this issue 13 years ago • 13 comments

Especially as we do longer code every week, a line number with the error message would save a lot of time. This is more a suggestion than a bug. :)

cyberwings avatar Nov 25 '12 11:11 cyberwings

Le 2012-11-25 à 6:37 AM, cyberwings [email protected] a écrit :

Especially as we do longer code every week, a line number with the error message would save a lot of time. This is more a suggestion than a bug. :)

— Reply to this email directly or view it on GitHub.

I guess this could be added to the preferences. When line numbers are added to error messages, the code editors would also have the line number in the gutter. This may be hard to do when the line is in the transcript.

Marc

feeley avatar Nov 26 '12 19:11 feeley

I guess it could be an advanced feature that would be enabled from the prefs menu... On my end it's trivial. Marc, if you have time to implement this is jseval, I can add it in <1hr.

dufour avatar Nov 26 '12 21:11 dufour

Le 2012-11-26 à 4:37 PM, Bruno Dufour [email protected] a écrit :

I guess it could be an advanced feature that would be enabled from the prefs menu... On my end it's trivial. Marc, if you have time to implement this is jseval, I can add it in <1hr.

Easy enough. The information is already there.

Marc

feeley avatar Nov 27 '12 04:11 feeley

I pushed a commit that adds line numbers to file editors if enabled from the prefs menu (the console is unaffected by this setting at the moment). Marc, if you want to update the error messages, the value to check is cb.options.showLineNumbers.

dufour avatar Nov 27 '12 20:11 dufour

Le 2012-11-27 à 3:14 PM, Bruno Dufour [email protected] a écrit :

I pushed a commit that adds line numbers to file editors if enabled from the prefs menu (the console is unaffected by this setting at the moment). Marc, if you want to update the error messages, the value to check is cb.options.showLineNumbers.

I made the changes on my side. Please give it a try.

Marc

feeley avatar Nov 28 '12 17:11 feeley

Hi, sorry for the noob question, but how do I activate it?

cyberwings avatar Nov 29 '12 14:11 cyberwings

Le 2012-11-29 à 9:33 AM, cyberwings [email protected] a écrit :

Hi, sorry for the noob question, but how do I activate it?

It is not yet online. I was waiting for Bruno to give me feedback. I wouldn't want to break something in the online version that many people are using on a regular basis.

Marc

feeley avatar Nov 29 '12 14:11 feeley

Oups, embarassing. I though the "give it a try" was for me! :P

cyberwings avatar Nov 29 '12 14:11 cyberwings

Le 2012-11-29 à 9:47 AM, cyberwings [email protected] a écrit :

Oups, embarassing. I though the "give it a try" was for me! :P

Of course you could always get all the latest sources yourself from github and try them locally on your computer. You would need to do:

git clone https://github.com/feeley/codeboot.git cd codeboot open index.html (on a Mac, or on other systems open the file index.html in your browser)

Later on, you just need to "pull" to update to the latest sources, i.e.

cd codeboot git pull

Marc

feeley avatar Nov 29 '12 14:11 feeley

Seems to work as expected, but since codeBoot is aimed primarily at novices, I would have used a slightly friendlier format for the line numbers (something like "Error in at line <#>: ...").

dufour avatar Nov 29 '12 15:11 dufour

Le 2012-11-29 à 10:36 AM, Bruno Dufour [email protected] a écrit :

Seems to work as expected, but since codeBoot is aimed primarily at novices, I would have used a slightly friendlier format for the line numbers (something like "Error in at line <#>: ...").

I have changed the location information to only include the start line number and file name. Can you check?

Marc

feeley avatar Nov 29 '12 16:11 feeley

I think that's much better. I haven't encountered any issue, it's probably safe to deploy this.

dufour avatar Nov 29 '12 16:11 dufour

Le 2012-11-29 à 11:40 AM, Bruno Dufour [email protected] a écrit :

I think that's much better. I haven't encountered any issue, it's probably safe to deploy this.

OK, it is now deployed.

Marc

feeley avatar Nov 29 '12 16:11 feeley