exclude/eligible don't get passed to crossbar

21 views
Skip to first unread message

David Ford

unread,
Dec 3, 2015, 7:15:15 PM12/3/15
to Autobahn
(in python)

using the form of:
self.publish(topic, content, exclude=[foo], eligible=[foo])

per the autobahn.ws documentation at http://autobahn.ws/js/reference_wampv1.html#publish-and-subscribe; these get dropped somewhere and never make it to crossbar. is the documentation out of date? autobahn.wamp.protocol suggests that i should instead be using options=types.PublishOptions at about line 1008.


class ApplicationSession(BaseSession):
    [...]
    def publish(self, topic, *args, **kwargs):
        [...]
        if 'options' in kwargs and isinstance(kwargs['options'], types.PublishOptions):
            options = kwargs.pop('options')
            msg = message.Publish(request_id, topic, args=args, kwargs=kwargs, **options.message_attr())
        else:
            options = None
            msg = message.Publish(request_id, topic, args=args, kwargs=kwargs)


it looks like this reference documentation should be changed to something more like publish(topic, content, options=PublishOptions(exclude=[list], eligible=[list], ...))


in autobahn.wamp.types, class PublishOptions starts as:

class PublishOptions(object):
    """
    Used to provide options for subscribing in
    :func:`autobahn.wamp.interfaces.IPublisher.publish`.
    """

should the doc note for this read differently such that it is for publishing rather than subscribing?

-david

Tobias Oberstein

unread,
Dec 4, 2015, 2:07:38 AM12/4/15
to autob...@googlegroups.com
Am 04.12.2015 um 01:15 schrieb David Ford:
> (in python)
>
> using the form of:
>
> /self.publish(topic, content, exclude=[foo], eligible=[foo])/
http://autobahn.ws/js/reference_wampv1.html#autobahn-legacy-wamp-v1-documentation

Note the word "deprecated".

Also: this is for AutobahnJS, not AutobahnPython
The docs are correct. Please see above.

>
> -david
>
> --
> You received this message because you are subscribed to the Google
> Groups "Autobahn" group.
> To unsubscribe from this group and stop receiving emails from it, send
> an email to autobahnws+...@googlegroups.com
> <mailto:autobahnws+...@googlegroups.com>.
> To post to this group, send email to autob...@googlegroups.com
> <mailto:autob...@googlegroups.com>.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/autobahnws/9a231672-216a-4e3a-9a51-0fcf55af25d4%40googlegroups.com
> <https://groups.google.com/d/msgid/autobahnws/9a231672-216a-4e3a-9a51-0fcf55af25d4%40googlegroups.com?utm_medium=email&utm_source=footer>.
> For more options, visit https://groups.google.com/d/optout.

David Ford

unread,
Dec 4, 2015, 11:50:47 AM12/4/15
to Autobahn
it pays to delete one's bookmarks and refresh :D  thank you for the reply!

Tobias Oberstein

unread,
Dec 4, 2015, 1:22:56 PM12/4/15
to autobahnws

:) np. cheers, /Tobias

Sent from Mobile (Google Nexus 5)

Am 04.12.2015 5:50 nachm. schrieb "David Ford" <firefig...@gmail.com>:
it pays to delete one's bookmarks and refresh :D  thank you for the reply!

--
You received this message because you are subscribed to the Google Groups "Autobahn" group.
To unsubscribe from this group and stop receiving emails from it, send an email to autobahnws+...@googlegroups.com.
To post to this group, send email to autob...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/autobahnws/26ce30f1-2c4d-4f47-87ee-37e925191867%40googlegroups.com.
Reply all
Reply to author
Forward
0 new messages