Comments (5)
weird MySQL behaviour
Ack, other databases don't have this, which are supported by ide-helper too. E.g. pgsql does not have this issue; so any change has to be considered carefully.
For one, using pgsql, I stopped using these migrations in my code base where I could and replaced them with more explicit, not null, types (basically timestampTz()
)
Or maybe check in migrations
That would a "big thing" IMHO, because ide-helper is not concerned with migrations. It purely works on the actual database.
IMHO it feels wrong to not have the field reflect the nullable, when in fact the database colum is nullable.
Can you use the hooks feature in ide-helper to change this for your project?
from laravel-ide-helper.
IMHO it feels wrong to not have the field reflect the nullable, when in fact the database colum is nullable.
I'd usually agree, but this case is very different. Given that 99.9999% of projects will not null those timestamps, I think the default shouldn't be for the vast majority to null-check them. Maybe this could be a config setting for those few that want nullable timestamps?
from laravel-ide-helper.
I added a hook for now but would be happy to see this. I can see if I can help with a PR if it's wanted.
from laravel-ide-helper.
Can only try to share my point of view once more:
- ide-helper should reflect the technical possibility/constraints
- the issue seems driver specific
- we've made hooks exactly for this
I simply think the additional complexity for this feature doesn't need to be in ide-helper 🤷🏼
from laravel-ide-helper.
I get your point. Didn't take me long to create a hook for it. Just thought others could benefit from it, given that the vast majority of users will have the same setup.
from laravel-ide-helper.
Related Issues (20)
- Exception: No query results for model inside on mutator or accessor HOT 5
- ide-helper not showing all suggested methods while use PHP Intelephense v1.10.4
- VsCode Go to definition not working
- ReflectionException in Alias::getMacroFunction HOT 1
- Phpstorm Redis Can you identify
- Unknown Column HOT 5
- Incorrect type for nullable morph HOT 3
- Two blank docblock lines in model HOT 1
- Thread docs bloks as primary source of type
- Defining database in $table no longer works? HOT 2
- Support for casts AsEnumCollection HOT 3
- php artisan ide-helper:meta throws error PHP Warning: Trying to access array offset on value of type null HOT 2
- Expected type 'iterable'. Found 'Illuminate\Database\Query\iterable'. HOT 3
- newQuery and newModelQuery are not static methods
- MySqlGrammar: : compileColumns function for mariadb and mysql information_schema. The columns structure difference is an error HOT 1
- Json mysql column is translated as mixed instead of string
- As a Developer working on Windows I want the Line-Endings inside the generated PHP Doc to be CRLF HOT 3
- Exception: Method MongoDB\Laravel\Schema\Grammar::compileColumns does not exist. HOT 1
- Macro on HttpClient does not return correct Return statement
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from laravel-ide-helper.