Author Archives: Robins

How to Solve SQL fulltext error

Today, the synchronization database reported an error FULLTEXT.
Reason: The 5.6 version synchronizes to 5.5 and an error is reported because it contains the FULLTEXT index.

Solution: Delete the index according to the prompt.

Information: Before MySQL version 5.6, only the MyISAM storage engine supports the full-text engine. In version 5.6, InnoDB added support for full-text indexing, but it does not support Chinese full-text indexing. In version 5.7.6, MySQL has a built-in full-text parser for ngram , Used to support participles of Asian languages.

[Solved] Vue Baidu map loading error: cannot read properties of undefined (reading ‘centerandzoom’)

Because the map positioning function needs to be used in the project, then I made a reference to the Vue Baidu map document, which can obtain the location name and location coordinates by clicking the map, and then save them to the database. When users edit the location information, they can locate the corresponding geographical location on the map through the coordinates stored in the database. However, when I finish the function, I find that there will be an error message when I load it for the first time, but the function is normal, and there will be no error message when I operate later

No more nonsense, let’s talk about the solution first:

Change mounted() to obtain the coordinate data stored in the database, and request the coordinate data when changed to created(). The following is a detailed description:

There are a lot of error messages, as shown below:

Code part

Here I got the coordinate data in the database from other pages and stored it in vuex, and then fetched the value from vuex, here can also be changed to use axios to send a request to get the coordinate data stored in the database. The value of form.csr_address is the “storage address”, and form.lng and form.lat are latitude and longitude.

Finally, I found that because the data is obtained during mounting, but Baidu map rendering seems to be before mounting, it will cause an error if it has not obtained the data from vuex when it calls the coordinate data. Then change mounted() to created() to solve the problem.

[Fixed] lazarus LAMW release-keystore.bat Could not Generate .keystore Files

Using LAMW, I found that I can’t generate APK with signature, after tracing, I found that the release-keystore.bat generated by LAMW has LC_ALL=C before keytool causing illegal generation of .keystore file, after deleting it, I can generate keystore file and APK with signature normally.

set JAVA_HOME=C:\Program Files\Java\jdk1.8.0_60
set PATH=%JAVA_HOME%\bin;%PATH%
set JAVA_TOOL_OPTIONS=-Duser.language=en
cd D:\fpcupdeluxe3\projects\LAMWProjects\AppLAMWProject6
LC_ALL=C keytool -genkey -v -keystore applamwproject6-release.keystore -alias applamwproject6.keyalias -keyalg RSA -keysize 2048 -validity 10000 < D:\fpcupdeluxe3\projects\LAMWProjects\AppLAMWProject6\keytool_input.txt
:Error
echo off
cls
echo.
echo Signature file created previously, remember that if you delete this file and it was uploaded to Google Play, you will not be able to upload another app without this signature.
echo.
pause

The file release-keystore.bat is automatically generated when creating a new APK, just remove LC_ALL=C from line 2219 of lamw\android_wizard\AndroidWizard_intf.pas and recompile lazarus.

Modified as:

The recompiled lazarus generates the correct release-keystore.bat when creating a new Android project project, so you don’t have to modify release-keystore.bat every time you create a new project.

[Solved] Ubuntu 18.04 install MATLAB Error: “License Manager Error -8”

Following the tutorial, the following error occurred when the installation was completed:

Solution:
Copy the crack tool MATLAB_R2018b_Linux64_Crack directory /home/username/mnt/LINUX/MATLAB/R2018b/bin/glnxa64/matlab_startup_plugins/lmgrimpl/ libmwlmgrimpl.so Copy to the installation directory /usr/local/MATLAB/R2018b/bin/glnxa64/matlab_startup_plugins/lmgrimpl/libmwlmgrimpl.so

Just restart

[Solved] Spring Error: Artifact spring:war exploded: Error during artifact deployment. See server log for details

Tomcat loading problem

After modifying the name of a class, use idea to automatically modify the name of this class. After modification, an error is reported:

Artifact storage:war exploded: Error during artifact deployment. See server log for details

Solution 1: regenerate the war package

1. In tomcat, delete the war package of the project

2. In idea -> Delete the war package in project settings and repackage it.

3. In tomcat, reload the war package

Method 2: regenerate the web xml

Check the log and find the web.inf under web-inf XML error. Delete web.XML, reconfigure XML

<?xml version="1.0" encoding="UTF-8"?>
<web-app xmlns="http://xmlns.jcp.org/xml/ns/javaee"
         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
         xsi:schemaLocation="http://xmlns.jcp.org/xml/ns/javaee http://xmlns.jcp.org/xml/ns/javaee/web-app_4_0.xsd"
         version="4.0">

    <servlet>
        <servlet-name>dispatcherServlet</servlet-name>
        <servlet-class>org.springframework.web.servlet.DispatcherServlet</servlet-class>
        <init-param>
            <param-name>contextConfigLocation</param-name>
            <param-value>classpath:springmvc.xml</param-value>
        </init-param>
        <load-on-startup>1</load-on-startup>
    </servlet>
    <servlet-mapping>
        <servlet-name>dispatcherServlet</servlet-name>
        <url-pattern>/</url-pattern>
    </servlet-mapping>
</web-app>

[Solved] Visual Studio Error: Creation of the virtual directory http://localhost:62498/ failed with the error: Filename: \\?C:…………………………

The project is uploaded to the team foundation server, and the following errors occur after others take it out.

Error: Cannot write configuration file due to insufficient permissions.

You will need to manually create this virtual directory in IIS before you can open this project.

From the stack overflow}, I checked the solutions to the corresponding problems and roughly understood the causes.

Cause: the directory of the removed personnel is inconsistent with that of the uploader.

Solution:

In the project folder Vs folder, find the config folder, and open applicationhost.com under the config folder Config file, find the following code after opening, modify the following absolute path to the absolute path on the downloader’s computer, and then save it (all the project files of the child are stored in the visual management folder). It is completely normal after opening.

                <application path="/" applicationPool="Clr4IntegratedAppPool">
                    <virtualDirectory path="/" physicalPath="C:\ABC\IT.ABC\Global\WebApplication\VisualManagement\VisualManagement" />
                </application>

[Solved] SpringbootExpection 1: Error creating bean with name ‘xxxImpl’: Unsatisfied dependency expressed through field

This error is due to an error when generating code with mybatisplus codegenerator.

Specific contents:

 1 org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'mentalityExamServiceImpl': Unsatisfied dependency expressed through field 'baseMapper'; nested exception is org.springframework.beans.factory.NoSuchBeanDefinitionException: No qualifying bean of type 'com.paper.demo.mapper.MentalityExamMapper' available: expected at least 1 bean which qualifies as autowire candidate. Dependency annotations: {@org.springframework.beans.factory.annotation.Autowired(required=true)}
 2     at org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor$AutowiredFieldElement.resolveFieldValue(AutowiredAnnotationBeanPostProcessor.java:659) ~[spring-beans-5.3.13.jar:5.3.13]
 3     at org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor$AutowiredFieldElement.inject(AutowiredAnnotationBeanPostProcessor.java:639) ~[spring-beans-5.3.13.jar:5.3.13]
 4     at org.springframework.beans.factory.annotation.InjectionMetadata.inject(InjectionMetadata.java:119) ~[spring-beans-5.3.13.jar:5.3.13]
 5     at org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor.postProcessProperties(AutowiredAnnotationBeanPostProcessor.java:399) ~[spring-beans-5.3.13.jar:5.3.13]
 6     at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.populateBean(AbstractAutowireCapableBeanFactory.java:1431) ~[spring-beans-5.3.13.jar:5.3.13]
 7     at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:619) ~[spring-beans-5.3.13.jar:5.3.13]
 8     at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:542) ~[spring-beans-5.3.13.jar:5.3.13]
 9     at org.springframework.beans.factory.support.AbstractBeanFactory.lambda$doGetBean$0(AbstractBeanFactory.java:335) ~[spring-beans-5.3.13.jar:5.3.13]
10     at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:234) ~[spring-beans-5.3.13.jar:5.3.13]
11     at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:333) ~[spring-beans-5.3.13.jar:5.3.13]
12     at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:208) ~[spring-beans-5.3.13.jar:5.3.13]
13     at org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:944) ~[spring-beans-5.3.13.jar:5.3.13]
14     at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:918) ~[spring-context-5.3.13.jar:5.3.13]
15     at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:583) ~[spring-context-5.3.13.jar:5.3.13]
16     at org.springframework.boot.web.servlet.context.ServletWebServerApplicationContext.refresh(ServletWebServerApplicationContext.java:145) ~[spring-boot-2.6.1.jar:2.6.1]
17     at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:730) ~[spring-boot-2.6.1.jar:2.6.1]
18     at org.springframework.boot.SpringApplication.refreshContext(SpringApplication.java:412) ~[spring-boot-2.6.1.jar:2.6.1]
19     at org.springframework.boot.SpringApplication.run(SpringApplication.java:302) ~[spring-boot-2.6.1.jar:2.6.1]
20     at org.springframework.boot.SpringApplication.run(SpringApplication.java:1301) ~[spring-boot-2.6.1.jar:2.6.1]
21     at org.springframework.boot.SpringApplication.run(SpringApplication.java:1290) ~[spring-boot-2.6.1.jar:2.6.1]
22     at com.paper.demo.DemoApplication.main(DemoApplication.java:10) ~[classes/:na]
23     at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[na:na]
24     at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[na:na]
25     at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[na:na]
26     at java.base/java.lang.reflect.Method.invoke(Method.java:567) ~[na:na]
27     at org.springframework.boot.devtools.restart.RestartLauncher.run(RestartLauncher.java:49) ~[spring-boot-devtools-2.6.1.jar:2.6.1]
28 Caused by: org.springframework.beans.factory.NoSuchBeanDefinitionException: No qualifying bean of type 'com.paper.demo.mapper.MentalityExamMapper' available: expected at least 1 bean which qualifies as autowire candidate. Dependency annotations: {@org.springframework.beans.factory.annotation.Autowired(required=true)}
29     at org.springframework.beans.factory.support.DefaultListableBeanFactory.raiseNoMatchingBeanFound(DefaultListableBeanFactory.java:1790) ~[spring-beans-5.3.13.jar:5.3.13]
30     at org.springframework.beans.factory.support.DefaultListableBeanFactory.doResolveDependency(DefaultListableBeanFactory.java:1346) ~[spring-beans-5.3.13.jar:5.3.13]
31     at org.springframework.beans.factory.support.DefaultListableBeanFactory.resolveDependency(DefaultListableBeanFactory.java:1300) ~[spring-beans-5.3.13.jar:5.3.13]
32     at org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor$AutowiredFieldElement.resolveFieldValue(AutowiredAnnotationBeanPostProcessor.java:656) ~[spring-beans-5.3.13.jar:5.3.13]
33     ... 25 common frames omitted

Solution:

Just add the @mapper annotation on the interface that inherits the basemapper class

[Solved] yolov3 Error: cuda error: out of memory darknet: ./src/cuda.c:36: check_error: Assertion `0′ failed.

Install the framework according to the tutorial on the official website of Darknet. According to your own conditions (NVIDIA graphics card driver has been installed, cuda9.0 cudnn7.1), modify GPU = 1 cudnn = 1 opencv = 1 in the makefile file, then make again, and then download yolov3 After weights, then use the test command provided on the web page to test.

darknet: ./src/cuda.c:36: check_error: Assertion `0' failed.

The result is an error: memory overflow.CUDA Error: out of memory
darknet: ./src/cuda.c:36: check_error: Assertion `0′ failed.
abort (core dumped) then modify yolov3.0 in the CFG folder Cfg file, original yolov3 The cfg file starts with:

[net]
# Testing
#batch=1
#subdivisions=1
# Training
batch=64
subdivisions=16

Amend to read:

[net]
# Testing
batch=1
subdivisions=1
# Training
#batch=64
#subdivisions=16

Batch can greatly reduce the amount of memory. If there is still insufficient memory in the above way, there are only two solutions, either use a smaller model or change yolov3.0 in the CFG directory The height and width values of CFG lines 8 and 9 are changed to 416 in width and height, and the test will be OK. Modified Yolo.cfg file:

no problem if you test again.

[How to Solve] dereferencing pointer to incomplete type

Solution:

Code situation

Initial condition: the chain stack already exists, and there is at least one element
typedef struct
{
	ElemType data;
	struct LinkedStackNode* next;
}LinkedStackNode, *Linknode;

//
/*
Initial condition: the chain stack already exists, and there is at least one element
*/
int StackTop(Linknode top, int* x)
{
	if(top->data == 0)
		return -1;
	*x = top->next->data;
	return 1;
}

Analyze problems

Dereference pointers of incomplete types

The meaning here is that there are incomplete pointers. The structure and pointer belong to reference types, and the internal definition of the structure is complete. Therefore, only the structure itself is incomplete, that is:

/
//typedef struct Modify to:
typedef struct LinkedStackNode
{
	ElemType data;
	struct LinkedStackNode* next;
}LinkedStackNode, *Linknode;

{
	ElemType data;
	struct LinkedStackNode* next;
}LinkedStackNode, *Linknode;

//
/*
Initial condition: the chain stack already exists, and there is at least one element
*/
int StackTop(Linknode top, int* x)
{
	if(top->data == 0)
		return -1;
	*x = top->next->data;
	return 1;
}