mathroc
Repos
160
Followers
23
Following
8

Option & Result types for PHP

5
2

Test code examples in PHP comments

8
1

Locking, the easy way

27
6

Phan is a static analyzer for PHP.

Events

pull request opened
Update on how to handle multi lines in control structures

let me know if you think something like this should be done.

the first thing I wanted to take care of was to allow to break a function call or an array into multiple line in a control structures expression without having to switch to full multi line mode for the expression

and I also noticed a case where multi line could be authorized for catch expression with multiple union'ed types

Created at 17 hours ago

Update on how to handle multi lines in control structures

Created at 17 hours ago
Created at 17 hours ago
issue comment
Add Attributes style guide

Ignoring the existence of compound attributes is not viable, and forbidding the use of a valid language feature is also not viable

What makes this a feature that can't be ignored? For example, having a comma after the last item of an array is a valid construct even if it's on a single line. What makes those different? It's not like there's no alternative to compound attributes, right?

Created at 1 week ago
issue comment
Add test to reproduce bug #22

Apparently, this is fixed in 3.1.4

Created at 1 week ago
opened issue
Check that Exception are chained

Feature request

When going through crash reports (eg: on Sentry) I often find that the Exception I see is not the original one and that the previous one has been swallowed and not chained.

I'd like PHPStan to tell me when, inside a catch block, an exception is thrown that don't chain the previous exception with the new one (if the new Exception accept a compatible $previous argument)

And, for Exceptions defined in my project to tell me when the constructor don't expose a \Throwable $previous argument

Created at 1 week ago

2022-07-20 23:47:34 UTC

Increment from deprecated EAPI

Merge updates from master

2022-07-22 23:01:38 UTC

2022-07-24 01:07:15 UTC

2022-07-24 18:03:40 UTC

2022-07-24 22:47:55 UTC

2022-07-26 05:02:30 UTC

2022-07-26 06:47:12 UTC

2022-08-02 04:17:45 UTC

2022-08-07 20:32:15 UTC

2022-08-07 21:47:00 UTC

2022-08-14 22:32:01 UTC

2022-08-15 14:16:50 UTC

2022-08-22 20:16:54 UTC

2022-08-24 05:02:59 UTC

2022-09-03 18:47:02 UTC

2022-09-04 19:46:59 UTC

2022-09-07 08:26:19 UTC

2022-09-12 19:25:36 UTC

Created at 2 weeks ago
issue comment
Make NoPrivateNetworkHttpClient & proxy usage work better together

the logic to retrieve the proxy is known (it's either in the options or in the env).

It's not that easy, there's HTTP_PROXY, HTTPS_PROXY, ALL_PROXY. Those, combined with redirections, would already mean that I can't know if the proxy will be used or not after a redirection if the scheme changes. And then there's also NO_PROXY which means I can't know if the proxy will be ignored before I know the URL (and its redirections)

In addition, we could define a set of hosts that should be rejected btw. This would allow forbidding internals hosts that could still be hit via the proxy. That would be just a regexp given as constructor argument.

Could we do the opposite: use the NoPrivateNetworkHttpClient but whitelist a few IPs for the proxies with a constructor argument? (array of IPs?)

Created at 2 weeks ago
issue comment
Make NoPrivateNetworkHttpClient & proxy usage work better together

In my use case, I learned that it was using a proxy when the code was deployed to production. :boom:

now that I know that we removed the NoPrivateNetworkHttpClient wrapper and I hope the proxy will never be removed, so I don't mind too much whether this issue is fixed or not. Just wanted to suggest what, I hope, would be an improvement :)

Created at 2 weeks ago

add fluidsynth web ui

fix name...

add balena.yml

Update README.md

Update main.yml

build for 32bits & 64bits fleets

Update main.yml

Update main.yml

Created at 3 weeks ago
opened issue
Make NoPrivateNetworkHttpClient & proxy usage work better together

Description

When using the NoPrivateNetworkHttpClient and there is a proxy set (eg: auto-discovered with the HTTPS_PROXY env var), if the proxy is local the request is blocked by the NoPrivateNetworkHttpClient.

I believe it would make sense to automatically authorize the proxy in this case, or skip the NoPrivateNetworkHttpClient entirely.

It's hard to figure out if we should skip adding NoPrivateNetworkHttpClient because the HttpClientInterface can't tell us if it's using a proxy or not. Even getting the inner client options and reproducing the logic it uses to figure out if and which proxy to use is not easy.

Ideally, the NoPrivateNetworkHttpClient could ask the inner client if it's using a proxy or not and not do anything when a proxy is used.

Example

No response

Created at 1 month ago
started
Created at 1 month ago

Fix few documentation typos (#12)

Fix few typos

Created at 1 month ago
pull request closed
Fix few documentation typos
Created at 1 month ago
issue comment
Fix few documentation typos

thank you!

Created at 1 month ago
delete branch
mathroc delete branch doc/improve-layout
Created at 1 month ago
pull request closed
doc: improve layout & navigation
Created at 1 month ago

doc: improve layout & navigation

Created at 1 month ago
pull request opened
doc: improve layout & navigation
Created at 1 month ago

doc: improve layout & navigation

Created at 1 month ago
create branch
mathroc create branch doc/improve-layout
Created at 1 month ago
delete branch
mathroc delete branch doc/improve-homepage
Created at 1 month ago
pull request closed
Add usage examples to documentation homepage
Created at 1 month ago

Add usage examples to documentation homepage

Created at 1 month ago
pull request opened
Add usage examples to documentation homepage
Created at 1 month ago