Skip Menu |

This queue is for tickets about the Purple CPAN distribution.

Report information
The Basics
Id: 83858
Status: open
Priority: 0/
Queue: Purple

People
Owner: CDENT [...] cpan.org
Requestors: mike [...] vasto.la
Cc:
AdminCc:

Bug Information
Severity: Important
Broken in: 1.3
Fixed in: (no value)



Subject: 2/10 client.t Subtests Failing on Install
Hi, So I'm running into a bit of a problem when I go to install the CPAN Purple module. I kind of skipped the whole 'learning Perl' thing because I decided it was a dead language, haha, but lo and behold, I really needed to make a plugin for my Pidgin IM client quickly, so I had to work my way through this. I ended up figuring out the issue (the test, rather than the actual library, had the bug) and all my logs, the patch as well as my environment information is attached. What appears to have been the problem is that on line 20, client.t instantiates a Purple::Server::REST instance. This instance possesses an instance variable named 'server' which is assigned the result of a call to the constructor Purple, which by default returns a new Purple::SQLite instance. This Purple::SQLite needs and uses a purple.db SQLite database file which it creates on instantiation. However, line 28 of client.t almost immediately thereafter deletes this file. client.t then, for the first iteration of its foreach loop, Calls methods on an instance of Purple::Client, which connects over HTTP to the Purple::Server::Rest instance, and at that point the latter attempts to utilize it's Purple::SQLite instance variable. This results in an I/O error (and thus causes the test to fail) however, because Purple::SQLite can quite understandably not function properly sans its datastore. Conversely, at the start of the SECOND and final iteration of the client.t foreach loop, the 'purple.db' SQLite DB file *does* need to be unlinked. This is because in this iteration, the $client variable is a Purple::SQLite and the database abstraction module is operated on directly rather than via an HTTP as before that utilized Purple::Server::REST and Purple::Client. Please let me know if you have any questions/issues or if there's any way I can help further. I've marked the severity as important because the bug seems to currently cause unforced install attempts to always fail, resulting in the module not being placed in Perl's library search locations, thus preventing any/all use and leading the user to think the module might not work correctly if the test results are ignored. Best, Mike
From: mike [...] vasto.la
Er. I know how to attach files. Promise!! Mike
Subject: install.log
Download install.log
application/octet-stream 3.2k

Message body not shown because it is not plain text.

Subject: patched-test-pass.log
Download patched-test-pass.log
application/octet-stream 670b

Message body not shown because it is not plain text.

Subject: version-info.log
Download version-info.log
application/octet-stream 205.1k

Message body not shown because it is not plain text.

Subject: patch
Download patch
application/octet-stream 438b

Message body not shown because it is not plain text.

Subject: client.t.fixed
Download client.t.fixed
application/octet-stream 1.6k

Message body not shown because it is not plain text.

Thanks for the detailed report and the patch. I agree with the change and applied the patch. I'll push a new version to CPAN in a few moments. Weird that it ever worked in the first place. Very curious to hear what you are doing with the module and Pidgin. It's been quite some time since anyone did much with this code (at least that I've heard) so would love to hear if you are up to interesting purple stuff.
From: mike [...] vasto.la
Thanks for merging the patch! I don't know enough about the inner workings of Perl to even begin to speculate why I was the only one with this problem. For now I'm just trying to get some already-written plugins installed (but I appear to be having sundry problems using them, even beyond this Module.. next up may be creating a bug report with Pidgin. :-p) I'll keep you updated though on what I'm able to come up with. If perhaps this hasn't been used often, mayhaps the perl plugins I found for Pidgin don't actually work with it's latest versions, in which you may find me informing you I've released versions/patches for compatibility with current Pidgin versions. :-) We shall see! (And I'll keep you posted.) Thanks again! Mike PS: Total n00b question. It appears you have, as promised, pushed the latest v1.4 to CPAN. How long should that take to propagate to CPAN mirrors so that I can test the automatic install? Alternatively, is there a URL for the master CPAN repository that I can place atop my list of 'mirrors' in CPAN (temporarily of course, because I'm sure the CPAN Police would come after me if I contributed to unnecessary traffic to their server.) PPS: Feel free to use my personal email if you feel this is getting OT.