(Title: Standup 11/31/2000: Something Interesting from the post)
Ask for Help
“I have a paid for iPhone app in the app store and I want to deprecate the paid for feature and release the next version as a free app with ads. How can I continue give the users who have paid an add free version while keeping all new/future downloads free-with-ads?”
So far the only idea has been to release a second app that is free, but that has the problem of loosing all positive press/feedback for the existing app. And would seem to double the effort to provide upgrades for all users.
“We are getting ‘Connection reset by peer’ errors using Rescue to kick off some background jobs. It seems to be happening even for jobs that run only locally on the machine. They seem to happen randomly for various bg jobs. Has anyone else experienced this or have ideas on what is causing it?”
The connection reset by peer error is most often thrown by TCP/IP connections being closed by someone other than the client. Either the remote service close the connection or the network failed to keep the connection open. No one seems to have ideas on why/how it would be happening for local BG jobs.
“Devise + Selenium == ‘you are being redirected’. When trying to selenium test log in, rather than redirecting correctly post login as it really does, the selenium test fails with a page stating ‘you are being redirected’. Why is it not doing the actual redirect?”
There is a config somewhat deep in SeleniumRC config that tells selenium whether or not to follow redirects, it may be that it is set wrong. (the default should be to follow them and if you have not messed with it, not sure if this is your problem)
“We would like to be able to run our full and long-running test suite in the background while still having the ‘test’ environment free for doing BDD/focused testing. There are many potential solutions for this but what is the easiest/best to implement?”
- Create a VM image that has your dev/test environment setup on it, push the changes to it and run you full suite in the through a terminal window. This has the drawback of a fair amount of time/effort setting up the vm correctly but that is a one-time-cost. You also need to do some interesting things with your hosts file and ssh keys to make access between your main system and the VM easier, and tends to require to commit the code somewhere in order to push it to the vm which, depending on your workflow, may be exactly what you don’t want to do.
- Create a new env & db call ‘test_suite’ and run your full suite against that environment. This solution generally requires you to clone a bunch of the default rake tasks which have the ‘test’ env hard coded in them such as db:test:prepare and related. if you look at db.rake for how often the test env is hard-coded you will see that it is non-trivial. Also once you have duplicated all those tasks you are stuck maintaining them as you upgrade rails.
- Someone mention a project called Vagrant as a variant on the VM solution. This may solve some of the main pain points with doing it that way.
- Someone else mentioned a plugin called Parallel Tests that utilizes the multiple environments approach. Maybe it can be tweaked/referenced as a solution to run all tests in an alt test environment
“I have upgraded to Selenium 2 pre-alpha 5 and seem to be unable to use ‘click’ in chrome?”
Most suggestions involved “… then don’t use click” or “… try double-click”
“We are trying out the new bluetooth only ‘magic mouse’ from apple but in this office with lots of macs it is taking for ever to connect the mouse. why?”
It seems that a lot of the machines have bluetooth enabled and have discoverability turned on at all times. It would be bets to turn bluetooth off if your not using it and if you are to turn off discoverability except when connecting a new device.
“after using ‘tail -f’ my terminal window no longer shows keyboard input. why?”
It is possible that you have a complex and buggy PS1 defined and there is some data being printed in whatever you are tailing that is messing with that PS1. Try greatly simplifying your PS1 and see if that resolves the problem then do a binary search on your old PS1 to find the offending portion.
If you are unable to find the root cause you can try one of the following. Try resetting your terminal using the unix command ‘reset’ and see if it fixes your terminal window. Try using the tailing option in Less ‘less -F [file]‘
- VCR is a great way to fake out an external dependency to run your tests against. It is an especially good/easy way to fake out external api’s