I wanted to install a r forumla from a person's branch of homebrew-science
I follow the instructions on homebrew FAQ, but got the following errors.
brew install https://github.com/aeroevan/homebrew-science/blob/5b75b8833140d8f443d398d64825da9213b44d09/r.rb
######################################################################## 100.0%
Error: /Library/Caches/Homebrew/Formula/r.rb:6: syntax error, unexpected '<'
<!DOCTYPE html>
^
/Library/Caches/Homebrew/Formula/r.rb:7: syntax error, unexpected '<'
<html>
^
/Library/Caches/Homebrew/Formula/r.rb:9: syntax error, unexpected '<'
<meta charset='utf-8'>
^
/Library/Caches/Homebrew/Formula/r.rb:10: syntax error, unexpected '<'
<meta http-equiv="X-UA-Compatible" content="IE=edge">
^
/Library/Caches/Homebrew/Formula/r.rb:10: syntax error, unexpected tIDENTIFIER, expecting $end
<meta http-equiv="X-UA-Compatible" content="IE=edge">
^
Please report this bug:
https://github.com/Homebrew/homebrew/wiki/troubleshooting
/usr/local/Library/Homebrew/formulary.rb:47:in `require'
/usr/local/Library/Homebrew/formulary.rb:47:in `klass'
/usr/local/Library/Homebrew/formulary.rb:137:in `get_formula'
/usr/local/Library/Homebrew/formulary.rb:182:in `factory'
/usr/local/Library/Homebrew/formula.rb:433:in `factory'
/usr/local/Library/Homebrew/extend/ARGV.rb:12:in `formulae'
/usr/local/Library/Homebrew/extend/ARGV.rb:12:in `map'
/usr/local/Library/Homebrew/extend/ARGV.rb:12:in `formulae'
/usr/local/Library/Homebrew/cmd/install.rb:40:in `install'
/usr/local/Library/brew.rb:107:in `send'
/usr/local/Library/brew.rb:107
The url you've used, https://github.com/aeroevan/homebrew-science/blob/5b75b8833140d8f443d398d64825da9213b44d09/r.rb, pretty clearly points to an HTML document, not a valid Ruby script. Click that link in your browser and you'll see. Instead use the URL to the raw file:
brew install https://raw2.github.com/aeroevan/homebrew-science/5b75b8833140d8f443d398d64825da9213b44d09/r.rb
Related
I am going to start off by saying that my knowledge of XML is pretty minimal.
I promise you than until 2 or 3 days ago the following code worked perfectly:
library("rvest")
url<-"https://en.wikipedia.org/wiki/Opinion_polling_for_the_next_United_Kingdom_general_election"
H<-read_html(url)
table<-html_table(H, fill=TRUE)
Z<-table[1]; Z1<-Z[[1]]
Which then allowed me to get on and do what I wanted, extracting the first table from that web page and putting it in data frame Z1. However, this has suddenly stopped working and I keep getting the error message:
Error in if (length(p) > 1 & maxp * n != sum(unlist(nrows)) & maxp * n != :
missing value where TRUE/FALSE needed
When I look at H it seems no longer to be a list and now looks like this:
{xml_document}
<html class="client-nojs" lang="en" dir="ltr">
[1] <head>\n<meta http-equiv="Content-Type" content="text/html; charset=UTF-8 ...
[2] <body class="mediawiki ltr sitedir-ltr mw-hide-empty-elt ns-0 ns-subject ...
It is clearly failing at html_table.
I really don't know where to start with this at all.
I believe you missed a step in parsing out the table nodes before the html_table function.
library("rvest")
url<-"https://en.wikipedia.org/wiki/Opinion_polling_for_the_next_United_Kingdom_general_election"
H<-read_html(url)
tables<-html_nodes(H, "table")
Z1<-html_table(tables[1], fill = TRUE)[[1]]
I'm trying to import a database from my xamppserver (v3.2.2) to my webserver at one.com. I exported it from phpmyadmin using sql (I tried csv and got the same error) and get this message:
There seems to be an error in your SQL query. The MySQL server error output below, if there is any, may also help you in diagnosing the problem
ERROR: Unknown Punctuation String # 15
STR: ><
SQL: <!DOCTYPE HTML><html lang='sv' dir='ltr' class='firefox firefox53'><head><meta charset="utf-8" /><meta name="referrer" content="no-referrer" /><meta name="robots" content="noindex,nofollow" /><meta http-equiv="X-UA-Compatible" content="IE=Edge"><style id="cfs-style">html{display: none;
SQL query:
<!DOCTYPE HTML><html lang='sv' dir='ltr' class='firefox firefox53'><head><meta charset="utf-8" /><meta name="referrer" content="no-referrer" /><meta name="robots" content="noindex,nofollow" /><meta http-equiv="X-UA-Compatible" content="IE=Edge"><style id="cfs-style">html{display: none;
MySQL said: Documentation
#1064 - You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near '<!DOCTYPE HTML><html lang='sv' dir='ltr' class='firefox firefox53'><head><meta c' at line 1
When I open the file, line 1 is as following:
<!DOCTYPE HTML><html lang='sv' dir='ltr' class='firefox firefox53'><head><meta charset="utf-8" /><meta name="referrer" content="no-referrer" />
I'm using a MariaDB server.
Any ideas what's causing this problem?
The example code:
assert_select 'div#<CSS id for error explanation>'
assert_select 'div.<CSS class for field with error>'
This generates:
DEPRECATION WARNING: The assertion was not run because of an invalid css selector. ] 16% Time: 00:00:01, ETA: 00:00:06
unexpected '#' after '[#]' (called from block in at /home/ubuntu/workspace/sample_app/test/integration/users_signup_test.rb:25)
DEPRECATION WARNING: The assertion was not run because of an invalid css selector.
unexpected '<' after '.' (called from block in at /home/ubuntu/workspace/sample_app/test/integration/users_signup_test.rb:26)
I read somewhere that versions 4.2+ need an other way to do assert_select. Is that true? And what should be used?
[ I have to say; I am still an absolute beginner ]
substitute a your-class under <CSS class...>, and your-id under <CSS id ...>
I'm getting the following error in the Chrome console:
Uncaught SyntaxError: Unexpected token ILLEGAL
At the start of my concatenated CSS file:
#import url("http://fonts.googleapis.com/css?family=Raleway:300,400,600")
This line ends up on its own, and it's specifically this line that throws the error:
I've had a look around and it seems this error should relate to invisible characters making their way into the code. Unfortunately in my case that doesn't seem to be true. I've even deleted this portion of code and re-written it by hand to make sure - no difference.
I use Stylus (with gulp) and the resulting compile is naturally what throws the error - is this maybe an issue with gulp-stylus? I've looked at the compiled code and can't track down any invisible characters there either…
Does anything else throw this error?
The error implies you are trying to load the style sheet with <script> instead of <link rel=stylesheet>.
CSS is not JavaScript and can't be treated as such.
My Complier file is like that
cd /d %~dp0
java -jar ../../../../file/css-compiler.jar --pretty-print ^
--allowed-unrecognized-property -khtml-opacity ^
../source/abc.gss ^
> ../abc.css
pause
when i am adding following line in order to detect IE Compiler giving error
<!--[if IE]>
.vidizmo-widget .result-summary {width:0px;}
<![endif]-->
then I write following line
#if (BROWSER_IE) {
.vidizmo-widget .result-summary {width:0px;}
}#else{
.vidizmo-widget .result-summary {width:30%;}
}
it doesn't generate error but i didn't find any impact on IE.
how can i detect browser using google css compiler ?
Yes, your second approach is correct
#if (BROWSER_IE) {
.vidizmo-widget .result-summary {width:0px;}
}#else{
.vidizmo-widget .result-summary {width:30%;}
}
Then you need to compile the closure template (gss) for every browser (more precisely: for every flag) you defined:
java -jar closure-stylesheets.jar example.gss > example.css
java -jar closure-stylesheets.jar --define BROWSER_IE example.gss > example.ie.css
java -jar closure-stylesheets.jar --define BROWSER_FF2 example.gss > example.ff2.css
…
Then, you need to load the appropriate css; and this is easy:
either with JavScript
or with a server-side serving based on User-Agent