Webfinger doesn't work
I can't find new users on my pod.
confirmed on diasp.eu diasp.de and diasp.org
I too have encountered this error on a pair of test machines.
I'm using the latest diaspora build from git.
searching for user2@pod2 by user1@pod1 results in the following error and stack trace:
NoMethodError in PeopleController#index
undefined method `+' for nil:NilClass
Rails.root: /home/brian/diaspora_src
lib/webfinger.rb:32:in `get'
lib/webfinger.rb:92:in `webfinger_profile_xrd'
lib/webfinger.rb:78:in `webfinger_profile'
lib/webfinger.rb:100:in `make_person_from_webfinger'
lib/webfinger.rb:52:in `create_or_update_person_from_webfinger_profile!'
lib/webfinger.rb:17:in `fetch'
app/models/jobs/fetch_webfinger.rb:10:in `perform'
lib/webfinger.rb:21:in `in_background'
app/controllers/people_controller.rb:38:in `block (2 levels) in index'
app/controllers/people_controller.rb:27:in `index'
lib/rack/chrome_frame.rb:39:in `call'
@maxwell Maybe there is a bug within https://github.com/diaspora/diaspora/commit/8e22d69d8e0ed2b4b68454367a81fea1d0f522a5 ?
are these two bugs really related? im not sure.
anyone want to take a crack
from the rails console
Webfinger.new('[email protected]').fetch
it shouldnt blow up :P
With [email protected] and an unknown user on my pod:
1.9.2p290 :006 > Webfinger.new('[email protected]').fetch
`Person Load (0.3ms) SELECT `people`.* FROM `people` WHERE `people`.`diaspora_handle` = '[email protected]' LIMIT 1
Profile Load (0.3ms) SELECT `profiles`.* FROM `profiles` WHERE `profiles`.`person_id` = 157 LIMIT 1
=> # <Person id: 157, guid: "4cec08f12c17431ff40000c5", url: "https://joindiaspora.com/", diaspora_handle: "[email protected]", serialized_public_key: "-----BEGIN RSA PUBLIC KEY-----\nMIICCgKCAgEAtZqOv8TX...", owner_id: nil, created_at: "2011-01-29 17:09:54", updated_at: "2011-01-29 17:09:54", closed_account: false>
1.9.2p290 :007 > Webfinger.new('[email protected]').fetch
Person Load (0.5ms) SELECT `people`.* FROM `people` WHERE `people`.`diaspora_handle` = '[email protected]' LIMIT 1
=> nil
1.9.2p290 :008 >
must be rescued somewhere in the code :(
Using the tagged pre-asset-pipeline.zip version i get the same error:
1.9.2p290 :002 > Webfinger.new('[email protected]').fetch
Person Load (0.2ms) SELECT `people`.* FROM `people` WHERE `people`.`diaspora_handle` = '[email protected]' LIMIT 1
=> nil
I think it's fixed with https://github.com/diaspora/diaspora/commit/2357d9b0f14bb50efd649f4114391f855b2205c5
Thx to @MrZYX
Oh really? The error I fixed there didn't throw an exception. So the manual fetch resulting in nil should be fixed but i'm unsure about the original issue.
Yep, the latest trunk checkout resolves the issue for me, thanks @MrZYX
Fixed thanks