领券联盟code是404,请求失败是url的问题么??
2022-03-16 18:41:47.547 4610-4610/? I/Zygote: seccomp disabled by setenforce 0
2022-03-16 18:41:47.548 4610-4610/? I/example.taobao: Late-enabling -Xcheck:jni
2022-03-16 18:41:47.566 4610-4610/? W/example.taobao: Unexpected CPU variant for X86 using defaults: x86_64
2022-03-16 18:41:48.087 4610-4610/com.example.taobaou I/example.taobaou: type=1400 audit(0.0:1820): avc: denied { open } for path="/dev/__properties__/u:object_r:firstboot_prop:s0" dev="tmpfs" ino=6223 scontext=u:r:untrusted_app:s0:c49,c256,c512,c768 tcontext=u:object_r:firstboot_prop:s0 tclass=file permissive=1
2022-03-16 18:41:48.087 4610-4610/com.example.taobaou I/example.taobaou: type=1400 audit(0.0:1821): avc: denied { getattr } for path="/dev/__properties__/u:object_r:firstboot_prop:s0" dev="tmpfs" ino=6223 scontext=u:r:untrusted_app:s0:c49,c256,c512,c768 tcontext=u:object_r:firstboot_prop:s0 tclass=file permissive=1
2022-03-16 18:41:48.087 4610-4610/com.example.taobaou I/example.taobaou: type=1400 audit(0.0:1822): avc: denied { map } for path="/dev/__properties__/u:object_r:firstboot_prop:s0" dev="tmpfs" ino=6223 scontext=u:r:untrusted_app:s0:c49,c256,c512,c768 tcontext=u:object_r:firstboot_prop:s0 tclass=file permissive=1
2022-03-16 18:41:48.143 4610-4610/com.example.taobaou W/example.taobao: Accessing hidden method Landroid/graphics/drawable/Drawable;->getOpticalInsets()Landroid/graphics/Insets; (light greylist, linking)
2022-03-16 18:41:48.143 4610-4610/com.example.taobaou W/example.taobao: Accessing hidden field Landroid/graphics/Insets;->left:I (light greylist, linking)
2022-03-16 18:41:48.143 4610-4610/com.example.taobaou W/example.taobao: Accessing hidden field Landroid/graphics/Insets;->right:I (light greylist, linking)
2022-03-16 18:41:48.143 4610-4610/com.example.taobaou W/example.taobao: Accessing hidden field Landroid/graphics/Insets;->top:I (light greylist, linking)
2022-03-16 18:41:48.143 4610-4610/com.example.taobaou W/example.taobao: Accessing hidden field Landroid/graphics/Insets;->bottom:I (light greylist, linking)
2022-03-16 18:41:48.165 4610-4610/com.example.taobaou W/example.taobao: Accessing hidden method Landroid/view/View;->computeFitSystemWindows(Landroid/graphics/Rect;Landroid/graphics/Rect;)Z (light greylist, reflection)
2022-03-16 18:41:48.166 4610-4610/com.example.taobaou W/example.taobao: Accessing hidden method Landroid/view/ViewGroup;->makeOptionalFitsSystemWindows()V (light greylist, reflection)
2022-03-16 18:41:48.213 4610-4610/com.example.taobaou W/example.taobao: Accessing hidden method Landroid/widget/TextView;->getTextDirectionHeuristic()Landroid/text/TextDirectionHeuristic; (light greylist, linking)
2022-03-16 18:41:48.335 4610-4610/com.example.taobaou D/NetworkSecurityConfig: No Network Security Config specified, using platform default
2022-03-16 18:41:48.336 4610-4610/com.example.taobaou W/example.taobao: Accessing hidden method Lcom/android/org/conscrypt/OpenSSLSocketImpl;->setUseSessionTickets(Z)V (light greylist, reflection)
2022-03-16 18:41:48.336 4610-4610/com.example.taobaou W/example.taobao: Accessing hidden method Lcom/android/org/conscrypt/OpenSSLSocketImpl;->setHostname(Ljava/lang/String;)V (light greylist, reflection)
2022-03-16 18:41:48.336 4610-4610/com.example.taobaou W/example.taobao: Accessing hidden method Lcom/android/org/conscrypt/OpenSSLSocketImpl;->getAlpnSelectedProtocol()[B (light greylist, reflection)
2022-03-16 18:41:48.336 4610-4610/com.example.taobaou W/example.taobao: Accessing hidden method Lcom/android/org/conscrypt/OpenSSLSocketImpl;->setAlpnProtocols([B)V (light greylist, reflection)
2022-03-16 18:41:48.336 4610-4610/com.example.taobaou W/example.taobao: Accessing hidden method Ldalvik/system/CloseGuard;->get()Ldalvik/system/CloseGuard; (light greylist, reflection)
2022-03-16 18:41:48.336 4610-4610/com.example.taobaou W/example.taobao: Accessing hidden method Ldalvik/system/CloseGuard;->open(Ljava/lang/String;)V (light greylist, reflection)
2022-03-16 18:41:48.337 4610-4610/com.example.taobaou W/example.taobao: Accessing hidden method Ldalvik/system/CloseGuard;->warnIfOpen()V (light greylist, reflection)
2022-03-16 18:41:48.352 4610-4610/com.example.taobaou D/OpenGLRenderer: Skia GL Pipeline
2022-03-16 18:41:48.421 4610-4650/com.example.taobaou I/ConfigStore: android::hardware::configstore::V1_0::ISurfaceFlingerConfigs::hasWideColorDisplay retrieved: 0
2022-03-16 18:41:48.422 4610-4650/com.example.taobaou I/ConfigStore: android::hardware::configstore::V1_0::ISurfaceFlingerConfigs::hasHDRDisplay retrieved: 0
2022-03-16 18:41:48.422 4610-4650/com.example.taobaou I/OpenGLRenderer: Initialized EGL, version 1.4
2022-03-16 18:41:48.422 4610-4650/com.example.taobaou D/OpenGLRenderer: Swap behavior 1
2022-03-16 18:41:48.513 4610-4650/com.example.taobaou D/vndksupport: Loading /vendor/lib64/hw/android.hardware.graphics.mapper@2.0-impl.so from current namespace instead of sphal namespace.
2022-03-16 18:41:48.514 4610-4650/com.example.taobaou D/vndksupport: Loading /vendor/lib64/hw/gralloc.sdm845.so from current namespace instead of sphal namespace.
2022-03-16 18:41:48.678 4610-4610/com.example.taobaou D/Constraints: code is -->404
2022-03-16 18:41:48.678 4610-4610/com.example.taobaou D/Constraints: 请求失败........
下面是我的url
package com.example.taobaou.utils;
public class Constants {
public static final String BASE_URL = "https://api.sunofbeaches.com/shop/";
}
如果不是url的问题应该是什么问题?
请求的完整URL发出来康康?
我用postman测的结果一样,估计是路径挂了,你可以用postman试试,因为有些参数可能没贴出来
先模拟请求再写代码吧。用Postman