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

minor refactor and bumped requests min version #1

Merged
merged 119 commits into from
May 23, 2019

Conversation

memsharded
Copy link

Some minor refactors:

  • Moved the responsibility of defining the proxies dict to ConanClientConfigParser class, as Requester main responsibility is different, and the former class was implemented exactly for that. Also, doing it directly in a single pass.
  • Minor pep8 style fixes (indents, blanks)
  • Bumped min requests version to 2.8.1, as it would be necessary for this feature, and is also from 2015, I think is reasonable to request it.

memsharded and others added 10 commits April 8, 2019 14:06
* remotes to metadata

* working....

* working on it, very bad state

* fixing things

* working

* getting there...

* tests passing but RegistryTest and RemoteTest

* python requires updates

* fixed test with time.sleep()

* working

* adding definition of remotes too

* working in dumps, new remotes.txt file?

* tests passing missing file format

* fixing tests

* remove simple paths

* remove simple paths

* renames

* removed print

* abs_path for CONAN_USER_HOME too

* fix storage_path

* working, not ready for review

* working...

* working..

* working...

* review and migrations for conan-config-install

* fix test
* new full metadata revision migration

* revert order of migrations
* substitute only the 'subprocess.check_output' calls that are actually capturing the output

* convert cmd to string

* add missing import

* mock the new check_output func

* mock func

* do not decode a string

* do not decode_text either

* no need to encode (there is no after the check_output call)

* check_output was being imported through a different module

* do not decode

* output is decoded

* no need for the __BEGIN__ trick

* revert, test name changed
* unzip with gz too

* fix test

* using destination argument

* docstring
memsharded and others added 19 commits April 10, 2019 16:35
* Update README.rst

* Update README.rst
conan-io#4941)

* Default filename for workspaces: conanws.yml (used in install command)

* typo

* no need to replace

* add text to help message of 'path' argument
…-io#4903)

* add '--raw' argument to command line 'inspect'

* add test with arguments in different order (is this enough to check that order is respected?)

* those test will fail

* --raw accepts one argument, incompatible with -a

* incompatible with json (it won't dump a raw json)
…mands with subarguments (conan-io#4902)

* Added required = True to subparsers in order to print error message in Py2 and Py3.

* Tests to check that an error is risen when no subarguments are provided
conan-io#4897)

* export-pkg message, notice about --package-folder

* update help string
jgsogo and others added 28 commits May 3, 2019 15:40
* create migration and introduce compiler.cppstd setting

* add tests at the profile level

* add comment

* keep old naming, add per compiler

* validation of package settings is done in the graph

* add checks for scoped settings

* fix some tests (still some failing)

* use compiler.cppstd instead of .cppstd (fix some tests)

* raise for undefined setting compiler.cppstd

* fix test, mocked settings needs a fields

* remove typos

* lost in migration

* catch deprecation warnings for tests coming from previous merge

* check settings after contraining

* test recipe with cppstd but without compiler

* fix pep8

* fix some tests

* up parameterized (add handy parameterized_class decorator)

* no need to warn twice (if we are check_cppstd for the conanfile)

* keep the warning for the user (in console, not to stderr)

* need fields attribute again

* calls to build need to silence warnings

* need a better mock

* add compiler version (needed to pass tests when the default compiler is different)

* add libcxx to compiler

* use cppstd=17 as it is also supported for Visual Studio (when running tests in Windows it is the compiler by default)

* catch warnings of test using cppstd in command line

* force a known default profile

* fix test for windows

* Add tests checking ID for different 'cppstd' strategies

* catch warnings

* order imports

* do not allow the user to specify both settings

* fix cancelation of cppstd for default value

* add tests (methodic) for compiler.cppstd with default value

* Add some notices: settings are being constrained before check

* typo, proper way to check if in settings

* no need to try/except

* set compiler.cppstd to default value if it is not given (neither cppstd), but keep old ID computation

* note about ConanInfo.loads

* at the moment of executing, settings can be different (info.header_only())

* organize code related to std_matching

* minimize changes in default_cppstd_test

* add settings for 1.15

* remove comment

* validate scoped profile at the very beginning

* do not copy if not needed

* we removed a call to deprecation... we raise less deprecation errors

* we removed a call to deprecation... we raise less deprecation errors

* cppstd deprecation message (for recipe) as warning

* use setting compiler.cppstd in build_helpers

* deprecate functions 'default_std_[non_]matching' for compiler.cppstd

* for pure_c, remove the compiler.cppstd subsetting

* checksum for conanfile template is different

* the flag is passed to the compiler

* examples of C library

* ID will be different for different platforms

* the id depends on other defaults (remove that test)

* do not populate default value of 'compiler.cppstd'

* no longer used function

* revert changes associated to checksum of conanfile generated for testing

* relax failure on user side

* remove tests (not for this PR)

* migrations_settings is populated just before the release
* fix migration

* fix migration too
* fix remote update --insert with same url

* add some checks
* check raise migration compiler.cppstd failed

* fix py2 raise
* raw description for commands

* prev message of export_pkg

* Show help for the list of commands: all the lines until the first blank one

* First capital letter, finishing with dot

* improve some help messages
* Inherit scm from superclass

* insert scm after class, when no scm

* Inject lines
…onan-io#5029)

* trying to reproduce conan-io#5017

* trying to reproduce conan-io#5017

* use 'revision' instead of 'last_changed_revision' for 'peg_version' in SVN

* use . instead of conanfile

* windows needs forward slashes
* Update conan_requester.py

Hi, I have a problem where proxy settings are _not_ being taken from the environment (so I have to manually specify them). In searching for the solution to that problem I noticed that this code might not work as intended. When the popped variable is True the right part of the "or" will not be executed ... and thus not all proxy settings would be cleared (probably only the first encountered).

>>> False or print("hi")
hi
>>> True or print("hi")
True  <=== the right part of the or did not execute.

Do I understand it right? Thanks.

* Update __init__.py

The call to urllib.request.getproxies() was putting modified system proxy settings into the proxies property (changed name: http_proxy becomes http). Code using that was assuming that these proxy settings came from conan.conf ... and then removed the valid system proxy settings, which resulted in broken proxy handling, since there were no valid settings left.

* Update __init__.py

Return an empty hash/dict from proxies() rather than None. Unit tests expect a hash, whereas the calling code evaluates (if), therefore an empty hash works in both cases.
* templates for conan new

* renamed to --file

* fix test
- Add alias for tools.oss.detected_os

Signed-off-by: Uilian Ries <uilianries@gmail.com>
* renames and moves

* fix

* fix search test

* registry remotes file creation moved

* removed .conan subfolder in ClientCache

* more moves

* fix test

* fixing tests

* removed TestRunner

* fix merge

* minor tweaks
* Feature: Support yaml list as workspace root.

Using yaml list for setting the workspace root variable makes it easier
to manage the yaml file, when the workspace has multiple roots.

* Add test for yaml list as workspace root (conan-io#5156)

* Refactor test for yaml list as workspace root (conan-io#5156)

The `root_as_yaml_list_test` test is removed and the
`multiple_roots_test` is parametrized to test for the different root
attribute formats.
@memsharded memsharded merged commit 75262c7 into dawidcha:develop May 23, 2019
@memsharded memsharded deleted the feature/multi_proxi branch May 23, 2019 08:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet