Closed janlelis closed 8 years ago
Need help too, looksee is the best gem I ever seen, no the one. Thanks.
Still not update, I still use Ruby 2.2.3, hope can use Ruby 2.3 serious soon.
Thanks.
just mentioning, same issue on ruby-head 2.4.0dev
thank you very much for your excellent gem !
I am definitely not going to upgrade my ruby until looksee works
sorry Matz ;)
+1
I have use Ruby 2.3 servel days, But, my Project still keep 2.2.3 ...
Thanks for the report & encouragement, and sorry for the slow response.
Unfortunately it seems the changes in ruby 2.3 have made the current implementation impossible. I'll need to decide on a path forward, but it probably won't be all that quick. In the meantime I can recommend pry’s ls
command, which isn’t quite as complete or accurate as Looksee, but hopefully good enough 99% of the time.
Cool, hope can patch Ruby 2.3 as quickly as possible.
Thank you for all your hard work creating the gem!
Maybe it is possible to involve Ruby core and ask them to provide the necessary reflection capabilities directly. What exactly would be needed?
doing a little bit of digging...
anyone looked at this commit ? https://github.com/ruby/ruby/commit/8f88ff4e37a5374e49025076905c57941379336a
it seems RCLASS_M_TBL_WRAPPER just becomes RCLASS_M_TBL
this is just a partial hint so far as I keep digging, but I thought of sharing it early... in case someone else knows more already on this?
looksee's usage of RClassDeprecated clearly shows that it is using some deprecated feature of ruby. one would hope there is some documentation on what is has been deprecated by?
another related commit https://github.com/ruby/ruby/commit/084b602d9a52b62a04d17f65ba1a9b8a767d1e3e
https://github.com/ruby/ruby/commit/1f2255604087e9a7d7efcb2df61b5ca0e2daa200 this commit clearly shows how the few attributes became internal...
right now, all MRI share the same ext/mri/mri.c
but it feels like we are going to need a different one for both 2.3 and 2.4
I am testing with both 2.3.1 and ruby-head because internal.h and method.h changed between 2.3 and head
this commit 18bbd05 explains what I am seeing on this travis build https://travis-ci.org/mathieujobin/looksee/jobs/126929337
it is of interested that
rwx
had a similar issue http://osdir.com/ml/ruby-core/2015-08/msg00201.html and they have now fixed the issue for both 2.3 and 2.4 https://travis-ci.org/Hanmac/rwx/builds/122278873
forget about the above... their issue was no where like this one ...
maybe i am dreaming,,, but I think I am making progress
2.3 https://travis-ci.org/mathieujobin/looksee/jobs/126960065 2.4 https://travis-ci.org/mathieujobin/looksee/jobs/126960201
latest piece of hint....
git log -p -S rb_method_entry_t --since 2015-03-01
5e8a147480f87f19a8b96ad3fb33a25fb4bb19b9
could be a rename to rb_callable_method_entry_t
rb_method_entry_struct
c19d37375074987b36413af6bf83df7262ce227d
- me->def->flags.visi = visi;
+ METHOD_ENTRY_VISI(me) = visi;
57b817f4c550e54ff57642b50723cc7c92bdd2fe
* rb_method_entry_t::flag is move to rb_method_definition_t::flag.
i made some good progress... missing a tiny something,... anyone willing to help on this ?
please have a look
@oggy
Unfortunately it seems the changes in ruby 2.3 have made the current implementation impossible. I'll need to decide on a path forward, but it probably won't be all that quick. In the meantime I can recommend pry’s ls command, which isn’t quite as complete or accurate as Looksee, but hopefully good enough 99% of the time.
the changes were not that bad finally... most of the current code still works... I think I only have one tiny issue left...
pry
is no where close what looksee does. I tried it, and it's not a very good replacement IMO
I talked with koichi and we should have all the necessary public methods for ruby 2.4
Don't Follow ...
Anyway, I am saw hope ...
anyone good at troubleshooting this kind of C compile error dereferencing pointer to incomplete type
please try my fork on either 2.3.0 or 2.3.1
thank you
@oggy whenever you have a minute, if you could take look. I think there is only one small compile issue left. hopefully this will be easy for you...
I meant to post my last comment on PR #36
Ruby 2.3.1 still not get support?
@zw963 I could be mistaken, but I think the branch I have open in #36 is not far from completion. I just don't understand why a type present a few lines above is not being found by the compiler/linker. anyone that would like to look into this one might be solving it for good.
I have not heard back from @oggy he must be busy on other things
I send a mail to ruby-talk maillist for this issue.
@mathieujobin, I still not get the key idea about your branch, I does not understood Linux C. what you mean is 2.3.0 is worked in your branch? if i fork your branch, looksee is work for me?
after talking with @ko1, opened this issue on ruby https://bugs.ruby-lang.org/issues/12655
hopefully there won't be a need for a C extension for ruby 2.4
thanks all。 2016年8月4日 下午10:52,Mathieu Jobin notifications@github.com写道:after talking with @ko1, opened this issue on ruby https://bugs.ruby-lang.org/issues/12655
hopefully there won't be a need for a C extension for ruby 2.4
—You are receiving this because you were mentioned.Reply to this email directly, view it on GitHub, or mute the thread.
Thanks for the push all!
I've pushed some "best effort" support for ruby 2.3 to master. This means it doesn't render undef'd methods, but it should do everything else. I'll be using this over the next day or two and if things seem good I'll push it to rubygems. Until then you can install this from the repo with:
bundle
bundle exec rake gem:build
gem install looksee-3.1.1.gem
(It'll be v4.0.0 once it goes to rubygems.)
I also replied to @mathieujobin 's redmine ticket (thanks for setting that up!). The version in master shrinks the extension down to just the two functions requested there. If we can get those into core we'll be extension free from that version onwards.
looks to be working fine, even the protected visibility shows as yellow now
i don't know what feature you removed but looks alright to me
thanks a lot for taking the time to work on it
I pushed 4.0.0 earlier today, so closing this at long last. Thanks for hanging in there.
@mathieujobin the feature removed was undefined methods (using undef_method
). You sometimes see this with proxy objects that delegate almost everything to another object. They use undef_method
rather than remove_method
so it forces most of the built-in methods to hit method_missing
.
It's a little less important as more projects move to supporting only ruby version that have BasicObject
, but it would still be nice to more accurately depict the method tables.
Cool.
Thanks all !!
Will try it right now.
Hi oggy,
looksee does not work for the new 2.3: