Connection refused on $currentUser->fetch()
Chưa có ai nhận issue này.
Đánh giá
- Độ khó
- 3/5
- Thời gian dự kiến
- 1-2 ngày
- Mức phù hợp với người mới
- 25/100
Hướng nghiên cứu
Start with the failing call in update_user.php and trace it through ParseObject.php:540 to ParseClient.php:584. Reproduce the fetch(true) path using the provided Parse PHP SDK 1.5 configuration and inspect the request endpoint and connection error. Done means determining whether the refusal is SDK behavior or an unreachable configured server, with a reproducible finding or narrowly scoped fix identified.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
Issue Description
i'm updating user informations using Parse PHP SDK the connection is 100% correct and established, i'm able to update other classes and everything fine, the problem is, when trying to update the user informations if there is error i'm doing $currentUser->fetch() which will get the current user informations without updating them incase there is error occur, and it throw the error below.
NOTE: The IP address in here is just dummy i didn't share the real one with this question.
Steps to reproduce
<?php
require 'vendor/autoload.php';
use Parse\ParseObject;
use Parse\ParseQuery;
use Parse\ParseACL;
use Parse\ParsePush;
use Parse\ParseUser;
use Parse\ParseInstallation;
use Parse\ParseException;
use Parse\ParseAnalytics;
use Parse\ParseFile;
use Parse\ParseCloud;
use Parse\ParseClient;
use Parse\ParseSessionStorage;
//use Parse\ParseQuery;
session_start();
Parse\ParseClient::initialize( 'HostAppId', 'HostRest', 'HostAppMaster');
Parse\ParseClient::setServerURL('http://1.1.1.1:1337/parse','/host');
//Parse\ParseClient::setHttpClient(new Parse\ParseCurlHttpClient());
$currentUser = Parse\ParseUser::getCurrentUser();
$currentUser->set("email", $email);
$currentUser->set("name", $name);
$email = "[email protected]";
$name = "Name ";
try {
$currentUser->save();
echo "OK";
} catch (Parse\ParseException $er) {
$ex = $er->getMessage();
echo $ex;
$currentUser->fetch(true);
}`
### Environment Details
- Your PHP Version: **7.0.31**
- Your Parse PHP SDK Version: **1.5.***
- Your Operating System: **onCatalina v 10.15.1**
### Logs/Traces
`Account already exists for this email address.<br /> <b>Fatal error</b>: Uncaught
Parse\ParseException: Failed to connect to 1.1.1.1 port 1337: Connection refused in
/Users/yousefalsbaihi/Desktop/HOST/vendor/parse/php-sdk/src/Parse/ParseClient.php:584 Stack
trace: #0 /Users/yousefalsbaihi/Desktop/HOST/vendor/parse/php-sdk/src/Parse/ParseObject.php(540):
Parse\ParseClient::_request('GET', 'classes/_User/e...', 'r:6347ca34fba62...', NULL, true) #1
/Users/yousefalsbaihi/Desktop/HOST/functions/update_user.php(35): Parse\ParseObject-
>fetch(true) #2 {main} thrown in <b>/Users/yousefalsbaihi/Desktop/HOST/vendor/parse/php-
sdk/src/Parse/ParseClient.php</b> on line <b>584</b><br />`
```
- Ngôn ngữ chính
- PHP
- Star
- 808
- Fork
- 341
- Chỉ số merge pull request
- Không có pull request nào được merge trong 30 ngày
Chuẩn bị môi trường
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của parse-community/parse-php-sdk
-
Undefined array key "result"Đang mởtype:feature
Độ khó 3/5 1-2 ngày Mức phù hợp với người mới 35/100
parse-community/parse-php-sdk#518 · 1 bình luận ·
-
bounty:$20 type:bug
Độ khó 3/5 1-2 ngày Mức phù hợp với người mới 48/100
parse-community/parse-php-sdk#516 · 5 bình luận · 1 reaction ·
-
"unauthorized: master key is required" error on aggregate ParseQuery despite the master key is setĐang mở
Độ khó 3/5 1-2 ngày Mức phù hợp với người mới 35/100
parse-community/parse-php-sdk#466 ·
-
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 25/100
parse-community/parse-php-sdk#465 ·
-
parse query for phpĐang mở
Độ khó 3/5 1-2 ngày Mức phù hợp với người mới 25/100
parse-community/parse-php-sdk#456 · 1 bình luận ·
Tất cả issue của parse-community/parse-php-sdk
Issue tương tự
-
Toolkit
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 88/100
Maintainer thường phản hồi trong vòng 1 ngày
-
[Bug] v-quick-install-app install crashes with ValueError if no supported PHP version is installedĐang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 84/100
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 88/100
langgenius/dify#43074 · 1 bình luận · 1 reaction ·
Maintainer thường phản hồi trong vòng 1 ngày
-
module: remove unused css
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 82/100
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 72/100
backdrop-contrib/field_group#99 · 2 bình luận ·