Tag: Python

Error “ModuleNotFoundError: No module named ‘manimpango’” (SOLVED)

When starting one of the programs the following error occurred: Traceback (most recent call last): File "/usr/bin/emote", line 33, in <module> sys.exit(load_entry_point('Emote==0.0.0', 'gui_scripts', 'emote')()) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/bin/emote", line 25, in importlib_load_entry_point return next(matches).load() ^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.11/importlib/metadata/__init__.py", line 202, in load module = import_module(match.group('module')) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.11/importlib/__init__.py", line 126, in import_module return _bootstrap._gcd_import(name[level:], package, level) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "<frozen importlib._bootstrap>", line 1206,...

How to get data from a web page using GET and POST methods in a Python script on Windows

Python programs and scripts can make requests to and receive data from websites and web services using the GET and POST methods (as well as other HTTP methods: PUT, PATCH and DELETE). But what if you want to pass data from a web page to a Python script? This can be done in several ways. How to get data from...

How to get data from a web page using GET and POST methods in a Python script

Python programs and scripts can make requests to and receive data from websites and web services using the GET and POST methods (as well as other HTTP methods: PUT, PATCH and DELETE). But what if you want to pass data from a web page to a Python script? This can be done in several ways. How to get data from...

How to install Python as a CGI module in Apache on Linux

Table of contents 1. How to run a Python script on a web server 2. How to set up Python as a CGI module in Apache on Debian (Ubuntu, Linux Mint, Kali Linux) 2.1 Setting up Python CGI for a single directory 2.2 Setting up Python CGI for the entire web server 3. How to set up Python as a...

How to set up Python as a CGI module in Apache on Arch Linux (Manjaro, BlackArch)

Setting up Python CGI for a single directory Create a directory /srv/http/cgi-bin/ - this is where the Python scripts will be located: sudo mkdir /srv/http/cgi-bin/ Open the /etc/httpd/conf/httpd.conf file – the web server configuration file: sudo gedit /etc/httpd/conf/httpd.conf Find a group of lines: <Directory "/srv/http/cgi-bin"> AllowOverride None Options None Require all granted </Directory> And replace it with: <Directory "/srv/http/cgi-bin"> AllowOverride...

How to set up Python as a CGI module in Apache on Debian (Ubuntu, Linux Mint)

Setting up Python CGI for a single directory Run the command to enable the CGI module: sudo a2enmod cgi Restart the web server for the changes to take effect: sudo systemctl restart apache2 Create file /usr/lib/cgi-bin/test.py: sudo gedit /usr/lib/cgi-bin/test.py Copy the following content to this file: #!/usr/bin/python3 print ("Content-type: text/html") print ("") print ("") print ("<html><head>") print ("") print ("</head><body>")...

How to convert a string to lowercase in Bash

This note will show you how to convert a string to lowercase (small letters) on the Linux command line. To convert a string to lower case regardless of its current case, use one of the following commands. tr echo "Hi all" | tr '[:upper:]' '[:lower:]' hi all Attention! If you want to change the case of any letters other than...

How to convert a string to uppercase in Bash

This note will show you how to convert a string to upper case (capital letters, uppercase) on the Linux command line. To convert a string to capital letters regardless of its current case, use one of the following commands. tr echo "Hi all" | tr '[:lower:]' '[:upper:]' HI ALL Attention! If you want to change the case of any letters...

How to get web page content and cookies of .onion sites in Python

A program that receives data from the Tor network must work with cookies, for example, in the case of a parser, it can be cURL, PHP script, Python script, and so on. In the article “Web site parsing in command line” there is an example of working with cookies in cURL, but how to get the content of a web...

ONVIF client with command line interface

ONVIF is an open industry forum that provides and promotes standardized interfaces for effective interoperability of IP-based physical security products. ONVIF protocol can be found on security cameras. Using ONVIF protocol, you can receive information from IP cameras and control them (set settings, rotate, etc.). This article will talk about python-onvif - an ONVIF client implemented in Python. This program...
Loading...
X