driade / phpfmt8

PHP formatter for Sublime Text 4, with PHP 8 support.
BSD 3-Clause "New" or "Revised" License
45 stars 2 forks source link

Troubleshoot information: phpfmt (fmt.stub.php version) err: #75

Open MarketHubb opened 5 months ago

MarketHubb commented 5 months ago

I followed the setup wizard and built a database at /phpfmt. The command appeared to work, but when I run a command like analyze this, I keep getting the "Autocomplete and autoimport need building a database of terms."

I then ran the "troubleshoot information" and there appears to be an issue with the fmt.stub.php version and I'm not sure where or how to set that.

phpfmt.sublime-settings

// Settings in here override those in "/phpfmt/phpfmt.sublime-settings",

{
    "autocomplete": true,
    "php_bin": "/Users/chris/Library/Application Support/Herd/bin/php",
}

Output from "troubleshoot information"

phpfmt (php version):
PHP 8.2.15 (cli) (built: Jan 19 2024 00:15:08) (NTS)
Copyright (c) The PHP Group
Zend Engine v4.2.15, Copyright (c) Zend Technologies
with Zend OPcache v8.2.15, Copyright (c), by Zend Technologies

phpfmt (php tokenizer) found

phpfmt (fmt.stub.php version):
phpfmt (fmt.stub.php version) err:
Formatting ...
0

0 files total
Took 0s

A snippet of the phpfmt/oracle.sqlite.

Screenshot 2024-04-10 at 2 44 58 PM
driade commented 5 months ago

Hi. If you run the command "build autocomplete database" from Sublime panel, does it works?

MarketHubb commented 5 months ago

@driade

I believe so. That screenshot of "A snippet of the phpfmt/oracle.sqlite" is the output of that command. Although, admittedly, I'm not entirely sure how that's supposed to look/format.

I can tell you that, even with the oracle.sqlite file in place, whenever I try to run a command (i.e analyze this), the package re-prompts me to create an auto-complete database.

Do I need to update my phpfmt.sublime-settings file to tell the package where that file lives, or does the build autocomplete database command save that?