Skip to content

Remove obsolete compilation error interpretations #1113

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jun 28, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
70 changes: 0 additions & 70 deletions arduino-ide-extension/src/node/cli-error-parser.ts
Original file line number Diff line number Diff line change
Expand Up @@ -149,76 +149,6 @@ function remapErrorMessages(result: ParseResult): ParseResult {

// Based on the Java IDE: https://github.com/arduino/Arduino/blob/43b0818f7fa8073301db1b80ac832b7b7596b828/arduino-core/src/cc/arduino/Compiler.java#L528-L578
const KnownErrors: Record<string, { error: string; message?: string }> = {
'SPI.h: No such file or directory': {
error: nls.localize(
'arduino/cli-error-parser/spiError',
'Please import the SPI library from the Sketch > Import Library menu.'
),
message: nls.localize(
'arduino/cli-error-parser/spiMessage',
'As of Arduino 0019, the Ethernet library depends on the SPI library.\nYou appear to be using it or another library that depends on the SPI library.'
),
},
"'BYTE' was not declared in this scope": {
error: nls.localize(
'arduino/cli-error-parser/byteError',
"The 'BYTE' keyword is no longer supported."
),
message: nls.localize(
'arduino/cli-error-parser/byteMessage',
"As of Arduino 1.0, the 'BYTE' keyword is no longer supported.\nPlease use Serial.write() instead."
),
},
"no matching function for call to 'Server::Server(int)'": {
error: nls.localize(
'arduino/cli-error-parser/serverError',
'The Server class has been renamed EthernetServer.'
),
message: nls.localize(
'arduino/cli-error-parser/serverMessage',
'As of Arduino 1.0, the Server class in the Ethernet library has been renamed to EthernetServer.'
),
},
"no matching function for call to 'Client::Client(byte [4], int)'": {
error: nls.localize(
'arduino/cli-error-parser/clientError',
'The Client class has been renamed EthernetClient.'
),
message: nls.localize(
'arduino/cli-error-parser/clientMessage',
'As of Arduino 1.0, the Client class in the Ethernet library has been renamed to EthernetClient.'
),
},
"'Udp' was not declared in this scope": {
error: nls.localize(
'arduino/cli-error-parser/udpError',
'The Udp class has been renamed EthernetUdp.'
),
message: nls.localize(
'arduino/cli-error-parser/udpMessage',
'As of Arduino 1.0, the Udp class in the Ethernet library has been renamed to EthernetUdp.'
),
},
"'class TwoWire' has no member named 'send'": {
error: nls.localize(
'arduino/cli-error-parser/sendError',
'Wire.send() has been renamed Wire.write().'
),
message: nls.localize(
'arduino/cli-error-parser/sendMessage',
'As of Arduino 1.0, the Wire.send() function was renamed to Wire.write() for consistency with other libraries.'
),
},
"'class TwoWire' has no member named 'receive'": {
error: nls.localize(
'arduino/cli-error-parser/receiveError',
'Wire.receive() has been renamed Wire.read().'
),
message: nls.localize(
'arduino/cli-error-parser/receiveMessage',
'As of Arduino 1.0, the Wire.receive() function was renamed to Wire.read() for consistency with other libraries.'
),
},
"'Mouse' was not declared in this scope": {
error: nls.localize(
'arduino/cli-error-parser/mouseError',
Expand Down
16 changes: 1 addition & 15 deletions i18n/en.json
Original file line number Diff line number Diff line change
Expand Up @@ -57,22 +57,8 @@
"uploadingCertificates": "Uploading certificates."
},
"cli-error-parser": {
"byteError": "The 'BYTE' keyword is no longer supported.",
"byteMessage": "As of Arduino 1.0, the 'BYTE' keyword is no longer supported.\nPlease use Serial.write() instead.",
"clientError": "The Client class has been renamed EthernetClient.",
"clientMessage": "As of Arduino 1.0, the Client class in the Ethernet library has been renamed to EthernetClient.",
"keyboardError": "'Keyboard' not found. Does your sketch include the line '#include <Keyboard.h>'?",
"mouseError": "'Mouse' not found. Does your sketch include the line '#include <Mouse.h>'?",
"receiveError": "Wire.receive() has been renamed Wire.read().",
"receiveMessage": "As of Arduino 1.0, the Wire.receive() function was renamed to Wire.read() for consistency with other libraries.",
"sendError": "Wire.send() has been renamed Wire.write().",
"sendMessage": "As of Arduino 1.0, the Wire.send() function was renamed to Wire.write() for consistency with other libraries.",
"serverError": "The Server class has been renamed EthernetServer.",
"serverMessage": "As of Arduino 1.0, the Server class in the Ethernet library has been renamed to EthernetServer.",
"spiError": "Please import the SPI library from the Sketch > Import Library menu.",
"spiMessage": "As of Arduino 0019, the Ethernet library depends on the SPI library.\nYou appear to be using it or another library that depends on the SPI library.",
"udpError": "The Udp class has been renamed EthernetUdp.",
"udpMessage": "As of Arduino 1.0, the Udp class in the Ethernet library has been renamed to EthernetUdp."
"mouseError": "'Mouse' not found. Does your sketch include the line '#include <Mouse.h>'?"
},
"cloud": {
"account": "Account",
Expand Down