(This is a reminder to myself, and maybe a help for someone else who might be in the same situation as me. The purpose was to be able to lint documentation I’m trying to update for the pip project work.)
This applies to installing “the latest” Python on Mac OS X 10.15.6.
I’ve used this helpful How-TO. Everything worked until the very end where brew couldn’t create a necessary directory:
🍺 /usr/local/Cellaremail@example.com/1.1.1h: 8,067 files, 18.5MB
==> Installing firstname.lastname@example.org
==> ./configure --prefix=/usr/local/Cellaremail@example.com/3.9.0_1 --enable-ipv6 --datarootdir=/usr/local/Cellarfirstname.lastname@example.org/3.9.0_1/share --datadir
==> make install PYTHONAPPSDIR=/usr/local/Cellaremail@example.com/3.9.0_1
==> make frameworkinstallextras PYTHONAPPSDIR=/usr/local/Cellarfirstname.lastname@example.orgemail@example.com
Error: An unexpected error occurred during the `brew link` step
The formula built, but is not symlinked into /usr/local
Permission denied @ dir_s_mkdir - /usr/local/Frameworks
Error: Permission denied @ dir_s_mkdir - /usr/local/Frameworks
I reran install python and got:
bernard@computer-number-6 ~ % brew install python
==> Auto-updated Homebrew!
Updated 1 tap (homebrew/cask).
==> Updated Casks
Warning: firstname.lastname@example.org 3.9.0_1 is already installed, it's just not linked
You can use `brew link email@example.com` to link this version.
The solution was to create the /usr/local/Framworks directory manually:
I’m working on the usability of pip (the official Python package manager) at the moment.
This short blogpost isn’t about how to design CLIs. It is about creating rapid prototypes with this tool – part “look at this useful tool, part “thank you Pradyun” part feature request list. 🙂
After putting together the feature request list below, Pradyun’s already updated cli-output with request 1 and 2 below. Reusable blocks, or repeatable blocks are a bit more work.
Prototyping commandline interfaces, for the non-developer, is not easy. While we have countless interface prototyping tools for graphical UIs, unless you can write code (Python, HTML/JS, etc), when it comes to commandline user interfaces, there’s little available.
One thing I have struggled with so far is being able to prototype commandline interfaces that look “real enough”, without it taking “a lot” of time.
I’ve tried making stop-motion videos, describing it in long verbose explanations, doing paper prototypes, but none of the work. A CLI is essentially an interactive scrolling text-only interface. Without that “motion” it is very difficult to prototype, without coding skills.
Pradyun Gedam, one of the pip maintainers, put together a nice tool to prototype commandline interfaces. It is essentially simulating a CLI in HTML and JS. Easy when you know how.
It allows you to do nice things like this:
1. Being able to include comments. Done!
As a CLI UX designer, I want to be able to write comments (which won’t show up in the cli output), so that I can include human-readable explanation or annotation in the output.
Things to think about: can I use common characters like `#`, `>` if they are going to be printed in a cli output? 🤔
2. Being able to easily repeat a large block
As a CLI UX designer, I want to be able to build output on previously drawn elements, so that it saves time.
I need to add a video here to show what I mean.
3. Being able to share the URL of a cli output prototype.
This would help so that I could share them in PRs, etc.
As a CLI UX designer, I want a weblink for each cli prototype I create, so that I can share them with people (in GH issues, users, etc).
Things to think about: I think using something like a pastbin unique URL (which allows editing) would be nice. I think something like how hastepin does URLs would be good.
4. Having the output scroll up like in a real terminal Done!
I need to add a video here to explain more.
5. Having reusable elements
As a CLI UX designer, I want to be have a number of elements I can use, so that I don’t need to build them from scratch each time.
Things to think about: It’d be nice to be able to reuse elements (for example a spinner) instead of having to redraw each `-`, `\`, `|`, `/` each time. For example, like you’ve created the spinner here. https://hackmd.io/@pradyunsg/HyyYzk5Lv
What elements? I think a spinner, and simple progress bar would be a great start.
Anyway, thank you Pradyun for what you’ve done so far. 🙏🏾
If you are a UX designer and you need to make quick CLI prototypes, I suggest you have a look.
Initially I was thinking “I hate seeing my face on video, I hate hearing my voice. This better not have ukelele music. I hate those kinds of videos.”
I liked the explanation she gave for wanting to do it – ‘so Python community, and users can see the human faces behind pip, that we’re real people’. We often forget (me included) that, for the moment, it’s still humans that make most software.
I think the video turned out well, and people seem to like it.
Dear LycaMobile, please unblock access to github.com. The blocking seems to be at the DNS level.
I’m sure this blocking is not intentional – more likely a mistake in configuration, a change in DNS somewhere, and no-one has reported it.
I’ve signed up for a LycaMobile Pay-as-you-go SIM account, and registered our personal details (purchasing SIM cards in Spain requires you to provide photographic identity, and registration of your identity!).
Trying to access Github does not work. Access to Github.com is blocked at the network level.
(Github.com is the US company that provides hosting for software development and version control using Git)
Using Ooni (the Open Observatory of Network Interference) tool I ran a quick test to determine any interference with access to www.github.com. Ooni tells me:
1.05% Processing input: https://github.com/ (10013.20s left) web_connectivity: starting dns_query for github.com web_connectivity: dns-query error: dns_temporary_failure web_connectivity: starting tcp_connect web_connectivity: starting http_request to https://github.com/ web_connectivity: http-request error: dns_lookup_error web_connectivity: doing control request Using backend https://wcth.ooni.io web_connectivity: comparing control with experiment web_connectivity: BLOCKING detected due to: dns on https://github.com/ 1.11% ending the test (11502.48s left) 1.11% test complete (11502.49s left) 1.12% starting the test (11646.82s left)
LycaMobile is an MVNO (Mobile Virtual Network Operator) – meaning it is a mobile operator that does not own it’s own radio access network equipment (the towers your phone/data device uses to connect to the mobile network. In this case it uses Movistar’s radio network equipment).
The MVNO also arranges a business agreement with the mobile network operator (in this case Movistar) to obtain bulk access to network services at wholesale rates. It then sets it’s prices independently.
It would be very unusual to have protocol blocking functionality in the radio network of a mobile phone network, so it is more likely the blocking is being done by LycaMobile’s 4G packet data equipment.
Note to self: The issue I’m having looks similar to this, but it’s not it.
For those who are not familiar with what a dependency conflict is – it arises when packages or libraries – on which several other packages have dependencies – are shared – but where they depend on different and incompatible versions of the shared packages.
If the shared package or library can only be installed in a single version, you may need to address the problem by obtaining newer, or older, versions of the dependent packages.
This, in turn, may break other dependencies and pushes the problem to another set of packages.
This research is to understand what behaviour users expect from pip with it encounters this scenario.
Want to take part in more pip research?
If you’d like to be involved in more pip UX research, we’d love to have you involved.
You get to decide what kind of studies you want to take part in – usability tests, surveys (like this study), interviews, and others.
Hello! It’s Bernard and Nicole here from the pip team.
What’s this research about?
The team is working on the improving the way that pip resolves package dependency conflicts and would like feedback from users who have projects with complex dependencies. By complex dependencies we mean projects that:
have at least 10 package dependencies
some package are pinned to specific versions
that you always have a dependency issue when installing it
you have to put in hacks, workarounds, or fixes
Currently, we’re trying to discover all the ways in which pip‘s dependency resolver fails, so that we can work out what error messages and/or debugging information we should display.
We hope to get some results in the next 2 weeks. The research will be running after these 2 weeks – please do try this out, and file an issue.
What we’d like you to do
On a project with a lot of dependencies and/or where you’ve had dependency problems in the past:
Upgrade pip to the latest version – 20.2b1 – by running pip install —upgrade —pre pip (you can check your version with pip -V or pip --version)
Use pip’s alpha resolver to install the project. You can do this by adding the option --unstable-feature=resolver when running pip
If the project installs without a problem, do what you can to break it! For example, add more packages, or fiddle with the versions of your packages. If you’ve put in workarounds, remove them!
Your terminal output, including the error message (if one is displayed)
Any inputs to pip, for example:
Package requirements: CLI arguments and/or your requirements.txt file
Already installed packages, outputted via pip freeze
we’d appreciate if you tag us in the Github issue – Bernard (@ei8fdb) and Nicole (@nlhkabu).
It would be great if you could also include your dependency tree (outputted via pipdeptree)
For users installing packages from a private repository or local directory, please try your best to describe your setup. We’d like to understand how to reproduce the error locally, so would need (at a minimum) a description of the packages you are trying to install, and a list of dependencies for each package.
How we will use your feedback
We will use your error report to create a list of error use cases. We may also contact you for follow up questions, or to discuss the kind of help you might need to resolve the error(s).
If you want to get in touch
We appreciate your time and help on this issue! If you need any help, or have any questions, please don’t hesitate to get in touch with me by email, here in the comments, or Twitter (I’m @bernardtyers) – we’ll be happy to talk it over it with you.
Here are some (anonymised) details about what the participants use Python for:
At work we use Python to deliver a smart metering solution to tens of thousands of people in the developing world. Everything from business logic to middleware to front ends are built on Python.
Used Python for automating tons of QA tests for medical software UI.
Work as a researcher in a ML lab
At work, I use python for GIS tools and data analysis.
(I work in) bioinformatics […] some software are written in python.
Text analysis for infosec and fraud detection Predictive maintenance
I’m a grad student in cognitive science so I use python to code tasks for subjects, data analysis for both behavioral and fMRI/eyetracking data, and additionally for personal automation of tasks or web scraping for info
connecting to hardware (like access gates, scanning devices)
Professionally I write web backends (REST+basic HTML/css), batch data processing, data integrations, and systems scripting for a large software company. In my personal time I do similar tasks on a much smaller scale.
I use Python for my work as a senior DevOps engineer developing tools and web platforms for infrastructure automation. I am also an open source author of a variety of tools, including browser automation, web programming, automation tooling, and more.
I am an archaeologist and since 2008 I have been using Python to develop small open source apps for some specialized tasks like radiocarbon calibration, downloading land survey data from total stations and analyzing archaeological stratigraphy data. I also use these tools at work but development is strictly a personal side project.
I use Python for web development and I teach Python. My students often struggle with virtual environments and pip.
Here are some (anonymised) details about what the participants use Python for:
I use pip exclusively to deal with pypi packages, thus using it in a very basic and straighforward way.
I use pip to install editable versions of the application in my virtualenvironment so the various scripts and entry points are in my path. I also use it + Twine to publish wheels and source distributions to both public Pypi, as well as an internal mirror. I’ve also used pip to execute unit tests.
Use pip in CI, building docker containers, package management of my local venvs
(I use) Basic commands: Install Upgrade Freeze
It varies by project but I predominantly use conda so sometimes uses conda install but quite often for a particular repo I’ll end up using pip if it’s easier overall (or sometimes if it’s the only option)