Zotero Pubget Feature - Article Locate Platform

57 views
Skip to first unread message

Cameron Allen

unread,
Oct 27, 2010, 4:58:38 PM10/27/10
to zotero-dev
Hello Dev Group,

It's been some time since this was last mentioned but the developers
here at Pubget have a beta for a feature we'd like to you to take a
look at. The feature was originally brought up in this thread:
http://groups.google.com/group/zotero-dev/browse_thread/thread/77074e86859e8674.
To summarize, it essentially expands the Locate dropdown menu on the
zotero item box, allowing the user to look up zotero items through
different services. The feature builds off of Firefox's search engine
interface and includes functionality to add third party "locate"
engines and to show or hide these engines in the locate dropdown. You
can download the patch at http://assets0.pubget.com.s3.amazonaws.com/zotero-locate-engines-patch-10.27.10.diff.

What we're looking for now is mostly feedback. We'd love to hear what
you guys think of where it's at right now and how much more it can be
improved. Any questions or comments can be directed at
cam...@pubget.com.

Best,

Cameron Allen

Avram Lyon

unread,
Oct 31, 2010, 5:54:24 PM10/31/10
to zoter...@googlegroups.com
2010/10/28 Cameron Allen <cameron...@gmail.com>

> What we're looking for now is mostly feedback.  We'd love to hear what
> you guys think of where it's at right now and how much more it can be
> improved.  Any questions or comments can be directed at
> cam...@pubget.com.

When I selected "Google" from the Locate... drop-down, I got this message:
ASSERT: *** Search: called nsISearchEngine::addParam on a read-only engine!
Stack Trace:
0:ENSURE_WARN(false,called nsISearchEngine::addParam on a read-only
engine!,2147500037)
1:SRCH_ENG_addParam(pmid,,text/html)
2:addParam(pmid,,text/html)
3:(Google,[object Object],[object Object])
4:onLocateClick([object XULCommandEvent])
5:oncommand([object XULCommandEvent])

The search proceeded normally nonetheless. As a polish issue, you
could probably get rid of the "Toggle" button in the Locate preference
pane, since it is simply replicating the checkbox column's function.

I'll keep playing with this and see what else I can offer. In general,
it seems to work, and the patch applied cleanly to my SVN checkout of
the trunk.

- Avram

Sean Takats

unread,
Oct 31, 2010, 10:24:11 PM10/31/10
to zoter...@googlegroups.com
Hi Cameron and the rest of the Pubget team,

Very exciting stuff! I'm delighted to see this code in action and have a little feedback.

I get the same error and results as Avram, running the latest Zotero trunk patched on Firefox 3.6.12. I'm sure Dan will have more helpful comments regarding the new Locate preferences and other things, but one issue I noticed is that the minus (-) button on the pane's right doesn't seem to do what one would expect. It only disables engines, which seems to duplicate what one can do via the toggle button. Should this button remove engines, or maybe the button itself should be removed?

It looks like the original "Library Lookup" and "Wayback Machine" engines have been removed. Do we need to rework those as standard Firefox search engines to reimplement them?

Best regards,
Sean

> --
> You received this message because you are subscribed to the Google Groups "zotero-dev" group.
> To post to this group, send email to zoter...@googlegroups.com.
> To unsubscribe from this group, send email to zotero-dev+...@googlegroups.com.
> For more options, visit this group at http://groups.google.com/group/zotero-dev?hl=en.
>

Avram Lyon

unread,
Nov 1, 2010, 2:18:39 AM11/1/10
to zoter...@googlegroups.com
Cameron, Pubget, and others,

For reference, this is Issue 716 in Trac
(https://www.zotero.org/trac/ticket/716). I went ahead and added the
patch to that ticket.

If you have Trac access, you may want to assign that issue to
yourself. Still, it's probably better to keep discussion of the patch
here on zotero-dev, since few people will receive bugmail for the
issue.

- Avram

2010/11/1 Sean Takats <sta...@gmu.edu>:

Cameron Allen

unread,
Nov 3, 2010, 3:48:06 PM11/3/10
to zotero-dev
Thank you all for your feedback. Avram, Sean, currently I'm trying to
reproduce the issue you're having with the error message. I didn't see
anything like it in my initial testing but there may be a debug flag I
have set the wrong way or perhaps a different Firefox preference
controls the output of the message. The problem comes up because the
search engine interface leaves no way to discern which Firefox search
engines can handle which parameters, so to work around this I used a
try/catch block and simply attempted to add all parameters, including
openURL parameters which regular search engines like Google won't have
a way to handle. This try/catch is supposed to catch these exceptions
but apparently something is missing.

Since the main problem is trying to differentiate between engines that
can and can't use openURL parameters, one approach would be to
leverage a piece of information that we know we can control like the
description. For example, if the description of the selected engine
contains the word "zotero", the locate manager would then attempt to
add the openURL parameters but if not these extra parameters would be
ignored and the search would be performed on just the title. The
ramification of this approach would be that any locate engine that
wants to use openURL parameters would have to include the word
"zotero" in their description, which doesn't seem overly demanding.
What do you guys think?

Past this issue, I've replaced the Library Lookup and Wayback Machine
options in the dropdown as they weren't meant to have been deleted.
Avram, I'm not against removing the toggle button as it doesn't add
anything special, but my only concern is with the checkbox style. They
default on my machine to a white background with no border and I was
mostly aiming to give confused users a lifeline in case all their
engines had become unchecked, leaving them with a screen of names and
descriptions but no discernible way to enable or disable their locate
engines. This can certainly be remedied with some simple CSS but until
then I'm hesitant to dismiss this corner case.

Finally, the "-" button is somewhat curious. While it's intended to
delete locate engines, it only works on engines that aren't Firefox's
default search engines since the interface does not permit the
deletion of these engines. Even if you "delete" them through Firefox's
search engine manager it will actually only mark them as hidden (which
is reversed with the "Restore Defaults" button). Given this
limitation, what should the functionality of the "-" button be when
used on Firefox's default search engines? If it marks them as hidden,
then they will also be hidden from the search engine which could be
considered intrusive to some users.

We'll continue to develop this on our end as more ideas come up.
Thanks for your feedback so far.

Cameron

On Nov 1, 2:18 am, Avram Lyon <ajl...@gmail.com> wrote:
> Cameron, Pubget, and others,
>
> For reference, this is Issue 716 in Trac
> (https://www.zotero.org/trac/ticket/716). I went ahead and added the
> patch to that ticket.
>
> If you have Trac access, you may want to assign that issue to
> yourself. Still, it's probably better to keep discussion of the patch
> here on zotero-dev, since few people will receive bugmail for the
> issue.
>
> - Avram
>
> 2010/11/1 Sean Takats <stak...@gmu.edu>:
>
>
>
>
>
>
>
> > Hi Cameron and the rest of the Pubget team,
>
> > Very exciting stuff! I'm delighted to see this code in action and have a little feedback.
>
> > I get the same error and results as Avram, running the latest Zotero trunk patched on Firefox 3.6.12. I'm sure Dan will have more helpful comments regarding the new Locate preferences and other things, but one issue I noticed is that the minus (-) button on the pane's right doesn't seem to do what one would expect. It only disables engines, which seems to duplicate what one can do via the toggle button. Should this button remove engines, or maybe the button itself should be removed?
>
> > It looks like the original "Library Lookup" and "Wayback Machine" engines have been removed. Do we need to rework those as standard Firefox search engines to reimplement them?
>
> > Best regards,
> > Sean
>
> > On Nov 1, 2010, at 4:54 AM, Avram Lyon wrote:
>
> >> 2010/10/28 Cameron Allen <cameronalle...@gmail.com>
> >>> What we're looking for now is mostly feedback.  We'd love to hear what
> >>> you guys think of where it's at right now and how much more it can be
> >>> improved.  Any questions or comments can be directed at
> >>> came...@pubget.com.
>
> >> When I selected "Google" from the Locate... drop-down, I got this message:
> >> ASSERT: *** Search: called nsISearchEngine::addParam on a read-only engine!
> >> Stack Trace:
> >> 0:ENSURE_WARN(false,called nsISearchEngine::addParam on a read-only
> >> engine!,2147500037)
> >> 1:SRCH_ENG_addParam(pmid,,text/html)
> >> 2:addParam(pmid,,text/html)
> >> 3:(Google,[object Object],[object Object])
> >> 4:onLocateClick([object XULCommandEvent])
> >> 5:oncommand([object XULCommandEvent])
>
> >> The search proceeded normally nonetheless. As a polish issue, you
> >> could probably get rid of the "Toggle" button in the Locate preference
> >> pane, since it is simply replicating the checkbox column's function.
>
> >> I'll keep playing with this and see what else I can offer. In general,
> >> it seems to work, and the patch applied cleanly to my SVN checkout of
> >> the trunk.
>
> >> - Avram
>
> >> --
> >> You received this message because you are subscribed to the Google Groups "zotero-dev" group.
> >> To post to this group, send email to zoter...@googlegroups.com.
> >> To unsubscribe from this group, send email to zotero-dev+...@googlegroups.com.
> >> For more options, visit this group athttp://groups.google.com/group/zotero-dev?hl=en.

mike

unread,
Nov 19, 2010, 5:08:17 PM11/19/10
to zotero-dev, rjo...@pubget.com
Hey folks,

I work with Cameron at Pubget. We're still stumped by the bug reported
in this thread, and can't reproduce it locally.

Would someone else be willing to take a stab at fixing or working with
us? I don't think there's much more we can do on our end, and it would
be a shame to not get this over the line given how far we've gotten.

The patch is on Trac, here: https://www.zotero.org/trac/ticket/716

Thanks in advance,
Mike Anderson



On Nov 3, 2:48 pm, Cameron Allen <cameronalle...@gmail.com> wrote:
> Thank you all for your feedback. Avram, Sean, currently I'm trying to
> reproduce the issue you're having with the error message. I didn't see
> anything like it in my initial testing but there may be a debug flag I
> have set the wrong way or perhaps a different Firefox preference
> controls the output of the message.  The problem comes up because the
> search engine interface leaves no way to discern which Firefox search
> engines can handle which parameters, so to work around this I used a
> try/catch block and simply attempted to add all parameters, including
> openURL parameters which regular search engines like Google won't have
> a way to handle. This try/catch is supposed to catch these exceptions
> but apparently something is missing.
>
> Since the main problem is trying to differentiate between engines that
> can and can't use openURL parameters, one approach would be to
> leverage a piece of information that we know we can control like the
> description. For example, if the description of the selected engine
> contains the word "zotero", thelocatemanager would then attempt to
> add the openURL parameters but if not these extra parameters would be
> ignored and the search would be performed on just the title. The
> ramification of this approach would be that anylocateengine that
> wants to use openURL parameters would have to include the word
> "zotero" in their description, which doesn't seem overly demanding.
> What do you guys think?
>
> Past this issue, I've replaced the Library Lookup and Wayback Machine
> options in the dropdown as they weren't meant to have been deleted.
> Avram, I'm not against removing the toggle button as it doesn't add
> anything special, but my only concern is with the checkbox style. They
> default on my machine to a white background with no border and I was
> mostly aiming to give confused users a lifeline in case all their
> engines had become unchecked, leaving them with a screen of names and
> descriptions but no discernible way to enable or disable theirlocate
> engines. This can certainly be remedied with some simple CSS but until
> then I'm hesitant to dismiss this corner case.
>
> Finally, the "-" button is somewhat curious. While it's intended to
> deletelocateengines, it only works on engines that aren't Firefox's
> default search engines since the interface does not permit the
> deletion of these engines. Even if you "delete" them through Firefox's
> search engine manager it will actually only mark them as hidden (which
> is reversed with the "Restore Defaults" button).  Given this
> limitation, what should the functionality of the "-" button be when
> used on Firefox's default search engines? If it marks them as hidden,
> then they will also be hidden from the search engine which could be
> considered intrusive to some users.
>
> We'll continue to develop this on our end as more ideas come up.
> Thanks for your feedback so far.
>
> Cameron
>
> On Nov 1, 2:18 am, Avram Lyon <ajl...@gmail.com> wrote:
>
>
>
>
>
>
>
> > Cameron, Pubget, and others,
>
> > For reference, this is Issue 716 in Trac
> > (https://www.zotero.org/trac/ticket/716). I went ahead and added the
> > patch to that ticket.
>
> > If you have Trac access, you may want to assign that issue to
> > yourself. Still, it's probably better to keep discussion of the patch
> > here on zotero-dev, since few people will receive bugmail for the
> > issue.
>
> > - Avram
>
> > 2010/11/1 Sean Takats <stak...@gmu.edu>:
>
> > > Hi Cameron and the rest of the Pubget team,
>
> > > Very exciting stuff! I'm delighted to see this code in action and have a little feedback.
>
> > > I get the same error and results as Avram, running the latest Zotero trunk patched on Firefox 3.6.12. I'm sure Dan will have more helpful comments regarding the newLocatepreferences and other things, but one issue I noticed is that the minus (-) button on the pane's right doesn't seem to do what one would expect. It only disables engines, which seems to duplicate what one can do via the toggle button. Should this button remove engines, or maybe the button itself should be removed?
>
> > > It looks like the original "Library Lookup" and "Wayback Machine" engines have been removed. Do we need to rework those as standard Firefox search engines to reimplement them?
>
> > > Best regards,
> > > Sean
>
> > > On Nov 1, 2010, at 4:54 AM, Avram Lyon wrote:
>
> > >> 2010/10/28 Cameron Allen <cameronalle...@gmail.com>
> > >>> What we're looking for now is mostly feedback.  We'd love to hear what
> > >>> you guys think of where it's at right now and how much more it can be
> > >>> improved.  Any questions or comments can be directed at
> > >>> came...@pubget.com.
>
> > >> When I selected "Google" from theLocate... drop-down, I got this message:

Avram Lyon

unread,
Nov 20, 2010, 3:22:38 PM11/20/10
to zoter...@googlegroups.com
If I understood Cameron correctly, the bug would be eliminated if we
could require that a certain string appear in the search engine
description. That string could reasonably be OpenURL. I see no reason
to not just make that a requirement.

We still need some feedback from Dan on UI integration and whatnot;
between this and the multilingual branch, the preferences are getting
pretty cramped.

Avram

2010/11/20 mike <saidth...@gmail.com>:

Dan Stillman

unread,
Nov 20, 2010, 3:32:49 PM11/20/10
to zoter...@googlegroups.com
On 11/20/10 3:22 PM, Avram Lyon wrote:
> We still need some feedback from Dan on UI integration and whatnot;
> between this and the multilingual branch, the preferences are getting
> pretty cramped.

I haven't had a chance to review the patch yet�I'll try to get to that
soon�but I thought we agreed that customization for this would be
handled as with Firefox search engines, where you access the management
pane from the bottom of the drop-down. Is that not the case for this?
(Apologies if I've missed some discussion of this.)

Cameron Allen

unread,
Dec 3, 2010, 3:43:57 PM12/3/10
to zotero-dev
A link to access the management pane is available at the bottom of the
drop down similar to the Firefox search engines, but currently the
link leads to a pane of the main preferences window. This can be
changed to open its own window, but it seemed to fit as a preferences
pane given its functionality.

I've implemented the idea of verifying that the string "OpenURL"
exists in the engine's description before adding the OpenURL
parameters. The new patch is available here:

http://assets0.pubget.com.s3.amazonaws.com/zotero-locate-engines-patch-12.3.10.diff

Avram and Sean, please let me know if this resolves the issues you two
are having regarding the error messages.

Cameron

On Nov 20, 3:32 pm, Dan Stillman <dstill...@zotero.org> wrote:
> On 11/20/10 3:22 PM, Avram Lyon wrote:
>
> > We still need some feedback from Dan on UI integration and whatnot;
> > between this and the multilingual branch, the preferences are getting
> > pretty cramped.
>
> I haven't had a chance to review the patch yet I'll try to get to that
> soon but I thought we agreed that customization for this would be

Dan Stillman

unread,
Dec 3, 2010, 3:54:39 PM12/3/10
to zoter...@googlegroups.com
On 12/3/10 3:43 PM, Cameron Allen wrote:
> A link to access the management pane is available at the bottom of the
> drop down similar to the Firefox search engines, but currently the
> link leads to a pane of the main preferences window. This can be
> changed to open its own window, but it seemed to fit as a preferences
> pane given its functionality.

The preferences are full enough (and there will be enough future demands
for space there) that having this in its own window should be
sufficient. There's no real need to access it any other way.

Cameron Allen

unread,
Dec 16, 2010, 10:56:41 AM12/16/10
to zotero-dev
That makes sense. I've written another patch (link below) placing the
locate engine manager in its own window, similar to how Firefox
handles its own search engines. Beyond this, does the rest of the
functionality seem appropriate and intuitive?

http://assets0.pubget.com.s3.amazonaws.com/zotero-locate-engines-patch-12.15.10.diff

Cameron

mike

unread,
Dec 22, 2010, 9:34:19 AM12/22/10
to zotero-dev
Hey folks,

Where does the process go from here? can we look forward to the patch
to being committed in the near future?

Mike
(Pubget)

On Dec 16, 10:56 am, Cameron Allen <cameronalle...@gmail.com> wrote:
> That makes sense. I've written another patch (link below) placing the
> locate engine manager in its own window, similar to how Firefox
> handles its own search engines. Beyond this, does the rest of the
> functionality seem appropriate and intuitive?
>
> http://assets0.pubget.com.s3.amazonaws.com/zotero-locate-engines-patc...

skornblith

unread,
Dec 28, 2010, 6:15:15 PM12/28/10
to zotero-dev
I'll try to review this after the holidays.

Simon

mike

unread,
Jan 12, 2011, 10:34:02 AM1/12/11
to zotero-dev
Hi Simon,

I was wondering if you were able to get the patch installed and verify
that it works correctly? I'm available if you have any questions,
please feel free to reach out.

Cheers,
Mike Anderson
Pubget, Inc

Dan Stillman

unread,
Jan 14, 2011, 3:44:50 PM1/14/11
to zoter...@googlegroups.com
We'll aim to get to this for the next beta.

- Dan

mike

unread,
Jan 18, 2011, 11:57:50 AM1/18/11
to zotero-dev
That sounds great. What's the scheduled release date for this? I'll be
sure to test out the beta around the office.
Reply all
Reply to author
Forward
0 new messages