isoc-ams 0.0.2__py2.py3-none-any.whl → 0.1.1__py2.py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of isoc-ams might be problematic. Click here for more details.

@@ -1,261 +0,0 @@
1
- Metadata-Version: 2.4
2
- Name: isoc-ams
3
- Version: 0.0.2
4
- Summary: A Python 3 module to cope with ISOC-AMS.
5
- Author-email: Klaus Birkenbihl <klaus.birkenbihl@isoc.de>
6
- Maintainer: Klaus Birkenbihl
7
- Description-Content-Type: text/markdown
8
- Classifier: License :: OSI Approved :: MIT License
9
- License-File: LICENSE
10
- Requires-Dist: selenium>4
11
- Project-URL: Home, https://github.com/birkenbihl/isoc-ams
12
-
13
-
14
- # isoc-ams
15
-
16
- A Python Interface to access the 'Advanced Members Administration System' (AMS) of the 'Internet Society' (ISOC). This especially useful for ISOC Chapter Admins who want to synchronize their Chapter Database with AMS (semi)automatically.
17
-
18
- After 10 years+ of sorrow, millions minutes of waiting for answers from the AMS web interface, tons of useless clicks, many (in fact) rejected requests to provide an API access: the author decided to build an API himself. Even if it might not be more than a demonstrator for the functionality needed. Anyhow (see below): for now it is running on a weekly basis doing a great job in avoiding manual work.
19
-
20
- Unfortunately the constraints are severe:
21
- - access had to be through the web interface since this is the only interface provided. As a consequence it is slow, sometimes unreliable and hard to implement. At least there are working implementations of the "W3C web driver" recommendation. One of them is Selenium used for this project.
22
- - the existing web interface is far from being stable or guaranteed. So changes to the web interface might spoil the whole project. There is great chance that few weeks from now a new "super duper" AMS will be announced and as always after these announcements things will get worse.
23
- - tests are close to impossible. There is no such thing as a TEST AMS.
24
-
25
- Is there a possible good exit? Well, maybe some day soon - in 10 or 20 years if ISOC still exists - there will be an API provided by ISOC that makes this project obsolete. Or at least may be an all-mighty AI will step in. Let's dream on!
26
-
27
- ## Features
28
- AMS maintains two main Lists that are relevant for the operation of this interface:
29
- - a list of ISOC members registered as members of the Chapter
30
- - a list of ISOC members that applied for a Chapter membership.
31
-
32
- Consequently isoc-ams provides methods for the following tasks:
33
- 1. read list of ISOC members registered as Chapter members
34
- 1. read list of ISOC members that applied for a Chapter membership
35
- 1. approve ISOC AMS applications
36
- 1. deny ISOC AMS applications
37
- 1. delete members from ISOC AMS Chapters Member list
38
- 1. add members to ISOC AMS Chapters Member list (Chapter admins are not authorized to do this. So the author suggest to write a mail to ams-support.)
39
-
40
- Don't forget: it takes time and you may see many kinds of errors. Often the cure is "try again later". Any expectation of flawless is not appropriate.
41
-
42
- So here we go:
43
-
44
- ## Installation
45
-
46
- Install isoc-ams with pip.
47
-
48
- ```bash
49
- python -m pip install -U isoc-ams
50
- ```
51
-
52
- Best would be to use a virtual environment (venv).
53
-
54
- ## Running isoc_ams
55
-
56
- You may select a webdriver of your choice (provided it is one of "firefox" or "chrome") by setting an environment variable ISOC_AMS_WEBDRIVER e.g.:
57
- ```bash
58
- ISOC_AMS_WEBDRIVER=firefox
59
- ```
60
- Recommended (and default) is "firefox".
61
-
62
- Since crazy things may happen it is important to keep track of what is going on. So ISOC_AMS lets you know what it is doing.
63
- by providing a logfile (goes to stdout by default).
64
-
65
- So this happens if we call the module with:
66
- ```bash
67
- python -m isoc_ams
68
- ```
69
- Output:
70
- ```
71
- Username: xxx
72
- Password:
73
-
74
- ********************************************
75
- AMS 2025-07-03 10:49:05 START
76
- ********************************************
77
-
78
- AMS 2025-07-03 10:49:07 logging in
79
- AMS 2025-07-03 10:49:11 log in started
80
- AMS 2025-07-03 10:49:20 now on community portal
81
- AMS 2025-07-03 10:49:25 waiting for Chapter Leader portal
82
- AMS 2025-07-03 10:49:27 Chapter Leader portal OK
83
-
84
-
85
- AMS 2025-07-03 10:49:27 start build members list
86
- AMS 2025-07-03 10:49:27 Creating page for Members
87
- AMS 2025-07-03 10:49:33 Members page created
88
- AMS 2025-07-03 10:49:33 Loading Members
89
- AMS 2025-07-03 10:49:39 got list of Members
90
- AMS 2025-07-03 10:49:39 collecting the following fields: "ISOC-ID", "first name", "last name", "email"
91
- AMS 2025-07-03 10:49:39 Total (records expected): 38
92
- AMS 2025-07-03 10:49:39 Waiting for Total to stabilise
93
- AMS 2025-07-03 10:49:42 Total (records expected): 59
94
- AMS 2025-07-03 10:49:45 calling reader with 31 table rows, (collected records so far: 0 )
95
- AMS 2025-07-03 10:49:50 calling reader with 32 table rows, (collected records so far: 29 )
96
- AMS 2025-07-03 10:49:54 calling reader with 24 table rows, (collected records so far: 53 )
97
- AMS 2025-07-03 10:49:55 records collected / total 59 / 59
98
- AMS 2025-07-03 10:49:55 Creating page for Member Contacts
99
- AMS 2025-07-03 10:50:00 Member Contacts page created
100
- AMS 2025-07-03 10:50:00 Loading Member Contacts
101
- AMS 2025-07-03 10:50:04 got list of Member Contacts
102
- AMS 2025-07-03 10:50:04 collecting the following fields: "action link" (for taking actions), "email" (to connect with members list)
103
- AMS 2025-07-03 10:50:04 Total (records expected): 8
104
- AMS 2025-07-03 10:50:04 Waiting for Total to stabilise
105
- AMS 2025-07-03 10:50:07 Total (records expected): 59
106
- AMS 2025-07-03 10:50:10 calling reader with 30 table rows, (collected records so far: 0 )
107
- AMS 2025-07-03 10:50:14 calling reader with 31 table rows, (collected records so far: 28 )
108
- AMS 2025-07-03 10:50:18 calling reader with 25 table rows, (collected records so far: 51 )
109
- AMS 2025-07-03 10:50:18 records collected / total 59 / 59
110
- AMS 2025-07-03 10:50:18 members list finished
111
-
112
-
113
- AMS 2025-07-03 10:50:18 start build pending applications
114
- AMS 2025-07-03 10:50:18 Creating page for Pending Applications
115
- AMS 2025-07-03 10:50:22 collecting the following fields: "name", "email", "action link", "date"
116
- AMS 2025-07-03 10:50:24 Total (records expected): 8
117
- AMS 2025-07-03 10:50:24 Waiting for Total to stabilise
118
- AMS 2025-07-03 10:50:27 Total (records expected): 8
119
- AMS 2025-07-03 10:50:30 calling reader with 8 table rows, (collected records so far: 0 )
120
- AMS 2025-07-03 10:50:31 records collected / total 8 / 8
121
- AMS 2025-07-03 10:50:31 pending application list finished
122
-
123
-
124
- MEMBERS
125
- 1 ...
126
- 2 ...
127
- ...
128
-
129
- PENDING APPLICATIONS
130
- 1 ...
131
- 2 ...
132
- ...
133
- ```
134
- As you can see: building the list is rather tedious: reading the Table scroll it to find the end ... and for the members list - in order to get the links for actions - we have to build 2 tables ...
135
- ### Running with arguments
136
- Normally isoc_ams won't show any browser output - running headless. To do debugging it might useful to follow the activities in the browser. If you call isoc_ams with a -h option like
137
- ```bash
138
- python -m isoc_ams -h
139
- ```
140
- the browser will open and you can follow all activities real time.
141
-
142
- An argument -i tells the module that there will be (or is) input available with actions to execute. An argument -d tells isoc_ams to make a dry run where actions are computed but not executed.
143
-
144
- Again an example:
145
- ```bash
146
- python -m isoc_ams -i -d
147
- ```
148
- Output:
149
- ```
150
- Username: xxx
151
- Username:klaus.birkenbihl@isoc.de
152
- Password:
153
-
154
- ********************************************
155
- AMS 2025-07-09 16:25:06 START DRYRUN
156
- ********************************************
157
-
158
- AMS 2025-07-09 16:25:06 logging in
159
- AMS 2025-07-09 16:25:09 log in started
160
- AMS 2025-07-09 16:25:17 now on community portal
161
- AMS 2025-07-09 16:25:21 waiting for Chapter Leader portal
162
- AMS 2025-07-09 16:25:21 Chapter Leader portal OK
163
-
164
-
165
- AMS 2025-07-09 16:25:21 start build members list
166
- ...
167
- AMS 2025-07-09 16:26:12 records collected / total 58 / 58
168
- AMS 2025-07-09 16:26:12 members list finished
169
-
170
-
171
- AMS 2025-07-09 16:26:12 start build pending applications
172
- ...
173
- AMS 2025-07-09 16:26:25 records collected / total 9 / 9
174
- AMS 2025-07-09 16:26:25 pending application list finished
175
-
176
-
177
- MEMBERS
178
- 1 2217734 Johannes Piesepampel self@piesepampel.com
179
- ...
180
-
181
- PENDING APPLICATIONS
182
- 1 23232 Franz Piesepampel franz@piesepampel.com 2025-01-22
183
- 2 22556 Abdul Piesepampel abdul@piesepampel.com 2025-03-21
184
- ...
185
- READING COMMANDS:
186
- deny 23232 22556 123
187
- AMS 2025-07-09 18:17:51 Denied 2323284 Franz Piesepampel
188
- AMS 2025-07-09 18:17:51 Denied 2333463 Abdul Piesepampel
189
- *******************************************************************************
190
- AMS 2025-07-09 18:17:51 ISOC-ID 123 is not in pending applications list
191
- *******************************************************************************
192
-
193
- delete 2217734
194
- AMS 2025-07-09 18:18:29 Deleted 22842 Franz Piesepampel
195
- EOF of command input
196
- Deviations from expected results:
197
- Dryrun No results expected
198
- All results as expected
199
- ```
200
-
201
- ## Using the API
202
-
203
- isoc_ams unleashes its full power when used as API to make things happen without human intervention. Check the file "[isoc_de_ams_main.py](https://github.com/birkenbihl/isoc-ams/blob/main/isoc_de_ams_main.py)" as an example for fully automatic synchronizing of local membership administration with AMS.
204
-
205
- Here an excerpt of the output:
206
- ```
207
- Pending Applications:
208
-
209
- the following pending applications will be approved:
210
- ...
211
- the following pending applications will be denied:
212
- ...
213
- the following pending applications will be invited:
214
- ...
215
- the following pending applications will be waiting:
216
- ...
217
-
218
- Members:
219
- the following members will be deleted from AMS:
220
- ...
221
- for the following members a nagging mail will be sent to AMS-support (we are not authorized to fix it!):
222
- ...
223
- the following locally registered members are in sync with AMS:
224
- ...
225
-
226
- AMS 2025-07-03 12:00:32 start delete ... from AMS Chapter members list
227
- ...
228
-
229
- Dear AMS-support team,
230
-
231
- this is an automatic, complimentary Message from the ISOC German Chapter
232
- Members Administration System (ISOC.DE MAS).
233
-
234
- Assuming you are interested in making ISOC AMS consistent, the purpose
235
- of this message is to help you with valid, up-to-date data.
236
-
237
- The following individuals are legally registered paying members
238
- of ISOC.DE - many of them for more than 25 years. They all are
239
- also registered as ISOC (global) members. Unfortunately they are
240
- not registered with AMS as members of ISOC.DE. Even more we are
241
- not authorized to fix this. So we forward this data to your attention:
242
-
243
- Uwe Mayer, xxx@yyy.com (ISOC-ID=1234567)
244
- ...
245
-
246
- Thank you,
247
- Your ISOC.DE MAS support team
248
- ...
249
-
250
- DEVIATIONS FROM EXPECTED RESULTS
251
- not deleted from members
252
- ...
253
- not approved from pending applicants list
254
- ...
255
- not removed from pending applicants list
256
- ...
257
- ```
258
- See file [isoc_ams.doc](https://github.com/birkenbihl/isoc-ams/blob/main/isoc_ams.doc) for doc on the API interface.
259
-
260
- Have fun!
261
-
@@ -1,5 +0,0 @@
1
- isoc_ams.py,sha256=pc1BLQcVs7fKDoy_FBuBe1hszEiaueGCOvPk76Qp4VI,33853
2
- isoc_ams-0.0.2.dist-info/licenses/LICENSE,sha256=BJcMew_kvBWHjs-_Hd_OMHnxOLmeczeT88V4gFCT21U,1067
3
- isoc_ams-0.0.2.dist-info/WHEEL,sha256=Dyt6SBfaasWElUrURkknVFAZDHSTwxg3PaTza7RSbkY,100
4
- isoc_ams-0.0.2.dist-info/METADATA,sha256=3IDSf6pRGsw255-F0W1VGXPcLLJFlCHxySAs7KVnsVE,10489
5
- isoc_ams-0.0.2.dist-info/RECORD,,