Comments (14)
This is odd. Maybe there was a bug in 0.1.2 that has since been fixed? Testing against 0.1.12, this passes:
adelevie@Alans-MacBook-Air:parse-ruby-client → master ruby -Itest test/test_query.rb
Loaded suite test/test_query
Started
.........
Finished in 1.178536 seconds.
9 tests, 16 assertions, 0 failures, 0 errors, 0 pendings, 0 omissions, 0 notifications
100% passed
Also, these tests pass fine on Travis.
Are you seeing this problem in one of your own applications? Feel free to email me and show me the problem there if that's easier. I really would like to get to the bottom of this. Thanks for reporting this.
from parse-ruby-client.
Sorry, I didn't mean 0.1.2 I meant 0.1.12
Yes, this is one of my own apps but I was able to reproduce it using the above modified unit-test.
In my app/script, the queries are ignored and 100 objects are returned every time. This seems to be the default Parse result-count limit. Setting limit on the query doesn't do anything either.
from parse-ruby-client.
If you clone the repo and run rake, do the tests pass? I'm having trouble reproducing this.
Sent from my iPhone
On Feb 4, 2013, at 3:00 PM, Brian Hammond [email protected] wrote:
Sorry, I didn't mean 0.1.2 I mean 0.1.12
Yes, this is one of my own apps but I was able to reproduce it using the above modified unit-test.
In my app/script, the queries are ignored and 100 objects are returned every time. This seems to be the default Parse result-count limit. Setting limit on the query doesn't do anything either.
—
Reply to this email directly or view it on GitHub.
from parse-ruby-client.
Here's the output when I run rake
from a clone of this repo:
parse-ruby-client(master) $ rake
WARNING: 'require 'rake/rdoctask'' is deprecated. Please use 'require 'rdoc/task' (in RDoc 2.4.2+)' instead.
at /usr/local/rubygems/gems/rake-0.9.2.2/lib/rake/rdoctask.rb
/System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/bin/ruby -I"lib:lib:test" -I"/usr/local/rubygems/gems/rake-0.9.2.2/lib" "/usr/local/rubygems/gems/rake-0.9.2.2/lib/rake/rake_test_loader.rb" "test/**/test_*.rb"
./test/../lib/parse-ruby-client.rb:11:in `require': no such file to load -- json (LoadError)
from ./test/../lib/parse-ruby-client.rb:11
from ./test/helper.rb:24:in `require'
from ./test/helper.rb:24
from /Users/bhammond/OpenSource/parse-ruby-client/test/test_batch.rb:1:in `require'
from /Users/bhammond/OpenSource/parse-ruby-client/test/test_batch.rb:1
from /usr/local/rubygems/gems/rake-0.9.2.2/lib/rake/rake_test_loader.rb:10:in `require'
from /usr/local/rubygems/gems/rake-0.9.2.2/lib/rake/rake_test_loader.rb:10
from /usr/local/rubygems/gems/rake-0.9.2.2/lib/rake/rake_test_loader.rb:9:in `each'
from /usr/local/rubygems/gems/rake-0.9.2.2/lib/rake/rake_test_loader.rb:9
from /usr/local/rubygems/gems/rake-0.9.2.2/lib/rake/rake_test_loader.rb:4:in `select'
from /usr/local/rubygems/gems/rake-0.9.2.2/lib/rake/rake_test_loader.rb:4
rake aborted!
Command failed with status (1): [/System/Library/Frameworks/Ruby.framework/...]
Tasks: TOP => default => test
(See full trace by running task with --trace)
from parse-ruby-client.
Of course I tried to install the json gem prior to this but for some reason when I use parse-ruby-client I had to first require 'json' then require 'parse-ruby-client' which your code does not seem (nor need) to do.
parse-ruby-client(master) $ gem install json
Building native extensions. This could take a while...
Successfully installed json-1.7.6
1 gem installed
Installing ri documentation for json-1.7.6...
Installing RDoc documentation for json-1.7.6...
from parse-ruby-client.
OK so that's not true actually looking at parse-ruby-client.rb. So, I'm not sure what's up there.
from parse-ruby-client.
Maybe it's a Ruby version issue? On Travis, I'm only testing against 1.9.2 and 1.9.3. This is largely for my sanity, but if upgrading Ruby for you is a no-go, let's keep this issue open and try to figure out what's going on.
from parse-ruby-client.
Bah... I installed Ruby 1.9.3 from Homebrew. Now I get this:
[BUG] cross-thread violation on rb_gc()
(null)
rake aborted!
SIGIOT
from parse-ruby-client.
That is...gross. I wish I could guide you on this one, but I'm probably
more clueless than you for this.
On Mon, Feb 4, 2013 at 4:01 PM, Brian Hammond [email protected]:
Bah... I installed Ruby 1.9.3 from Homebrew. Now I get this:
[BUG] cross-thread violation on rb_gc()
(null)rake aborted!
SIGIOT—
Reply to this email directly or view it on GitHubhttps://github.com//issues/64#issuecomment-13099173.
from parse-ruby-client.
Alright no worries. So my target host platform is Heroku not OS X so I will try this again on a Linux VM soon.
Thanks.
from parse-ruby-client.
Cool, let me know how that goes. For what it's worth, I run OS X for
developing parse-ruby-client using ruby 1.9.3.
On Mon, Feb 4, 2013 at 4:11 PM, Brian Hammond [email protected]:
Alright no worries. So my target host platform is Heroku not OS X so I
will try this again on a Linux VM soon.Thanks.
—
Reply to this email directly or view it on GitHubhttps://github.com//issues/64#issuecomment-13099656.
from parse-ruby-client.
OK I installed Ruby 1.9.3 via RVM.
Problem is still happening:
TourneyRunner(master) $ ruby -v
ruby 1.9.3p374 (2013-01-15 revision 38858) [x86_64-darwin11.4.2]
TourneyRunner(master) $ gem -v
1.8.25
TourneyRunner(master) $ gem list
*** LOCAL GEMS ***
bigdecimal (1.1.0)
bundler (1.2.3)
io-console (0.3)
json (1.7.6, 1.5.4)
minitest (2.5.1)
parse-ruby-client (0.1.12)
patron (0.4.18, 0.4.9)
rack (1.5.0)
rack-protection (1.3.2)
rake (0.9.2.2)
rdoc (3.9.4)
sinatra (1.3.4)
tilt (1.3.3)
TourneyRunner(master) $ pbcopy < test.rb
require 'rubygems'
require 'json'
require 'parse-ruby-client'
Parse.init
foo = Parse::Object.new "Post"
foo["random"] = rand
foo.save
foo_query = Parse::Query.new("Post").eq("random", foo["random"])
print "1 == #{foo_query.get.size}\n"
bar = Parse::Object.new "Post"
bar["random"] = rand
bar.save
bar_query = Parse::Query.new("Post").eq("random", bar["random"])
print "1 == #{foo_query.get.size}\n"
query = foo_query.or(bar_query)
print "2 == #{foo_query.get.size}\n"
TourneyRunner(master) $ ruby test.rb
1 == 1
1 == 2
2 == 2
from parse-ruby-client.
I moved test.rb to a different directory thinking that perhaps something I am unaware of in the Ruby ecosystem was screwing things up. Sure enough, it worked as expected.
After some trial and error, it seems that the bug is in Patron. I was specifying an old version 0.4.9. How I had that in there I have no idea.
Anyway, thanks.
from parse-ruby-client.
That's really odd that it was an issue with the Patron version. Thanks for working through this though.
I hope you enjoy using the gem.
Sent from my iPhone
On Feb 4, 2013, at 9:36 PM, Brian Hammond [email protected] wrote:
I moved test.rb to a different directory thinking that perhaps something I am unaware of in the Ruby ecosystem was screwing things up. Sure enough, it worked as expected.
After some trial and error, it seems that the bug is in Patron. I was specifying an old version 0.4.9. How I had that in there I have no idea.
Anyway, thanks.
—
Reply to this email directly or view it on GitHub.
from parse-ruby-client.
Related Issues (20)
- Why does this require bundler to run? HOT 2
- How to initialize Parse key HOT 3
- Parse Retirement HOT 10
- Can't use github master version HOT 5
- "both URI are relative" when configuring after self-hosted Parse server HOT 4
- unable to create client from console HOT 1
- Google OAuth Configuration
- client key shouldn't be required HOT 3
- Query can end up doing a POST! HOT 10
- Remove support for Ruby 1.9 and 2.0 HOT 4
- Running with local parse server HOT 2
- client.query - error client is undefined method in the contoller HOT 7
- back4app URL HOT 6
- Switch off parse.com HOT 3
- Switch tests to a hosted Parse server
- Multiple Coveralls comments
- Future of this project HOT 2
- Does Parse::Cloud::Function.new Still Work? HOT 2
- user = User.authenticate stopped working HOT 5
- NoMethodError occuered during retry request. HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from parse-ruby-client.