ryanb / private_pub

Handle pub/sub messaging through private channels in Rails using Faye.
MIT License
864 stars 228 forks source link

404 on faye-browser-min.js.map #85

Open andrei4002 opened 10 years ago

andrei4002 commented 10 years ago

running rails 3.1.12, per-wiki installation.

When loading the page i see that something calls for a http://localhost:9292/faye-browser-min.js.map which doesn't exist (404)

I tried calling http://localhost:9292/faye/faye-browser-min.js.map which does exist, but I'm not sure what's going on here (meaning who calls the wrong url)

resure commented 10 years ago

The same thing for Rails 4.

resure commented 10 years ago

Workaround: set server in private_pub.yml to something like this: http://localhost:9292/faye/faye (yes, double faye at the end).

workmaster2n commented 10 years ago

@resure - I've got the same problem and the workaround works for me, but you got any idea what causes this so we can fix it in the long run?

resure commented 10 years ago

@workmaster2n, I've migrated project to another pc and everything works fine there. So currently I can't reproduce the bug :(

dblommesteijn commented 10 years ago

I had the same issue with Rails4 issue indeed, and the one @andrei4002 is describing! It turned out to be an issue with environments!

faye rack runs in production, and my primary app in development (and forgot to change the config for development in private_pub.yml)

chrise86 commented 10 years ago

@dblommesteijn can you explain exactly how you fixed this please? As far as I can tell everything is setup ok for me, but I'm still getting this error

abdul-shajin commented 10 years ago

It is working for me in development and testing server..but not in production.. any permanent solution??

abdul-shajin commented 10 years ago

@resure double faye resolved loading map file issue..but when we try to post request with faye, browser showing status as pending which is not coming when I have removed double faye..

dblommesteijn commented 10 years ago

@chrise86 I'm not sure what your issue is, however my problem was triggered when faye (running in production) was trying to use the production configuration to access information from my rails app (which was running in development). I had no configuration setup for my rails-app in production, therefore faye returned the error, expecting a production setup.

ajbraus commented 10 years ago

+1

Where are we with fixing this, should just be a path issue no? add "/faye" to the path route?

joeystdio commented 10 years ago

This problem can be fixed by loading the correct faye js path.

If, like me, you followed ryanb's tutorial you are loading the JS like this: http://localhost:9292/faye.js

You should use this path instead: http://localhost:9292/faye/faye.js

Then the second script that is loaded through this script will load at its correct path.

kocasp commented 8 years ago

+1 The solution by @resure with adding /faye/faye worked for me also. After hours of struggle.

fera2k commented 8 years ago

The quick patch would be putting this faye-browser-min.js.map file on to folder /vendor/assets/javascripts

You can download the zip which contains this file here: http://faye.jcoglan.com/assets/faye.1-1-1.zip

Hermanverschooten commented 8 years ago

@fera2k Tx