> On Feb 5, 2022, at 5:51 AM, Stephen J. Turnbull <stephenjturnb...@gmail.com> > wrote: > > Suyash Singh writes: > > Welcome, Suyash! > > Sorry this mail has been sitting in my drafts for a day or so, but I > don't think anybody else has answered yet. Let me just send it and > start the conversation. > >> I have started a development environment and am starting to read the >> documentation. I picked up issue #973 because it seemed like a easy issue >> to fix. > > Not clear what you're reading. The dev setup guide starts here, but > the site structure is somewhat complicated (disorganized): > https://docs.mailman3.org/en/latest/devsetup.html > >> Link to Issue: https://gitlab.com/mailman/mailman/-/issues/973 > > Note that at least one other developer (whose handle I don't recognize > so probably new) is working on that issue. > >> 1) I am unable to recreate the problem. As I can't find the API url and how >> do I access them in my development environment. I tried the using the >> command "mailman shell" which is referred to in the documentation for >> debugging. and after holding a message and handling it. I get the following >> error: >>>>> handle_message(mlist, 1, Action.discard) >>>>> handle_message(mlist, 1, Action.discard) >> Traceback (most recent call last): >> File "<console>", line 1, in <module> >> File >> "/home/suyashsingh/Desktop/mailman/mailman/src/mailman/app/moderator.py", >> line 113, in handle_message >> key, msgdata = requestdb.get_request(id) >> TypeError: cannot unpack non-iterable NoneType object > > I think you probably don't have Mailman running, but I can't be sure > because of the limited information you've given about how you set up > your dev environment. > >> 2) How can I start http://localhost:9001/ on my local machine as currently >> its not working. What is the port 9001 used for? > > In a dev environment, port 9001 is used for the REST API served by > Mailman core. You start Mailman by running "mailman start" in the > directory where you want Mailman's database stored (this assumes you > have configured your dev environment to use sqlite3 as the backend).
A minor clarification for this, Port 9001 is only used in our testing since we don’t want to start a test server on 8001, which is the default port and also the port using for dev. Although, this does make me think that we should consider making a chage to our docs to suite more as docs and less as just tests. It would interfere with a dev server running when you run tests, which isn’t ideal though. We have pages that have documented this kind of behavior about 9001/8001 I think, but I am sure this has to be told at least once to folks new to Mailman documentation. I wonder if we can do something about it? At some point though, I want to get rid of call_api() towards `requests.get()` or simple urllib3.urlopen() methods as it will be a lot easier for folks to understand and run for folks and maybe equally testable. -- thanks, Abhilash Raj (maxking)
signature.asc
Description: Message signed with OpenPGP
_______________________________________________ Mailman-Developers mailing list -- mailman-developers@python.org To unsubscribe send an email to mailman-developers-le...@python.org https://mail.python.org/mailman3/lists/mailman-developers.python.org/ Mailman FAQ: https://wiki.list.org/x/AgA3 Security Policy: https://wiki.list.org/x/QIA9