Seems like the post() method of FluentLogger can not handle numeric arrays
Nobody has claimed this yet.
Assessment
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Newbie friendliness
- 45/100
- Issue type
- Bug
- Clarity
- Mostly clear
- Activity status
- Stale
- Tech stack
- php
- Domain
- observability-sre
Research direction
Start at FluentLogger::post and follow how the Entity is constructed and serialized. Reproduce the behavior with arrays using numeric indices, then determine whether the conversion belongs in post() or the Entity path. Done means numeric-indexed posted data is handled correctly and the behavior is covered by an appropriate test.
Written by the indexing model from the issue text.
Description
This problem was costing me some time to find that only string indicies in the array are allowed:
/**
* send a message to specified fluentd.
*
* @param string $tag
* @param array $data
* @return bool
*
* @api
*/
public function post($tag, array $data)
{
$entity = new Entity($tag, $data);
return $this->postImpl($entity);
}
I do now know the exact reason for this behaviour, but can you please just apply PHPs strval() function for posted arrays with numeric indicies?
If this problem does not result from the library (I am not 100% sure) please sorry for bothering the wrong implementors ;-)
- Dominant language
- PHP
- Stars
- 218
- Forks
- 58
- PR merge metrics
- No merged PRs in 30d
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from fluent/fluent-logger-php
-
Difficulty 2/5 1-3 hours Newbie friendliness 52/100
fluent/fluent-logger-php#71 · 1 comment ·
-
Difficulty 5/5 Over a week Newbie friendliness 10/100
fluent/fluent-logger-php#69 · 2 reactions ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 42/100
fluent/fluent-logger-php#67 · 5 comments ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 45/100
fluent/fluent-logger-php#66 ·
-
Difficulty 4/5 3-5 days Newbie friendliness 20/100
fluent/fluent-logger-php#58 ·
All issues in fluent/fluent-logger-php
Similar issues
-
priority: p3
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
googleapis/librarian#7636 ·
-
0. Needs triage bug
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
nextcloud/fulltextsearch#1011 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 84/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
phpstan/phpstan-doctrine#794 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 74/100
Automattic/static-site-importer#1767 ·