GithubHelp home page GithubHelp logo

bezhansalleh / filament-exceptions Goto Github PK

View Code? Open in Web Editor NEW
138.0 138.0 22.0 155 KB

A Simple & Beautiful Pluggable Exception Viewer for FilamentPHP's Admin Panel

License: MIT License

PHP 66.80% JavaScript 1.06% CSS 9.13% Blade 23.02%
exception-reporter exception-viewer filamentadmin filamentphp laravel plugin

filament-exceptions's Introduction

🥷 Hi! My name is Bezhan

Twitter Followers Mastodon GitHub Sponsors

Git Stats

I am a full-stack developer, mainly working with Laravel, TALL stack & VueJs. I work for Roshan as an Application Developer, building innovative Applications for Mobile and Web in Telecom Industry!

🔭 I'm currently working on...

Filament Shield Filament Exceptions Filament Addons Filament Language Switch Filament Google Analytics

  • Roshan.af, a rebuild with Filament and Tailwind CSS.
  • My Roshan app, providing customers an efficient way to stay connected through Afghanistan’s largest telecommunications service provider anywhere inside the country and beyond.

filament-exceptions's People

Contributors

aminetiyal avatar bezhansalleh avatar damms005 avatar dependabot[bot] avatar fludem avatar github-actions[bot] avatar iraziul avatar josefbehr avatar marjose123 avatar martin-ro avatar minnshinsawlingmyat avatar patrickcurl avatar pxlrbt avatar ralphjsmit avatar shuvroroy avatar vanhooff avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

filament-exceptions's Issues

composer require bezhansalleh/filament-exceptions error!

our requirements could not be resolved to an installable set of packages.

Problem 1
- Root composer.json requires bezhansalleh/filament-exceptions ^1.0 -> satisfiable by bezhansalleh/filament-exceptions[1.0.0].
- bezhansalleh/filament-exceptions 1.0.0 requires bezhansalleh/filament-addons ^1.0 -> found bezhansalleh/filament-addons[dev-feature/chip-column, dev-main, v0.0.0, ..., 0.0.4] but it does not match the constraint.

Error with using multi tenant

Hey, can you add customization for isScopedToTenant in your exception resource. I need to give isScopedToTenant false.

Not enough context

This really should be a feature request, but the feature request issue creation button currently displays error 404 (screenshot attached)

The exception should display the authenticated user (like Laravel Telescope does, screenshot also attached).

image
image

SPA mode: No line numbers or syntax highlighting

Hi! I've noticed a problem with SPA mode. Line numbers and syntax highlighing aren't visible when viewing an exception. Refreshing the browser while on the exceptions page fixes the issue. I'm guessing the problem is that the assets aren't being loaded when using wire:navigate to navigate to the exceptions page.

image

Laravel 11 Error Handling

In Laravel 11 ExceptionHandler removed
What i do?

<?php

namespace App\Exceptions;

use BezhanSalleh\FilamentExceptions\FilamentExceptions;

class Handler extends ExceptionHandler
{
    ...

    public function register()
    {
        $this->reportable(function (Throwable $e) {
            if ($this->shouldReport($e)) {
                FilamentExceptions::report($e);
            }
        });

        ...
    }

Bug on publish filament component

I got error trim(): Argument #1 ($string) must be of type string, Filament\Support\Enums\IconPosition given when i published filament component with command php artisan vendor:publish filament-views.

I got this error without changes any code on filament-views component. is this possible from this package or filament it self, cause the error is coming at file resources/views/vendor/filament/components/tabs/item.blade.php in e at line 56?

Array to string error

When array exists in the elements of $values, the page errors out with ErrorException(code: 0): Array to string conversion.

Allow for custom model

Hey,

Can you allow for custom model?

I'm using multiple database tenancy so need to modify the model to use the central connection :)

Thanks

Filament v3: Missing info: Register plugin

Hi,

This plugin is missing Filament V3 installation info:

4. Register the plugin for the Filament Panel

public function panel(Panel $panel): Panel
{
    return $panel
        ->plugins([
            \BezhanSalleh\FilamentExceptions\FilamentExceptionsPlugin::make()
        ]);
}

Unsupported operand types: string + int

Description

Steps to reproduce the bug:

Use named bindings in a database query, for example:

DB::select('select * from users where id = :id', bindings: ['id' => 1])

In my case, I have a stored procedure in another Oracle OCI connection that is called in the same manner, using named bindings.

When there is a query error, the package saves the bindings, but within resources/components/query-preview.blade.php, there is a section of code that retrieves the key and adds 1:

...
@foreach ($query['bindings'] as $key => $value)
    <div class="flex px-4 py-2">
        <div class="py-2 font-mono text-gray-500 basis-1/12 dark:text-gray-400">
            {{ $key + 1 }}
        </div>
        <div
            class="px-4 py-2 font-medium text-gray-500 rounded-lg basis-11/12 dark:text-gray-200 bg-gray-950/5 dark:bg-white/5">
            {{ $value }}
        </div>
    </div>
@endforeach
...

Since the key is a string due to the named bindings, this results in an "Unsupported operand types: string + int" error.

Expected behavior:

The component should handle named bindings correctly without throwing an error.

Current behavior:

The application throws an "Unsupported operand types: string + int" error when named bindings are used and the key is a string.

Package version:

"bezhansalleh/filament-exceptions": "^2.1"

Environment:

PHP: 8.2.1
Laravel: 10.48.14
Operating System: WSL with Ubuntu 20.04

Pull Request Suggestion

To fix this issue, I suggest adding a validation to check if the key is an integer before performing the addition. Here is the proposed change:

File: resources/components/query-preview.blade.php

...
@foreach ($query['bindings'] as $key => $value)
    <div class="flex px-4 py-2">
        <div class="py-2 font-mono text-gray-500 basis-1/12 dark:text-gray-400">
            {{ is_int($key) ? ($key + 1) : $key }}
        </div>
        <div
            class="px-4 py-2 font-medium text-gray-500 rounded-lg basis-11/12 dark:text-gray-200 bg-gray-950/5 dark:bg-white/5">
            {{ $value }}
        </div>
    </div>
@endforeach
...

This modification ensures that if the key is an integer, it will be incremented by 1. If it is a string, it will be displayed as-is, preventing the "Unsupported operand types: string + int" error.

Feel free to adapt this to better fit the style and requirements of your bug report and pull request.

Sorting not working

/** Show or hide in navigation/sidebare */
'navigation_enabled' => true,

/** Sort order, if shown. No effect, if navigation_enabled it set to false. */
'navigation_sort' => 10,

Still on top.
Also how do i add this to a navigation group?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.