MoonPoint Support Logo

 


Shop Amazon Warehouse Deals - Deep Discounts on Open-box and Used ProductsAmazon Warehouse Deals



Advanced Search
June
Sun Mon Tue Wed Thu Fri Sat
       
5 6 7 8 9 10
11 12 13 14 15 16 17
18 19 20 21 22 23 24
25 26 27 28 29 30  
2023
Months
Jun
Jul Aug Sep
Oct Nov Dec


Mon, May 29, 2023 9:09 pm

youtube-dl unable to extract uploader id

I installed ytdl-org / youtube-dl from Github to download videos from YouTube to a Linux system with the pip package manager, since youtube-dl is a Python script, using the command pip3 install youtube-dl. But when I tried to download a YouTube video with youtube-dl, I received an error message indicating the script was unable to extract the ID of the uploader of the video and the video was not downloaded.

$ youtube-dl https://www.youtube.com/watch?v=JmSmjDngVXM
[youtube] JmSmjDngVXM: Downloading webpage
ERROR: Unable to extract uploader id; please report this issue on https://yt-dl.org/bug . Make sure you are using the latest version; see https://yt-dl.org/update on how to update. Be sure to call youtube-dl with the --verbose flag and include its complete output.

$

I verified I had the latest version of the program, 2021.12.17.

$ youtube-dl --version 2021.12.17 $

To obtain further information on the error, I then ran the script with the --verbose option which showed me more details on the error.

$ youtube-dl --verbose https://www.youtube.com/watch?v=JmSmjDngVXM
[debug] System config: []
[debug] User config: []
[debug] Custom config: []
[debug] Command-line args: ['--verbose', 'https://www.youtube.com/watch?v=JmSmjDngVXM']
[debug] Encodings: locale UTF-8, fs utf-8, out UTF-8, pref UTF-8
[debug] youtube-dl version 2021.12.17
[debug] Python version 3.6.8 (CPython) - Linux-3.10.0-229.7.2.el7.x86_64-x86_64-with-centos-7.1.1503-Core
[debug] exe versions: none
[debug] Proxy map: {}
[youtube] JmSmjDngVXM: Downloading webpage
ERROR: Unable to extract uploader id; please report this issue on https://yt-dl.org/bug . Make sure you are using the latest version; see https://yt-dl.org/update on how to update. Be sure to call youtube-dl with the --verbose flag and include its complete output.
Traceback (most recent call last):
File "/usr/local/lib/python3.6/site-packages/youtube_dl/YoutubeDL.py", line 815, in wrapper
return func(self, *args, **kwargs)
File "/usr/local/lib/python3.6/site-packages/youtube_dl/YoutubeDL.py", line 836, in __extract_info
ie_result = ie.extract(url)
File "/usr/local/lib/python3.6/site-packages/youtube_dl/extractor/common.py", line 534, in extract
ie_result = self._real_extract(url)
File "/usr/local/lib/python3.6/site-packages/youtube_dl/extractor/youtube.py", line 1794, in _real_extract
'uploader_id': self._search_regex(r'/(?:channel|user)/([^/?&#]+)', owner_profile_url, 'uploader id') if owner_profile_url else None,
File "/usr/local/lib/python3.6/site-packages/youtube_dl/extractor/common.py", line 1012, in _search_regex
raise RegexNotFoundError('Unable to extract %s' % _name)
youtube_dl.utils.RegexNotFoundError: Unable to extract uploader id; please report this issue on https://yt-dl.org/bug . Make sure you are using the latest version; see https://yt-dl.org/update on how to update. Be sure to call youtube-dl with the --verbose flag and include its complete output.

$

The software, which is a command-line program to download videos from YouTube.com and other video sites, is maintained by ytdl-org and, on a Github webpage for the organization, I found issue #32247, ERROR: Unable to extract uploader id, which attributed the error to YouTube recently starting to add that "at sign", i.e., @, to URLs. jgmayer, who posted his comments and the solution just 3 hours before I encountered the problem posted the following solution:

The solution is to go to the file that you getting the error:
"/usr/local/Cellar/youtube-dl/2021.12.17/libexec/lib/python3.10/site-packages/youtube_dl/extractor/common.py"

Find the following line:

'uploader_id': self._search_regex(r'/(?:channel|user)/([^/?&#]+)', owner_profile_url, 'uploader id') if owner_profile_url else None,

Replace with the following:

'uploader_id': self._search_regex(r'/(?:channel/|user/|@)([^/?&#]+)', owner_profile_url, 'uploader id', default=None),

The poster indicated the relevant file is /usr/local/Cellar/youtube-dl/2021.12.17/libexec/lib/python3.10/site-packages/youtube_dl/extractor/common.py, but there is no /usr/local/Cellar directory on my system and running the script with the verbose option, showed the relevant code is on line 1,794 of /usr/local/lib/python3.6/site-packages/youtube_dl/extractor/youtube.py.

After making the suggested change, I was able to download a YouTube video with the program.

$ youtube-dl https://www.youtube.com/watch?v=JmSmjDngVXM
[youtube] JmSmjDngVXM: Downloading webpage
[download] Destination: Ancient Greek Lesson #1 _ Learn Greek Fast Online-JmSmjDngVXM.mp4
[download] 100% of 14.88MiB in 04:20
$

The updated youtube.py that can be used to replace the 2021.12.17 version in /usr/local/lib/python3.6/site-packages/youtube_dl/extractor/youtube.py.

References:

  1. ERROR: Unable to extract uploader id #32247
    By: jgmayer
    Date: May 29, 2023
    Github - ytdl-org / youtube-dl

Related Articles:

  1. Python script to download YouTube videos on Mac OS X

[/video/youtube] permanent link

Mon, May 22, 2023 10:05 pm

Relaying Denied by Sendmail

A family member reported she was no longer able to send email via a Sendmail service I have running on a CentOS Linux system. She sent me a screenshot of the message she received when attempting to send a message. I saw a "Server error: '550 5.7.1 ... Relaying denied'" message. At first, I thought that a technician from her Internet Service Provider (ISP) might have changed her Microsoft Outlook settings when he upgraded her network equipment recently, but then I remembered I was restricting email relaying on the system by IP address and realized her IP address would have changed when the technician upgraded her network equipment. So I had her visit whatismyipaddress.com and provide me with the public IPv4 IP address it showed for her. I then replaced her prior IP address in /etc/mail/access. The format for an entry to allow relaying from a particular IP address is as shown below.
# Jane Doe
192.168.71.77                           RELAY

You can include a comment to indicate who the IP address is associated with by prefixing the comment with a pound sign. The IP address should be followed by the word "RELAY" (you can put tabs in between the IP address and the word, if you like).

After changing the IP address, I rebuilt the access database with the makemap command. I then restarted Sendmail

# makemap hash /etc/mail/access </etc/mail/access
# service sendmail restart
Redirecting to /bin/systemctl restart  sendmail.service
#

I was then able to receive a test message she sent me. After updating the IP address, I may only have needed to restart Sendmail without running the makemap command first as I found the following at 19.3.2. Sendmail on a Red Hat website in reference to running the make all -C /etc/mail/ command (CentOS is derived from Red Hat Enterprise Linux):

All other generated files in /etc/mail (db files) will be regenerated if needed. The old makemap commands are still usable. The make command is automatically used whenever you start or restart the sendmail service.

[/network/email/sendmail] permanent link

Sun, Mar 19, 2023 10:11 pm

Renaming a PC and joining it to a Windows domain

If you need to rename a computer running the Windows 10 operating system and/or make it a member of a Windows domain, you can take the following steps. To see the system's current name, you can press the Windows key and the Pause/Break key on the keyboard simultaneously. Alternatively, you can type about in the "Type here to search" field at the bottom, left-hand side of the screen and then select the About your PC entry which is returned from the search. You can also type this pc in the "Type here to search" field at the bottom, left-hand side of the screen and then select the This PC app when you see it listed. For any of the three above options, you will then see an About window that lists "Device name," which is the system's current name. If you just need to rename the PC, click on Rename this PC. If you need to both rename the PC and join a Windows domain, then instead of clicking on Rename this PC, scroll downards in the About window until you see "Rename this PC (advanced)" and click on it.

[ More Info ]

[/os/windows/domain] permanent link

Mon, Oct 24, 2022 10:10 pm

Daily Backup Using Robocopy

I wanted to use Robocopy, to backup a directory on a Windows Server 2022 system to an external USB drive attached to the server every weekday. The server is at a company where employees don't usually work on files at the office on weekends and I create a weekly backup archive on weekends using a different backup method. I opted to use Robocopy since it is a free command-line utility for replicating files and directories that is provided by Microsoft with current Windows operating systems. The directory I want to backup is D:\ACCI and I want to create the backup on the external E:\ drive in the existing directory E:\ACI\Backups\ACCI. I want that backup directory to always mirror the source directory, so any files added during the day should be added to the backup directory when the Robocopy command runs and any files that are deleted from the source directory during the day should be deleted from the backup directory when the Robocopy command runs. I.e., the backup directory should mirror the source directory, so I use Robocopy's /MIR option. The source directory is a directory shared over the local area network (LAN) and it is possible that an employee may leave for the day with one or more files in the shared folder on the server still open. I don't want Robocopy to wait and try again to backup an open file since the script will be running at night at a time employees aren't likely to be still working and so any file that is locked because it is still open will likely remain open until at least the the next day when employees resume work. So I use the /W:0 option to tell Robocopy to immediately retry to backup a file if it encounters a problem (by default it will wait 30 seconds and try again) and the /R:1 option to tell Robocopy to only retry backing up a file once rather than try repeatedly (it will try 1 million times by default). I want to record all output of the Robocopy daily backups in E:\ACI\Backups\RoboCopyBackup.log so I place that output path and filename after >> which will append the daily output to that file—if you just use one greater than sign rather than two, the file will be overwritten each time the Robocopy command runs. So I have the following Robocopy command, which I placed in a file I created with Windows Notepad named Robocopy_Daily_Mirror.bat (when you are saving a batch file in notepad change "save as type" from "Text Documents (*.txt)" to "All Files"):

robocopy D:\ACCI E:\ACI\Backups\ACCI /MIR /W:0 /R:1 >> E:\ACI\Backups\RoboCopyBackup.log

[ More Info ]

[/os/windows/utilities/backup/robocopy] permanent link

Sun, Aug 28, 2022 3:45 pm

Setting the path variable for Java

I had installed Java on a Windows 10 system as part of the installation of the Eclipse integrated development environment (IDE), which did not add the directory where the java.exe and javac.exe executable files were installed. I could temporarily add the directory where Eclipse installed those files to the path environment variable—see Running java from an Eclipse installation from the command line—but I didn't want to continue to have to do that every time I wanted to compile a Java program at a command prompt or run one from a command-line interface (CLI). So I added the path to the executable files to the system-wide path environment variable so it would be permanent and apply to all accounts on the system.

[ More Info ]

[/languages/java] permanent link

Sun, Aug 28, 2022 1:47 pm

Setting JAVA_HOME for Gradle

While trying to set up Gradle, a software develpment build automation tool, on a Microsoft Windows 10 system, when I ran the gradle.bat file in the gradle bin directory, I saw the message below:

C:\Users\Jim\Downloads\gradle-7.5.1-bin\gradle-7.5.1\bin>gradle.bat

ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.

Please set the JAVA_HOME variable in your environment to match the
location of your Java installation.

C:\Users\Jim\Downloads\gradle-7.5.1-bin\gradle-7.5.1\bin>

I had installed Java with the Eclipse integrated development environment (IDE) previously and the java.exe executable was installed beneath the C:\Users\Jim\.p2\pool\plugins\org.eclipse.justj.openjdk.hotspot.jre.full.win32.x86_64_18.0.1.v20220515-1614\jre\ directory, so I created a JAVA_HOME environment variable pointing to that directory that applied to all accounts on the system. You can create a temporary JAVA_HOME environment variable for the account under which you are currently logged in from a command line interface (CLI) as noted at Running java from an Eclipse installation from the command line, but I wanted to create a permanent environment variable so I typed advanced system settings in the Windows "Type here to search" field and then clicked on View advanced system settings when I saw that listed.

[ More Info ]

[/languages/java] permanent link

Sun, Aug 14, 2022 10:01 am

Excel Proper Case

I inherited an Excel spreadsheet containing names and addresses for all the members of an organization where all the letters for the names and addresses were capitalized. I wanted to convert the names and addresses to "proper case" where only the first letters of names, streets, and cities are capitalized (in the Python programming language proper case is known as "title case"). Fortunately, Excel provides a function, propercase, to perform that function. To perform the conversion, I inserted a new column to the right of each of the columns where all uppercase letters were used. The first column in the Excel workbook contained the last names for the members. There was a header titled "Last Name" in cell A1 with the first person's last name appearing in cell A2, so in the newly inserted column, B, I put =proper(A2) in cell B2. When I hit Enter, instead of AIKIN, JR in A2, I then had Aikin, Jr in B2. I then clicked in cell B2 and dragged the mouse pointer downwards to the last row containing a member's contact information, which resulted in all the members last names being placed in column B with the proper case, i.e., uppercase letters for the first letter of the name and lowercase letters for the rest of the name. I couldn't just delete column A then, which would cause a #REF! message to appear in column B for every name, since I was using a formula that depended on a value being in column A. So, instead, I copied all of column B by clicking on the B at the top of the column to highlight all entries in the column. I then used the Ctrl-C keys to copy all of the entries. I then needed to paste the values in column B into column A, rather than pasting in the formulas. You can do so, by right-clicking on the column designator letter, i.e.the A for column A in this case, and then choosing the appropriate paste option, To paste just the values and not the formulas and formatting, you can click on the icon of a clipboard with "123" on it.

Excel Paste Options

Or you can select Paste Special and then click on the same icon that appears beneath Paste Values.

Excel Paste Special

Once you've pasted the values that are in proper case, you can delete the column, e.g., B in this case, where the formulas are used.

Note: for addresses with Post Office boxes, any instance of "PO BOX" would be replaced with "Po Box," but you can use Excel's find and replace feature to search for all instances of "Po Box" and have it replace all those occurences with "PO Box".

[/software/office/excel] permanent link

Sat, Aug 13, 2022 6:39 pm

PeaZip temporary file location when creating an archive file

I hadn't used PeaZip as a backup utility previously, but after reading about the program, I thought it would be well-suited to copy a directory containing about 37 GB of files on a Microsoft Windows Small Business Server (SBS) 2003 server to an external USB drive so that I could transfer the directory, which was shared over the network from the server, to the new 2022 server I was setting up to replace the outdated server. I downloaded the portable version, PeaZip Portable to a USB flash drive and when I started the program, I specified the external USB drive as the location for the .tar archive I wished to create, but when the PeaZip program showed it was progressing with the backup, I did not see the archive file on that external drive. After some time wondering whether PeaZip was actually creating the tar file, I wondered whether it might be creating a temporary file elsewhere, so from a command prompt, I checked the location Windows was using to store temporary files for the account I was using with echo %temp% and, when I checked that location, found a .tar.tmp file that PeaZip was using for the ongoing archive process. Unfortunately, that temporary file was in a directory on drive C that I knew did not have enough free space left to accomodate the archive file as PeaZip progressed further, so I had to delete a lot of files from that drive and mover others there so that I would not have to restart the archive process.

C:\>echo %temp%
C:\DOCUME~1\ADMINI~1.MAY\LOCALS~1\Temp

C:\>cd %temp%

C:\DOCUME~1\ADMINI~1.MAY\LOCALS~1\Temp>dir *.tar.tmp
 Volume in drive C has no label.
 Volume Serial Number is E88C-7773

 Directory of C:\DOCUME~1\ADMINI~1.MAY\LOCALS~1\Temp

08/12/2022  11:14 PM     5,569,092,608 Andy_2022-08-12.tar.tmp
               1 File(s)  5,569,092,608 bytes
               0 Dir(s)  33,934,786,560 bytes free

C:\DOCUME~1\ADMINI~1.MAY\LOCALS~1\Temp>

When PeaZip concluded the archive process, it moved the temporary file to the location I specified with the .tmp extension now removed, but now I know I need to ensure that the location specified with the Windows %temp% environment variable for a site has enough free space to accomodate the archive file before using PeaZip to create a .zip, .tar, etc. file archive.

[/software/archiving/PeaZip] permanent link

Fri, Aug 05, 2022 5:01 pm

Running java from an Eclipse installation from the command line

For an introductory Java class I am taking, I installed the Eclipse integrated development environment (IDE) on a Microsoft Windows 10 system. In addition to compiling and running Java programs through the IDE, though, I wanted to compile Java programs using the Java compiler, javac.exe, and run them using java.exe from Windows' command-line interface (CLI). The installation process for Eclipse installed the javac.exe and java.exe executables in a user directory with a long directory path to those executables. Note: you should install the Eclipse IDE from the account which you wish to use to compile and run java programs. The location wasn't added to the path environment variable, so if you try to run the programs from a command prompt, you will see the following, unless you specify the full path name where the executable files are located.

C:\Users\Jim>java
'java' is not recognized as an internal or external command,
operable program or batch file.

C:\Users\Jim>javac
'javac' is not recognized as an internal or external command,
operable program or batch file.

C:\Users\Jim>

I didn't want to have to copy and paste the full path on the command line or type it in every time I wanted to use the two executables from the command line. To avoid that problem you can add the directory path to the path environment variable through a set path= command or create another environment variable, e.g., JAVA_HOME that points to the directory where the two files are located, though both methods apply only to a particular command line instance. I.e., if you close a command prompt window where you've set one of the variables to include the location where Eclipse installed java.exe and javac.exe then open another command prompt window, you will have to set the environment variable again in the new instance. An alternative way to make a permanent path change from a command prompt interface is to use the Windows setx command, though I would not recommend it, since if your path variable already has a path that is more than 1,024 characters long, setx can truncate the path to 1,024 characters, so that you not only don't get the additional directory added to the path, but you may lose some of the path setting you had prior to issuing the command. If you want to make a permanent change, see responses to the "Overcoming the 1024 character limit with setx" posting at the superuser.com site.

[More Info ]

[/languages/java/eclipse] permanent link

Mon, Jul 11, 2022 9:08 pm

Enabling Wake on LAN (WoL) on a Dell PC with a Realtek PCIe GBE NIC

Computers that support the Wake-on-LAN (WoL or WOL) standard can be awoken from a sleep state by sending a "magic packet" to their network card from another system. For an Ethernet card, the packet is an Ethernet frame that is sent to all systems on the local area network (LAN). The packet contains 6 bytes of the hexadecimal value FF followed by 16 repetitions of the 48-bit media access control (MAC) address of the system to be awakened from a sleep state. I tried unsuccessfully on Friday to remotely "wake" a Dell PC from another PC by connecting to the other PC on the same LAN and then sending a magic packet to the sleeping computer using the Wake-on-LAN program from www.matcode.com—I no longer see a download link for the free software for Windows systems on the developer's website, but you can download it from a snapshot of the site taken by the Wayback Machine on December 19, 2007 at Wake-on-LAN where you can also find the utility MCGETMAC.EXE that will allow you to obtain the MAC address for a network interface card (NIC) on another computer, or you can download WakeMeOnLan, another free program for Windows systems created by Nir Sofer. After the user powered on her Dell computer this morning and left the office, I connected to her system remotely to verify that the system is configured to respond to a magic packet to wake it when it is sleeping.

[ More Info ]

[/network/wol] permanent link

Once You Know, You Newegg AliExpress by Alibaba.com

Shop Amazon Local - Subscribe to Deals in Your Neighborhood

Valid HTML 4.01 Transitional

Privacy Policy   Contact

Blosxom logo