node-gyp configure "binding.gyp not found (cwd: D:\MyProject) while trying to load binding.gyp" - ethereum

I searched many and installed all necessary packages they said,
npm install --global --production windows-build-tools
node-gyp --python /path/to/python2.7
I have vs2017 installed in my win10 pc, I am using last versions of nodes tools
node -v //8.12.0
npm -v //6.4.1
I tried remove nodejs and reinstall to start fresh install but stuck in this step each,
here my .npmrc content;
strict-ssl=false
node_gyp=node C:\Users\ASUS\AppData\Roaming\npm\node_modules\node-gyp\bin\node-gyp.js
msvs_version=2015
python=C:\Python27\python.exe
GYP_MSVS_VERSION=2015
ss of powershell, (node-gyp configure)
it looks for a file called 'binding.pyp'
If I add that file manually errormessage changes.. but other examples dont create any file they just install packges and run..
How can I fix this I searched on net many and did all advices(install ms build tools set msvs version 2017)

Related

How can I get the keyring extension working for mercurial in Ubuntu 18.04?

I've tried dozens of guides on installing mercurial and keyring extensions on Ubuntu and have never been able to get the keyring extension to work. It was a snap under Windows.
I've installed mercurial many different ways. I'm not sure if the install method has anything to do with the keyring, but here are a few of the things I've tried:
sudo apt-get install mercurial
sudo apt install mercurial
pip install mercurial
... and so on.
I even used this method where it compiles mercurial.
All of these methods work for mercurial. It runs. I can do commits, etc. It's keyring and mercurial_keyring installations that are giving me trouble. I installed both of those using pip install. When I do a command like:
hg out http://somerepo
At the moment, I'm getting the following message:
No handlers could be found for logger "keyring.backend"
I feel like there is a concise set of steps to get keyring working, but it's just eluding me. I've made half a dozen attempts on fresh virtual machines and can never get this to work. :(
pip uninstall keyring
The reason is that python has already the library python-keyring installed which conflicts with the one installed with pip. Credits to Python library woes on Ubuntu 18.04 by Kai Koenig
Edit: the story actually did not end there because what it did was to get rid of that error but was not the actual solution. I had to continue with these commands
pip install keyrings.alt
pip install keyring
(yes, I installed it back)
python -c "import keyring.util.platform_; print(keyring.util.platform_.config_root())"
That was taken from keyring docummentation. It turned out that my config folder shown by this command was not created so I did:
mkdir ~/.local/share/python_keyring
vi ~/.local/share/python_keyring/keyringrc.cfg
I had to create the .cfg file as well and put this inside (on my MacOS Mojave!):
[backend]
default-keyring=keyring.backends.OS_X.Keyring
Now everything works fine, no password asked anymore

npm install/uninstall modifies packages.json

I've recently upgraded to node8 (using nvm) and a weird things started to happen in one of the project I'm working on.
Node v8.11.1
Npm 5.6.0
I cd inside my project having a packages.json.
For dev purposes I wanted to remove some packages previously installed but I didn't want to modify my packages.json.
Whenever I run either npm uninstall package-name or npm install packages-name they both try to install all the missing packages listed in packages.json!
I am explicitly NOT passing the --save or --save-dev flag but still npm ignores that.
I think it might have to do with package-lock.json file?
Q: How to tell npm I do not want it to mess up with other packages or modify my packages.json?

Install GreenPAK Designer RPM

I am attempting to install closed source software from Silego, GreenPAK Designer, on a machine running Fedora 19. The supported installation packages on Silego's Website only target Ubuntu and Debian. I downloaded the .deb package and used Alien to convert to an RPM. So far so good, but a dry run of yum install showed dependency errors, which I solved by installing the necessary packages with yum:
qt5-qbase
qt5-qbase-gui
qt5-qtdeclarative
qt5-qtlocation
qwt
Now, yum installed the above libraries in /usr/lib/ but the GreenPAK RPM defaults to /usr/local/bin as the output dir. I figured I could run
sudo yum localinstall --nodeps --noscripts greenpak-designer-x.x.x.rpm
and get a successful install but I received conflict errors relating to dirs such as '/', '/usr', '/usr/bin' etc. I worked around this issue with:
rpmrebuild -pe --notest-install --replacefiles --noscripts greenpak-designer.x.x.x.rpm
and removing the offending lines in the script. It allowed me to install rpm but the software is broken because of dependency issues (not surprisingly). From the system log:
Jan 4 16:06:49 pelican gnome-session[1729]: /usr/local/greenpak-designer/bin/GP5: error while loading shared libraries: libicui18n.so.52: cannot open shared object file: No such file or directory
The machine has a /usr/lib/libicui18n.so.50
One thing I did not try is rebuilding my shared object cache with ldconfig, which sometimes solves problems with missing .so links when building from source but I don't see how that would apply in this instance (I'm not trying to link object files to libraries, rather simply trying to drop binaries in default install locations, no?)
Of course, I contacted the vendor and begged for an RPM. The contact was helpful but informed me the software folks are on a well deserved break. I thought I'd continue puttering with this in the meantime while I have time.
Any ideas? It seems the solution to this problem would be helpful when trying to install almost any closed source software targeting Debian on a Fedora box.

Electron cannot find module mysql

So i've been creating a desktop application using electron. The problem is that when I run my application using npm it doesn't show any error about a missing module but when i package it and run it this error shows
I'm sure that i've install mysql module using npm install -g mysql and npm install mysql in the project directory. It's all working fine when i run the unpacked version of the application
Assuming that you have installed mysql if not please install mysql npm install mysql --save-dev
Hi I also ran in same error I tried everything possible but nothing seems to work , after several hit and trial I was able to fix it and in the end realize that it was all happening because of
When I installed MySQL module I never saved it (--save-dev)
And electron-packager was not able to locate it when I pack it because was not mention in package.json
A solution might locate mysql folder in node_module folder and delete
then install it npm install mysql --save-dev
or manually
add it under dependencies in package.json file

Running gulp in dreamhost VPS

Since the last dreamhost update which banned VPS users from accessing root/administrator. I am wondering how to do i install GULP in my hosting as it looks like we need admin access to install that and which dreamhost clearly denies it to give access.
So the problem is there are several tasks i need on my server to accomplish via GULP.
Do we have any alternative/Solution to this problem? (except changing the hosting service :))
I'm fed up of not being able to implement my production code in production environment.
thanks
DreamHost VPS are managed servers, they try to strike a balance between giving more computing power and isolation to customers (as opposed to shared hosting) while taking some management burden off of customers hands. This results in a compromise where you don't have to care about the underlying OS and basic services at all, and focus on your applications... but you're limited somewhat to what you can install on the machine.
The good news is that you can manage npm packages as an unprivileged user. While I am not a node expert, I have managed to upgrade npm and install gulp and all dependencies on my local user.
I first created a new dir for my version of npm (mkdir npm) then set the npm prefix to it
$ npm config set prefix ~/npm
Then it's time to install a newer version of npm in that dir:
$ npm install -g npm
After that's done, update the $PATH variable in your .bash_profile and in the current session, too export PATH="$HOME/npm/bin:$PATH" and confirm with a which npm that the npm command bash will execute is /home/$YOUR_VPS_USER/npm/bin/npm.
Now you can install the rest:
npm install -g bower
npm install -g grunt-cli
npm install -g gulp
npm install -g yo
If you need to have more power and accept the responsibilities of running an unmanaged server, DreamHost Cloud is more for you though.