GithubHelp home page GithubHelp logo

Rewrap started failing? about rewrap HOT 9 CLOSED

peterbourgon avatar peterbourgon commented on August 24, 2024
Rewrap started failing?

from rewrap.

Comments (9)

peterbourgon avatar peterbourgon commented on August 24, 2024

I closed some tabs and opened some other tabs, and it started working again. I'll leave the issue open in case you want to debug further...

from rewrap.

stkb avatar stkb commented on August 24, 2024

Thanks for reporting. Unfortunately I can't really tell anything from that; it's all just vscode's own code. I'll leave this open for a while in case you or anyone else has the same problem and we can work on reproducing it, and I'll add some more logging code into the next version to try to diagnose any errors that occur.

from rewrap.

nicot avatar nicot commented on August 24, 2024

Hi @stkb, I think I'm running into this issue. I'm on VS Code 1.6.1 (rolled back from 1.7), macOS Sierra 10.12.1, and rewrap 0.6.2

Here's the log:

[Extension Host] TypeError: Cannot read property '0' of null
    at Object.textAfterPrefix (/Users/nico/.vscode/extensions/stkb.rewrap-0.6.2/out/src/Strings.js:28:51)
    at /Users/nico/.vscode/extensions/stkb.rewrap-0.6.2/out/src/Section.js:35:33
    at Array.map (native)
    at new Section (/Users/nico/.vscode/extensions/stkb.rewrap-0.6.2/out/src/Section.js:32:18)
    at BasicLanguage.findSections (/Users/nico/.vscode/extensions/stkb.rewrap-0.6.2/out/src/BasicLanguage.js:35:38)
    at wrapSomething (/Users/nico/.vscode/extensions/stkb.rewrap-0.6.2/out/src/Main.js:33:28)
    at /Users/nico/.vscode/extensions/stkb.rewrap-0.6.2/out/src/Main.js:15:20
    at /Applications/Visual Studio Code.app/Contents/Resources/app/out/vs/workbench/node/extensionHostProcess.js:13:23492
    at e.edit (/Applications/Visual Studio Code.app/Contents/Resources/app/out/vs/workbench/node/extensionHostProcess.js:12:16971)
    at /Applications/Visual Studio Code.app/Contents/Resources/app/out/vs/workbench/node/extensionHostProcess.js:13:23458

I can only reproduce it in one file right now, a compiled version of https://github.com/Microsoft/vscode/blob/master/src/vs/editor/contrib/goToDeclaration/common/goToDeclaration.ts.

Thanks for the great plugin.

from rewrap.

stkb avatar stkb commented on August 24, 2024

@nicot Thanks, that helps a lot, but I'm having trouble reproducing. Could you upload the exact file that it errors on (you can attach a file to a comment here), and tell me which comment in it you're trying to wrap?

from rewrap.

nicot avatar nicot commented on August 24, 2024

Here's a gist with the failing code/line: https://gist.github.com/nicot/aed1b230392ec2a3bcdc7b2ac970f653#file-gotodeclaration-js-L321. It blows up on every line I've tried in that file though.

from rewrap.

stkb avatar stkb commented on August 24, 2024

Perfect! thanks. In that file, it's the empty // on line 54 with nothing after it, that's causing the error. I'll get on to fixing it.

from rewrap.

stkb avatar stkb commented on August 24, 2024

Have just published v0.6.3 which hopefully fixes the issue (have tried on vscode 1.6.1 and 1.7.1). Could you update and confirm?

from rewrap.

nicot avatar nicot commented on August 24, 2024

Works perfectly now! Thanks a bunch for quick the fix and the great plugin.

from rewrap.

stkb avatar stkb commented on August 24, 2024

Great! Thanks for the help

from rewrap.

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.