This is what I see after all the Puppetclass destroy events. Also I’ve now added and synched the Library environment to the proxy, but this puppet environment for this also has the same issue with the classes being removed. But also only on promotion not the first Library publish.
2019-08-01T11:00:42 [I|app|9462b42c] Processing by PuppetclassesController#index as HTML
Response: 200: [{"scratchpad": {"checksum_type": "sha256"}, "display_name": "CentOS-7_sclo x86_64 rh", "description": null, "last_unit_added": "2019-07-29T09:38:03Z", "notes": {"_repo-type": "rpm-repo"}, "last_unit_removed": null, "content_unit_counts": {"rpm": 8373}, "_ns": "repos", "_id": {"$oid": "5d3ebb04eb12d86db2e9f042"}, "id": "7-CentOS7_Base-DEV-d91dd7f5-1f06-44fa-90d4-ae45077aed3b", "_href": "/pulp/api/v2/repositories/7-CentOS7_Base-DEV-d91dd7f5-1f06-44fa-90d4-ae45077aed3b/"}, {"scratchpad": {"checksum_type": "sha1"}, "display_name": "Puppet 6", "description": null, "last_unit_added": "2019-07-29T10:28:19Z", "notes": {"_repo-type": "rpm-repo"}, "last_unit_removed": null, "content_unit_counts": {"rpm": 106}, "_ns": "repos", "_id": {"$oid": "5d3ebb02eb12d86db3931445"}, "id": "7-CentOS7_Base-DEV-cf2b657c-c824-4af3-8350-0555a4964703", "_href": "/pulp/api/v2/repositories/7-CentOS7_Base-DEV-cf2b657c-c824-4af3-8350-0555a4964703/"}, {"scratchpad": {"checksum_type": "sha256"}, "display_name": "CentOS-7_updates x86_64", "description": null, "last_unit_added": "2019-07-29T10:44:18Z", "notes": {"_repo-type": "rpm-repo"}, "last_unit_removed": null, "content_unit_counts": {"rpm": 2303}, "_ns": "repos", "_id": {"$oid": "5d3ebb06eb12d86db2e9f045"}, "id": "7-CentOS7_Base-DEV-c7935819-6a03-42a9-a14b-9985123c0f85", "_href": "/pulp/api/v2/repositories/7-CentOS7_Base-DEV-c7935819-6a03-42a9-a14b-9985123c0f85/"}, {"scratchpad": {"checksum_type": "sha256"}, "display_name": "CentOS-7_os x86_64", "description": null, "last_unit_added": "2019-07-29T10:08:01Z", "notes": {"_repo-type": "rpm-repo"}, "last_unit_removed": null, "content_unit_counts": {"package_group": 88, "distribution": 1, "rpm": 10019}, "_ns": "repos", "_id": {"$oid": "5d3ebb05eb12d86db393144d"}, "id": "7-CentOS7_Base-DEV-c6c07d48-646f-4ead-865d-1d00bdc22e75", "_href": "/pulp/api/v2/repositories/7-CentOS7_Base-DEV-c6c07d48-646f-4ead-865d-1d00bdc22e75/"}, {"scratchpad": {"checksum_type": "sha256"}, "display_name": "Foreman client 1.22 x86_64", "description": null, "last_unit_added": "2019-07-29T09:25:00Z", "notes": {"_repo-type": "rpm-repo"}, "last_unit_removed": null, "content_unit_counts": {"package_group": 1, "rpm": 10}, "_ns": "repos", "_id": {"$oid": "5d3ebb02eb12d86db2e9f03f"}, "id": "7-CentOS7_Base-DEV-9eedc3c1-c4eb-4ee0-bf4e-b2fd04d3accd", "_href": "/pulp/api/v2/repositories/7-CentOS7_Base-DEV-9eedc3c1-c4eb-4ee0-bf4e-b2fd04d3accd/"}, {"scratchpad": {"checksum_type": "sha256"}, "display_name": "CentOS-7_sclo x86_64 sclo", "description": null, "last_unit_added": "2019-07-29T10:45:13Z", "notes": {"_repo-type": "rpm-repo"}, "last_unit_removed": null, "content_unit_counts": {"rpm": 786}, "_ns": "repos", "_id": {"$oid": "5d3ebb04eb12d86db19dfe9e"}, "id": "7-CentOS7_Base-DEV-68cb8112-fd0f-48b1-8887-c044aa5cf767", "_href": "/pulp/api/v2/repositories/7-CentOS7_Base-DEV-68cb8112-fd0f-48b1-8887-c044aa5cf767/"}, {"scratchpad": {"checksum_type": "sha256"}, "display_name": "CentOS-7_extras x86_64", "description": null, "last_unit_added": "2019-07-29T09:24:52Z", "notes": {"_repo-type": "rpm-repo"}, "last_unit_removed": null, "content_unit_counts": {"rpm": 419}, "_ns": "repos", "_id": {"$oid": "5d3ebb02eb12d86db3931444"}, "id": "7-CentOS7_Base-DEV-5f2ea244-ed1d-4483-baeb-a787926fdb30", "_href": "/pulp/api/v2/repositories/7-CentOS7_Base-DEV-5f2ea244-ed1d-4483-baeb-a787926fdb30/"}, {"scratchpad": {"checksum_type": "sha256"}, "display_name": "CentOS-7_configmanagement x86_64 ansible27", "description": null, "last_unit_added": "2019-07-29T09:28:04Z", "notes": {"_repo-type": "rpm-repo"}, "last_unit_removed": null, "content_unit_counts": {"rpm": 9}, "_ns": "repos", "_id": {"$oid": "5d3ebb03eb12d86db393144a"}, "id": "7-CentOS7_Base-DEV-5b7bde62-06c8-4023-a058-e4f817e4477b", "_href": "/pulp/api/v2/repositories/7-CentOS7_Base-DEV-5b7bde62-06c8-4023-a058-e4f817e4477b/"}, {"scratchpad": {"checksum_type": "sha256"}, "display_name": "Zabbix 4.2 rhel 7 x86_64", "description": null, "last_unit_added": "2019-07-29T09:27:54Z", "notes": {"_repo-type": "rpm-repo"}, "last_unit_removed": null, "content_unit_counts": {"rpm": 79}, "_ns": "repos", "_id": {"$oid": "5d3ebb02eb12d86db19dfe9b"}, "id": "7-CentOS7_Base-DEV-13c733e4-1c79-4c96-a992-f084abc3668b", "_href": "/pulp/api/v2/repositories/7-CentOS7_Base-DEV-13c733e4-1c79-4c96-a992-f084abc3668b/"}, {"scratchpad": {"checksum_type": "sha256"}, "display_name": "Epel_7", "description": null, "last_unit_added": "2019-07-31T11:05:17Z", "notes": {"_repo-type": "rpm-repo"}, "last_unit_removed": "2019-07-31T11:02:52Z", "content_unit_counts": {"package_group": 33, "rpm": 13328, "erratum": 4328}, "_ns": "repos", "_id": {"$oid": "5d3ebb06eb12d86db19dfea1"}, "id": "7-CentOS7_Base-DEV-0cbe31d4-d40d-4f25-9842-e3d57e27b02f", "_href": "/pulp/api/v2/repositories/7-CentOS7_Base-DEV-0cbe31d4-d40d-4f25-9842-e3d57e27b02f/"}]
Response: 200: [{"scratchpad": {}, "display_name": "CentOS7_Base Puppet Environment", "description": null, "last_unit_added": "2019-07-30T12:14:49Z", "notes": {"_repo-type": "puppet-repo"}, "last_unit_removed": null, "content_unit_counts": {"puppet_module": 12}, "_ns": "repos", "_id": {"$oid": "5d3ebb06eb12d86db19dfea4"}, "id": "7-CentOS7_Base-DEV-puppet-d4c00915-ac1c-4306-a151-c4d0191bf920", "_href": "/pulp/api/v2/repositories/7-CentOS7_Base-DEV-puppet-d4c00915-ac1c-4306-a151-c4d0191bf920/"}]
2019-08-01T11:00:50 [I|app|2a288f2e] Processing by PuppetclassesController#index as HTML
Response: 200: {"scratchpad": {"checksum_type": "sha1"}, "display_name": "Puppet 6", "description": null, "distributors": [{"repo_id": "7-CentOS7_Base-DEV-cf2b657c-c824-4af3-8350-0555a4964703", "last_updated": "2019-07-29T09:23:14Z", "_href": "/pulp/api/v2/repositories/7-CentOS7_Base-DEV-cf2b657c-c824-4af3-8350-0555a4964703/distributors/7-CentOS7_Base-DEV-cf2b657c-c824-4af3-8350-0555a4964703/", "last_override_config": {}, "last_publish": "2019-07-31T22:27:33Z", "distributor_type_id": "yum_distributor", "auto_publish": true, "scratchpad": {}, "_ns": "repo_distributors", "_id": {"$oid": "5d3ebb02eb12d86db3931449"}, "config": {"protected": true, "http": true, "https": true, "relative_url": "TEST/DEV/CentOS7_Base/custom/Puppet/Puppet_6"}, "id": "7-CentOS7_Base-DEV-cf2b657c-c824-4af3-8350-0555a4964703"}], "last_unit_added": "2019-07-29T10:28:19Z", "notes": {"_repo-type": "rpm-repo"}, "last_unit_removed": null, "content_unit_counts": {"rpm": 106}, "_ns": "repos", "importers": [{"repo_id": "7-CentOS7_Base-DEV-cf2b657c-c824-4af3-8350-0555a4964703", "last_updated": "2019-07-29T09:23:14Z", "_href": "/pulp/api/v2/repositories/7-CentOS7_Base-DEV-cf2b657c-c824-4af3-8350-0555a4964703/importers/yum_importer/", "_ns": "repo_importers", "importer_type_id": "yum_importer", "last_override_config": {}, "last_sync": "2019-07-31T21:44:29Z", "scratchpad": {"repomd_revision": 1564394535, "repomd_checksum": "c8f91f672f85b95f361e9e6bcfe9de08b83816baaafd04d10ae33588044796b3"}, "_id": {"$oid": "5d3ebb02eb12d86db3931447"}, "config": {"feed": "https://***.****.***/pulp/repos/TEST/DEV/CentOS7_Base/custom/Puppet/Puppet_6/", "ssl_ca_cert": "Certificate: ***** -----END RSA PRIVATE KEY-----\n"}, "id": "yum_importer"}], "locally_stored_units": 1, "_id": {"$oid": "5d3ebb02eb12d86db3931445"}, "total_repository_units": 106, "id": "7-CentOS7_Base-DEV-cf2b657c-c824-4af3-8350-0555a4964703", "_href": "/pulp/api/v2/repositories/7-CentOS7_Base-DEV-cf2b657c-c824-4af3-8350-0555a4964703/"}
Response: 200: {"scratchpad": {}, "display_name": "CentOS7_Base Puppet Environment", "description": null, "distributors": [{"repo_id": "7-CentOS7_Base-DEV-puppet-d4c00915-ac1c-4306-a151-c4d0191bf920", "last_updated": "2019-07-29T09:23:18Z", "_href": "/pulp/api/v2/repositories/7-CentOS7_Base-DEV-puppet-d4c00915-ac1c-4306-a151-c4d0191bf920/distributors/7-CentOS7_Base-DEV-puppet-d4c00915-ac1c-4306-a151-c4d0191bf920_puppet/", "last_override_config": {}, "last_publish": "2019-07-31T22:42:05Z", "distributor_type_id": "puppet_distributor", "auto_publish": true, "scratchpad": {}, "_ns": "repo_distributors", "_id": {"$oid": "5d3ebb06eb12d86db19dfea6"}, "config": {"serve_https": true, "serve_http": false}, "id": "7-CentOS7_Base-DEV-puppet-d4c00915-ac1c-4306-a151-c4d0191bf920_puppet"}, {"repo_id": "7-CentOS7_Base-DEV-puppet-d4c00915-ac1c-4306-a151-c4d0191bf920", "last_updated": "2019-07-29T09:23:18Z", "_href": "/pulp/api/v2/repositories/7-CentOS7_Base-DEV-puppet-d4c00915-ac1c-4306-a151-c4d0191bf920/distributors/7-CentOS7_Base-DEV-puppet-d4c00915-ac1c-4306-a151-c4d0191bf920/", "last_override_config": {}, "last_publish": "2019-07-31T22:42:06Z", "distributor_type_id": "puppet_install_distributor", "auto_publish": true, "scratchpad": {}, "_ns": "repo_distributors", "_id": {"$oid": "5d3ebb06eb12d86db19dfea7"}, "config": {"install_path": "/etc/puppetlabs/code/environments/KT_TEST_DEV_CentOS7_Base_20", "subdir": "modules"}, "id": "7-CentOS7_Base-DEV-puppet-d4c00915-ac1c-4306-a151-c4d0191bf920"}], "last_unit_added": "2019-07-30T12:14:49Z", "notes": {"_repo-type": "puppet-repo"}, "last_unit_removed": null, "content_unit_counts": {"puppet_module": 12}, "_ns": "repos", "importers": [{"repo_id": "7-CentOS7_Base-DEV-puppet-d4c00915-ac1c-4306-a151-c4d0191bf920", "last_updated": "2019-07-29T09:23:18Z", "_href": "/pulp/api/v2/repositories/7-CentOS7_Base-DEV-puppet-d4c00915-ac1c-4306-a151-c4d0191bf920/importers/puppet_importer/", "_ns": "repo_importers", "importer_type_id": "puppet_importer", "last_override_config": {}, "last_sync": "2019-07-31T22:41:45Z", "scratchpad": null, "_id": {"$oid": "5d3ebb06eb12d86db19dfea5"}, "config": {"feed": "https://***.****.***/pulp/puppet/7-CentOS7_Base-DEV-puppet-d4c00915-ac1c-4306-a151-c4d0191bf920/", "ssl_ca_cert": "Certificate:\n ***-----END RSA PRIVATE KEY-----\n"}, "id": "puppet_importer"}], "locally_stored_units": 12, "_id": {"$oid": "5d3ebb06eb12d86db19dfea4"}, "total_repository_units": 12, "id": "7-CentOS7_Base-DEV-puppet-d4c00915-ac1c-4306-a151-c4d0191bf920", "_href": "/pulp/api/v2/repositories/7-CentOS7_Base-DEV-puppet-d4c00915-ac1c-4306-a151-c4d0191bf920/"}