I successfully started a Cassandra server instance. When I try to start client instance using the following command
bin/cassandra-cli
It seems to startup successfully since it displays the following prompt.
[default#unknown]
However no matter what command I type it always displays three dots:
...
Where am I going wrong here?
I guess I can answer my own question the ';' at the end was missing. The textbooks did not have it. Looks like that is needed..
Related
In my machine when i start SPARK console in command prompt , I am unable to type anything in it. When I type something , It is not visible and when I use Enter or Control + Enter on it, It shows the result which was typed. But whatever is typed is not visible.
Please suggest some remedy for this .
The spark version I am using is Spark - 1.2.0
Also It is sowing me this line while starting the spark in command prompt
Failed to created SparkJLineReader: java io. IOExceptio : No such file or directory.
Could that be a problem?
The issue seems to be related to permissions on home directory. The same issue is resolved here
I am trying to make this slack bot run : https://github.com/lmammino/norrisbot
I am not very skilled with npm and node yet, but I follow his instructions and try to run the bot with the help of the npm start command.
Here's the output I get :
F:\norrisbot>npm start
> norrisbot#1.0.5 start F:\norrisbot
> node bin/bot.js
F:\norrisbot>
No error, but nothing happens either in the console or the slack general channel...
By the way I set up my BOT_API_KEY variable correctly (with the token.js method)
By your command prompt it's clear you're running in Windows. The operations for running Node properly in Windows are different in several ways from Mac/Linux, and a LOT (most?) of developers don't address these because they're on Mac/Linux themselves. Path formats, file locations, how you expose environment variables, and all sorts of things are different in Win.
Try hand-editing bin/bot.js in your locally cloned copy of the repo. Find this line at the end of the file:
norrisbot.run();
Change it to read as follows:
console.log('Running Norris Bot');
norrisbot.run();
console.log('Ran Norris Bot');
I bet you will find that either NEITHER of these lines gets printed, or only one does.
If NEITHER line gets printed, the issue is with the npm command improperly formatting the path to the executable script for Windows users. In that case, try running it as (make sure NodeJS is in your PATH):
node bin/bot.js
If only the FIRST line gets printed, there is almost certainly a bug elsewhere in the module itself. I didn't evaluate all of its code, and I'm not on Windows myself at the moment - I just use it often enough to be aware of its differences. But either way it will get you started on finding the issue, and if it's truly a bug, you can pursue the bug report I see you've already filed in Github.
I'm trying to build web interface for GIT on Node.js.
Currently I have one problem: wrong Unicode encoding while 'git commit'. Commit message are shown in gibberish in log. And I have no clue on which step in which way I need to correct.
At this point I have:
1) UTF-8 encoded HTML page for interface;
2) Node.js child_process.spawn() to execute git commands;
3) ["-C",repo.path,"commit","-m",post.msg] as an argument list to pass to git;
When I execute the same command from git shell (Under Windows if it matters) - everything is fine.
Any suggestions?
Thanks in advance!
Update
I guess I won't have this question answered, but still add one detail:
it feels like somewhere message is converted from UTF8 to ISO 8859-1
Update2
Looks like 8859-1 - is my default CMD.exe (who proceed my commands) encoding... still have no idea on what to do with it.
The cause of problem was not about git, cmd or node.js. It was my stupid mistake.
On client I wrapped data into encodeURIComponent before send. On server unwrapped it with unescape. It took too much time to notice it.
Now, after I replaced unescape by decodeURIComponent, it works perfectly well.
When I debug my Node application, my ObjectId's are represented by Unicode gibberish like ObjectID {id: RýÕ/H} instead of the actual readable ID. Here's a screenshot. Does anyone know what's causing this?
I am using WebStorm 7.0.1 on Crunchbang Waldorf x64.
UPDATE: After checking in node-inspector, I get the same results: http://i.imgur.com/8dxOGhd.png
The only time I can see my ObjectId's properly is if I check them in Robomongo (a MongoDB GUI) or if I log them to the console from within the Node app.
Unfortunately, it's just the way WebStorm currently works. You can do a quick evaluate using object.toString() when debugging if you need it. Instead of WebStorm showing something friendly, it's showing the binary representation of the ObjectID.
I had the same problem while doing a Node.js and MongoDB exercise from this book: https://leanpub.com/nodecraftsman. The code I'm talking about is on page 83, line 12.
I was running and testing everything through the command line.
What I discovered was that one line of the code (line #12) contained console.dir(documents). I changed it to console.log(documents), and it gave me back an id I expected -- something like 54e95c6f322fd679214d3a18 rather than the gibberish of, for example, Té\o2/Öy!M:\u0015
MDN describes console.dir() as "nonstandard," so perhaps there was something odd going on. More info: https://developer.mozilla.org/en-US/docs/Web/API/Console/dir
This is a bug in WebStorm. They are tracking the issue here:
https://youtrack.jetbrains.com/issue/WEB-9945
var localFile = Components.classes["#mozilla.org/filelocal;1"].createInstance(Components.interfaces.nsILocalFile);
localFile.initWithPath("C:\Windows\system32\cmd.exe");
var process = Components.classes["#mozilla.org/processutil;1"].createInstance(Components.interfaces.nsIProcess);
process.init(localFile);
var args=null;
process.run(false, args, args.length);
I am using Firefox/3.6. The above code is not getting invoked. I wanna that is there any need to include something in my code to invoke these components. In my browser these XPComponent are available as i checked using **
XPComViewer.
Plzzz Reply ASAP.
Regards, rAHUL......
i did like this only but i am getting the following error:
Error: Permission denied for http://localhost:8080 to get property XPCComponents.classes Source File: localhost:8080/ViewerSoln Line: 60
i am trying this on Firefox 2.0 and 3.6 both. its windows environment. please suggest me something ASAP.
Thank you,
Rahul.
Set up the development environment and check the Error Console. That would give you hints as to what your problem is.
Just copy the snippet from https://developer.mozilla.org/en/Code_snippets/Running_applications#Using_nsIProcess, that will give you correct code to get the necessary services.
Two less obvious errors are that a '\' has a special meaning and needs to be escaped (as in the linked snippet) and args=null won't work because you try to get its length a line later. You want args=[].
Finally, you didn't say where you're trying to run this from.