Tag Archives: error

[Solved] Error :: You must put some ‘source‘ URIs in your sources.list

Solution:

Just enter the following three lines.

sudo cp /etc/apt/sources.list /etc/apt/sources.list~
sudo sed -Ei 's/^# deb-src /deb-src /' /etc/apt/sources.list
sudo apt-get update

Users who are not logged in can copy the code below.

sudo cp /etc/apt/sources.list /etc/apt/sources.list~
sudo sed -Ei ‘s/^# deb-src /deb-src /’ /etc/apt/sources.list
sudo apt-get update

Reference:
https://askubuntu.com/questions/496549/error-you-must-put-some-source-uris-in-your-sources-list

[Solved] redis Startup Error: Creating Server TCP listening socket 127.0. 0.1:6379: bind: no error redis

Error: [52904] 08 Dec 15:09:41.278 # creating server TCP listening socket 127.0 0.1:6379: bind: No error

Solution:

You can connect successfully by entering the following commands in sequence

D:\zip\redis\Redis-x64-3.2.100>redis-server.exe redis.windows.conf
[52904] 08 Dec 15:09:41.278 # Creating Server TCP listening socket 127.0.0.1:6379: bind: No error

D:\zip\redis\Redis-x64-3.2.100>redis-cli.exe
127.0.0.1:6379> shutdown
not connected> exit

D:\zip\redis\Redis-x64-3.2.100>redis-server.exe  redis.windows.conf
                _._
           _.-``__ ''-._
      _.-``    `.  `_.  ''-._           Redis 3.2.100 (00000000/0) 64 bit
  .-`` .-```.  ```\/    _.,_ ''-._
 (    '      ,       .-`  | `,    )     Running in standalone mode
 |`-._`-...-` __...-.``-._|'` _.-'|     Port: 6379
 |    `-._   `._   /    _.-'    |     PID: 47344
  `-._    `-._  `-./  _.-'    _.-'
 |`-._`-._    `-.__.-'    _.-'_.-'|
 |    `-._`-._        _.-'_.-'    |           http://redis.io
  `-._    `-._`-.__.-'_.-'    _.-'
 |`-._`-._    `-.__.-'    _.-'_.-'|
 |    `-._`-._        _.-'_.-'    |
  `-._    `-._`-.__.-'_.-'    _.-'
      `-._    `-.__.-'    _.-'
          `-._        _.-'
              `-.__.-'

[47344] 08 Dec 15:10:36.580 # Server started, Redis version 3.2.100
[47344] 08 Dec 15:10:36.583 * DB loaded from disk: 0.000 seconds
[47344] 08 Dec 15:10:36.584 * The server is now ready to accept connections on port 6379

[Solved] fatal error: Eigen/Geometry: No such file or directory

Error encountered when compiling the program of Aubo manipulator. Eigen cannot be found

/opt/ros/melodic/include/moveit/robot_model/joint_model.h:47:10: fatal error: Eigen/Geometry: No such file or directory
#include <Eigen/Geometry>

Reason:
the location of eigin library is/usr/include/eigin3/eigen. The system cannot find this location. We need to link it manually

Solution:
manually create a soft link to the upper level directory

sudo ln -sf /usr/include eigen3/Eigen /usr/include/Eigen
sudo ln -sf /usr/include/eigen3/unsupported /usr/include/unsupported

[Solved] Mac Install homebrew Error: error: Not a valid ref: refs/remotes/origin/master

The MAC reports the following error after installing homeberw:

Press RETURN to continue or any other key to abort
==> /usr/bin/sudo /usr/sbin/chown -R aa:admin /opt/homebrew
==> Downloading and installing Homebrew...
HEAD is now at 8de10a05b Merge pull request #10472 from MikeMcQuaid/new-issue-templates
error: Not a valid ref: refs/remotes/origin/master
fatal: ambiguous argument 'refs/remotes/origin/master': unknown revision or path not in the working tree.
Use '--' to separate paths from revisions, like this:
'git [...] -- [...]'
fatal: the remote end hung up unexpectedly
fatal: early EOF
fatal: index-pack failed
Error: Fetching /opt/homebrew/Library/Taps/homebrew/homebrew-core failed!
fatal: invalid upstream 'origin/master'
Failed during: /opt/homebrew/bin/brew update --force --quiet

The solution is as follows:

Uninstall homebrew

/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/uninstall.sh)"

Set git compression:

git config --global core.compression 0

Set git buffer size:

git config --global http.postBuffer 1048576000

Reinstall brew

/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install.sh)"

[Solved] ESLint error: Newline required at end of file but not found (eol-last)

When verifying Vue projects with eslint, the following warnings were found:

error: Newline required at end of file but not found (eol-last)

The results are as follows:

I found that the online solution is to insert a blank line after the warning code. I think this is very bad.

[solution]
1. Insert a configuration file .Editorconfig , in the project_final_Newline = true is changed to false

2. Cancel the verification of the last rule in . Eslintrc. JS

recompile without warning.

[Solved] The Shell Script error: syntax error: “(” unexpected “)

Execute the shell script with the following error messages

This is related to the version of shell you actually use. It can be printed with LS - L/bin/*sh, for example:

Here, SH is redirected to dash, so if sh positionpara.Sh, dash is used. There are many ways to avoid error reporting, such as executing bash positionpara.Sh, or executing ./positionpara.Sh .

Parse error in ubantu/Linux system [How to Solve]

Parse error in ubantu/Linux system

This problem took me some time. In order to avoid forgetting to post a blog in the future

Phenomenon:

The execution code and error reporting contents are as follows:

reason:

This is because the standard supported by the Linux gcc compiler is different from the current C89 standard. This C standard requires that the declaration of variables in a block be placed in front of all non declarative statements.

We can see that on line 266, a definition statement is placed before the declaration statement, so an error is reported

Solution:

Put 266 this non declarative statement under all declarative statements
as shown in the following figure:

the compilation succeeded without error, and the problem was solved successfully

[Solved] Warning: Unknown: Failed to write session data using user defined save handler. (session.save_path:


Warning: Unknown: Failed to write session data using user-defined save handler. (session.save_path: D:\Software\phpstudy_pro\Extensions\tmp\tmp) in Unknown on line 0

Reasons:

1. the path of session.save_path is not correct
2. session.save_path's file permissions are not correct
3. and other reasons for the error, (but mine is not the problem) this problem sent me a day of time

My mistake:

The session that occurs when using this method_set_save_handler(‘open’,‘close’,‘read’,‘write’,‘destory’,‘gc’);

reason

	1. the read callback function must return the value of the string, if not, other errors will be reported
	2. write callback function must return true, if false will return the above error
	3. write in the insert statement of the variable value must be added to the single quotes, otherwise it can not be inserted into the database
	4. all but the read callback function must return a bool value, write must return true to insert into the database, and the others I think should also return true (not tested here)

Encounter this wrong idea

1. Check the configuration file for errors first
2. then check for errors in the return value
3. then check the sql statement for errors
4. debug with echo or var_dump at each step

If you solve the big guys’ problems, please give me a favor.