How to unzip a unknown zip file in the google colab - google-colaboratory

I have downloaded a dataset from google colab. But it is neither a folder nor a zip file. It has no extension about it. I downloaded it using !wget https://sc.link/r7wp command. But I can't unzip or extract it anyway. Can anyone help me to extract this? See the given screenshot for more explanation
Screenshot

Let's have a look
First try to download it
$ wget https://sc.link/r7w
--2022-08-12 11:59:49-- https://sc.link/r7w
Resolving sc.link (sc.link)... 37.230.233.245
Connecting to sc.link (sc.link)|37.230.233.245|:443... connected.
HTTP request sent, awaiting response... 302 Found
Location: https://sc.link/ [following]
--2022-08-12 11:59:58-- https://sc.link/
Reusing existing connection to sc.link:443.
HTTP request sent, awaiting response... 200 OK
Length: 30986 (30K) [text/html]
Saving to: ‘r7w’
r7w 100%[=================================================>] 30.26K --.-KB/s in 0s
2022-08-12 11:59:58 (97.0 MB/s) - ‘r7w’ saved [30986/30986]
What does unzip think
$ unzip -l r7w
Archive: r7w
End-of-central-directory signature not found. Either this file is not
a zipfile, or it constitutes one disk of a multi-part archive. In the
latter case the central directory and zipfile comment will be found on
the last disk(s) of this archive.
note: r7w may be a plain executable, not an archive
unzip: cannot find zipfile directory in one of r7w or
r7w.zip, and cannot find r7w.ZIP, period.
That matches what you are seeing. Let's see if it is actually a zip file.
$ file r7w
r7w: HTML document, UTF-8 Unicode text, with very long lines
Nope - not a zip file. It's HTML
$ head r7w
<!DOCTYPE html><html lang="ru"><head><meta name="viewport" content="width=device-width, initial-scale=1"/><meta name="developers" content="Shadow Dev Team: Kirill Shekhovtsov, Nickolay Galko, Daniil Shemelin, Ivan Ganev, Anatoly Lukasevich, Vlad Vihrov, Alexander Sudarev, Grigory Bezobrazov"/><meta name="theme-color" content="#333333"/><meta name="mobile-web-app-capable" content="yes"/><meta name="apple-mobile-web-app-title" content="SberCloud - облачная платформа Группы Сбербанк"/><meta property="og:image" content="https://sc.link/sc-link-og.png"/><meta name="yandex-verification" content="0ee928565a89abce"/><meta name="facebook-domain-verification" content="q27f48up1g7ono6azi8oe82uwrrysr"/><meta name="google-site-verification" content="6Jsi0B7XAEVcTZTNbbcRG__GhyFIaI-Oej8AiqNMqAg"/><link rel="icon" type="image/png" href="/favicon.png"/><link rel="apple-touch-icon" href="https://sc.link/logo-192.png"/><link rel="shortcut icon" href="/favicon.png"/><link rel="manifest" href="/manifest.json"/><script>(function (w, d, s, l, i) {

I resolved this issue using this command.
!jar xvf r7wp
where r7wp is the file name

Related

Why I can't access the NPM modules for the aboutus.html page of my website?

The NPM modules needed for my aboutus.html page cannot be found and I get a 404 error. Everything works perfectly for index.html though.
I looked into NPM server and the parsed path seems to be wrong:
19.01.20 22:33:07 304 GET /index.html
19.01.20 22:33:07 404 GET /aboutus.html/node_modules/bootstrap/dist/css/bootstrap.min.css
This is from the Chrome inspector:
http://localhost:3000/aboutus.html/node_modules/bootstrap/dist/js/bootstrap.min.js net::ERR_ABORTED 404 (Not Found)
This is the path that I have in my code:
<link rel="stylesheet" href="node_modules/bootstrap/dist/js/bootstrap.min.js">
The aboutus.html page is located in the root of my folder so what I don't understand is why NPM is adding aboutus.html/ in front of my path. This doesn't happen for the index.html.
I already tried adding / and ../ in front of my paths but to no success.
Please bear with me since this is my first question here and I am also new to the web development field. Thanks!
Place a / in front of your paths. By default, the path is resolved relative, which in this case is after your *.html file. A / causes the path to be resolved absolutely to your server root.
On index.html, the URL is usually entered as .../, not .../index.html, which would have the same behavior.
<link rel="stylesheet" href="/node_modules/...">
I solved it. The problem was in linking the wrong way from the index.html page to the aboutus.html page.
This is the way it was linked before:
<a class="nav-link" href="./aboutus.html/">About</a>
This is what I changed the line to:
<a class="nav-link" href="aboutus.html">About</a>
I hope this will help for people who will encounter the same issue.

How to produce deployment version of a Vue.js CLI site?

I have setup a Vue.js CLI project
I ran npm run dev and it runs in my browser at port 8080
I made some changes to the site
I typed npm run build.
moved the contents of the dist folder under an Apache server
but I get the error
Failed to load resource: the server responded with a status of 404(Not
Found)
What else do I need to copy here to avoid this error, or what can't it load exactly?
Ok, I figured it out:
Because I put the files in a subdirectory, I had to go into the index.html file and search and replace /static with static.
From: <link href=/static/css/app.fd50d336198a48f4f49d999710298aad.css
To: <link href=static/css/app.fd50d336198a48f4f49d999710298aad.css

What is wrong with my solr account?

I am trying to get familiar solr to eventually complete a school project that involves indexing a .csv file. I am following the instructions on the following website: https://lucene.apache.org/solr/5_4_1/quickstart.html
and in particular, under the section Indexing CSV (Comma/Column Separated Values). I entered the commands just as specified (except im using solr version 6.3.0) and getting constant errors.
Below is what I entered into terminal:
Tylers-MacBook-Pro:6.3.0 tyler$ solr start
Archiving 1 old GC log files to /usr/local/Cellar/solr/6.3.0/server/logs/archived
Archiving 1 console log files to /usr/local/Cellar/solr/6.3.0/server/logs/archived
Rotating solr logs, keeping a max of 9 generations
Waiting up to 180 seconds to see Solr running on port 8983 [-]
Started Solr server on port 8983 (pid=20594). Happy searching!
Tylers-MacBook-Pro:6.3.0 tyler$ bin/post -c gettingstarted example/exampledocs/books.csv
java -classpath /usr/local/Cellar/solr/6.3.0/libexec/dist/solr-core-6.3.0.jar -Dauto=yes -Dc=gettingstarted -Ddata=files org.apache.solr.util.SimplePostTool example/exampledocs/books.csv
SimplePostTool version 5.0.0
Posting files to [base] url http://localhost:8983/solr/gettingstarted/update...
Entering auto mode. File endings considered are xml,json,jsonl,csv,pdf,doc,docx,ppt,pptx,xls,xlsx,odt,odp,ods,ott,otp,ots,rtf,htm,html,txt,log
POSTing file books.csv (text/csv) to [base]
SimplePostTool: WARNING: Solr returned an error #404 (Not Found) for url: http://localhost:8983/solr/gettingstarted/update
SimplePostTool: WARNING: Response: <html>
<head>
<meta http-equiv="Content-Type" content="text/html;charset=utf-8"/>
<title>Error 404 Not Found</title>
</head>
<body><h2>HTTP ERROR 404</h2>
<p>Problem accessing /solr/gettingstarted/update. Reason:
<pre> Not Found</pre></p>
</body>
</html>
SimplePostTool: WARNING: IOException while reading response: java.io.FileNotFoundException: http://localhost:8983/solr/gettingstarted/update
1 files indexed.
COMMITting Solr index changes to http://localhost:8983/solr/gettingstarted/update...
SimplePostTool: WARNING: Solr returned an error #404 (Not Found) for url: http://localhost:8983/solr/gettingstarted/update?commit=true
SimplePostTool: WARNING: Response: <html>
<head>
<meta http-equiv="Content-Type" content="text/html;charset=utf-8"/>
<title>Error 404 Not Found</title>
</head>
<body><h2>HTTP ERROR 404</h2>
<p>Problem accessing /solr/gettingstarted/update. Reason:
<pre> Not Found</pre></p>
</body>
</html>
Time spent: 0:00:00.199
Tylers-MacBook-Pro:6.3.0 tyler$
What exactly is going on? All I have done is followed exactly what I was supposed to do. Thanks for any help.
Try bin/solr start -e techproducts. And then use techproducts instead of gettingstarted. There is no gettingstarted collection anymore and the techproducts is the nearest one.
What you've done is started a server with no collections in it at all. So you could also create a collection there, but you would need the right configuration to bootstrap it. So, the first method might be a bit easier at this point.

Laravel is searching for CSS file in wrong directory when using Elixir

Why is Laravel searching for my CSS file in the wrong directory? I've seen this question posted a few times but it's never actually been answered with Elixir. I am assuming there are possibly some configurations that need to be done which aren't covered in the documentation (at least from what I can tell).
My layout.blade.php file links to the css stylesheet as follows:
<link rel="stylesheet" href="{{ elixir('css/app.css') }}">
My CSS file is loaded in the following path:
localhost/fresh/public/build/css/app-279b78681b.css
However,it is looking for the file here (it is notably missing /Fresh/public/ which I can't determine why?):
localhost/build/css/app-279b78681b.css
I am running an Apache 2.4 webserver for my laravel 5.2 project (not on homestead and not on a VM) and my gulpfile.js file has the following code:
elixir(function(mix) {
mix.sass('app.scss')
.version('/css/app.css');
});
All of that being said, if I were to change my layout.blade.php file to the following:
<link rel="stylesheet" href='css/app.css'>
It will capture my stylesheet that is located in the following directory correctly:
localhost/fresh/public/css/app.css
Sooooo, why can't it capture the css stylesheet when i use Elixir and why is it linking the wrong location?
I have the same problem too.
I used as workaround:
<link rel="stylesheet" href="{{ url(elixir('css/app.css') }}">
or
<link rel="stylesheet" href="{{ asset(elixir('css/app.css')) }}">
It's just that it outputs absolute path then in the generated file. It works but I don't like it so am also still interested how to fix it properly.

How to include a static or uploaded file in Velocity macro via #include

I am trying to optimize some mobile web pages (or number of server requests more accurately) by in-lining some CSS in the HTML downloaded with initial request.
These pages are delivered from our Vosao-based CMS, and use Apache Velocity macros.
This works fine, as expected.
<link rel="stylesheet" type="text/css" media="screen" href="/file/downloads/contact.css"
This fails
<style>
#include( "/file/downloads/contact.css" )
</style>
as Velocity cannot find the file, with this output
org.apache.velocity.exception.ResourceNotFoundException: Unable to find resource '/file/downloads/contact.css'
and this in logs
org.apache.velocity.runtime.log.CommonsLogLogChute log: ResourceManager : unable to find resource '/file/Downloads/contact.css' in any resource loader.
E 2012-06-20 13:59:19.688
org.apache.velocity.runtime.log.CommonsLogLogChute log: #include(): cannot find resource '/file/Downloads/contact.css', called at vm[line 7, column 3]
I have read the velocity documentation (about resource ROOT property) and even spent some time on the source code. I've played with the properties for that at load time....and no luck.
How can I get Velocity to do an include of either a static file in my /war dir, or getter it to include from a path?
I have successfully used like this:
<style type="text/css">
#include("my/path/to/file/file.css")
</style>
Maybe is your file path wrong?