Coder Social home page Coder Social logo

locus's People

Contributors

alidavut avatar liampronan avatar offirmo avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

locus's Issues

can't use with karma

I'd love to be able to use this to stop my angular tests under karma/phantom.js

Feature Request ↑

Hello, great tool. I use it every day. However, it would be nice to do an arrow up to get back to the code you just tested to modify so we don't need to type it again!

Unable to define new variables

First off, this is amazing! I'm trying to debug an electron app, and the built in debugger sucks and crashes all the time. The pryjs package won't load at all. I installed this, and it did exactly what I expected right away.

Now, when I try to define a new variable in the console (like you can with pry), I just get undefined returns.

ʆ: var i = 0;
undefined
ʆ: i
ReferenceError: i is not defined

Usage ?

I'm not even sure of what your lib does (since doc is so short). I guessed it is a debug tool.

I try to follow the README and can't see any effect.

npm install locus

var locus = require('locus')

console.log('Hello world !');
var foo = 'bar';

eval(locus);

Would you mind enhancing the README a little ?

Documentation unclear

What does this module do? All I can tel from the readme is that this is meant to be used on a REPL, but opening a REPL with "with access to all variables" means literally nothing to me. Please clarify. The example with a screenshot didn't help..

Autocompletion Support

Hey,

I think it's possible and useful to add autocompletion to locus, I really like the idea, a true debugging assistant.

I'm a little busy with a few open-source projects and some other work, but I will definitely take a look, what do you think @alidavut?

TypeError: Generator is already running

I get this whenever I try to type anything after the REPL is shown. Not in all places of the script, but in many. I don't know why, perhaps because I'm calling it inside callback functions or some other async magic?

Here's an example:

 /home/fiatjaf/comp/wft/trelew/index.js - Line: 194 
————————————————————————————————————————————————————
186 : 
187 :     // list comments
188 :     var comments = vorpal.find('comments')
189 :     if (comments) comments.remove()
190 :     vorpal
191 :       .command('comments', "list this card's comments.")
192 :       .alias('ls comments')
193 :       .action(function (_, cb) {
ʆ: readline.js:924
            throw err;
            ^

TypeError: Generator is already running
    at next (native)
    at ReadStream.onData (readline.js:918:36)
    at emitOne (events.js:77:13)
    at ReadStream.emit (events.js:169:7)
    at readableAddChunk (_stream_readable.js:146:16)
    at ReadStream.Readable.push (_stream_readable.js:110:10)
    at TTY.onread (net.js:523:20)
    at Function.module.exports.loopWhile (/home/fiatjaf/comp/wft/trelew/node_modules/deasync/index.js:64:21)
    at CommandInstance.listener (eval at <anonymous> (/home/fiatjaf/comp/wft/trelew/index.js:195:14), <anonymous>:95:11)
    at eval (eval at <anonymous> (/home/fiatjaf/comp/wft/trelew/index.js:195:14), <anonymous>:96:4)
fiatjaf@spooner ~/c/w/trelew> 

Is it possible to use locus in node console?

Got following error when calling a function containing "eval(locus)":
Error: ENOENT: no such file or directory, open 'repl'

It would be great if it is possible to debug inside node console.

Does not work on Windows

I am using WSL, but it seems like this issue is more general for Windows. Installation works, and the first run of locus appears to work fine as well. However, after exiting, all subsequent calls to locus produce something like this

File : /home/kloughead/projects/API_demo/app.js @ line: 12

     6: const request = require('request');
     7: require('locus');
     8: 
     9: 
    10: request('https://jsonplaceholder.typicode.com/users/1', function(error, response, body) {
    11:     if (!error && response.statusCode == 200) {
 => 12:         eval(locus)
    13:         var parsedData = JSON.parse(body);
    14:         console.log(parsedData);
    15:     }

internal/fs/streams.js:59
    throw new ERR_OUT_OF_RANGE(name, '>= 0 and <= 2 ** 53 - 1', pos);
    ^

RangeError [ERR_OUT_OF_RANGE]: The value of "start" is out of range. It must be >= 0 and <= 2 ** 53 - 1. Received -25580
    at checkPosition (internal/fs/streams.js:59:11)
    at new ReadStream (internal/fs/streams.js:115:5)
    at Object.createReadStream (fs.js:1835:10)
    at onLoad (/home/kloughead/projects/API_demo/node_modules/readline-history/readline-history.js:55:25)
    at ReadStream.onend (/home/kloughead/projects/API_demo/node_modules/readline-history/readline-history.js:48:21)
    at ReadStream.emit (events.js:333:22)
    at endReadableNT (_stream_readable.js:1201:12)
    at processTicksAndRejections (internal/process/task_queues.js:84:21)
    at process.runNextTicks [as _tickCallback] (internal/process/task_queues.js:66:3)
    at Function.module.exports.loopWhile (/home/kloughead/projects/API_demo/node_modules/deasync/index.js:70:11) {
  code: 'ERR_OUT_OF_RANGE'
}

I am taking a course on Udemy and there are others having similar issues. We were told by the teaching assistant to try installing version 2.0.0, but that fails also. Installation works, all calls stop just for the interactive portion. That is, you see something like this:

     6: const request = require('request');
     7: require('locus');
     8: 
     9: 
    10: request('https://jsonplaceholder.typicode.com/users/1', function(error, response, body) {
    11:     if (!error && response.statusCode == 200) {
 => 12:         eval(locus)
    13:         var parsedData = JSON.parse(body);
    14:         console.log(parsedData);
    15:     }

$

Unable to install on Windows

Looks like this requires Python to run which Windows doesn't have by default. Might need to add that to the README as a requirement.

image

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.