我正在研究一个django项目,因为几天后django在我更改源文件后不断记录我.
Cookie和数据库中的过期日期显示还有1个月.
即使在进行更改后,会话cookie也与数据库中的相同,但我必须再次登录.并且在登录后同时更改了sessionids(数据库和浏览器).
我正在使用django 1.8.5
编辑:一些与会话相关的设置:
SESSION_EXPIRE_AT_BROWSER_CLOSE False
SESSION_COOKIE_HTTPONLY True
SESSION_COOKIE_DOMAIN None
SESSION_SAVE_EVERY_REQUEST False
SESSION_COOKIE_SECURE False
Run Code Online (Sandbox Code Playgroud)
EDIT2:
更清楚一点:在更改一些源文件(python文件,模板工作正常)后,服务器将重新加载(如果我使用--noreload,我必须手动完成以获取更改),之后每个人都是登出.
EDIT3:
CACHES {'default': {'BACKEND': 'django.core.cache.backends.locmem.LocMemCache'}}
SESSION_ENGINE 'django.contrib.sessions.backends.db'
Run Code Online (Sandbox Code Playgroud) 我在Android棒棒糖和更高版本录制语音通话时遇到问题.通过这段代码,我能够录制我的声音,但无法记录其他人的声音.
public void startRecording() {
if (recording == false) {
Log.e("here", "--------Recorder_Sarted------" + fname);
SimpleDateFormat sdf = new SimpleDateFormat("ddMMyyyy");
int randomPIN = (int) (Math.random() * 9000) + 1000;
recorder.setAudioSource(MediaRecorder.AudioSource.VOICE_COMMUNICATION);
recorder.setOutputFormat(MediaRecorder.OutputFormat.THREE_GPP);
recorder.setAudioEncoder(MediaRecorder.AudioEncoder.AMR_NB);
String file = Environment.getExternalStorageDirectory().toString();
String filepath = file + "/Aeris/Recording";
File dir = new File(filepath);
dir.mkdirs();
Log.e("here ", "----------------" + sdf.format(Calendar.getInstance().getTime()) + " " + fname + " " + type);
filepath += "/" + type + "-" + fname + "-" + sdf.format(Calendar.getInstance().getTime()) + "-" + randomPIN + …Run Code Online (Sandbox Code Playgroud)