Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix Deprecated Warning in Doctor.php #8105

Conversation

xuelink
Copy link
Contributor

@xuelink xuelink commented May 8, 2024

What does this PR do?

This PR addresses the deprecated warning messages in the Doctor.php file. It resolves the issue of implicit conversion from float to int, which was causing precision loss and generating warnings. The fix ensures that the codebase maintains compatibility and eliminates the warnings, improving the overall code quality and maintainability.

BEFORE

Deprecated: Implicit conversion from float 0.2 to int loses precision in /usr/src/code/src/Appwrite/Platform/Tasks/Doctor.php on line 112

[Connectivity]
🟢 Console.DB(console)...............................connected
🟢 Projects.DB(database_db_main).....................connected
🟢 Cache(cache_redis_main)...........................connected
🟢 Queue(queue)......................................connected
🟢 PubSub(pubsub)....................................connected
🟢 SMTP..............................................connected

Deprecated: Implicit conversion from float 0.2 to int loses precision in /usr/src/code/src/Appwrite/Platform/Tasks/Doctor.php on line 197

[Volumes]
🟢 Uploads Volume is readable
🟢 Uploads Volume is writeable
🟢 Cache Volume is readable
🟢 Cache Volume is writeable
🟢 Config Volume is readable
🟢 Config Volume is writeable
🟢 Certs Volume is readable
🟢 Certs Volume is writeable

Deprecated: Implicit conversion from float 0.2 to int loses precision in /usr/src/code/src/Appwrite/Platform/Tasks/Doctor.php on line 225

[Disk Space]
🟢 Uploads Volume has 43.20GB free space (31.07% used)
🟢 Cache Volume has 43.20GB free space (31.07% used)
🟢 Config Volume has 43.20GB free space (31.07% used)
🟢 Certs Volume has 43.20GB free space (31.07% used)

AFTER

[Connectivity]
🟢 Console.DB(console)...............................connected
🟢 Projects.DB(database_db_main).....................connected
🟢 Cache(cache_redis_main)...........................connected
🟢 Queue(queue)......................................connected
🟢 PubSub(pubsub)....................................connected
🟢 SMTP..............................................connected

[Volumes]
🟢 Uploads Volume is readable
🟢 Uploads Volume is writeable
🟢 Cache Volume is readable
🟢 Cache Volume is writeable
🟢 Config Volume is readable
🟢 Config Volume is writeable
🟢 Certs Volume is readable
🟢 Certs Volume is writeable

[Disk Space]
🟢 Uploads Volume has 43.20GB free space (31.07% used)
🟢 Cache Volume has 43.20GB free space (31.07% used)
🟢 Config Volume has 43.20GB free space (31.07% used)
🟢 Certs Volume has 43.20GB free space (31.07% used)

Test Plan

docker compose exec appwrite doctor

Related PRs and Issues

  • No Issue

Checklist

  • Have you read the Contributing Guidelines on issues?
  • If the PR includes a change to an API's metadata (desc, label, params, etc.), does it also include updated API specs and example docs?

@xuelink xuelink changed the title chore: Improve sleep duration in Doctor.php Fix Deprecated Warning in Doctor.php May 8, 2024
@stnguyen90 stnguyen90 added the community PR or issues handled by the community members who may need guidance from core label May 8, 2024
@stnguyen90 stnguyen90 self-requested a review May 8, 2024 23:46
@stnguyen90 stnguyen90 merged commit 5e8a18e into appwrite:main May 9, 2024
23 checks passed
@xuelink xuelink deleted the cicd-fix-float-to-int-conversion-warning-at-appwrite-doctor branch May 9, 2024 10:43
This was referenced May 15, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
community PR or issues handled by the community members who may need guidance from core
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

None yet

2 participants