<commit_before>package io.spacedog.utils;

import com.fasterxml.jackson.databind.JsonNode;

import io.spacedog.http.SpaceException;
import io.spacedog.model.Credentials;

public class Exceptions {

	public static final String ALREADY_EXISTS = "already-exists";
	public static final String UNCHALLENGED_PASSWORD = "<PASSWORD>";
	public static final String PASSWORD_MUST_CHANGE = "<PASSWORD>";
	public static final String INVALID_AUTHORIZATION_HEADER = "invalid-authorization-header";
	public static final String DISABLED_CREDENTIALS = "disabled-credentials";
	public static final String INVALID_ACCESS_TOKEN = "invalid-access-token";
	public static final String EXPIRED_ACCESS_TOKEN = "expired-access-token";
	public static final String INVALID_CREDENTIALS = "invalid-credentials";

	public static RuntimeException runtime(String message, Object... args) {
		return new RuntimeException(String.format(message, args));
	}

	public static RuntimeException runtime(Throwable t) {
		return new RuntimeException(t);
	}

	public static RuntimeException runtime(Throwable t, String message, Object... args) {<commit_msg>Add Exceptions.unsupported(...)<commit_after>package io.spacedog.utils;

import com.fasterxml.jackson.databind.JsonNode;

import io.spacedog.http.SpaceException;
import io.spacedog.model.Credentials;

public class Exceptions {

	public static final String ALREADY_EXISTS = "already-exists";
	public static final String UNCHALLENGED_PASSWORD = "<PASSWORD>";
	public static final String PASSWORD_MUST_CHANGE = "<PASSWORD>";
	public static final String INVALID_AUTHORIZATION_HEADER = "invalid-authorization-header";
	public static final String DISABLED_CREDENTIALS = "disabled-credentials";
	public static final String INVALID_ACCESS_TOKEN = "invalid-access-token";
	public static final String EXPIRED_ACCESS_TOKEN = "expired-access-token";
	public static final String INVALID_CREDENTIALS = "invalid-credentials";

	public static RuntimeException runtime(String message, Object... args) {
		return new RuntimeException(String.format(message, args));
	}

	public static RuntimeException runtime(Throwable t) {
		return new RuntimeException(t);
	}

	public static UnsupportedOperationException unsupported(String message, Object... args) {
		return new UnsupportedOperationException(String.format(message, args));
	}

	public static RuntimeException runtime(Throwable t, String message, Object... args) {
{'fraction_non_alphanumeric': 0.08751555371215264, 'fraction_numerical': 0.0, 'mean_word_length': 6.265060240963855, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 7, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 2}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1559085', 'n_tokens_mistral': 689, 'n_tokens_neox': 665, 'n_words': 186}