Skip to content

v0.2.7

Choose a tag to compare

@github-actions github-actions released this 06 Oct 21:49
· 114 commits to main since this release
Add France Télévisions, with France 2 and four more channels

France Télévisions, the French public broadcaster, streams its
channels on france.tv. telesfor now offers France 2, France 3,
France 4, France 5 and franceinfo from a tuner of their own at
/francetv, numbered from 4001. None of it takes an account.

The guide is the one france.tv's own is made of, a day of a channel
at a time. It has what a channel shows and when, but calls a
programme by its episode alone, such as "Émission du mercredi 7
octobre 2026". The name of the programme comes from the API of
France Télévisions' apps, which keeps a programme at a path that the
guide does not give. So the provider asks what is at every path the
programme may be at, under the address of its episodes' pages or
under its own name, until the answer has the id the guide has for
it, and remembers the answer. A guide asked for while another's
programmes are looked up waits for them. A programme found nowhere
goes by the name the guide has for its statistics, as "Dans le
retro". The episode's name is the first line of the description, and
a programme's poster is its upright one.

The guide's starts and lengths do not add up: lengths are those of
recordings or of slots, and what comes between programmes is not
listed. A programme ends where the next one starts, unless that is
more than twenty minutes after its own end, and a programme listed
twice a minute or two apart is kept once. Where nothing is listed,
the guide has the channel's name, an hour at a time.

Tuning asks the apps' API for the channel's live video, the player's
API where its stream is, and for a pass to it, which stands in the
path of every address of the stream. It then looks at the stream's
best quality and at its newest segment: the playlists are handed out
anywhere, the picture and the sound only in France, all but
franceinfo's. A channel that is blocked abroad, refused, unavailable
or DRM-protected is told apart, and -francetv-proxy takes a proxy
with a French exit.

ffmpeg reads the stream through a transport of the provider's:

- It is handed the best quality and the French sound only. Given
  the whole master playlist, it would read the start of six
  qualities, three sounds and the subtitles, each with a playlist of
  four hours.
- Playlists are asked for whole rather than by range, so that they
  come compressed: 640 kB of playlist is 14 kB on the wire, every
  few seconds.
- France 4's and franceinfo's playlists name their key by its full
  address, which ffmpeg would ask for itself, past the relay and the
  proxy, and be refused. It is named by its path instead.
- A pass lasts six hours. A request that is refused is sent again
  with a new one, which the requests after it go with.

The daily check of the providers' real sites now checks France
Télévisions' as well.

- internal/provider/francetv: the provider, its tests and a live
  test.
- cmd/telesfor/main.go: france.tv's tuner and -francetv-proxy.
- .github/workflows/live.yml: the daily check, for france.tv too.
- README.md, docs/usage.md, docs/development.md,
  packaging/linux/telesfor.env: france.tv, its guide, its proxy and
  its live delay.