Impossible to invoke a method ("url") on a null variable.
<section class="spectacle-content-section">
{% if pressLinks is not empty or pdfLinks is not empty or associatedArtists is not empty %}
<div class="artiste-block">
<ul class="list-unstyled badge-list">
{% for associatedArtist in associatedArtists %}
{% set asAr = site.find("artistes").children().listed().findBy('uid', associatedArtist.associated_artist) %}
<li><a class="badge badge-xl rounded-pill" href="{{ asAr.url() }}">{{ asAr.title }}</a></li>
{% endfor %}
{% for pressLink in pressLinks %}
<li><a class="badge badge-xl rounded-pill" href="{{ pressLink.press_url() }}" target="_blank">{{ pressLink.press_text() }}</a></li>
{% endfor %}
{% for pdfLink in pdfLinks %}
<li><a class="badge badge-xl rounded-pill" href="{{ pdfLink.pdf_content().toFile().url() }}" target="_blank">{{ pdfLink.pdf_text() }}</a></li>