pull request commentmoby/moby
overlay[2] graphdriver: Fix/improve overlayfs support check for rootless
This works like a champ on CentOS 7.7 choosing between vfs and overlay2. Similar to my own original patch, I have no idea how to test overlay vs overlay2 detection.
comment created time in 6 days
pull request commentmoby/moby
overlay[2] graphdriver: Fix/improve overlayfs support check for rootless
I'm unfortunately away from a Docker-friendly computer for the weekend. I'll check it out on Monday and report back.
comment created time in 8 days
pull request commentmoby/moby
Improve rootless Docker overlay support detection
For whatever my opinion is worth, the functions are basically the same but only by happenstance rather than design (i.e. they both use overlay mount type versus this being a generic "try to mount it function"). Also, I think there is value in each filesystem detection routine being separate.
Ultimately, it's up to you maintainer folk and I'll happily make the code work either way.
comment created time in 18 days
issue commentsdispater/poetry
Poetry breaks when there are spaces in path to Python
@finswimmer are your concerns about environment variables targeted at this particular problem or generic? I can't think of any sane circumstance where it would be an issue here.
The only thing I can think of is if the shell launched by Python via shell=True sources a different set of environment variables than what were defined before Python was executed. However, the function in question shouldn't be dependent on any external variables.
comment created time in 22 days
push eventCaligatio/moby
commit sha e8d468b234809e382e3ebc83355c367101e43af5
Changing comparison to bool constant to shorter form Signed-off-by: Brian Turek <[email protected]>
push time in 23 days
push eventCaligatio/moby
commit sha 895e1c585166ece4c904c54d287cd1904ee0ceed
Change error catching when making directories Signed-off-by: Brian Turek <[email protected]>
push time in 23 days
issue commentdocker/for-linux
Rootless Docker fails at detecting root-requiring overlay support
PR is now at moby/moby#40131
comment created time in 24 days
PR opened moby/moby
Signed-off-by: Brian Turek [email protected]
<!-- Please make sure you've read and understood our contributing guidelines; https://github.com/moby/moby/blob/master/CONTRIBUTING.md
** Make sure all your commits include a signature generated with git commit -s **
For additional information on our contributing process, read our contributing guide https://docs.docker.com/opensource/code/
If this is a bug fix, make sure your description includes "fixes #xxxx", or "closes #xxxx"
Please provide the following information: -->
- What I did Fixed overlay support detection for rootless Docker on CentOS (and other non-Ubuntu based distros). The current implementation causes runtime errors when running rootless Docker on CentOS due lack of mounting permissions. See docker/for-linux#836 and docker-library/docker#193 for related tickets
- How I did it Current overlay detection works by merely checking for filesystem support for overlay rather than overlay support for that particular user (i.e. Ubuntu allows non-root users to use overlay, CentOS does not). This patch changes the logic to attempt a real overlay mount and determine overlay support by checking whether than mount was successful.
Note that this is literally the first time I've written Go so constructive criticism is appreciated.
- How to verify it
- Run the new dockerd binary as rootless on CentOS, the storage-driver falls back to
vfs - Run the new dockerd binary as root on CentOS, the storage-driver is
overlay2 - Run the new dockerd binary as rootless on Ubuntu, the storage-driver is
overlay2 - Run the new dockerd binary as root on Ubuntu, the storage-driver is
overlay2
- Description for the changelog <!-- Write a short (one line) summary that describes the changes in this pull request for inclusion in the changelog: --> Improve rootless Docker overlay support detection
- A picture of a cute animal (not mandatory but encouraged)
pr created time in 24 days
fork Caligatio/moby
Moby Project - a collaborative project for the container ecosystem to assemble container-based systems
fork in 24 days
issue openeddocker/for-linux
Rootless Docker fails at detecting root-requiring overlay support
<!-- This issue tracker is for bug reports and feature requests. For questions, and getting help on using docker:
- Docker documentation - https://docs.docker.com
- Docker Forums - https://forums.docker.com
- Docker community Slack - https://dockercommunity.slack.com/ (register here: http://dockr.ly/community)
- Post a question on StackOverflow, using the Docker tag -->
- [x] This is a bug report
- [ ] This is a feature request
- [ ] I searched existing issues before opening this one
<!-- DO NOT report security issues publicly! If you suspect you discovered a security issue, send your report privately to [email protected]. -->
Expected behavior
Rootless Docker detection of filesystem support should exclude CentOS's implementation of overlay as it requires root to work
Actual behavior
Rootless Docker detects the overlay kernel module is loaded and assumes it will work causing runtime failures
Steps to reproduce the behavior
<!-- Describe the exact steps to reproduce. If possible, provide a minimum reproduction example; take into account that others do not have access to your private images, source code, and environment.
REMOVE SENSITIVE DATA BEFORE POSTING (replace those parts with "REDACTED")
-->
I worked with the docker:dind-rootless image team on docker-library/docker#193 to work this out.
Steps:
- sudo modprobe overlay
- ./dockerd-rootless.sh --experimental
- docker -H unix:///run/user/1000/docker.sock run -ti alpine
docker: Error response from daemon: error creating overlay mount to /home/brian/.local/share/docker/overlay/918283926d7ce7e89ed73b6b17034793980a11b4f07534ba411bd54ee177dece-init/merged: operation not permitted.
I believe the problem lies with https://github.com/docker/docker-ce/blob/6d1e64f40569cf42e2f684690d1e2f5cff9546d1/components/engine/daemon/graphdriver/overlay2/overlay.go#L286 which doesn't check the return of the mount attempt to see if there was an error.
Output of docker version:
Client: Docker Engine - Community
Version: 19.03.4
API version: 1.40
Go version: go1.12.10
Git commit: 9013bf583a
Built: Fri Oct 18 15:52:22 2019
OS/Arch: linux/amd64
Experimental: false
Server: Docker Engine - Community
Engine:
Version: 19.03.4
API version: 1.40 (minimum version 1.12)
Go version: go1.12.10
Git commit: 9013bf583a
Built: Fri Oct 18 15:50:54 2019
OS/Arch: linux/amd64
Experimental: true
containerd:
Version: 1.2.10
GitCommit: b34a5c8af56e510852c35414db4c1f4fa6172339
runc:
Version: 1.0.0-rc8+dev
GitCommit: 3e425f80a8c931f88e6d94a8c831b9d5aa481657
docker-init:
Version: 0.18.0
GitCommit: fec3683
Output of docker info:
Client:
Debug Mode: false
Server:
Containers: 0
Running: 0
Paused: 0
Stopped: 0
Images: 1
Server Version: 19.03.4
Storage Driver: overlay
Backing Filesystem: xfs
Supports d_type: true
Logging Driver: json-file
Cgroup Driver: none
Plugins:
Volume: local
Network: bridge host ipvlan macvlan null overlay
Log: awslogs fluentd gcplogs gelf journald json-file local logentries splunk syslog
Swarm: inactive
Runtimes: runc
Default Runtime: runc
Init Binary: docker-init
containerd version: b34a5c8af56e510852c35414db4c1f4fa6172339
runc version: 3e425f80a8c931f88e6d94a8c831b9d5aa481657
init version: fec3683
Security Options:
seccomp
Profile: default
rootless
Kernel Version: 3.10.0-1062.4.1.el7.x86_64
Operating System: CentOS Linux 7 (Core)
OSType: linux
Architecture: x86_64
CPUs: 2
Total Memory: 3.701GiB
Name: localhost.localdomain
ID: V2R5:7CUM:WUBK:CMPZ:5CXD:NMNA:DDKF:W4GJ:YZBF:JJWW:DUHW:Z6LK
Docker Root Dir: /home/brian/.local/share/docker
Debug Mode: false
Registry: https://index.docker.io/v1/
Labels:
Experimental: true
Insecure Registries:
127.0.0.0/8
Live Restore Enabled: false
WARNING: bridge-nf-call-iptables is disabled
WARNING: bridge-nf-call-ip6tables is disabled
WARNING: the overlay storage-driver is deprecated, and will be removed in a future release.
Additional environment details (AWS, VirtualBox, physical, etc.) This testing has been done entirely on CentOS 7 VMs using various hypervisors
created time in 24 days
issue closeddocker-library/docker
dind-rootless image needs overlay detection
I've been working on getting docker:dind-rootless working on CentOS 7.7 and ran into an issue because of overlay detection. The docker:dind-rootless image apparently assumes the host OS supports overlay (there's even a TODO) which then causes the image to fail when launching child containers with a "operation not permitted" referencing the overlay mount command.
My workaround is passing --storage-driver=vfs on the docker run but I believe that the image should auto-detect overlay support or have documentation about the above flag.
closed time in 24 days
Caligatioissue commentdocker-library/docker
dind-rootless image needs overlay detection
So a manual sudo modprobe overlay on the host causes both cases to "succeed" in detecting overlay but then of course fail when it actually tries to use it. It appears that dockerd's detection of rootless overlay appears to be lacking.
It appears my test order was what caused the confusion. I always tried native rootless Docker first (it cannot load the overlay module) which correctly used vfs. I then always started a rootful Docker daemon to try dind-rootless and the rootful Docker daemon loaded the overlay module.
Thanks for the help; off to submit bug report with Docker proper!
comment created time in 24 days
issue commentdocker-library/docker
dind-rootless image needs overlay detection
It's definitely something unique to the image vs an underlying dockerd problem (I think).
Relevant log entries from running rootless Docker directly on host (note the use of vfs):
ERRO[2019-10-22T07:53:59.008188371+01:00] 'overlay' not found as a supported filesystem on this host. Please ensure kernel is new enough and has overlay support loaded. storage-driver=overlay2
ERRO[2019-10-22T07:53:59.009369254+01:00] AUFS cannot be used in non-init user namespace storage-driver=aufs
ERRO[2019-10-22T07:53:59.014333070+01:00] 'overlay' not found as a supported filesystem on this host. Please ensure kernel is new enough and has overlay support loaded. storage-driver=overlay
INFO[2019-10-22T07:53:59.032246241+01:00] Loading containers: start.
WARN[2019-10-22T07:53:59.035343935+01:00] Running modprobe bridge br_netfilter failed with message: modprobe: ERROR: could not insert 'br_netfilter': Operation not permitted
insmod /lib/modules/3.10.0-1062.4.1.el7.x86_64/kernel/net/bridge/br_netfilter.ko.xz
, error: exit status 1
INFO[2019-10-22T07:53:59.119941796+01:00] Default bridge (docker0) is assigned with an IP address 172.17.0.0/16. Daemon option --bip can be used to set a preferred IP address
INFO[2019-10-22T07:53:59.155279439+01:00] Loading containers: done.
INFO[2019-10-22T07:53:59.165889078+01:00] Docker daemon commit=9013bf583a graphdriver(s)=vfs version=19.03.4
Relevant log entries from running docker run -ti --privileged docker:dind-rootless on a rootful docker daemon (note use of overlay):
ERRO[2019-10-22T06:56:41.322548316Z] AUFS cannot be used in non-init user namespace storage-driver=aufs
WARN[2019-10-22T06:56:41.325611279Z] [graphdriver] WARNING: the overlay storage-driver is deprecated, and will be removed in a future release
INFO[2019-10-22T06:56:41.358526463Z] Loading containers: start.
WARN[2019-10-22T06:56:41.390562547Z] Running modprobe bridge br_netfilter failed with message: Device "bridge" does not exist.
bridge 151336 2 br_netfilter,ebtable_broute
stp 12976 1 bridge
llc 14552 2 bridge,stp
Device "br_netfilter" does not exist.
br_netfilter 22256 0
bridge 151336 2 br_netfilter,ebtable_broute
modprobe: can't change directory to '/lib/modules': No such file or directory
, error: exit status 1
INFO[2019-10-22T06:56:41.479545182Z] Default bridge (docker0) is assigned with an IP address 172.17.0.0/16. Daemon option --bip can be used to set a preferred IP address
INFO[2019-10-22T06:56:41.509871117Z] Loading containers: done.
INFO[2019-10-22T06:56:41.537544463Z] Docker daemon commit=9013bf583a graphdriver(s)=overlay version=19.03.4
There are enough moving/experimental parts here that there might be something else going on. Any ideas? I'm happy to experiment.
comment created time in a month
issue openeddocker-library/docker
dind-rootless image needs overlay detection
I've been working on getting docker:dind-rootless working on CentOS 7.7 and ran into an issue because of overlay detection. The docker:dind-rootless image apparently assumes the host OS supports overlay (there's even a TODO) which then causes the image to fail when launching child containers with a "operation not permitted" referencing the overlay mount command.
My workaround is passing --storage-driver=vfs on the docker run but I believe that the image should auto-detect overlay support or have documentation about the above flag.
created time in a month
pull request commentsdispater/poetry
Add support for custom certificate authority and client certificates
Rebased to master and merged in the changes. Should be good to go!
comment created time in a month
push eventCaligatio/poetry
commit sha 8ee4c89094c33bd712164fbc55a8d06af6c017ca
Make black happy
push time in a month
push eventCaligatio/poetry
commit sha 58ba79c997bc3331c0f7a3f2de679b26cfbab761
Ignore packages with invalid metadata (#1346) Some packages (like `pygame-music-grid`) have unparseable metadata. This resulted in a ValueError. pip ignores packages like these, so it's reasonable to do the same in poetry itself and only display the well-formed ones. Fixes #1345. Fixes #637.
commit sha cb8dc0d94e68042f120441b4e30d89c92598b40e
Use consistent indicative grammar mood in command-line help (#1369) * Update about.py * Update add.py * Update update.py
commit sha 2f84178e6fd183539a85cb2d08c173595f011c7f
Enforce package name for poetry projects from directory source (#1327)
commit sha c9bacf53b79132ac4402763001d48cc1ce92b7c2
Improve issue templates (#1398) * Update issue templates, thanks @explosion for the inspiration. Direct support questions to StackOverflow instead. * Remove stale issue templates. * Update ---bug-report.md * Update ---documentation.md
commit sha 9e9f44553b19687c4c8cdd15cf3c7bf17d63dc99
Fix small typos, missing header, and add label to Documentation.
commit sha 0a5b448d27e08e9930163a01fb17a3aa8a61f437
Improve command-line descriptions (#1374)
commit sha 4ea2ea18852ddda372566d0603ff0c56afe39169
Use canonical name when validating package from directory (#1305) Closes: #1303
commit sha f0855d984d9b0b38657c8b8522d3cfa36280b47c
Ensure develop flag is respected for git packages (#1321) Resolves: #1080
commit sha 66790b4d17f4152995b80dcddeac8d1530a0d55d
docs: Specify Python versions using double pipe (#1397) * Fix specification of Python versions for dependencies using double pipe (`||`) instead of using an array which leads to confusion (see for instance https://github.com/sdispater/poetry/issues/847). * Fixes #847 Signed-off-by: mr.Shu <[email protected]>
commit sha 3fa47e0208b13fd71284402de6a810a9c2a56fae
Improve the shell command (#1395)
commit sha 845ae55c3c85714e4234c9ad46d3c8665f2592db
Merge branch 'master' into develop
commit sha aa2cc9b58b9ce869c0625463197e4799aca84c2e
Update lock file
commit sha 4c6d225024115eba60ab89e80d6a4f03dd886777
Align the debug resolve command with add and init
commit sha 4dfd66a168df9a3cefe5242f77928a90dc47c9ae
Fix inline tables issues by upgrading tomlkit
commit sha 183258c18ff7294d70f98c9ddafc993600775934
Fix remaining calls to Poetry.create()
commit sha a581ff62106f69c03aec26607e0b5fcb790fc052
Use `os.execvp` for `poetry run` (#1236) * Use os.execvp for poetry run * Use subprocess.Popen for Windows * Handle env kwargs
commit sha c7c20d8c94ffa2b7a1ccfa3cd041e155072ab20e
Add support for special characters in username/password for pip (#1341)
commit sha 02d78ba87c48ec7e5e979c9a3624c038235c4d50
Add support for Python 3.8 (#1437)
commit sha 94dd726e34bdbf7f55c0104198e49651bfefee68
Fix console output render for show command (#1430) Resolves: #1401
commit sha af71f6c0e585ac20a029e1eccb6501898adb6395
Fix invalid lock file generation in some cases
push time in a month
pull request commentsdispater/poetry
Add support for custom certificate authority and client certificates
I consider it done and am just waiting on it to be merged.
comment created time in a month
pull request commentsdispater/poetry
Add support for special characters in username/password for pip
As @oleastre mentioned, there is a significant code divergence between master and develop so the patch cannot be applied to master. My recommendation is to not let perfect be the enemy of good and just merge both #1402 and this PR.
Honestly, this master vs develop situation is a giant pain and, as highlighted by this situation, is impeding work. It's only getting worse since there was a major refactor in develop that changes many core functions.
comment created time in 2 months
pull request commentsdispater/poetry
Add support for custom certificate authority and client certificates
Checked it today and it both pulls packages using certs and will publish. Confidence restored!
comment created time in 2 months
pull request commentsdispater/poetry
Add support for custom certificate authority and client certificates
I changed the name and was very confident everything would continue working, however, there were major changes to develop that make me less confident.
comment created time in 2 months
push eventCaligatio/poetry
commit sha acf9ecf83c5fc1f83c682c25b62e89b114e94ab5
fix typo in doc site poetry = 'poetry:console.run' is wrong. poetry = 'poetry.console:run' is right.
commit sha ce124603e57ac8ede4addc6f96fc810a82090259
Explicitly import io.open (#1212) Fixes bug on Python 2.7, introduced in #1088
commit sha 4dbcb3dba0e987694e30644f2539ad3da7fde17c
Fix mistake in example (#1273)
commit sha ab81ff026755a709faae7b3eabc500488caa2bf2
Merge pull request #945 from CircleOnCircles/patch-1 fix typo in doc site
commit sha 0fb8d92850cbf49827707b0e12f08e796395e714
add test to reproduce sdispater/poetry#756
commit sha 73ea7d14489a116b00ecac28cae619d675b795e9
Allow local version identifier in wheel filenames Fixes cases where the version part of the wheel file name would become `0.1b1_gitbranch.buildno.1` instead of `0.1b1+gitbranch.buildno.1` Fixes sdispater/poetry#756
commit sha a34aa28ea4579a96351912919edfe092e1d95316
Don't replace '+' in dist-info/METADATA Building upon patch from [#1299][1] [1]: https://github.com/sdispater/poetry/pull/1299/commits Co-authored-by: David Hotham <[email protected]>
commit sha e69077e19774e2ae137be40f21e1b643c074abda
Simplify test
commit sha f4803e91bca440e6f4af6ad54e396d01c024a76f
Merge pull request #1309 from sdispater/950-simplified 950 simplified
commit sha 8db845406b3982a2784edea9b924630db57060e2
Improve documentation (#1344) doc: fix some typos - Add missing ".py" for file structure - Fix slash for Windows path - Fix word case to match other titles
commit sha cd3ad8c3f5efd12d7b93a683554ff11339165411
Update README for pipenv command name (#1343) remove --> uninstall
commit sha 0b38fada8dfc41bf6a47288781785373d663185e
Setup CI with Github Actions (#1347) * Setup basic Github actions * Remove Travis and Appveyor config files * Update pre-commit configuration
commit sha 27dbf0bc173a33d2eb907af75639c2addc953d7f
Merge branch 'master' into develop
commit sha 8c0e1d69a231a33365db0a76a1f9d495c62ec1ad
Fix tests
commit sha 3c7592c2f3d481f5e655a68fc1fa15c5bc024cda
Fix METADATA generation for git dependencies with extras (#1129) * fix METADATA generation for git dependencies with extras * add comment * add comment * add comment and linting * Move trailing space from `base_pep_508_name()` to `to_pep_508()` * Merge remote-tracking branch 'origin/master' # Conflicts: # tests/packages/test_vcs_dependency.py * Make changes python2 compliant * Handle any type of marker * Insert space before semicolon in dependency.py if vcs
commit sha c5e54ad3babd65ebc07deb0b2f878fa787fb7c23
Fix support for url sourced packages in pip installer (#1306) This change fixes the installation of packages using a url source. Previously, the installer attempted to install the package using the name ignoring the source url.
commit sha 9b516064ccf79f17f4246f42da73e64ce938426c
Fix file installation for wheels with no Requires-Dist (#1322)
commit sha 7b1e01f3d3e6054cc0370ad6ff4fd86cc3a4b7ae
Add make targets for clean and format (#1266)
commit sha 7b13f003f73c5ca4385814a8938f0a4cad50c0a4
Optimize tests/conftest.py (#1271) - apply the PyCharm "optimize imports" - place functions above fixtures - alphabetize fixture functions - remove duplicate tmp_dir fixture
commit sha be03ab9ea6d74ca8b9c6e251b71a8c608212dc63
Revert "Setup CI with Github Actions (#1347)" This reverts commit 0b38fada8dfc41bf6a47288781785373d663185e.
push time in 2 months
push eventCaligatio/poetry
commit sha f7d0d1d96733e7e83ca4d7261661c749474590ab
Rename custom-ca to cert
push time in 2 months
issue commentmihaifm/HIBPOfflineCheck
KeePass update check claims v1.7.1 is available
NP, probably the easiest bug to squash :)
comment created time in 2 months
issue openedmihaifm/HIBPOfflineCheck
KeePass update check claims v1.7.1 is available
On launch, KeePass pops up a warning telling me to upgrade my current HIBPOfflineCheck from v1.7.0 to v1.7.1 but there is no v1.7.1 available in this repository. It appears that version.txt reflects this incorrect version.
created time in 2 months
issue commentsdispater/poetry
I don't know what I thought I saw but all the type hinting is Python 2 friendly. Sorry about that!
comment created time in 2 months
pull request commentsdispater/poetry
It appears that the way configs were handled changed drastically between master and develop. It would have been entirely possible to write the values back in master as a handle was kept to each of the configs and they closely resembled files. In develop, the concept of the config was abstracted away and the individual config files are merged into the abstracted config; there is no longer a handle to the underlying files.
comment created time in 3 months
pull request commentsdispater/poetry
I confused source and upload repositories in my mind when I gave above options; sorry about that. There are actually fewer places that are possibilities:
- When someone configs an upload repository (like you have)
- Pros: It can write the updated value back to the config
- Cons: The update only happens at the time of the original
configcall
- In the Publisher class
- Pros: The updated value gets updated per publish, no matter how many files
- Cons:
- I don't believe you can write the value back to the config
- This involves making a new requests session (see previous comment about certs)
- In the Uploader class
- Pros: The updated value gets updated per publish, no matter how many files
- Cons: I don't believe you can write the value back to the config
I don't think there is a perfect solution here. In the Uploader seems best in terms of always working but then you don't get to perma-write the value back to the config. Maybe throw a warning in Uploader if an updated URL is detected? The idea was brought up in #1310. I could maybe make the argument that a warning and forcing the user to update their own config is clearer than auto updating a config :)
comment created time in 3 months
pull request commentsdispater/poetry
I'm a bit torn whether the below ideas are over-engineering the situation or not. However, I would definitely have a follow_redirects=True on the POST. The current code depends on, essentially, one redirect-change happening in the lifetime of the repository otherwise we'll have another silent error. Now, in terms of possible over-engineering ideas:
- Check the redirect on repository instantiation (happens per poetry run)?
- Check the redirect on every POST (i.e. do a HEAD everytime)?
- Check the redirect on the first usage of a repository?
To be clear here, I'm not a maintainer so my ideas are just ideas, not requests.
comment created time in 3 months
pull request commentsdispater/poetry
Wouldn't it make more sense to somehow hook URL usage versus config? Many people don't use the config command and this also means you would potentially catch a redirect once during the lifetime of a project.
comment created time in 3 months
issue commentsdispater/poetry
pip 19.2. breaks poetry (private repository)
Can you check to see if #1341 solves your problem?
comment created time in 3 months
PR opened sdispater/poetry
Pull Request Check List
This is just a reminder about the most common mistakes. Please make sure that you tick all appropriate boxes. But please read our contribution guide at least once, it will save you unnecessary review cycles!
- [x] Added tests for changed code.
- [ ] Updated documentation for changed code.
Note: If your Pull Request introduces a new feature or changes the current behavior, it should be based
on the develop branch. If it's a bug fix or only a documentation update, it should be based on the master branch.
If you have any questions to any of the points above, just submit and ask! This checklist is here to help you, not to deter you from contributing!
Per #1249 and pip #6776, newer versions of pip require require the username and password to be properly encoded/quoted. This PR simply quotes the URL when calling pip.
As referenced in #1249, we do not want to pre-quote the strings as that fouls up the metadata fetch which does not use pip.
pr created time in 3 months
issue commentsdispater/poetry
I think this is closed with #1320?
Admittedly I'm a bit confused by the PR because the rest of the codebase does type hinting by comment (Python 2 friendly) whereas that file is Python3 only...
comment created time in 3 months
startedsdispater/poetry
started time in 3 months
Pull request review commentsdispater/poetry
Add support for custom certificate authority and client certificates
class PublishCommand(Command): ), option("username", "u", "The username to access the repository.", flag=False), option("password", "p", "The password to access the repository.", flag=False),+ option(+ "custom-ca",
I probably struggled the most with naming the silly parameters compared to anything else about this PR. I started with custom-ca, hated it, but then figured we could come to consensus in the PR itself :)
Since I'm interfacing with both requests and pip under the hood, I need to use a combined client cert/key file as that's the only thing both take (pip is the picky one). That being said, I liked pip's --client-cert and went with it.
For CA:
- Twine (as you noted) uses
--cacert - pip (as you noted) uses
--cert - cURL uses
--cacert - wget uses
--ca-certificate requestsuses the parameterverify(that's terrible)- Python's built-in
sslmodule uses the parametercafile urllib3uses the parameterca_certs
Since I did --client-cert (with the hyphen in between), I'm thinking it should be consistent and be --ca-<SOMETHING> but that looks weird too. I'm happy to change it to anything that the maintainers will accept; I fully recognize --custom-ca is not great.
comment created time in 3 months
issue commentsdispater/poetry
Support For TLS Certificate Mutual Authentication
I'm forgetting if GitHub emails people on cross ticket mentions but I have a PR, #1325, that addresses this request. The developers said in Discord that they're ranking PRs by number of votes so please +1 the PR :)
comment created time in 3 months
issue commentsdispater/poetry
Allow root CA bundle to be configured
I'm forgetting if GitHub emails people on cross ticket mentions but I have a PR, #1325, that addresses this request. The developers said in Discord that they're ranking PRs by number of votes so please +1 the PR :)
comment created time in 3 months
pull request commentsdispater/poetry
Add support for custom certificate authority and client certificates
@brycedrennan I realize this is a substantial PR but I just successfully used my branch to both push and pull to a mutual TLS authenticated repository. This unfortunately is a blocker for my major use case of Poetry so please let me know I can help this along.
comment created time in 3 months
push eventCaligatio/poetry
commit sha bd5fcf9b302fa11e853cdccde84b2409c869a229
Check to ensure the global config exists before reading (#1324) Check to ensure the global config exists before reading
commit sha af57f15c9dae32a84b9d68ef3382dcae778546f0
Fix pytest fixtures on Win10 (#1326) Catch and deal with failed symlinking on Windows
commit sha 557c728a13c6761c36452971c0676058f56e0aee
Merge remote-tracking branch 'upstream/develop' into cert-auth
commit sha 3cd115521c2d8ca651e96774f585a53415d6e76a
Fix requests+pathlib problem and logic hole when BasicAuth+certs are used
push time in 3 months
issue commentsdispater/poetry
can't install tensorflow==2.0.0rc0 with poetry (python3.6.5)
It appears that tensorflow 2.0.0-rc0's setup.py dynamically changes its requirements depending on the environment by executing code. My guess is that Poetry does not handle this case well for some reason as it appears ALL of the Python2-linked dependencies are being grabbed.
I've never really played with the ast module and I'm only taking guesses here...
comment created time in 3 months
Pull request review commentsdispater/poetry
def mock_download(self, url, dest): if dest.exists(): os.unlink(str(dest)) - if PY2 and WINDOWS:- shutil.copyfile(str(fixture), str(dest))+ if WINDOWS:
Added and pushed
comment created time in 3 months
push eventCaligatio/poetry
commit sha de61610a0318a6546b7e2c1c4bdaf62951fc161d
Add comment describing Win10 symlink situation
push time in 3 months
Pull request review commentsdispater/poetry
def mock_download(self, url, dest): if dest.exists(): os.unlink(str(dest)) - if PY2 and WINDOWS:- shutil.copyfile(str(fixture), str(dest))+ if WINDOWS:
So os.symlink isn't available on Windows in Python 2 which would then maybe throw an AttributeError instead? I was thinking along the same lines as your try/except and also was unsure given the previous use of flags :)
comment created time in 3 months
pull request commentsdispater/poetry
Check to ensure the global config exists before reading
Pinned down the problem: this is a brittle unit test that made strong assumptions on how a file would be tested whether it exists. My original code was correct but I edited it to make it fit the mock assumptions. I don't know why/how but my code was previously passing (locally) on Win10 Python 3.7 without the modification in place (weird).
P.S. - My last commit message should have been "by using exists" and not "by existing exists." It's getting late :(
comment created time in 3 months
push eventCaligatio/poetry
commit sha fabdbd75fac29c9f75eb1b258ee64bbf1634f366
Make the unittest/mock happy by existing exists on a different object
push time in 3 months
issue openedsdispater/poetry
Period(s) in repository "name" causes issues
<!-- Hi there! Thank you for discovering and submitting an issue.
Before you submit this; let's make sure of a few things. Please make sure the following boxes are ticked if they are correct. If not, please try and fulfill these first. -->
<!-- Checked checkbox should look like this: [x] -->
- [x] I am on the latest Poetry version.
- [x] I have searched the issues of this repo and believe that this is not a duplicate.
- [x] If an exception occurs when executing a command, I executed it again in debug mode (
-vvvoption).
<!-- Once those are done, if you're able to fill in the following list with your information, it'd be very helpful to whoever handles the issue. -->
- OS version and name: Win10
- Poetry version: 1.0.0b1
- Link of a Gist with the contents of your pyproject.toml file: N/A
Issue
<!-- Now feel free to write your issue, but please be descriptive! Thanks again 🙌 ❤️ -->
Adding a custom [[tool.poetry.source]] whose name includes a period causes issues when paired with http_basic settings. The add_property method on the ConfigSource object blindly splits on periods, including those in the repo name. The side effect of this is that the resulting TOML becomes very "deep."
I'm happy to do a PR but I'm curious to know how much name checking is appropriate.
created time in 3 months
push eventCaligatio/poetry
commit sha 426dbdcff02eb0552f4e336bedb53aa16198c57f
Fix circular dependencies resolution
commit sha 5c60bafff8a0fc259a9d1f3edb58adbd34d7cc54
Clarify documentation for `--all` option in `cache clear` command Resolves: #1162
commit sha bd0e32741a9e10fc166a82a624c4f68486a5edb4
Merge branch 'abn-issue/1162'
commit sha e7912085d0797416207d8a9408ef2f0d2f5e7816
Fix the build target at Makefile (#1177)
commit sha 83f3d1ff4c6e45be60cc6537b4c473c5b88dcb30
Skip updating git dependencies if short hash match (#1186) This change ensures that short hashes are taken into consideration when evaluating if the required version of the dependency is already installed. The previous implementation only skipped update of a git dependencies if the revision specified in the pyproject.toml matched the full hash of the installed package. Resolves: #1157
commit sha 964d004b69bc0d7a677798540507f0052cbb6ffe
Use system keyring for passwords when available (#774) This change introduces the use of system keyring to store repository passwords when one is available. Passwords are added to and removed from the keyring using the config command. Resolves: #210
commit sha 159123f37612e9c3953efeadb7cf36df5f8f57b8
Add support for maintainers setting in pyproject.toml (#1175)
commit sha f43ef0509eb6945e4afdf80ad98aa037a94cdd3c
Show project version if no argument provided for version command (#1191) This changes the behavior of version command to show the current version of the project if no arguments are provided.
commit sha 269e91c65e26edb382a8d3e50d96c1a83001012d
Typing syntax fixes (#1156) * Typing syntax fixes * Fix some function signatures that were messing with ellipsis for example, `fun(a, ...)` is not valid, but `fun(...)` is * Dict value types - is that legal? (puzzle/provider.py) * Ignore assigning instance to classes (singletons like Infinity in version/utils.py) * Add basic mypy config This configuration has all common settings like: * strict Optional in functions that returns None * ignore missing imports - this is usual thing * Check code that has no typing annotation but uses typed classes/functions
commit sha e9a13f855ff5f31c9ad62c02fc2778dbd7b4f569
Review of (explicit) encoding for files being created in text mode (#1088) * Fix encoding for files created for building package (issue #1027) This is minimal set of modifications, which fixed the problem. There are still more places, where files are open in text mode without explicit encoding, thus possibly failing on systems not using UTF-8 console encoding. * test_api.py use explicit encoding for files. * get-poetry.py: fix explicit (utf-8) encoding for files open in text mode * tests: fix explicit (utf-8) encoding for files open in text mode * poetry init: use explicit utf-8 for created pyproject.toml * installed: use explicit utf-8 for text files * layouts: use explicit utf-8 for open text files * spdx: explicit utf-8 for open text files * pypi_repository: explicit utf-8 for open text files * explicit utf-8 for json * explicit utf-8 for metadata * explicit utf-8 for requires.txt * open files with explicit encoding in py27 * fix creation of poetry.bat on Windows * Make get-poetry.py compatible to py2/3 * Blacked two files to pass linter test * remove extranous encoding related comments * rewert broken move of import related to ansible * removed extraneous comments about opening files in UTF-8 * rewert ansible.release import (keep order of vars unchanged) * Revert to original content (as it comes from external project) * all vendored setup.py files in fixtures reverted back to org
commit sha 42eb36a32a222f4fdabcf1590d9e71e5f4ec8e67
Autocomplete instructions for Zsh with Homebrew (#1127)
commit sha 1ba6be8bb5374c85c20d5bb8c59ef29a30d0bcff
Use subprocess.run() to properly capture return codes. (#1075) * Use subprocess.run() to properly capture return codes. Fixes #1074 * replaced capture_output flag - only available on 3.7 * Ensure the backported CalledProcessError is imported. * Fix env tests on windows. * Format and comment fixes
commit sha df98fd289b9b629d2171900c1b1bddcee3696cff
[FIX] activation of venv, when `.venv` is a file (#1054) Some programs (ex. Emacs with auto-virtualenvwrapper package) uses .venv file to auto-determine the virtualenv of the project. Which is pretty handy. As well as, it doesn't make sense inside a poetry to try to set the venv, when it is a file.
commit sha 2085be6d483f3c6ffaed0665110586edf987b389
Update dependencies
commit sha 8cb0d53ddbc44f894b8261844b2433cf342a28c2
Update dependencies
commit sha bff20b25e535f78475fa9151d5edc4d5a3c46f78
Fix about command display
commit sha 4300d607342797a316b117bb192f4f872cc17440
Add extra line for errors when uploading
commit sha 31d8d2ef896039a28c82e489c0749b9e35ac4e78
Update CHANGELOG
commit sha 909424f84b0f1de2e10bb14bc261d6b26208ba63
Update dependencies
commit sha 7699a83a498b280c0671d6a6a331296fc0c25c50
Bump version to 0.12.17
push time in 3 months
push eventCaligatio/poetry
commit sha 35577b0175e596413fa41ebb32db9f4748f26c5e
Add cli options to publish for cert and custom ca
push time in 3 months
pull request commentsdispater/poetry
Check to ensure the global config exists before reading
I'm pretty sure Travis CI just hiccuped during my tests as those failures have absolutely nothing to do with the changed code.
comment created time in 3 months
PR opened sdispater/poetry
Pull Request Check List
This is just a reminder about the most common mistakes. Please make sure that you tick all appropriate boxes. But please read our contribution guide at least once, it will save you unnecessary review cycles!
- [ ] Added tests for changed code.
- [ ] Updated documentation for changed code.
Note: If your Pull Request introduces a new feature or changes the current behavior, it should be based
on the develop branch. If it's a bug fix or only a documentation update, it should be based on the master branch.
If you have any questions to any of the points above, just submit and ask! This checklist is here to help you, not to deter you from contributing!
Two conftest.py files are currently attempting to perform symlinking as part of a fixture which requires either admin privileges or "Developer Mode" to be enabled on Win10. This PR just wraps the symlink call in a try/except and falls back to copying if it fails.
pr created time in 3 months
PR opened sdispater/poetry
Pull Request Check List
This is just a reminder about the most common mistakes. Please make sure that you tick all appropriate boxes. But please read our contribution guide at least once, it will save you unnecessary review cycles!
- [x] Added tests for changed code.
- [x] Updated documentation for changed code.
Note: If your Pull Request introduces a new feature or changes the current behavior, it should be based
on the develop branch. If it's a bug fix or only a documentation update, it should be based on the master branch.
If you have any questions to any of the points above, just submit and ask! This checklist is here to help you, not to deter you from contributing!
This PR adds support for specifying a custom certificate authority to validate custom repositories as well as using client certificate-based authentication for custom repos. This was quite a bit bigger than I anticipated but I think I plumbed everything that is needed.
This should address #1012 and #297
pr created time in 3 months
push eventCaligatio/poetry
commit sha 07aba89908182f3d2ea51970bac1bdad01993f61
Add documentation on certificates
push time in 3 months
PR opened sdispater/poetry
Pull Request Check List
This is just a reminder about the most common mistakes. Please make sure that you tick all appropriate boxes. But please read our contribution guide at least once, it will save you unnecessary review cycles!
- [ ] Added tests for changed code.
- [ ] Updated documentation for changed code.
Note: If your Pull Request introduces a new feature or changes the current behavior, it should be based
on the develop branch. If it's a bug fix or only a documentation update, it should be based on the master branch.
If you have any questions to any of the points above, just submit and ask! This checklist is here to help you, not to deter you from contributing!
#1272 introduced a bug on "develop" where poetry performs a blind read on the global config file without checking whether it exists first. This is a one-line fix that simply checks to make sure the file exists before the read. The existing follow-on code already handles creation of the file just fine.
This should close out #1179
pr created time in 3 months