HTTPError in message moderation for non-members

Bug #1432406 reported by Ashish
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Postorius
New
Undecided
Unassigned

Bug Description

Hi, I was trying to send a msg by no member id but I am getting http error.

>>> client.domains
[<Domain "example.net">, <Domain "example.org">, <Domain "domain.org">]
>>> example = client.get_domain("domain.org")
>>> example
<Domain "domain.org">
>>> test_one = example.create_list('test-one')
>>> test_one
<List "<email address hidden>">
>>> msg
'From: <email address hidden>\nTo: <email address hidden>\nSubject: Something\nMessage-ID: <moderated_01>\n\nSome Text.\n\n'
>>> msg = """From: <email address hidden>
... To: <email address hidden>
... Subject: Something
... Message-ID: <moderated_01>
...
... Some text.
...
... """
>>> inq = client.queues['in']
>>> inq.inject('test-one.example.com', msg)
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/home/ashish/mailman/mm2/mailman.client/src/mailmanclient/_client.py", line 999, in inject
    self._connection.call(self.url, dict(list_id=list_id, text=text))
  File "/home/ashish/mailman/mm2/mailman.client/src/mailmanclient/_client.py", line 108, in call
    raise HTTPError(url, response.status, content, response, None)
urllib2.HTTPError: HTTP Error 400: No such list: test-one.example.com
>>>

Revision history for this message
Ana Badescu (anabee-emacs) wrote :

Hello Ashish,

I believe you're getting that error due to an invalid list id when calling inq.inject(). Can you run test_one.list_id before performing the inject, and use that result string as the inject's first parameter?

Cheers,
Ana

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.