Bug 1416359

Summary: Pulp generates DeprecationWarning for various scripts/actions
Product: Red Hat Satellite Reporter: Ben <ben.argyle>
Component: PulpAssignee: satellite6-bugs <satellite6-bugs>
Status: CLOSED DUPLICATE QA Contact: Katello QA List <katello-qa-list>
Severity: medium Docs Contact:
Priority: medium    
Version: 6.2.7CC: bbuckingham, egolov, jcallaha, mhrivnak
Target Milestone: UnspecifiedKeywords: Triaged
Target Release: Unused   
Hardware: x86_64   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2017-01-28 09:01:59 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
grep -i warning /var/log/messages none

Description Ben 2017-01-25 11:02:58 UTC
Description of problem:

Jan 24 01:54:24 satellite1 pulp: py.warnings:WARNING: (31066-27584) /usr/lib/python2.7/site-packages/pulp/server/db/model/__init__.py:536: DeprecationWarning: update is deprecated. Use replace_one, update_one or update_many instead.
Jan 24 01:54:24 satellite1 pulp: py.warnings:WARNING: (31066-27584)   TaskStatus._get_collection().update({'task_id': task_id}, update, upsert=True)
Jan 24 01:54:24 satellite1 pulp: py.warnings:WARNING: (31066-27584)
Jan 24 01:54:28 satellite1 pulp: py.warnings:WARNING: (31068-27584) /usr/lib/python2.7/site-packages/pulp/server/db/model/__init__.py:536: DeprecationWarning: update is deprecated. Use replace_one, update_one or update_many instead.
Jan 24 01:54:28 satellite1 pulp: py.warnings:WARNING: (31068-27584)   TaskStatus._get_collection().update({'task_id': task_id}, update, upsert=True)
Jan 24 01:54:28 satellite1 pulp: py.warnings:WARNING: (31068-27584)
Jan 24 16:33:58 satellite1 pulp: py.warnings:WARNING: (31066-20288) /usr/lib/python2.7/site-packages/pulp/server/managers/consumer/cud.py:79: DeprecationWarning: save is deprecated. Use insert_one or replace_one instead
Jan 24 16:33:58 satellite1 pulp: py.warnings:WARNING: (31066-20288)   _id = collection.save(consumer)
Jan 24 16:33:58 satellite1 pulp: py.warnings:WARNING: (31066-20288)
Jan 24 16:33:58 satellite1 pulp: py.warnings:WARNING: (31066-20288) /usr/lib/python2.7/site-packages/pulp/server/managers/consumer/history.py:88: DeprecationWarning: save is deprecated. Use insert_one or replace_one instead
Jan 24 16:33:58 satellite1 pulp: py.warnings:WARNING: (31066-20288)   ConsumerHistoryEvent.get_collection().save(event)
Jan 24 16:33:58 satellite1 pulp: py.warnings:WARNING: (31066-20288)
Jan 24 16:34:01 satellite1 pulp: py.warnings:WARNING: (31066-23424) /usr/lib/python2.7/site-packages/pulp/server/managers/consumer/profile.py:64: DeprecationWarning: save is deprecated. Use insert_one or replace_one instead
Jan 24 16:34:01 satellite1 pulp: py.warnings:WARNING: (31066-23424)   collection.save(p)
Jan 24 16:34:01 satellite1 pulp: py.warnings:WARNING: (31066-23424)
[...]
Jan 24 16:34:59 satellite1 pulp: py.warnings:WARNING: (31068-23424) /usr/lib/python2.7/site-packages/pulp/server/managers/consumer/profile.py:64: DeprecationWarning: save is deprecated. Use insert_one or replace_one instead
Jan 24 16:34:59 satellite1 pulp: py.warnings:WARNING: (31068-23424)   collection.save(p)
Jan 24 16:34:59 satellite1 pulp: py.warnings:WARNING: (31068-23424)
Jan 24 16:34:59 satellite1 pulp: py.warnings:WARNING: (31068-23424) /usr/lib/python2.7/site-packages/pulp/server/managers/consumer/history.py:88: DeprecationWarning: save is deprecated. Use insert_one or replace_one instead
Jan 24 16:34:59 satellite1 pulp: py.warnings:WARNING: (31068-23424)   ConsumerHistoryEvent.get_collection().save(event)
Jan 24 16:34:59 satellite1 pulp: py.warnings:WARNING: (31068-23424)
Jan 24 16:35:00 satellite1 pulp: py.warnings:WARNING: (31068-27584) /usr/lib/python2.7/site-packages/pulp/server/managers/consumer/bind.py:75: DeprecationWarning: save is deprecated. Use insert_one or replace_one instead
Jan 24 16:35:00 satellite1 pulp: py.warnings:WARNING: (31068-27584)   collection.save(bind)
Jan 24 16:35:00 satellite1 pulp: py.warnings:WARNING: (31068-27584)
Jan 24 16:35:03 satellite1 pulp: py.warnings:WARNING: (31067-32864) /usr/lib/python2.7/site-packages/pulp/server/managers/consumer/bind.py:75: DeprecationWarning: save is deprecated. Use insert_one or replace_one instead
Jan 24 16:35:03 satellite1 pulp: py.warnings:WARNING: (31067-32864)   collection.save(bind)
Jan 24 16:35:03 satellite1 pulp: py.warnings:WARNING: (31067-32864)
Jan 24 16:35:03 satellite1 pulp: py.warnings:WARNING: (31067-32864) /usr/lib/python2.7/site-packages/pulp/server/managers/consumer/history.py:88: DeprecationWarning: save is deprecated. Use insert_one or replace_one instead
Jan 24 16:35:03 satellite1 pulp: py.warnings:WARNING: (31067-32864)   ConsumerHistoryEvent.get_collection().save(event)
Jan 24 16:35:03 satellite1 pulp: py.warnings:WARNING: (31067-32864)
[...]
Jan 24 16:36:12 satellite1 pulp: py.warnings:WARNING: (31067-05696) /usr/lib/python2.7/site-packages/pulp/server/managers/consumer/profile.py:64: DeprecationWarning: save is deprecated. Use insert_one or replace_one instead
Jan 24 16:36:12 satellite1 pulp: py.warnings:WARNING: (31067-05696)   collection.save(p)
Jan 24 16:36:12 satellite1 pulp: py.warnings:WARNING: (31067-05696)
Jan 24 16:38:12 satellite1 pulp: py.warnings:WARNING: (31067-05696) /usr/lib/python2.7/site-packages/mongoengine/document.py:324: DeprecationWarning: save is deprecated. Use insert_one or replace_one instead
Jan 24 16:38:12 satellite1 pulp: py.warnings:WARNING: (31067-05696)   object_id = collection.save(doc, **write_concern)
Jan 24 16:38:12 satellite1 pulp: py.warnings:WARNING: (31067-05696)
Jan 24 16:38:12 satellite1 pulp: py.warnings:WARNING: (31066-23424) /usr/lib/python2.7/site-packages/mongoengine/document.py:324: DeprecationWarning: save is deprecated. Use insert_one or replace_one instead
Jan 24 16:38:12 satellite1 pulp: py.warnings:WARNING: (31066-23424)   object_id = collection.save(doc, **write_concern)
Jan 24 16:38:12 satellite1 pulp: py.warnings:WARNING: (31066-23424)
Jan 24 16:38:12 satellite1 pulp: py.warnings:WARNING: (31068-27584) /usr/lib/python2.7/site-packages/mongoengine/document.py:324: DeprecationWarning: save is deprecated. Use insert_one or replace_one instead
Jan 24 16:38:12 satellite1 pulp: py.warnings:WARNING: (31068-27584)   object_id = collection.save(doc, **write_concern)
Jan 24 16:38:12 satellite1 pulp: py.warnings:WARNING: (31068-27584)
Jan 24 16:38:14 satellite1 pulp: py.warnings:WARNING: (31067-05696) /usr/lib/python2.7/site-packages/pulp/server/db/model/__init__.py:536: DeprecationWarning: update is deprecated. Use replace_one, update_one or update_many instead.
Jan 24 16:38:14 satellite1 pulp: py.warnings:WARNING: (31067-05696)   TaskStatus._get_collection().update({'task_id': task_id}, update, upsert=True)
Jan 24 16:38:14 satellite1 pulp: py.warnings:WARNING: (31067-05696)

Version-Release number of selected component (if applicable):


How reproducible:


Steps to Reproduce:
1.
2.
3.

Actual results:


Expected results:


Additional info:

Comment 1 Ben 2017-01-26 11:35:46 UTC
Created attachment 1244755 [details]
grep -i warning /var/log/messages

This is a grep of /var/log/messages for WARNING/warning.  It shows a lot of deprecation warnings both for celery and Python itself.

Comment 2 Ben 2017-01-26 11:36:57 UTC
Apologies, the new attachment was of /var/log/messages following a 6.2.6->6.2.7 upgrade.

Comment 4 Michael Hrivnak 2017-01-28 09:01:59 UTC
Thanks for the report. Luckily we're already tracking this issue and have a fix in-progress.

*** This bug has been marked as a duplicate of bug 1365348 ***

Comment 5 Michael Hrivnak 2017-01-28 09:02:35 UTC
And here is the upstream issue just for reference: https://pulp.plan.io/issues/1594

Comment 6 Ben 2017-01-30 10:06:18 UTC
That's excellent.  Thank you for the information.  Is there a approximate ETA for the fix?  I can't see bug 1365348.