Abhilash Raj pushed to branch master at GNU Mailman / Mailman Core
Commits: 3c9dbd86 by Mark Sapiro at 2019-07-29T02:26:47Z Expose usenet gateway settings in REST. - - - - - 9bf0b116 by Abhilash Raj at 2019-07-29T02:26:47Z Merge branch 'nntp' into 'master' Expose usenet gateway settings in REST. See merge request mailman/mailman!541 - - - - - 3 changed files: - src/mailman/rest/docs/listconf.rst - src/mailman/rest/listconf.py - src/mailman/rest/tests/test_listconf.py Changes: ===================================== src/mailman/rest/docs/listconf.rst ===================================== @@ -52,6 +52,8 @@ All readable attributes for a list are available on a sub-resource. first_strip_reply_to: False footer_uri: fqdn_listname: a...@example.com + gateway_to_mail: False + gateway_to_news: False goodbye_message_uri: header_uri: http_etag: "..." @@ -60,13 +62,16 @@ All readable attributes for a list are available on a sub-resource. join_address: ant-j...@example.com last_post_at: None leave_address: ant-le...@example.com + linked_newsgroup: list_name: ant mail_host: example.com max_message_size: 40 max_num_recipients: 10 member_roster_visibility: moderators moderator_password: None + newsgroup_moderation: none next_digest_number: 1 + nntp_prefix_subject_too: True no_reply_address: nore...@example.com owner_address: ant-ow...@example.com post_id: 1 @@ -81,6 +86,7 @@ All readable attributes for a list are available on a sub-resource. send_welcome_message: True subject_prefix: [Ant] subscription_policy: confirm + usenet_watermark: None volume: 1 welcome_message_uri: @@ -128,6 +134,11 @@ When using ``PUT``, all writable attributes must be included. ... posting_pipeline='virgin', ... filter_content=True, ... first_strip_reply_to=True, + ... gateway_to_mail=True, + ... gateway_to_news=True, + ... linked_newsgroup='my.group', + ... newsgroup_moderation='moderated', + ... nntp_prefix_subject_too=False, ... convert_html_to_plaintext=True, ... collapse_alternatives=False, ... reply_goes_to_list='point_to_list', @@ -189,11 +200,16 @@ These values are changed permanently. first_strip_reply_to: True footer_uri: fqdn_listname: a...@example.com + gateway_to_mail: True + gateway_to_news: True ... include_rfc2369_headers: False ... member_roster_visibility: members moderator_password: {plaintext}password + newsgroup_moderation: moderated + ... + nntp_prefix_subject_too: False ... posting_pipeline: virgin preferred_language: ja ===================================== src/mailman/rest/listconf.py ===================================== @@ -26,6 +26,7 @@ from mailman.interfaces.digests import DigestFrequency from mailman.interfaces.mailinglist import ( DMARCMitigateAction, IAcceptableAliasSet, IMailingList, ReplyToMunging, SubscriptionPolicy) +from mailman.interfaces.nntp import NewsgroupModeration from mailman.interfaces.template import ITemplateManager from mailman.model.roster import RosterVisibility from mailman.rest.helpers import ( @@ -181,17 +182,22 @@ ATTRIBUTES = dict( filter_content=GetterSetter(as_boolean), first_strip_reply_to=GetterSetter(as_boolean), fqdn_listname=GetterSetter(None), + gateway_to_mail=GetterSetter(as_boolean), + gateway_to_news=GetterSetter(as_boolean), include_rfc2369_headers=GetterSetter(as_boolean), info=GetterSetter(str), join_address=GetterSetter(None), last_post_at=GetterSetter(None), leave_address=GetterSetter(None), list_name=GetterSetter(None), + linked_newsgroup=GetterSetter(str), mail_host=GetterSetter(None), moderator_password=GetterSetter(password_bytes_validator), max_message_size=GetterSetter(integer_ge_zero_validator), member_roster_visibility=GetterSetter(enum_validator(RosterVisibility)), + newsgroup_moderation=GetterSetter(enum_validator(NewsgroupModeration)), next_digest_number=GetterSetter(None), + nntp_prefix_subject_too=GetterSetter(as_boolean), no_reply_address=GetterSetter(None), owner_address=GetterSetter(None), post_id=GetterSetter(None), @@ -205,6 +211,7 @@ ATTRIBUTES = dict( send_welcome_message=GetterSetter(as_boolean), subject_prefix=GetterSetter(str), subscription_policy=GetterSetter(enum_validator(SubscriptionPolicy)), + usenet_watermark=GetterSetter(None), volume=GetterSetter(None), respond_to_post_requests=GetterSetter(as_boolean), max_num_recipients=GetterSetter(integer_ge_zero_validator), ===================================== src/mailman/rest/tests/test_listconf.py ===================================== @@ -68,11 +68,16 @@ RESOURCE = dict( dmarc_wrapped_message_text='some message text', filter_content=True, first_strip_reply_to=True, + gateway_to_mail=False, + gateway_to_news=False, goodbye_message_uri='mailman:///goodbye.txt', include_rfc2369_headers=False, info='This is the mailing list info', + linked_newsgroup='', moderator_password='password', max_message_size='150', + newsgroup_moderation='none', + nntp_prefix_subject_too=False, posting_pipeline='virgin', preferred_language='en', reply_goes_to_list='point_to_list', View it on GitLab: https://gitlab.com/mailman/mailman/compare/941991bebc5c882c96d5f09c0e3a54a5e76f2104...9bf0b1160aa2df862566769a373fb0a796b00857 -- View it on GitLab: https://gitlab.com/mailman/mailman/compare/941991bebc5c882c96d5f09c0e3a54a5e76f2104...9bf0b1160aa2df862566769a373fb0a796b00857 You're receiving this email because of your account on gitlab.com.
_______________________________________________ Mailman-checkins mailing list Mailman-checkins@python.org Unsubscribe: https://mail.python.org/mailman/options/mailman-checkins/archive%40jab.org