---
title: "TYPO3 Exception 1176558158"
manual: "TYPO3 Exceptions"
version: "main"
permalink: "https://docs.typo3.org/permalink/t3exceptions:typo3-exception-1176558158"
source: "Exceptions/1176558158.rst"
rendered: "2026-09-24T13:19:33+00:00"
---

# TYPO3 Exception 1176558158 {#typo3-exception-1176558158}

> [!NOTE]
> Below, the TYPO3 community may have provided additional information or
> solutions for this exception. However, these may or may not apply to your
> particular case. If you can provide more information, you should come back
> here and add your experience and solution steps to this issue once you have
> resolved it.
>
> General TYPO3 troubleshooting tips can be found in the *Troubleshooting*
> section in the menu. You can also ask questions and receive support in the
> [TYPO3 Questions category on talk.typo3.org](https://talk.typo3.org/c/typo3-questions/).
>
> To add your experience, click "Edit on GitHub" above and follow the
> ["Edit on GitHub" workflow](https://docs.typo3.org/m/typo3/docs-how-to-document/main/en-us/Howto/EditOnGithub.html#docs-contribute-github-method).
> Also check out
> [our tip on Coding Style and reST](https://docs.typo3.org/permalink/t3exceptions:tip-about-rest-coding-style).

## TYPO3 11.5.21 -03.01.2023 {#typo3-11-5-21-03-01-2023}

```none
An argument "site" does not exist for this request.
```

### Situation {#situation}

This happens when you call the following in an action of an Extbase controller:

```php
$site =  $this->request->getArgument('site');
```

### Solution {#solution}

You must retrieve the site configuration with `getAttribute()` not `getArgument`:

```php
$site =  $this->request->getAttribute('site');
```

## TYPO3 12.4.3 - 24.07.23 {#typo3-12-4-3-24-07-23}

> [!CAUTION]
> **Error**
>
> An argument "currentContentObject" does not exist for this request.

### Situation {#situation-1}

This error was thrown in the `\TYPO3\CMS\Extbase\Mvc\Web\Routing\UriBuilder` when calling it from a non-Extbase context

### Solution {#solution-1}

Pass the current request object to the UriBuilder:

```php
$uri = $uriBuilder->reset()
        ->setRequest($this->getExtbaseRequest())
        ->setTargetPageUid(188)
        // ...
        ->build();
```

See also [Generating URLs with the UriBuilder](https://docs.typo3.org/m/typo3/reference-coreapi/main/en-us/ExtensionArchitecture/Extbase/Routing/UriBuilder.html#extbase-uri-builder).
