Blank page with js error after upgrade

javascript

(Jong Eun Lee) #1

I configurated multisite.
Before upgrading, it work properly.
After upgrading via admin/upgrade page, my discourse site shows only white blank page.

Only thing I know, there is a javascript error :

TypeError: undefined is not an object (evaluating 'Discourse.PageTracker.current')

./launcher rebuild web several times. Not helpful.


(Sam Saffron) #2

Which browser, can we access the site? Which locale, what’s in /logs


(Jong Eun Lee) #3

safari and chrome show same error. ko/kr locale…

chrome

Uncaught TypeError: Cannot read property 'current' of undefined

Did you mean /var/www/discourse/log in container?
There is no error. All requests are 200 OK


(Jong Eun Lee) #4

./launch logs web result :

run-parts: executing /etc/runit/1.d/00-ensure-links
run-parts: executing /etc/runit/1.d/anacron
run-parts: executing /etc/runit/1.d/cleanup-pids
Cleaning stale PID files
run-parts: executing /etc/runit/1.d/copy-env
run-parts: executing /etc/runit/1.d/ensure-web-nginx-read
Started runsvdir, PID is 34
rsyslogd: invalid or yet-unknown config file command 'KLogPermitNonKernelFacility' - have you forgotten to load a module? [try http://www.rsyslog.com/e/3003 ]
rsyslogd: warning: ~ action is deprecated, consider using the 'stop' statement instead [try http://www.rsyslog.com/e/2307 ]
Server listening on 0.0.0.0 port 22.
Server listening on :: port 22.
rsyslogd: Could no open output pipe '/dev/xconsole': No such file or directory [try http://www.rsyslog.com/e/2039 ]
supervisor pid: 42 unicorn pid: 58
Accepted publickey for root from 172.17.42.1 port 44784 ssh2: RSA 4c:f1:b9:d1:f4:05:fa:3b:e9:d2:9c:c3:a0:c2:c8:ff
Received disconnect from 172.17.42.1: 11: disconnected by user
Accepted publickey for root from 172.17.42.1 port 46106 ssh2: RSA 4c:f1:b9:d1:f4:05:fa:3b:e9:d2:9c:c3:a0:c2:c8:ff
Received disconnect from 172.17.42.1: 11: disconnected by user
root@discourse:/var/discourse# ./launcher logs web
run-parts: executing /etc/runit/1.d/00-ensure-links
run-parts: executing /etc/runit/1.d/anacron
run-parts: executing /etc/runit/1.d/cleanup-pids
Cleaning stale PID files
run-parts: executing /etc/runit/1.d/copy-env
run-parts: executing /etc/runit/1.d/ensure-web-nginx-read
Started runsvdir, PID is 34
rsyslogd: invalid or yet-unknown config file command 'KLogPermitNonKernelFacility' - have you forgotten to load a module? [try http://www.rsyslog.com/e/3003 ]
rsyslogd: warning: ~ action is deprecated, consider using the 'stop' statement instead [try http://www.rsyslog.com/e/2307 ]
Server listening on 0.0.0.0 port 22.
Server listening on :: port 22.
rsyslogd: Could no open output pipe '/dev/xconsole': No such file or directory [try http://www.rsyslog.com/e/2039 ]
supervisor pid: 42 unicorn pid: 58
Accepted publickey for root from 172.17.42.1 port 44784 ssh2: RSA 4c:f1:b9:d1:f4:05:fa:3b:e9:d2:9c:c3:a0:c2:c8:ff
Received disconnect from 172.17.42.1: 11: disconnected by user
Accepted publickey for root from 172.17.42.1 port 46106 ssh2: RSA 4c:f1:b9:d1:f4:05:fa:3b:e9:d2:9c:c3:a0:c2:c8:ff
Received disconnect from 172.17.42.1: 11: disconnected by user

(Jong Eun Lee) #5

I modified web.yml as below

params:
  ## Which Git revision should this container use? (default: tests-passed)
  version: latest-release

And run rebuild, it work properly.
beta works also.

Pagetracker is a new feature?


(Sam Saffron) #6

Page tracker is old, is it broken for tests-passed?


(Jong Eun Lee) #7

Yes, it is broken for tests-passed.

Beta works properly also.


(Ionuț Staicu) #8

Today update broke this functinoality: Discourse.PageTracker.current(); (thisis also missing on meta.discourse as well).

I used for small things, but i was able to use jquery's ready.


(Sam Saffron) #9

Ahh this must have been some es6 work @eviltrout did, can you paste in the consumer code you have?


(Robin Ward) #10

As we are going forward with ES6 modules I am removing constants like Discouse.XYZ in favor of importing the modules instead. I’ve been trying to put a deprecation notice in place but it’s hard to remember all the constants that people are using.

This commit adds a proper backwards compatible deprecation notice for PageTracker. You’ll want to update your code to import it instead.

https://github.com/discourse/discourse/commit/b587bc580f35be992329c5b0ff1f64abd2a8f28b


How to enable Piwik analytics on Discourse
#11

Sorry I re-dump this topic but yesterday I upgrade discourse from “1.5.0.beta9” to "1.5.0.beta11" and now I’ve got the same “blank page” on my site :’(

I don’t have strange plugins on it.
Only:

  • Adsense
  • Tagging
  • Solved

At chrome’s console I have only 1 error:
Uncaught TypeError: Cannot read property 'current' of undefined pointing (?) to /assets/application-fc163a7681e31ca5970dd32b81b08fc9.js

What can I do?


(Sam Saffron) #12

Try without Adsense ?


#13

Well, I removed Adsense.
Now it works fine!

So “Adsense plugin” does not working fine with last version. Cc. @michaeld

Thanks @Sam !!!


(Michael - DiscourseHosting.com) #14

This is caused by the new Client API changes.

@eviltrout has updated the AdSense plugin now! :heart_eyes: