(self, regulation: str)
| 2931 | return update |
| 2932 | |
| 2933 | def check_regulation(self, regulation: str) -> list: |
| 2934 | if regulation not in SOURCES: |
| 2935 | print(f"Unknown regulation: {regulation}") |
| 2936 | return [] |
| 2937 | updates = [] |
| 2938 | sources = SOURCES[regulation] |
| 2939 | print(f"\nChecking {regulation} ({len(sources)} sources)...") |
| 2940 | for source_id, source in sources.items(): |
| 2941 | full_id = f"{regulation}/{source_id}" |
| 2942 | print(f" [{full_id}] {source['name']}") |
| 2943 | result = self.check_source(full_id, source) |
| 2944 | if result: |
| 2945 | updates.append(result) |
| 2946 | print(f" -> UPDATE DETECTED: {result.get('note', '')}") |
| 2947 | else: |
| 2948 | print(f" -> No changes") |
| 2949 | time.sleep(1.0) |
| 2950 | return updates |
| 2951 | |
| 2952 | def check_all(self) -> list: |
| 2953 | all_updates = [] |
no test coverage detected