Skip to content
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

Failing test: X-Pack Saved Object API Integration Tests -- security_and_spaces.x-pack/test/saved_object_api_integration/security_and_spaces/apis/bulk_create·ts - saved objects security and spaces enabled _bulk_create user with no access within the default space "after all" hook for "should return 403 forbidden [hiddentype/any]" #122829

Closed
kibanamachine opened this issue Jan 12, 2022 · 5 comments · Fixed by #122962
Labels
failed-test A test failure on a tracked branch, potentially flaky-test Team:Core Core services & architecture: plugins, logging, config, saved objects, http, ES client, i18n, etc

Comments

@kibanamachine
Copy link
Contributor

kibanamachine commented Jan 12, 2022

A test failed on a tracked branch

ResponseError: x_content_parse_exception: [parsing_exception] Reason: [1:65] [ids] unknown field [type]
    at onBody (/opt/local-ssd/buildkite/builds/kb-n2-4-bf1ddb6b4a216c51/elastic/kibana-7-dot-latest-es-forward-compatibility/kibana/node_modules/@elastic/elasticsearch/lib/Transport.js:367:23)
    at IncomingMessage.onEnd (/opt/local-ssd/buildkite/builds/kb-n2-4-bf1ddb6b4a216c51/elastic/kibana-7-dot-latest-es-forward-compatibility/kibana/node_modules/@elastic/elasticsearch/lib/Transport.js:291:11)
    at IncomingMessage.emit (node:events:402:35)
    at endReadableNT (node:internal/streams/readable:1343:12)
    at processTicksAndRejections (node:internal/process/task_queues:83:21) {
  meta: {
    body: { error: [Object], status: 400 },
    statusCode: 400,
    headers: {
      'x-elastic-product': 'Elasticsearch',
      'content-type': 'application/json;charset=utf-8',
      'content-length': '422'
    },
    meta: {
      context: null,
      request: [Object],
      name: 'elasticsearch-js',
      connection: [Object],
      attempts: 0,
      aborted: false
    }
  }
}

First failure: CI Build - 7.17

@kibanamachine kibanamachine added the failed-test A test failure on a tracked branch, potentially flaky-test label Jan 12, 2022
@botelastic botelastic bot added the needs-team Issues missing a team label label Jan 12, 2022
@kibanamachine
Copy link
Contributor Author

New failure: CI Build - 7.17

@mshustov mshustov added Team:Security Team focused on: Auth, Users, Roles, Spaces, Audit Logging, and more! and removed needs-team Issues missing a team label labels Jan 13, 2022
@elasticmachine
Copy link
Contributor

Pinging @elastic/kibana-security (Team:Security)

@jportner
Copy link
Contributor

Full errors from log:

└-: saved objects security and spaces enabled
--
  | └-> "before all" hook: beforeTestSuite.trigger in "saved objects security and spaces enabled"
  | └-> "before all" hook in "saved objects security and spaces enabled"
  | └-: _bulk_create
  | └-> "before all" hook: beforeTestSuite.trigger in "_bulk_create"
  | └-: user with no access within the default space
  | └-> "before all" hook: beforeTestSuite.trigger for "should return 403 forbidden [isolatedtype/defaultspace-isolatedtype-id]"
  | └-> "before all" hook for "should return 403 forbidden [isolatedtype/defaultspace-isolatedtype-id]"
  | └- ✖ fail: saved objects security and spaces enabled _bulk_create user with no access within the default space "before all" hook for "should return 403 forbidden [isolatedtype/defaultspace-isolatedtype-id]"
  | │      ResponseError: illegal_argument_exception: [illegal_argument_exception] Reason: request [/.kibana_7.17.0_001] contains unrecognized parameter: [include_type_name]
  | │       at onBody (/opt/local-ssd/buildkite/builds/kb-n2-4-bf1ddb6b4a216c51/elastic/kibana-7-dot-latest-es-forward-compatibility/kibana/node_modules/@elastic/elasticsearch/lib/Transport.js:367:23)
  | │       at IncomingMessage.onEnd (/opt/local-ssd/buildkite/builds/kb-n2-4-bf1ddb6b4a216c51/elastic/kibana-7-dot-latest-es-forward-compatibility/kibana/node_modules/@elastic/elasticsearch/lib/Transport.js:291:11)
  | │       at IncomingMessage.emit (node:events:402:35)
  | │       at endReadableNT (node:internal/streams/readable:1343:12)
  | │       at processTicksAndRejections (node:internal/process/task_queues:83:21)
  | │
  | │
  | └-> "after all" hook for "should return 403 forbidden [hiddentype/any]"
  | └- ✖ fail: saved objects security and spaces enabled _bulk_create user with no access within the default space "after all" hook for "should return 403 forbidden [hiddentype/any]"
  | │      ResponseError: x_content_parse_exception: [parsing_exception] Reason: [1:65] [ids] unknown field [type]
  | │       at onBody (/opt/local-ssd/buildkite/builds/kb-n2-4-bf1ddb6b4a216c51/elastic/kibana-7-dot-latest-es-forward-compatibility/kibana/node_modules/@elastic/elasticsearch/lib/Transport.js:367:23)
  | │       at IncomingMessage.onEnd (/opt/local-ssd/buildkite/builds/kb-n2-4-bf1ddb6b4a216c51/elastic/kibana-7-dot-latest-es-forward-compatibility/kibana/node_modules/@elastic/elasticsearch/lib/Transport.js:291:11)
  | │       at IncomingMessage.emit (node:events:402:35)
  | │       at endReadableNT (node:internal/streams/readable:1343:12)
  | │       at processTicksAndRejections (node:internal/process/task_queues:83:21)

@mshustov I think this isn't necessarily a problem specific to Security tests, but it's a problem with Saved Objects loading/unloading?

Seems like it's coming from

before(() =>
esArchiver.load(
'x-pack/test/saved_object_api_integration/common/fixtures/es_archiver/saved_objects/spaces'
)
);
after(() =>
esArchiver.unload(
'x-pack/test/saved_object_api_integration/common/fixtures/es_archiver/saved_objects/spaces'
)
);

Related: #122814

@jportner jportner added the Team:Core Core services & architecture: plugins, logging, config, saved objects, http, ES client, i18n, etc label Jan 13, 2022
@elasticmachine
Copy link
Contributor

Pinging @elastic/kibana-core (Team:Core)

@mshustov
Copy link
Contributor

@jportner some adjustments to data archives are necessary. covered by #122962

@mshustov mshustov removed the Team:Security Team focused on: Auth, Users, Roles, Spaces, Audit Logging, and more! label Jan 17, 2022
@mshustov mshustov reopened this Jan 17, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
failed-test A test failure on a tracked branch, potentially flaky-test Team:Core Core services & architecture: plugins, logging, config, saved objects, http, ES client, i18n, etc
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants