Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 745924 - =sec-policy/selinux-base-2.20190201-r1 - python3 -t -t -E -W error support/sedoctool.py -b policy/booleans.conf -m policy/modules.conf -x doc/policy.xml : SyntaxError: "is not" with a literal. Did you mean "!="?
Summary: =sec-policy/selinux-base-2.20190201-r1 - python3 -t -t -E -W error support/se...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: SELinux (show other bugs)
Hardware: AMD64 Linux
: Normal normal (vote)
Assignee: SE Linux Bugs
URL:
Whiteboard: 2.20200818-r1
Keywords: PATCH
Depends on:
Blocks:
 
Reported: 2020-10-01 07:46 UTC by Oskari Pirhonen
Modified: 2020-12-05 05:15 UTC (History)
2 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
sec-policy/selinux-base-2.20190201-r1 emerge log (sec-policy_selinux-base-2.20190201-r1_20201001-070933.log,36.67 KB, text/plain)
2020-10-01 07:46 UTC, Oskari Pirhonen
Details
Patch to fix the aforementioned error (0001-Fix-SyntaxError-is-not-with-a-literal.patch.txt,808 bytes, patch)
2020-10-01 07:47 UTC, Oskari Pirhonen
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Oskari Pirhonen 2020-10-01 07:46:10 UTC
Created attachment 663403 [details]
sec-policy/selinux-base-2.20190201-r1 emerge log

I was following the SELinux install guide on the Gentoo wiki, and the step which has me run `FEATURES="-selinux" emerge -1 selinux-base` fails with a Python syntax error:

python3 -t -t -E -W error support/sedoctool.py -b policy/booleans.conf -m policy/modules.conf -x doc/policy.xml
  File "support/sedoctool.py", line 269
    if desc.data is not '':
       ^
SyntaxError: "is not" with a literal. Did you mean "!="?

I've attached a full log of a failed emerge.
Comment 1 Oskari Pirhonen 2020-10-01 07:47:51 UTC
Created attachment 663406 [details, diff]
Patch to fix the aforementioned error

This patch fixes the error and lets the emerge complete successfully.
Comment 2 Oskari Pirhonen 2020-10-12 19:43:32 UTC
Has anyone had a chance to look at this yet?
Comment 3 Jason Zaman gentoo-dev 2020-11-05 05:55:51 UTC
This is fixed in the 2.20200818-r1 policies
Comment 4 Jason Zaman gentoo-dev 2020-12-05 05:15:45 UTC
2.20200818-r2 is stable