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

Integration test & unit tests jobs separation #6649

Closed
wants to merge 13 commits into from
Closed

Integration test & unit tests jobs separation #6649

wants to merge 13 commits into from

Conversation

auvipy
Copy link
Member

@auvipy auvipy commented Feb 28, 2021

No description provided.

@auvipy auvipy added this to the 5.1.0 milestone Feb 28, 2021
@auvipy auvipy requested a review from xirdneh February 28, 2021 05:23
@auvipy
Copy link
Member Author

auvipy commented Feb 28, 2021

@xirdneh you can push improvement on this branch as use this as a base. I am checking how service containers going to work here for integration tests

@auvipy
Copy link
Member Author

auvipy commented Feb 28, 2021

pypy tests were failing before this PR.

@codecov
Copy link

codecov bot commented Feb 28, 2021

Codecov Report

Merging #6649 (a1ae742) into master (3cf5072) will decrease coverage by 0.15%.
The diff coverage is n/a.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #6649      +/-   ##
==========================================
- Coverage   89.23%   89.08%   -0.16%     
==========================================
  Files         138      138              
  Lines       16623    16623              
  Branches     2099     2099              
==========================================
- Hits        14834    14808      -26     
- Misses       1570     1597      +27     
+ Partials      219      218       -1     
Flag Coverage Δ
unittests 89.07% <ø> (-0.16%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
celery/backends/couchbase.py 40.62% <0.00%> (-42.19%) ⬇️
celery/backends/asynchronous.py 60.64% <0.00%> (+0.46%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update d3e5df3...a1ae742. Read the comment docs.

@auvipy
Copy link
Member Author

auvipy commented Feb 28, 2021

redis connection is throwing errors. the service container might need some adjsutment

@@ -63,3 +64,71 @@ jobs:
flags: unittests # optional
fail_ci_if_error: true # optional (default = false)
verbose: true # optional (default = false)


Integration:
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We need to set the integration tests to only run after the unit tests to save resources.
See syntax: https://docs.github.com/en/actions/reference/workflow-syntax-for-github-actions#jobsjob_idneeds

.github/workflows/python-package.yml Outdated Show resolved Hide resolved
@auvipy
Copy link
Member Author

auvipy commented Mar 5, 2021

@matusvalo please suggest modification too.

@matusvalo
Copy link
Member

Let me check CI in celery. It should be pretty straightforward to port kombu/py-amqp CI to celery also...

@maybe-sybr
Copy link
Contributor

Just freshened this on master. I think I'll spend a little time on it today to see if I can get the redis suite quite working as a first step and then the rabbitmq/rpc prior to merge

@maybe-sybr
Copy link
Contributor

The suite starts running now, but we have a busted test which fails the run after a few retries.

@lgtm-com
Copy link

lgtm-com bot commented May 24, 2021

This pull request introduces 1 alert when merging 1dac185 into 025bad6 - view on LGTM.com

new alerts:

  • 1 for Unused import

@@ -117,7 +117,7 @@ def test_active(self, inspect):
'exchange': '',
'routing_key': 'celery',
'priority': 0,
'redelivered': False
'redelivered': ANY,
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm not sure why these tests stopped passing. AFAICT the redelivered seems to be set to None implying that we "don't know" (or don't bother to default to False) if a task has been redelivered or not. These tests /probably/ (??) don't care about that so changing this to an ANY seems like it is okay.

I'd like for someone a bit more familiar with redelivery logic to think about this if possible. I just don't know what we should be expecting here and why it's not False like it must have been in the past.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

redelivered is set when the broker redelivers the message (at least with AMQP brokers).
I honestly don't have an idea what has changed. Do you mind debugging this?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'll see if I can find some time later this week

@lgtm-com
Copy link

lgtm-com bot commented May 24, 2021

This pull request introduces 1 alert and fixes 2 when merging bfab125 into 025bad6 - view on LGTM.com

new alerts:

  • 1 for Unused import

fixed alerts:

  • 1 for Non-exception in 'except' clause
  • 1 for Module is imported with 'import' and 'import from'

@maybe-sybr
Copy link
Contributor

maybe-sybr commented May 24, 2021

Not sure why that inspect test is failing. It passes on my box reliably. Leaving this diff for the moment, someone else can feel free to take a look at it in the meantime.

@lgtm-com
Copy link

lgtm-com bot commented May 24, 2021

This pull request introduces 1 alert when merging 8f8d402 into 025bad6 - view on LGTM.com

new alerts:

  • 1 for Unused import

python-version: ['3.7', ] #'3.8', '3.9', 'pypy3']
# XXX: Does each matrix variation get their own copy of the service
# containers? Test cross-talk may be an issue...
toxenv: ['redis', ] #'rabbitmq']
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should probably actually be called backend since it's only the tail of the toxenv name.

@thedrow thedrow removed this from the 5.1.0 milestone May 24, 2021
@thedrow
Copy link
Member

thedrow commented Aug 8, 2021

I rebased this PR.
We have to merge this soon so we can work on 5.2 safely.

@thedrow thedrow added this to the 5.2 milestone Aug 8, 2021
@lgtm-com
Copy link

lgtm-com bot commented Aug 8, 2021

This pull request fixes 2 alerts when merging 762668e into d3e5df3 - view on LGTM.com

fixed alerts:

  • 2 for Wrong name for an argument in a call

@lgtm-com
Copy link

lgtm-com bot commented Aug 9, 2021

This pull request fixes 2 alerts when merging a1ae742 into d3e5df3 - view on LGTM.com

fixed alerts:

  • 2 for Wrong name for an argument in a call

@thedrow
Copy link
Member

thedrow commented Aug 9, 2021

What is wrong with the test suite?
Is it running locally just fine? @celery/core-developers

@maybe-sybr
Copy link
Contributor

     File "/home/runner/work/celery/celery/celery/app/trace.py", line 358, in build_tracer
      push_request = request_stack.push
  AttributeError: 'NoneType' object has no attribute 'push'

This seems pretty bad 😬

@auvipy
Copy link
Member Author

auvipy commented Nov 11, 2021

     File "/home/runner/work/celery/celery/celery/app/trace.py", line 358, in build_tracer
      push_request = request_stack.push
  AttributeError: 'NoneType' object has no attribute 'push'

This seems pretty bad grimacing

was the rabbitmq tests passing? I cant remember, I can only remember redis was failing. I will be doing some experiment in another PR to see if rabbit services & tests are running. I goose step at a time, lets see

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
No open projects
Celery 5.1.0
  
Postponed
Development

Successfully merging this pull request may close these issues.

None yet

5 participants