Pip and pywal packages

Based on Mr Abhishek’s article, I installed the latest versions of pip and pywal packages on my Ubuntu 18.04.5 desktop, but the command <wal -i path_to_filename> failed to work. Kindly advise. Terminal output is given below:

anand@anand-Inspiron-N5010:~$ inxi -Fxz
System:    Host: anand-Inspiron-N5010 Kernel: 5.4.0-48-generic x86_64
           bits: 64 gcc: 7.5.0
           Desktop: Gnome 3.28.4 (Gtk 3.22.30-1ubuntu4)
           Distro: Ubuntu 18.04.5 LTS
Machine:   Device: portable System: Dell product: Inspiron N5010 v: A11 serial: N/A
           Mobo: Dell model: 0P2H9M v: A11 serial: N/A
           BIOS: Dell v: A11 date: 01/06/2011
Battery    hidpp__0: charge: N/A condition: NA/NA Wh
           model: Logitech Wireless Keyboard status: Discharging
CPU:       Dual core Intel Core i3 M 380 (-MT-MCP-) 
           arch: Nehalem rev.5 cache: 3072 KB
           flags: (lm nx sse sse2 sse3 sse4_1 sse4_2 ssse3 vmx) bmips: 10108
           clock speeds: max: 2527 MHz 1: 1265 MHz 2: 1216 MHz 3: 1340 MHz
           4: 1137 MHz
Graphics:  Card: Intel Core Processor Integrated Graphics Controller
           bus-ID: 00:02.0
           Display Server: x11 (X.Org 1.20.8 )
           drivers: vesa (unloaded: modesetting,fbdev)
           Resolution: 1366x768@59.64hz
           OpenGL: renderer: Mesa DRI Intel HD Graphics (ILK)
           version: 2.1 Mesa 20.0.8 Direct Render: Yes
Audio:     Card Intel 5 Series/3400 Series High Def. Audio
           driver: snd_hda_intel bus-ID: 00:1b.0
           Sound: Advanced Linux Sound Architecture v: k5.4.0-48-generic
Network:   Card-1: Intel Centrino Wireless-N 1000 [Condor Peak]
           driver: iwlwifi bus-ID: 12:00.0
           IF: wlp18s0 state: up mac: <filter>
           Card-2: Realtek RTL810xE PCIE Fast Ethernet controller
           driver: r8169 port: e000 bus-ID: 13:00.0
           IF: enp19s0 state: down mac: <filter>
Drives:    HDD Total Size: 327.8GB (15.7% used)
           ID-1: /dev/sda model: WDC_WD3200BPVT size: 320.1GB
           ID-2: USB /dev/sdb model: Cruzer_Blade size: 7.8GB
Partition: ID-1: / size: 293G used: 47G (17%) fs: ext4 dev: /dev/sda1
RAID:      No RAID devices: /proc/mdstat, md_mod kernel module present
Sensors:   System Temperatures: cpu: 69.0C mobo: N/A
           Fan Speeds (in rpm): cpu: N/A
Info:      Processes: 265 Uptime: 3:01 Memory: 2830.9/3736.9MB
           Init: systemd runlevel: 5 Gcc sys: 7.5.0
           Client: Shell (bash 4.4.201) inxi: 2.3.56 
anand@anand-Inspiron-N5010:~$ wal -i -/Desktop/Wallpapers/20200325_AmazonForestDawn.jpg
usage: wal [-h] [-a "alpha"] [-b background] [--backend [backend]]
           [--theme [/path/to/file or theme_name]] [--iterative]
           [--saturate 0.0-1.0] [--preview] [--vte] [-c]
           [-i "/path/to/img.jpg"] [-l] [-n] [-o "script_name"] [-q] [-r] [-R]
           [-s] [-t] [-v] [-e]
wal: error: argument -i: expected one argument

Stab in the dark :
wal -i -/Desktop/Wallpapers/20200325_AmazonForestDawn.jpg
should maybe be :
wal -i ~/Desktop/Wallpapers/20200325_AmazonForestDawn.jpg

Note - that’s a “tilde” character “~” not a dash/hyphen - “~” is shorthand for your home folder…

1 Like

Even though the image is stored at the stated location, it is still not being retrieved, even with the dash/hyphen changed to tilde character. Terminal output:
anand@anand-Inspiron-N5010:~$ wal -i ~/Desktop/Wallpapers/20200325_AmazonForestDawn.jpg
[E] image: No valid image file found.

have you tried the absolute path instead of ~/?

wal -i /home/ananad/Desktop/Wallpapers/20200325_AmazonForestDawn.jpg

Shouldn’t make a difference, because the shell is expanding this shortcut to an absolute path, before passing it to the next process.

Check what the file really is:

file ~/Desktop/Wallpapers/20200325_AmazonForestDawn.jpg

It is a jpg image file to be used as a wall paper, in tune with the suggestions made in the subject article.
I have also used the absolute path, but the command <wal -i path_to_filename> is not working.

Can you still execute the command I have shown you?

Yes! Terminal output:
anand@anand-Inspiron-N5010:~$ wal -i ~/home/Desktop/Wallpapers/20200325_AmazonForestDawn.jpg
[E] image: No valid image file found.

I am talking about this command.

Copy this and execute it in your terminal:
file ~/Desktop/Wallpapers/20200325_AmazonForestDawn.jpg

anand@anand-Inspiron-N5010:~$ wal -i file ~/Desktop/Wallpapers/20200325_AmazonForestDawn.jpgemphasized text
usage: wal [-h] [-a “alpha”] [-b background] [–backend [backend]]
[–theme [/path/to/file or theme_name]] [–iterative]
[–saturate 0.0-1.0] [–preview] [–vte] [-c]
[-i “/path/to/img.jpg”] [-l] [-n] [-o “script_name”] [-q] [-r] [-R]
[-s] [-t] [-v] [-e]
wal: error: unrecognized arguments: /home/anand/Desktop/Wallpapers/20200325_AmazonForestDawn.jpg

Another attempt made:

anand@anand-Inspiron-N5010:~$ file ~/Desktop/Wallpapers/20200325_AmazonForestDawn.jpg
/home/anand/Desktop/Wallpapers/20200325_AmazonForestDawn.jpg: cannot open /home/anand/Desktop/Wallpapers/20200325_AmazonForestDawn.jpg' (No such file or directory) anand@anand-Inspiron-N5010:~$ file ~/Home/Desktop/Wallpapers/20200325_AmazonForestDawn.jpg /home/anand/Home/Desktop/Wallpapers/20200325_AmazonForestDawn.jpg: cannot open /home/anand/Home/Desktop/Wallpapers/20200325_AmazonForestDawn.jpg’ (No such file or directory)
Whereas, the file is located in the Wallpapers Folder placed on the Desktop.

anand@anand-Inspiron-N5010:~$ ls AmazonForestDawn.jpg
ls: cannot access ‘AmazonForestDawn.jpg’: No such file or directory
anand@anand-Inspiron-N5010:~$ file AmazonForestDawn.jpg
AmazonForestDawn.jpg: cannot open `AmazonForestDawn.jpg’ (No such file or directory)

You are providing the wrong path. Copy the exact path to the file. Don’t assume the path.
Best solution:

  1. Go to this directory, where the picture is.
  2. Open a terminal in this directory.
  3. Run
find "$(cd ..; pwd)"  -maxdepth 2 -name 20200325_AmazonForestDawn.jpg
  1. Take the output and put it into your wal command.
1 Like

No success, despite several attempts; latest terminal output:

anand@anand-Inspiron-N5010:~$ find /home/anand/Desktop/Wallpapers/
/home/anand/Desktop/Wallpapers/
/home/anand/Desktop/Wallpapers/20200328_Old Water Mill, Saas-Fee Village, Switzerland.jpg
/home/anand/Desktop/Wallpapers/20200328_Zhanglialie National Forest Park, Hunan, China.jpg
/home/anand/Desktop/Wallpapers/20200328_Lavender field, France.jpg
/home/anand/Desktop/Wallpapers/20200325_Newlands Valley, Lake District National Park, England.jpg
/home/anand/Desktop/Wallpapers/20200328_Howe Sound, British Columbia, Canada.jpg
/home/anand/Desktop/Wallpapers/20200325_Amazon Forest Dawn.jpg
/home/anand/Desktop/Wallpapers/20200325_Chacraraju Mountain Range, Peru.jpg
/home/anand/Desktop/Wallpapers/20200325_Stevens Pass Washington.jpg
/home/anand/Desktop/Wallpapers/20200328_Hawthorne Tree, English Lake District, UK.jpg
/home/anand/Desktop/Wallpapers/20200325_China Camp, SFO Bay, California.jpg
/home/anand/Desktop/Wallpapers/20200325_Dutch Barn.jpg
/home/anand/Desktop/Wallpapers/20200325_Sunset by seaside.jpg
/home/anand/Desktop/Wallpapers/20200328_Grand Canal from Rialto Bridge, Venice, Italy.jpg
/home/anand/Desktop/Wallpapers/20200325_Dawn in African Wild.jpg
/home/anand/Desktop/Wallpapers/20200325_Sugar_Loaf at Sunrise, Rio de Janeiro, Brazil.jpg
/home/anand/Desktop/Wallpapers/20200328_Ban Rak Thai, Mae Hong Son, Thailand.jpg
/home/anand/Desktop/Wallpapers/20200328_Stanley Lake, Sawtooth Mountains, Idaho, USA.jpg
/home/anand/Desktop/Wallpapers/20200328_Mount Hood, Laurence Lake, Oregon, USA.jpg
/home/anand/Desktop/Wallpapers/20200328_Schleswig Holstein, Germany.jpg
/home/anand/Desktop/Wallpapers/20200325_Sky Blue lagoon.jpg
/home/anand/Desktop/Wallpapers/20200325_Quiraing at Sartle, Isle of.jpg
anand@anand-Inspiron-N5010:~$ wal -i file ~/home/anand/Desktop/Wallpapers/20200325_Amazon Forest Dawn.jpg
usage: wal [-h] [-a “alpha”] [-b background] [–backend [backend]]
[–theme [/path/to/file or theme_name]] [–iterative]
[–saturate 0.0-1.0] [–preview] [–vte] [-c]
[-i “/path/to/img.jpg”] [-l] [-n] [-o “script_name”] [-q] [-r] [-R]
[-s] [-t] [-v] [-e]
wal: error: unrecognized arguments: /home/anand/home/anand/Desktop/Wallpapers/20200325_Amazon Forest Dawn.jpg
anand@anand-Inspiron-N5010:~$ wal -i file ~/home/anand/Desktop/Wallpapers/20200325_Amazon_ Forest_ Dawn.jpg
usage: wal [-h] [-a “alpha”] [-b background] [–backend [backend]]
[–theme [/path/to/file or theme_name]] [–iterative]
[–saturate 0.0-1.0] [–preview] [–vte] [-c]
[-i “/path/to/img.jpg”] [-l] [-n] [-o “script_name”] [-q] [-r] [-R]
[-s] [-t] [-v] [-e]
wal: error: unrecognized arguments: /home/anand/home/anand/Desktop/Wallpapers/20200325_Amazon_ Forest_ Dawn.jpg
anand@anand-Inspiron-N5010:~$ wal -i ~/home/anand/Desktop/Wallpapers/20200325_Amazon_ Forest_ Dawn.jpg
usage: wal [-h] [-a “alpha”] [-b background] [–backend [backend]]
[–theme [/path/to/file or theme_name]] [–iterative]
[–saturate 0.0-1.0] [–preview] [–vte] [-c]
[-i “/path/to/img.jpg”] [-l] [-n] [-o “script_name”] [-q] [-r] [-R]
[-s] [-t] [-v] [-e]
wal: error: unrecognized arguments: Forest_ Dawn.jpg
anand@anand-Inspiron-N5010:~$ wal -i ~/home/anand/Desktop/Wallpapers/20200325_Amazon_Forest_Dawn.jpg
[E] image: No valid image file found.
anand@anand-Inspiron-N5010:~$ wal -i ~/home/anand/Desktop/Wallpapers/20200325_Amazon Forest Dawn.jpg
usage: wal [-h] [-a “alpha”] [-b background] [–backend [backend]]
[–theme [/path/to/file or theme_name]] [–iterative]
[–saturate 0.0-1.0] [–preview] [–vte] [-c]
[-i “/path/to/img.jpg”] [-l] [-n] [-o “script_name”] [-q] [-r] [-R]
[-s] [-t] [-v] [-e]
wal: error: unrecognized arguments: Forest Dawn.jpg

That’s your solution:

wal -i '/home/anand/Desktop/Wallpapers/20200325_Amazon Forest Dawn.jpg'


Before trying anything else, you need to read this:


https://towardsdatascience.com/basics-of-bash-for-beginners-92e53a4c117a
https://www.tecmint.com/free-online-linux-learning-guide-for-beginners/

Thanks for your support! I am already currently in the process of going through TLCL 19.01.pdf Manual as advised by you.

1 Like

interesting :thinking:

2 Likes