All notable changes to the Algeria Medicines Register Actor.
- Rows are pushed while the run reads, not at the end. Each sheet's products
go out in 500-row chunks as they are built (
EMIT_CHUNK), so a reader
watching the dataset sees products within seconds and a version: all run
fills one workbook after another. Buffering the run and pushing once at the
end showed nothing until everything was done.
- The proxy is not optional, and the copy no longer suggests it is. Runs
execute on the platform, where a direct connection to the Ministry's site is
refused; "turn it off if you are in Algeria" described a path a buyer cannot
take. The setting stays configurable for a caller who has their own Algerian
proxy, and the default is unchanged.
- The status message is written before the process ends.
Actor.exit({statusMessage})
races its API write against a 1 ms sleep, so a run that failed in seconds
finished with an empty status message — the one field a launcher reads. The
message is now written explicitly, and a successful run carries its row counts
(9,595 product row(s) from 1 workbook(s) / 3 sheet(s)…).
- The site refuses everyone outside Algeria, so the Actor routes itself. On
the platform, a direct run hung at the first request: the hostname resolves
from anywhere, but TCP 443 times out from Apify and from Google Cloud while
the same call succeeds from Algeria and through an Algerian residential
proxy.
proxyConfiguration now defaults to an Algerian residential address,
and {useApifyProxy: false} is the explicit opt-out for callers whose own
connection is already in Algeria.
- A blocked run says why, within about a minute. The page is bounded at
30 s per attempt (a TCP connect that is silently dropped ignores the request
timeout — measured 131 s for a 30 s budget, so the deadline is enforced with
an abort), a connection failure is retried once, and the run then surfaces
UnreachableError — "answers Algerian addresses only, enable the Algerian
residential proxy" — instead of hanging on a geographic block.
- Renamed.
MIPH Nomenclature Scraper → Algeria Medicines Register
Scraper (algeria-medicines-register-scraper). The Ministry's acronym says
nothing about what the data is; the new name leads with country and subject.
- No moving counts in the Store copy. The listing no longer states a
particular edition or its row counts — those change every month. It now
describes what a run returns (one row per product on every sheet, the register
plus its annexes) rather than how large one edition happened to be.
First release (as miph-nomenclature-scraper).
- Two modes.
files lists the workbooks the nomenclature page publishes
(monthly editions, 2 standing annexes, the per-year registered lists);
medicines downloads them and reads every product on every sheet — at
release, the newest edition yielded 9,595 rows (5,425 current, 1,491
non-renewed, 2,679 withdrawn).
- Version selection.
version takes latest, all, registered, a year
(2025) or one version (2025-12); an unpublished value fails the run and
names what exists. fileUrls reads workbooks given by hand and skips
discovery.
- Columns by heading, not by position. The header sits on row 11, 12, 13 or
17 depending on the edition, and the withdrawal sheet does not share the
nomenclature sheet's column set — so every column is mapped by its own header
text (
CONDITIONNEMENT and COND both land on packaging).
- Dates as dates. Excel serials become
YYYY-MM-DD, with the printed
dd/mm/yyyy beside them; a non-date in a date column keeps its text and gets
no invented value.
- Self-checking. The row count the sheet's title claims is compared with
what was read (they match for the August 2026 edition), and a run that
collects nothing fails with the cause in its status message instead of
finishing
SUCCEEDED on an empty dataset.
- Links, no binaries. No workbook is stored; every medicine row carries the
URL it came from.