Error while installing from script ZeroBraneStudio - zerobrane

When executing ZeroBraneStudioEduPack-1.70-linux.sh i get this error: xdg-desktop-menu: No writable system menu directory found.
It could be related to my desktop environment ? currently i'm using sway with xwayland.

According to this answer, seems to be an xdg bug. You can check if running sudo mkdir /usr/share/desktop-directories/ before running the install command fixes the issue. I'll consider adding it to the install script if it helps.

Related

WSL Stopped working with error: 0x80070003

WSL2 stopped working. When, I do a new installation of linux distro, it throws the following error on click of the launch button:
Installing, this may take a few minutes...
WslRegisterDistribution failed with error: 0x80070003
Error: 0x80070003 The system cannot find the path specified.
Press any key to continue...
the wsl --help command works fine
however wsl -l command and other wsl commands throw the following error
The system cannot find the path specified.
Check if you have any .wslconfig inside your profile in %USERPROFILE% folder and delete it! I finally got it working
FIY: https://github.com/microsoft/WSL/issues/3232#issuecomment-777023885
I was getting the same issue and it was due to my bad attempt at deleting the installed Distro. If yours is the same case, this should be pretty easy to fix, use the wsl --unregister <DISTRO_NAME> which in my case was debian so wsl --unregister debian unregistered the old path for the Debian executable and then I installed Debian again. This worked for my personal case but I thought it might help someone on the internet.

Error when installing a python module in Linux

I am encoutering two kinds of issues while trying to install a package called Boltztrap2.
1) Trying to install Boltztrap2 using 'pip3'. However, when I punch in the command, the process goes smoothly for a while and then spits out an error :
BoltzTraP2/sphere/frontend.cpp:32:20: fatal error: Python.h: No such file or directory
#include "Python.h"
^
compilation terminated.
error: command 'gcc' failed with exit status 1
I did some troubleshooting and found out that it is just a path issue - I confirmed this by typing 'locate Python.h'. However, I don't get how to manually incorporate this change since the 'pip3' command that I use downloads the program and compiles it automatically. I don't seem to have access to change any scripts, or rather I do not know how to, since I'm kind of new to all this.
PS: I do not have sudo access.
2) Trying to install Boltztrap2 by manually compiling the python setup file: This seems to work fine until the system spits out an error saying:
Error:numpy is not installed.
PS: Again, I do not have sudo access.
I would be very glad if someone could help me install this package through either method. I just want to get the software to work. Thanks in advance for any assistance.
python3 -m pip install --upgrade pip
pip3 install numpy
Check if you can upgrade pip?
If that works then you can pip install numpy.

How do I stop iTerm2 from running xcodebuild and hanging when I open a window?

Since this morning, on my iMac (macOS High Sierra Version 10.13.6) any time I open an iTerm2 window (with Oh My Zsh installed), I see this:
It seems that it's trying to run xcodebuild and it's stuck. I never get a prompt, even after waiting a long time. I've tried pressing ctrl+C to end the process, and then I see this:
I'm not purposely trying to do anything with Xcode. I just want to use the command line. I've been working for months without this problem, and it just started today. Any suggestion for how I can resolve this and use iTerm like normal?
I had the similar issue.
This resolved the problem:
# sudo xcodebuild -license accept
I got the same issue with macOS Big Sur.
Tried all Google results and nothing works. Eventually, I found it was caused by setting Node.js v8.x as default in nvm, alias default to system will resolve the issue. Although I don't know why nvm need to run xcodebuild for Node.js v8.x.
I have got the same issue after updating my MBP16 with Big Sur today
I have checked my xcode command tools path with xcode-select -p and I found that the path was related to an older version of xcode (10.1 in my case, I do not remember the path, maybe /Applications/Xcode_10.1.app/Contents/Developer/).
I have reinstall xcode command tools (sudo rm -rf /Library/Developer/CommandLineTools and xcode-select --install) and I have switched the xcode command tools path with this command sudo xcode-select -switch /Library/Developer/CommandLineTools
The issue is resolved now
Many answers but at the first start the console is still very slow (15s).
Looking around I found out that somehow nvm needs xcodebuild.
The slowdown was fixed changing the nvm default to system
nvm alias default system
Still not well clear why this is happening, I suggest to figure out trying to change the nvm configuration until you obtain the result.
The hanging I was experiencing happened only once after reboot, and consequent launches of the shell happened instantly.
I've spent hours debugging this issue. I eventually traced the hanging to homebrew's start script. My finding was that /usr/bin/git was slow at start (took 12 secs to load) for some reason and Homebrew used that binary unless another was installed. I installed a newer version of git through Homebrew using brew install git and this fixed the issue.
Investigation
I could see that the hang causes 100% CPU usage in syspolicyd and I could see a -67062 error at the end of the hang through Console.app (this error means code object is not signed at all). Unfortunately, the error log did not point me to a specific file and I had to add echos inside the brew script to isolate the exact location of the hang. It turned out to be an execution of git. Installing another version of git that would overwrite the default one fixed the problem. I used brew install git since homebrew checks its own directory first for a git binary.
I am not exactly sure how/why the code signature of /usr/bin/git is broken. It wasn't broken when I first installed Homebrew. It was somehow corrupted later on.

mix local.hex fails from SSL after updating Erlang

I was prompted to update Erlang on my machine and I did. Then when I restarted my server I was prompted to update using mix local.hex.
When i did this it gave me the following error.
mix local.hex --force didn't work either.
I eventually found out that I installed erlang originally without brew originally which is where the prompt came from. After I updated it, it caused an issue with mix local.hex.
I manually removed the folder /usr/local/lib/erlang and all erlang on my machine. I installed erlang using 'brew install erlang' and then ran 'brew link erlang'
This originally didn't work because I didn't have permission but then I ran the following to get permission.
sudo chown -R $(whoami) /usr/local/lib
After that 'brew link erlang' worked and I was able to run 'mix local.hex' like normal.

RubyODBC Cannot allocate SQLHENV

I'm trying to connect to SQL Server on Ubuntu 9.04 using Ruby. I translated and followed all the steps outlined in getting OSX talking to SQL Server from here:
http://toolmantim.com/articles/getting_rails_talking_to_sqlserver_on_osx_via_odbc
Everything is working on the FreeTDS and unixODBC end. I can see and query the database using tsql.
When I try to access the database from Ruby using IRB I get the following error:
DBI::DatabaseError : INTERN (0) [RubyODBC] Cannot allocate SQLHENV
Has anyone run into this and what can I do to solve this?
I started getting this error when I upgraded to Ubuntu 9.10 (Karmic Koala). Your tip regarding installation order of the Ubuntu packages didn't work for me.
It seems the fix was to manually compile ruby-odbc.
wget http://www.ch-werner.de/rubyodbc/ruby-odbc-0.9997.tar.gz
tar xzvf ruby-odbc-0.9997.tar.gz
cd ruby-odbc-0.9997
ruby extconf.rb --with-dlopen
make
sudo make install
System
Ubuntu 9.10 64 bit
I had to specify the odbc directory in the rubyodbc install
wget http://www.ch-werner.de/rubyodbc/ruby-odbc-0.9997.tar.gz
tar xzvf ruby-odbc-0.9997.tar.gz
cd ruby-odbc-0.9997
ruby extconf.rb --with-odbc-dir=/usr/lib/odbc --disable-dlopen
make
sudo make install
I had the same problem.
But on Centos 5.5 not Ubuntu
Tried many forums/solutions with no joy.
The error message hints at a missing reference to unixODBC.
Which was setting using LD_LIBRARY_PATH variable.
Found another way to set path, by creating
/etc/ld.so.conf.d/odbc.conf.
add unixODBC location to file ie /usr/local/lib.
Run, sudo ldconfig.
Go fig that I actually got this working after submitting my question. What I ended up doing was uninstall libdbd-odbc-ruby and libdbi-ruby and then reinstalling them by installing libdbi-ruby first and then installing libdbd-odbc-ruby. I guess when I installed them before, something must of messed up.
BTW, following the instructions to recompile Ruby-ODBC on Ubuntu 9.10 (Karmic) required installation of either the libiodbc2-dev or the unixodbc-dev package. When using libiodbc2-dev, I got segmentation faults when my Ruby program tried:
connection.select_all('select top 15 * from log_device_healths')
..but no problem when using unixodbc-dev instead.
Tim Morgan's solution didn't work for me. However I was able to get things working by installing an older version of libodbc-ruby (0.9995) from here:
http://mirrors.kernel.org/ubuntu/pool/universe/libo/libodbc-ruby/libodbc-ruby1.8_0.9995-1_i386.deb
Additional details are available from Carsten Gehling's blog:
http://gehling.dk/2010/02/the-woes-of-libodbc-ruby1-8-and-debian-ubuntu/
Be careful though -- Ubuntu's Update Manager will happily "upgrade" this version of libodbc-ruby to the broken 0.9997-2. I accidentally overwrote the older version this way only to end up back here, trying to figure out how I fixed it last time.
Well, it seems my other answer stopped working for me. This thread helped me to solve the issue in another way, and I wanted to share it here.
sudo gem uninstall ruby-odbc
sudo rm /usr/local/lib/site_ruby/1.8/x86_64-linux/odbc.so
cd /tmp
wget http://mirrors.kernel.org/ubuntu/pool/universe/libo/libodbc-ruby/libodbc-ruby1.8_0.9995-1_amd64.deb
sudo dpkg -i libodbc-ruby1.8_0.9995-1_amd64.deb
If you're not on a 64-bit platform, you'll need to download a different Debian package.
Basically, what solves the problem is installing version 0.9995 of the ruby-odbc Ubuntu package.