Skip to content

matematicsolutions/awesome-matematic-skills-pl / ochrona-danych/skills/rodo-dsar-pl

rodo-dsar-pl

Verified

Obsługa żądań osób, których dane dotyczą (DSAR) po polsku, w oparciu o art. 12 oraz 15-22 RODO. Identyfikuje typ żądania (dostęp 15, sprostowanie 16, usunięcie 17, ograniczenie 18, przenoszenie 20, sprzeciw 21, decyzje zautomatyzowane 22), pilnuje TERMINU (najpóźniej 1 miesiąc od otrzymania, art. 12 ust. 3; przedłużenie o maks. 2 miesiące z uwagi na skomplikowany charakter lub liczbę żądań), bramkuje wyjątki i podstawy odmowy (np. art. 17 ust. 3, żądania ewidentnie nieuzasadnione lub nadmierne - art. 12 ust. 5), składa draft odpowiedzi i rejestr. Weryfikacja tożsamości wnioskodawcy (art. 12 ust. 6) jako pierwszy krok. Wysyłkę odpowiedzi oraz usunięcie lub eksport danych zostawia człowiekowi. Nie dodaje konektorów i sam niczego nie wysyła; treść wniosku trafia do modelu, który masz skonfigurowany. Używaj gdy: "wniosek o dostęp do danych", "żądanie usunięcia", "prawo do bycia zapomnianym", "sprzeciw RODO", "termin na odpowiedź DSAR".

FileKindSize
LICENSEother11.1 KB
SKILL.mdskill md7.9 KB
scripts/gdpr_deadlines.pyscript4.9 KB

scripts/gdpr_deadlines.py

View on GitHub
#!/usr/bin/env python3
"""GDPR / RODO deadline calculator - deterministic, offline, zero dependencies.

Computes the outer time limits of the two GDPR clocks. Both duties also run "without undue
delay", so the computed date is the latest acceptable moment, not the target. Both results err
early, never late:

- **Breach notification (Art. 33(1))** - 72 hours from AWARENESS (the moment the controller
  became aware), not from the event. Computed as awareness + 72h; under Regulation (EEC,
  Euratom) No 1182/71 art. 3(1) the hour of awareness itself would not count.
- **Data subject request / DSAR (Art. 12(3))** - one month from RECEIPT, extendable by two
  further months. Month arithmetic per Regulation (EEC, Euratom) No 1182/71 art. 3(2)(c):
  a period in months ends on the day of the last month bearing the same number as the start
  day; if that month has no such day, it ends on the last day of that month
  (e.g. receipt 31 Jan -> one month -> 28/29 Feb). Not applied: art. 3(4), which moves a
  period ending on a Saturday, Sunday or public holiday to the next working day.

Usage:
    python gdpr_deadlines.py breach  --from "2026-06-30T14:30"
    python gdpr_deadlines.py dsar    --from 2026-01-31 [--extend]

Output is JSON. Dates are naive local-time ISO 8601; the caller supplies the timezone context.
This is a clerical aid - the legal decision (whether a deadline applies, whether to extend)
stays with the controller / DPO.
"""

from __future__ import annotations

import argparse
import calendar
import json
import sys
from datetime import datetime, timedelta


def add_months(d: datetime, months: int) -> datetime:
    """Add whole months per Reg. 1182/71 art. 3(2)(c): same day-number, clamped to month end."""
    total = d.month - 1 + months
    year = d.year + total // 12
    month = total % 12 + 1
    last_day = calendar.monthrange(year, month)[1]
    day = min(d.day, last_day)
    return d.replace(year=year, month=month, day=day)


def breach_deadline(awareness: datetime) -> dict:
    deadline = awareness + timedelta(hours=72)
    return {
        "regime": "breach_notification",
        "basis": "RODO/GDPR art. 33(1) - 72h od stwierdzenia / from awareness",
        "awareness": awareness.isoformat(),
        "deadline_72h": deadline.isoformat(),
        "note": "PL: zegar startuje od STWIERDZENIA naruszenia, nie od zdarzenia; zglos bez "
                "zbednej zwloki - 72h to granica, nie cel; po 72h zglos z wyjasnieniem opoznienia "
                "(art. 33 ust. 1 zd. 2). "
                "EN: the clock starts on AWARENESS, not the event; notify without undue delay - "
                "72h is the outer limit, not the target; after 72h, notify with reasons for the "
                "delay (art. 33(1) sent. 2).",
    }


def dsar_deadline(receipt: datetime, extend: bool) -> dict:
    base = add_months(receipt, 1)
    out = {
        "regime": "data_subject_request",
        "basis": "RODO/GDPR art. 12(3) - 1 miesiac od otrzymania / from receipt",
        "receipt": receipt.isoformat(),
        "deadline_1_month": base.isoformat(),
    }
    if extend:
        out["deadline_extended_3_months"] = add_months(receipt, 3).isoformat()
        out["note"] = ("PL: przedluzenie o max 2 miesiace, gdy to konieczne ze wzgledu na "
                       "skomplikowany charakter lub liczbe zadan - poinformuj osobe w ciagu "
                       "PIERWSZEGO miesiaca z podaniem przyczyn opoznienia (art. 12 ust. 3). "
                       "EN: extension of up to 2 months where necessary, taking into account the "
                       "complexity and number of the requests - inform the person within the FIRST "
                       "month, with the reasons for the delay (art. 12(3)).")
    return out


def _parse(s: str) -> datetime:
    for fmt in ("%Y-%m-%dT%H:%M:%S", "%Y-%m-%dT%H:%M", "%Y-%m-%d %H:%M", "%Y-%m-%d"):
        try:
            return datetime.strptime(s, fmt)
        except ValueError:
            continue
    raise SystemExit(f"error: nieczytelna data {s!r}; uzyj ISO 8601 (YYYY-MM-DD lub YYYY-MM-DDTHH:MM)")


def main(argv: list[str] | None = None) -> int:
    p = argparse.ArgumentParser(description="GDPR/RODO deadline calculator")
    sub = p.add_subparsers(dest="regime", required=True)
    b = sub.add_parser("breach", help="72h breach notification (art. 33)")
    b.add_argument("--from", dest="frm", required=True, help="awareness time, ISO 8601")
    d = sub.add_parser("dsar", help="data subject request (art. 12(3))")
    d.add_argument("--from", dest="frm", required=True, help="receipt date, ISO 8601")
    d.add_argument("--extend", action="store_true", help="apply the +2 month extension")
    args = p.parse_args(argv)

    when = _parse(args.frm)
    if args.regime == "breach":
        result = breach_deadline(when)
    else:
        result = dsar_deadline(when, args.extend)
    print(json.dumps(result, ensure_ascii=False, indent=2))
    return 0


if __name__ == "__main__":
    sys.exit(main())
slack-gif-creatoranthropics/skillsKnowledge and utilities for creating animated GIFs optimized for Slack. Provides constraints, validation tools, and animation concepts. Use when users request animated GIFs for Slack like "make me a GIF of X doing Y for Slack."Stars: 198kUpdated Claude CodeCodexVerifiedInstall
ponytailDietrichGebert/ponytailLazy senior dev mode for any coding task: the smallest change that fully solves it, and a reply a busy human understands in one read.Stars: 194kUpdated Claude CodeCodexVerifiedInstall
ponytail-debtDietrichGebert/ponytailHarvest every shortcut: comment into one debt ledger, so deferrals get tracked instead of forgotten. One-shot report.Stars: 194kUpdated Claude CodeCodexVerifiedInstall
ponytail-debtDietrichGebert/ponytailList every `shortcut:` comment (and older `ponytail:` ones) as a debt ledger. One-shot report, changes nothing. Use for "ponytail debt", "what did ponytail defer", "list the shortcuts", /ponytail-debt.Stars: 194kUpdated Claude CodeCodexVerifiedInstall