Mastodon: Oops! An unexpected error occured

Created on 12 Apr 2017  Â·  10Comments  Â·  Source: tootsuite/mastodon

I just pulled the latest master and now receive 'Oops! An unexpected error occured' along with the following in dev console:

application-1acd0924ba5d49503aeade9df4f4907ba50096417e3d33b85ab707576eca4b61.js:39 TypeError: _httpLinkHeader2.default.parseParams is not a function
    at Function._httpLinkHeader2.default.parseAttrs (application-1acd0924ba5d49503aeade9df4f4907ba50096417e3d33b85ab707576eca4b61.js:38)
    at Link.parse (application-1acd0924ba5d49503aeade9df4f4907ba50096417e3d33b85ab707576eca4b61.js:352)
    at Function.Link.parse (application-1acd0924ba5d49503aeade9df4f4907ba50096417e3d33b85ab707576eca4b61.js:352)
    at exports.getLinks (application-1acd0924ba5d49503aeade9df4f4907ba50096417e3d33b85ab707576eca4b61.js:30)
    at application-1acd0924ba5d49503aeade9df4f4907ba50096417e3d33b85ab707576eca4b61.js:29
    at <anonymous>

I've done db:migrate/precompile:assets to no avail. Even rolling back to previous commits isn't fixing this. Any ideas?


  • [x] I searched or browsed the repo’s other issues to ensure this is not a duplicate.

Most helpful comment

Reproducing this here on my mastodon.dev Vagrant instance too. I can see that [email protected] is in node_modules with the function present and correct. I've also confirmed it's present in the VM's filesystem. But I'm still getting that parseParams is not a function error. When I look in the built .js file my instance is serving, sure enough, the function is missing and it's still the old version.

Things I've done:

  • yarn install
  • yarn upgrade
  • rake assets:clean
  • rake assets:precompile

It seems to be some kind of confusing cache invalidation thing. Even just adding a single blank line to app/assets/javascripts/components/link_header.jsx is enough to get it to serve a fresh build with the new version.

All 10 comments

You need to update http-link-header, _yarn install_ should do the trick.

Yep, sorry forgot to mention that I have already done 'yarn install' - modules updated but problem still occurs.

I've noticed that upon restarting the streaming service - the feed in the timelines works when reloading the service but just once - any refreshes of the page and back to the unexpected error occurs messages..

Same problem with my instance :)

Rolling back to 64dbde0 has temporarily fixed my instance. I'm not sure if this is the last working commit or not but the problem has obviously been introduced since then.

Seems to be a problem with the ~/live/public/assets/application-XXX.js
I get the mastodon.social and it works back with the command :
wget https://assets.mastodon.social/assets/application-7a52ba7d11954ab13a3523a568b7aa54c697e6be5283702337f7ae68b20be69f.js
It is soooooooooo ugly :(, Sorry

I'm still experiencing this issue after using the latest commit (96715d9af5a95d75b244efc67c6870325c2b322d) but I've also noticed that this has been happening for the past day or two when I've tried to upgrade as well. I've also done yarn install.

TypeError: _httpLinkHeader2.default.parseParams is not a function
    at Function._httpLinkHeader2.default.parseAttrs (application-5764060….js:38)
    at Link.parse (application-5764060….js:352)
    at Function.Link.parse (application-5764060….js:352)
    at exports.getLinks (application-5764060….js:30)
    at application-5764060….js:29

Reproducing this here on my mastodon.dev Vagrant instance too. I can see that [email protected] is in node_modules with the function present and correct. I've also confirmed it's present in the VM's filesystem. But I'm still getting that parseParams is not a function error. When I look in the built .js file my instance is serving, sure enough, the function is missing and it's still the old version.

Things I've done:

  • yarn install
  • yarn upgrade
  • rake assets:clean
  • rake assets:precompile

It seems to be some kind of confusing cache invalidation thing. Even just adding a single blank line to app/assets/javascripts/components/link_header.jsx is enough to get it to serve a fresh build with the new version.

Work Fine! Thank you kind man

same error even after doing yarn upgrade

mastodon@inxovh-soc001:~/live$ yarn upgrade
yarn upgrade v0.21.3
[1/4] Resolving packages...
warning @kadira/storybook > babel-preset-react-app > [email protected]: ? preset-latest accomplishes the same task as babel-preset-env. ? Please install it with 'npm install babel-preset-env --save-dev'. '{ "presets": ["latest"] }' to '{ "presets": ["env"] }'. For more info, please check the docs: http://babeljs.io/docs/plugins/preset-env ?. And let us know how you're liking Babel at @babeljs on ?
[2/4] Fetching packages...
?????????????????????????????????????????

is that normal ?

Was this page helpful?
0 / 5 - 0 ratings

Related issues

0gust1 picture 0gust1  Â·  59Comments

miguelpeixe picture miguelpeixe  Â·  61Comments

ashfurrow picture ashfurrow  Â·  73Comments

BrianPansky picture BrianPansky  Â·  69Comments

ghost picture ghost  Â·  54Comments