boarddata 6.8.7__tar.gz → 6.8.9__tar.gz
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.
- {boarddata-6.8.7 → boarddata-6.8.9}/PKG-INFO +1 -1
- {boarddata-6.8.7 → boarddata-6.8.9}/__init__.py +1 -1
- {boarddata-6.8.7 → boarddata-6.8.9}/_assemblies.py +30 -9
- {boarddata-6.8.7 → boarddata-6.8.9}/_committees.py +2 -1
- {boarddata-6.8.7 → boarddata-6.8.9}/boarddata.egg-info/PKG-INFO +1 -1
- {boarddata-6.8.7 → boarddata-6.8.9}/pyproject.toml +1 -1
- {boarddata-6.8.7 → boarddata-6.8.9}/tests/test_exports.py +14 -0
- boarddata-6.8.9/types/committees.py +40 -0
- boarddata-6.8.7/types/committees.py +0 -27
- {boarddata-6.8.7 → boarddata-6.8.9}/CLAUDE.md +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/README.md +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/_auditors.py +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/_base.py +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/_comex.py +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/_companies.py +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/_criteria.py +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/_directors.py +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/_documents.py +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/_esg.py +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/_indexes.py +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/_persons.py +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/_risks.py +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/_sentinel.py +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/_utilities.py +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/boarddata.egg-info/SOURCES.txt +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/boarddata.egg-info/dependency_links.txt +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/boarddata.egg-info/requires.txt +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/boarddata.egg-info/top_level.txt +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/cache.py +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/client.py +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/dq/__init__.py +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/dq/adjudicate.py +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/dq/apply.py +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/dq/context.py +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/dq/db.py +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/dq/domains.py +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/dq/models.py +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/dq/oracle.py +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/dq/registry.py +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/dq/report.py +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/dq/rules/__init__.py +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/dq/rules/cross_company.py +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/dq/rules/lexical.py +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/dq/s3.py +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/dq/verify_s3.py +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/errors.py +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/py.typed +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/scripts/__init__.py +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/scripts/dq_apply.py +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/scripts/dq_batch.py +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/scripts/dq_plan.py +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/scripts/dq_revert.py +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/scripts/dq_scan.py +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/scripts/dq_verify_s3.py +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/setup.cfg +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/tests/__init__.py +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/tests/conftest.py +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/tests/test_assemblies.py +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/tests/test_auditors.py +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/tests/test_base.py +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/tests/test_build_payload.py +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/tests/test_cache.py +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/tests/test_comex.py +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/tests/test_committees.py +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/tests/test_companies.py +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/tests/test_config.py +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/tests/test_criteria.py +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/tests/test_directors.py +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/tests/test_documents.py +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/tests/test_esg.py +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/tests/test_indexes.py +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/tests/test_persons.py +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/tests/test_politic_fixture_conformance.py +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/tests/test_risks.py +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/tests/test_sentinel.py +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/tests/test_types_politic.py +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/tests/test_utilities.py +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/types/__init__.py +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/types/assemblies.py +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/types/auditors.py +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/types/comex.py +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/types/companies.py +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/types/core.py +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/types/criteria.py +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/types/directors.py +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/types/documents.py +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/types/esg.py +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/types/indexes.py +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/types/persons.py +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/types/risks.py +0 -0
- {boarddata-6.8.7 → boarddata-6.8.9}/types/sentinel.py +0 -0
|
@@ -43,10 +43,19 @@ class AssemblyMixin:
|
|
|
43
43
|
def list_assemblies(self, **params: Any) -> PaginatedResponse:
|
|
44
44
|
"""List assemblies.
|
|
45
45
|
|
|
46
|
+
Default order: ``assembly_date`` descending, then ``id`` (stable
|
|
47
|
+
across pages).
|
|
48
|
+
|
|
46
49
|
Args:
|
|
47
|
-
company: Filter by company UUID
|
|
48
|
-
|
|
49
|
-
|
|
50
|
+
company: Filter by ONE company UUID (a list keeps only its last
|
|
51
|
+
value). A malformed UUID is a 400. Backends older than this
|
|
52
|
+
filter ignored it silently and returned every company's
|
|
53
|
+
assemblies.
|
|
54
|
+
assembly_type: Filter by assembly type: ``"ordinary"``,
|
|
55
|
+
``"extraordinary"`` or ``"mixed"`` (comma-separate several).
|
|
56
|
+
Any other value matches nothing.
|
|
57
|
+
fiscal_year: Filter by fiscal year (int; a non-integer is a 400).
|
|
58
|
+
Same backend note as ``company``.
|
|
50
59
|
page: Page number.
|
|
51
60
|
page_size: Results per page.
|
|
52
61
|
|
|
@@ -74,9 +83,9 @@ class AssemblyMixin:
|
|
|
74
83
|
GET /api/assemblies/published/
|
|
75
84
|
|
|
76
85
|
Server-applied (cannot be overridden by query params):
|
|
77
|
-
-
|
|
86
|
+
- assembly_validated=True
|
|
78
87
|
- excludes assemblies with both agenda_html and report_html empty
|
|
79
|
-
- ordered by assembly_date DESC
|
|
88
|
+
- ordered by assembly_date DESC, then id (stable across pages)
|
|
80
89
|
|
|
81
90
|
Args:
|
|
82
91
|
date_from: assembly_date >= (``"YYYY-MM-DD"``).
|
|
@@ -340,9 +349,10 @@ class AssemblyMixin:
|
|
|
340
349
|
rows without pagination.
|
|
341
350
|
|
|
342
351
|
Args:
|
|
343
|
-
company: Filter by company UUID.
|
|
344
|
-
assembly_type: Filter by type
|
|
345
|
-
|
|
352
|
+
company: Filter by company UUID (see ``list_assemblies``).
|
|
353
|
+
assembly_type: Filter by type: ``"ordinary"``, ``"extraordinary"``
|
|
354
|
+
or ``"mixed"``.
|
|
355
|
+
fiscal_year: Filter by fiscal year (see ``list_assemblies``).
|
|
346
356
|
**kwargs: Additional filters forwarded as query params.
|
|
347
357
|
|
|
348
358
|
Returns:
|
|
@@ -480,7 +490,13 @@ class AssemblyMixin:
|
|
|
480
490
|
def list_resolutions(self, **params: Any) -> PaginatedResponse:
|
|
481
491
|
"""List resolutions (top-level, with filters).
|
|
482
492
|
|
|
493
|
+
Default order: assembly date, then ``number``, then ``id`` (stable
|
|
494
|
+
across pages).
|
|
495
|
+
|
|
483
496
|
Common filter kwargs (forwarded as query params):
|
|
497
|
+
company: str — ONE company UUID (a list keeps only its last
|
|
498
|
+
value; a malformed UUID is a 400). Backends older than this
|
|
499
|
+
filter ignored it silently.
|
|
484
500
|
rejected: bool — only resolutions with status=rejected.
|
|
485
501
|
narrowly_passed: bool — only accepted resolutions with
|
|
486
502
|
approval_rate strictly less than 80.
|
|
@@ -541,6 +557,7 @@ class AssemblyMixin:
|
|
|
541
557
|
def export_resolutions(
|
|
542
558
|
self,
|
|
543
559
|
*,
|
|
560
|
+
company: str | None = None,
|
|
544
561
|
date_from: str | None = None,
|
|
545
562
|
date_to: str | None = None,
|
|
546
563
|
search: str | None = None,
|
|
@@ -559,12 +576,15 @@ class AssemblyMixin:
|
|
|
559
576
|
rows without pagination.
|
|
560
577
|
|
|
561
578
|
Args:
|
|
579
|
+
company: Filter by company UUID (see ``list_resolutions``).
|
|
562
580
|
date_from: Filter by assembly date >= (``"YYYY-MM-DD"``).
|
|
563
581
|
date_to: Filter by assembly date <= (``"YYYY-MM-DD"``).
|
|
564
582
|
search: Search by text.
|
|
565
583
|
status: Filter by resolution status.
|
|
566
584
|
resolution_type: Filter by resolution type code.
|
|
567
|
-
resolution_type_search:
|
|
585
|
+
resolution_type_search: Case-insensitive substring match on the
|
|
586
|
+
type name. The server OR-combines repeated values; it does
|
|
587
|
+
not split one value on whitespace.
|
|
568
588
|
rejected: Only resolutions with status=rejected.
|
|
569
589
|
narrowly_passed: Only accepted resolutions with approval_rate < 80.
|
|
570
590
|
is_dissenting: Filter dissenting resolutions.
|
|
@@ -580,6 +600,7 @@ class AssemblyMixin:
|
|
|
580
600
|
"""
|
|
581
601
|
return self._get_export( # type: ignore[attr-defined]
|
|
582
602
|
"resolutions/export/",
|
|
603
|
+
company=company,
|
|
583
604
|
date_from=date_from,
|
|
584
605
|
date_to=date_to,
|
|
585
606
|
search=search,
|
|
@@ -10,5 +10,6 @@ class CommitteesMixin:
|
|
|
10
10
|
"""Batch upsert board committees. Each item is keyed by issuer ISIN;
|
|
11
11
|
the backend resolves members to existing persons and idempotently
|
|
12
12
|
upserts Committee + CommitteeMembership. Returns one result per item
|
|
13
|
-
(action: loaded / skipped_unknown_company /
|
|
13
|
+
(action: loaded / skipped_older_year / skipped_unknown_company /
|
|
14
|
+
error)."""
|
|
14
15
|
return self._post("committees/batch/", items) # type: ignore[attr-defined]
|
|
@@ -326,6 +326,20 @@ class TestExportResolutions:
|
|
|
326
326
|
assert kwargs["params"]["date_from"] == "2024-01-01"
|
|
327
327
|
assert kwargs["params"]["date_to"] == "2024-12-31"
|
|
328
328
|
|
|
329
|
+
def test_passes_company_filter(self):
|
|
330
|
+
c = self._client()
|
|
331
|
+
with patch("requests.request", return_value=_make_response(200, [])) as mock_req:
|
|
332
|
+
c.export_resolutions(company="uuid1")
|
|
333
|
+
_, kwargs = mock_req.call_args
|
|
334
|
+
assert kwargs["params"]["company"] == "uuid1"
|
|
335
|
+
|
|
336
|
+
def test_omits_company_when_none(self):
|
|
337
|
+
c = self._client()
|
|
338
|
+
with patch("requests.request", return_value=_make_response(200, [])) as mock_req:
|
|
339
|
+
c.export_resolutions(date_from="2024-01-01")
|
|
340
|
+
_, kwargs = mock_req.call_args
|
|
341
|
+
assert "company" not in kwargs["params"]
|
|
342
|
+
|
|
329
343
|
def test_passes_boolean_filters(self):
|
|
330
344
|
c = self._client()
|
|
331
345
|
with patch("requests.request", return_value=_make_response(200, [])) as mock_req:
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
"""Committee batch types. The nested committee/member dicts are issuer-shaped;
|
|
2
|
+
the authoritative schema lives in the extractor + apps/committees loader."""
|
|
3
|
+
|
|
4
|
+
from __future__ import annotations
|
|
5
|
+
|
|
6
|
+
import sys
|
|
7
|
+
from typing import Any
|
|
8
|
+
|
|
9
|
+
if sys.version_info >= (3, 11):
|
|
10
|
+
from typing import NotRequired, TypedDict
|
|
11
|
+
else:
|
|
12
|
+
from typing_extensions import NotRequired, TypedDict
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
class CommitteeBatchItemPayload(TypedDict):
|
|
16
|
+
company: str # issuer ISIN
|
|
17
|
+
year: int
|
|
18
|
+
committees: list[dict[str, Any]]
|
|
19
|
+
|
|
20
|
+
|
|
21
|
+
class CommitteeBatchResultItem(TypedDict):
|
|
22
|
+
company: str
|
|
23
|
+
action: str # "loaded" | "skipped_older_year" | "skipped_unknown_company" | "error"
|
|
24
|
+
# "loaded": the counters and the two name lists below.
|
|
25
|
+
committees_loaded: NotRequired[int]
|
|
26
|
+
committees_renamed: NotRequired[int]
|
|
27
|
+
memberships_loaded: NotRequired[int]
|
|
28
|
+
members_unmatched: NotRequired[int]
|
|
29
|
+
mandates_unlinked: NotRequired[int]
|
|
30
|
+
seats_closed: NotRequired[int]
|
|
31
|
+
closures_blocked: NotRequired[int]
|
|
32
|
+
closures_pending: NotRequired[int]
|
|
33
|
+
committees_absent: NotRequired[int]
|
|
34
|
+
rates_ignored: NotRequired[int]
|
|
35
|
+
members_unmatched_names: NotRequired[list[str]]
|
|
36
|
+
committees_absent_names: NotRequired[list[str]]
|
|
37
|
+
# "skipped_older_year": a committee of the company already has a source
|
|
38
|
+
# document of a later fiscal year; nothing was written.
|
|
39
|
+
newest_source_year: NotRequired[int]
|
|
40
|
+
detail: NotRequired[str]
|
|
@@ -1,27 +0,0 @@
|
|
|
1
|
-
"""Committee batch types. The nested committee/member dicts are issuer-shaped;
|
|
2
|
-
the authoritative schema lives in the extractor + apps/committees loader."""
|
|
3
|
-
|
|
4
|
-
from __future__ import annotations
|
|
5
|
-
|
|
6
|
-
import sys
|
|
7
|
-
from typing import Any
|
|
8
|
-
|
|
9
|
-
if sys.version_info >= (3, 11):
|
|
10
|
-
from typing import NotRequired, TypedDict
|
|
11
|
-
else:
|
|
12
|
-
from typing_extensions import NotRequired, TypedDict
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
class CommitteeBatchItemPayload(TypedDict):
|
|
16
|
-
company: str # issuer ISIN
|
|
17
|
-
year: int
|
|
18
|
-
committees: list[dict[str, Any]]
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
class CommitteeBatchResultItem(TypedDict):
|
|
22
|
-
company: str
|
|
23
|
-
action: str # "loaded" | "skipped_unknown_company" | "error"
|
|
24
|
-
committees_loaded: NotRequired[int]
|
|
25
|
-
memberships_loaded: NotRequired[int]
|
|
26
|
-
members_unmatched: NotRequired[list[str]]
|
|
27
|
-
detail: NotRequired[str]
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|