Spyder自动缩进停止工作

时间:2017-03-27 08:46:38

标签: python anaconda spyder auto-indent

我多年来一直在使用Anaconda / Spyder。今天自动缩进只是在带有冒号的“for”语句后停止缩进。我也尝试了绝对没有代码在for语句之上,所以它不是前一行中的语法错误。我是否密集?

1 个答案:

答案 0 :(得分:1)

您可以通过终端/ CMD恢复默认设置,如下所示:

CREATE TABLE IF NOT EXISTS `xxx`.`service_provider` ( `custom_id` VARCHAR(45) NOT NULL, `patient_idpatient` INT NOT NULL, `service_provider_type_idservice_provider_type` INT NOT NULL, `date_created` TIMESTAMP NULL, `last_updated` TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP, INDEX `fk_service_provider_patient1_idx` (`patient_idpatient` ASC), INDEX `fk_service_provider_service_provider_type1_idx` (`service_provider_type_idservice_provider_type` ASC), PRIMARY KEY (`custom_id`, `patient_idpatient`, `service_provider_type_idservice_provider_type`), CONSTRAINT `fk_service_provider_patient1` FOREIGN KEY (`patient_idpatient`) REFERENCES `xxx`.`patient` (`idpatient`) ON DELETE CASCADE ON UPDATE NO ACTION, CONSTRAINT `fk_service_provider_service_provider_type1` FOREIGN KEY (`service_provider_type_idservice_provider_type`) REFERENCES `xxx`.`service_provider_type` (`idservice_provider_type`) ON DELETE NO ACTION ON UPDATE NO ACTION) ENGINE = InnoDB;

或者删除位于用户文件夹中的spyder --reset文件夹。