gadicc / node-yahoo-finance2

Unofficial API for Yahoo Finance
https://www.npmjs.com/package/yahoo-finance2
MIT License
376 stars 62 forks source link

Failed validation: #/definitions/QuoteSummaryResult #638

Closed chincheta closed 1 year ago

chincheta commented 1 year ago

Validation Error

Minimal Reproduction

let data = await yahooFinance.quoteSummary('BMW.DE', { modules: [ 'price', 'assetProfile', 'incomeStatementHistory', 'incomeStatementHistoryQuarterly', 'balanceSheetHistory', 'balanceSheetHistoryQuarterly', 'cashflowStatementHistory', 'cashflowStatementHistoryQuarterly', 'quoteType', 'financialData', 'defaultKeyStatistics', 'earnings', 'earningsHistory', 'earningsTrend', 'calendarEvents', 'summaryDetail', 'summaryProfile' ] });

Symbol(s) that it happened for

Error Message

The following result did not validate with schema: #/definitions/QuoteSummaryResult

 [
      {
        instancePath: '/assetProfile',
        schemaPath: '#/additionalProperties',
        keyword: 'additionalProperties',
        params: { additionalProperty: 'industryDisp' },
        message: 'must NOT have additional properties',
        data: {
          address1: 'Fasanenweg 10',
          city: 'Leinfelden-Echterdingen',
          zip: '70771',
          country: 'Germany',
          phone: '49 711 8485 0',
          website: 'https://www.daimlertruck.com',
          industry: 'Farm & Heavy Construction Machinery',
          industryDisp: 'Farm & Heavy Construction Machinery',
          sector: 'Industrials',
          longBusinessSummary: 'Daimler Truck Holding AG manufactures and sells light, medium- and heavy-duty trucks and buses in Europe, North America, Asia, Latin America, and internationally. It operates through five segments: Trucks North America, Mercedes-Benz, Trucks Asia, Daimler Buses, and Financial Services. The company offers light, medium, and heavy-duty trucks; city and intercity buses, touring coaches, and bus chassis; industrial engines; and special vehicles that are primarily used in the municipal sector, as well as new and used commercial vehicles. It also provides various financial services, such as leasing, financing, hire purchase, and insurance products under the Daimler Truck Financial Services brand name. In addition, the company offers connectivity solutions under the Detroit Connect, Fuso Connect, Mercedes-Benz Uptime, and Fleetboard brands; and aftersales services, such as maintenance and repair, as well as sells spare parts. It provides trucks and buses under the Mercedes-Benz, Freightliner, Western Star, FUSO, BharatBenz, Setra, and Thomas Built Buses brand names. The company was founded in 1896 and is headquartered in Leinfelden-Echterdingen, Germany.',
          fullTimeEmployees: 104729,
          companyOfficers: [
            {
              maxAge: 1,
              name: 'Mr. Martin  Daum',
              age: 63,
              title: 'CEO, Pres & Chairman of Management',
              yearBorn: 1959,
              exercisedValue: 0,
              unexercisedValue: 0
            },
            {
              maxAge: 1,
              name: 'Mr. Jochen  Goetz',
              age: 51,
              title: 'Member of the Board of Management and Fin. & Controlling Officer',
              yearBorn: 1971,
              exercisedValue: 0,
              unexercisedValue: 0
            },
            {
              maxAge: 1,
              name: 'Mr. Jurgen  Hartwig',
              age: 55,
              title: 'Member of the Board of Management & Human Resource Officer',
              yearBorn: 1967,
              exercisedValue: 0,
              unexercisedValue: 0
            },
            {
              maxAge: 1,
              name: 'Ms. Karin  Radstrom',
              age: 43,
              title: 'Member of the Board of Management',
              yearBorn: 1979,
              exercisedValue: 0,
              unexercisedValue: 0
            },
            {
              maxAge: 1,
              name: 'Mr. Stephan  Unger',
              age: 55,
              title: 'Member of Management Board',
              yearBorn: 1967,
              exercisedValue: 0,
              unexercisedValue: 0
            },
            {
              maxAge: 1,
              name: "Mr. John  O'Leary",
              age: 62,
              title: 'Member of the Board of Management',
              yearBorn: 1960,
              exercisedValue: 0,
              unexercisedValue: 0
            },
            {
              maxAge: 1,
              name: 'Mr. Karl  Deppen',
              age: 56,
              title: 'Member of the Board of Management',
              yearBorn: 1966,
              exercisedValue: 0,
              unexercisedValue: 0
            },
            {
              maxAge: 1,
              name: 'Dr. Andreas  Gorbach',
              age: 47,
              title: 'Member of the Board of Management',
              yearBorn: 1975,
              exercisedValue: 0,
              unexercisedValue: 0
            },
            {
              maxAge: 1,
              name: 'Mr. Christian  Herrmann',
              age: 44,
              title: 'Head of Investor Relations & M&A and VP',
              yearBorn: 1978,
              exercisedValue: 0,
              unexercisedValue: 0
            },
            {
              maxAge: 1,
              name: 'Mr. Sven  Grable',
              title: 'Head of Mercedes-Benz Trucks Operations',
              exercisedValue: 0,
              unexercisedValue: 0
            }
          ],
          auditRisk: 5,
          boardRisk: 2,
          compensationRisk: 2,
          shareHolderRightsRisk: 1,
          overallRisk: 2,
          governanceEpochDate: 2023-05-01T00:00:00.000Z,
          maxAge: 86400
        }
      },
      {
        instancePath: '/summaryProfile',
        schemaPath: '#/definitions/SummaryProfile/additionalProperties',
        keyword: 'additionalProperties',
        params: { additionalProperty: 'industryDisp' },
        message: 'must NOT have additional properties',
        data: {
          address1: 'Fasanenweg 10',
          city: 'Leinfelden-Echterdingen',
          zip: '70771',
          country: 'Germany',
          phone: '49 711 8485 0',
          website: 'https://www.daimlertruck.com',
          industry: 'Farm & Heavy Construction Machinery',
          industryDisp: 'Farm & Heavy Construction Machinery',
          sector: 'Industrials',
          longBusinessSummary: 'Daimler Truck Holding AG manufactures and sells light, medium- and heavy-duty trucks and buses in Europe, North America, Asia, Latin America, and internationally. It operates through five segments: Trucks North America, Mercedes-Benz, Trucks Asia, Daimler Buses, and Financial Services. The company offers light, medium, and heavy-duty trucks; city and intercity buses, touring coaches, and bus chassis; industrial engines; and special vehicles that are primarily used in the municipal sector, as well as new and used commercial vehicles. It also provides various financial services, such as leasing, financing, hire purchase, and insurance products under the Daimler Truck Financial Services brand name. In addition, the company offers connectivity solutions under the Detroit Connect, Fuso Connect, Mercedes-Benz Uptime, and Fleetboard brands; and aftersales services, such as maintenance and repair, as well as sells spare parts. It provides trucks and buses under the Mercedes-Benz, Freightliner, Western Star, FUSO, BharatBenz, Setra, and Thomas Built Buses brand names. The company was founded in 1896 and is headquartered in Leinfelden-Echterdingen, Germany.',
          fullTimeEmployees: 104729,
          companyOfficers: [],
          maxAge: 86400
        }
      }
    ]

Environment

Node: node Node version (if applicable): v16.20.0 Npm version: 9.6.5 Library version (e.g. 1.10.1): v2.4.1

Additional Context

gadicc commented 1 year ago

Thanks for the report, @chincheta, and for your patience. This is fixed now and will be in the next release; there'll be an automated message here when that happens.

gadicc commented 1 year ago

:tada: This issue has been resolved in version 2.4.4 :tada:

The release is available on:

Your semantic-release bot :package::rocket: