[python-uk] London Python (remote) Dojo - Thursday 7th May, 7pm

2020-04-30 Thread Daniel Pope
The London Python Dojo is back next week - remotely!

Join us next Thursday, 7th May, from 7pm for an evening of pizza, beer and
hacking (pizza and beer not included, but feel free to bring your own). Of
course, given that we’re remote, you don’t have to be London-based to
participate.

We’ll be using Discord for this dojo (and as an ongoing dojo hangout).
Please join our Discord “server” using this link: https://discord.gg/6tzdVTZ
and let us know if you intend to participate next week by thumbs-upping our
#announcement.

What does an online dojo look like?

   - You can socialise with other Pythonistas, share photos of your pizza
   and tasting notes about the beer you’re drinking.
   - We have a space to post “we’re hiring” or “I’m looking” messages.
   - We will break into teams that each tackle the same project. Teams will
   be able to use a private Discord voice/video chat and will have around 2
   hours of coding time.
   - Then we have a “show and tell” in which each team will be asked to
   present their solution.

We will organise GitHub repositories and permissions for you, so please
make sure you have a GitHub account and can log in.
___
python-uk mailing list
python-uk@python.org
https://mail.python.org/mailman/listinfo/python-uk


[python-uk] (no subject)

2018-09-29 Thread Daniel Pope
Hi all,

Pyweek 26 is running from 21st to 27th October:

https://pyweek.org/26/

Pyweek is an online Python-only game jam. You have a week to write a game
"from scratch" in Python, using Pygame, Pyglet or any other technology you
like. Theme voting starts on the 14th October with five themes to think
about and rank in preference order. Your game must include the winning
theme announced when the contest starts.

For the first time, Pyweek 26 will have non-anonymous feedback on entries,
which is hoped will produce much more useful and positive feedback.

Hope to see you there!

Dan
___
python-uk mailing list
python-uk@python.org
https://mail.python.org/mailman/listinfo/python-uk


[python-uk] Pyweek Game Jam in April

2018-03-25 Thread Daniel Pope
The next Pyweek will run from 00:00 UTC on Sunday 15th April to 00:00 UTC
on Sunday 22nd April. It's an online games programming competition, where
you have to write a game from scratch in a week. The full rules are at
https://pyweek.org/s/rules/.

We usually have a few UK entrants. I've entered a couple of times with
London-based teams but you can also enter as an individual. I'm going to be
entering as an individual this time. But now I'm also running the
competition too!

It's a chance to exercise your creativity, practice Python, and release
something!

If creating a game alongside a number of other teams sounds like a fun
challenge, register at https://pyweek.org/register/ (then add an entry from
the drop-down).

Hope to see you there!

Dan
___
python-uk mailing list
python-uk@python.org
https://mail.python.org/mailman/listinfo/python-uk


Re: [python-uk] Burning desire to watch cataract surgery?

2017-10-16 Thread Daniel Pope
I'm in tears!

On Mon, 16 Oct 2017, 10:52 Steve Holden,  wrote:

> You people are clearly very sharp.  S
>
> Steve Holden
>
> On Mon, Oct 16, 2017 at 9:38 AM, Nathan Jeffrey 
> wrote:
>
>> I roil at eye rolls for eye roles.
>>
>> - N
>>
>> On 13 Oct 2017 20:25, "S Walker"  wrote:
>>
>>> Is it appropriate to roll your eyes at the roles for eyes?
>>>
>>> S
>>>
>>> On 13/10/17 17:42, David Steven-Jennings wrote:
>>>
>>> *rolls eyes* :p
>>>
>>> On 13 Oct 2017 5:37 pm, "Stestagg"  wrote:
>>>
>>> I think I’ll keep a close eye on this thread!
>>> On Fri, 13 Oct 2017 at 17:00, S Walker  wrote:
>>>
 These puns are delivered with surgical precision.


 S


 On 13/10/17 16:31, Nicholas H.Tollervey wrote:

 Iris you could have given us more details...

 (BTW, plenty more where that came from...)

 :-)

 N.

 On 13/10/17 14:36, Hansel Dunlop wrote:

 He's getting to the heart of the matter

 On Fri, Oct 13, 2017 at 2:30 PM, Richard Barran
 mailto:rich...@arbee-design.co.uk> 
 > wrote:

 I see what you did there...


 On 13 Oct 2017, at 15:21, Adam Johnson >>>  > wrote:

 Sounds cutting edge!

 On 13 October 2017 at 14:05, Hansel Dunlop
 mailto:han...@interpretthis.org> 
 > wrote:

 Probably not, in fact I probably don't want to watch another
 one in my life if I can help it. BUT:

 For those who know me, and for those that don't. The company
 I'm working for (It's called Touch Surgery, and I look after
 the platform team) is growing quickly at the moment. There are
 a broad range of technical roles. I'm particularly keen to
 find some Python devs who have worked on large Django projects
 but anyone senior looking for something exciting would be of
 great interest.
 

 ___
 python-uk mailing list
 python-uk@python.org  
 
 https://mail.python.org/mailman/listinfo/python-uk
  
 




 --

 Hansel


 ___
 python-uk mailing 
 listpython-uk@python.orghttps://mail.python.org/mailman/listinfo/python-uk



 ___
 python-uk mailing 
 listpython-uk@python.orghttps://mail.python.org/mailman/listinfo/python-uk


 ___
 python-uk mailing list
 python-uk@python.org
 https://mail.python.org/mailman/listinfo/python-uk

>>>
>>> ___
>>> python-uk mailing list
>>> python-uk@python.org
>>> https://mail.python.org/mailman/listinfo/python-uk
>>>
>>>
>>>
>>>
>>> ___
>>> python-uk mailing 
>>> listpython-uk@python.orghttps://mail.python.org/mailman/listinfo/python-uk
>>>
>>>
>>>
>>> ___
>>> python-uk mailing list
>>> python-uk@python.org
>>> https://mail.python.org/mailman/listinfo/python-uk
>>>
>>>
>> ___
>> python-uk mailing list
>> python-uk@python.org
>> https://mail.python.org/mailman/listinfo/python-uk
>>
>>
> ___
> python-uk mailing list
> python-uk@python.org
> https://mail.python.org/mailman/listinfo/python-uk
>
___
python-uk mailing list
python-uk@python.org
https://mail.python.org/mailman/listinfo/python-uk


[python-uk] Pyweek 24 is next week

2017-10-09 Thread Daniel Pope
Next week will be Pyweek 24! Pyweek is a week-long games programming
contest, which has been running since 2005 [1]. Entrants create a game in
Python in exactly one week, on a theme chosen by vote, and which will be
rated by other entrants on criteria of fun, production, and innovation.

Theme voting has just begun, and the potential themes are:

   - I never saw that coming
   - It's too dangerous
   - Los Angeles has been saved
   - Storm's dying down
   - They're behind everything

This time, for the first time, it will be possible to write games in Godot
Engine [2] and in Unreal Engine 4 [3], which I'm really excited by!

If you have an evening or two (or more) free next week, why not sign up and
create something fun? You can enter as a team or as an individual.

Sign up at https://pyweek.org/.

[1] I have recently written a brief history of Pyweek:
http://mauveweb.co.uk/posts/2017/08/fun-and-games.html
[2] https://github.com/touilleMan/godot-python
[3] https://github.com/20tab/UnrealEnginePython
___
python-uk mailing list
python-uk@python.org
https://mail.python.org/mailman/listinfo/python-uk


Re: [python-uk] A stack with better performance than using a list

2017-06-11 Thread Daniel Pope
I was able to get about a 20% speed up over Steve's solution, on some
benchmark data I created, by:

* converting LOAD_GLOBAL to LOAD_FAST for __builtins__
* eliminating the conditional in each loop in favour of a conditional on
pop only
* eliminating string comparison for the operation in favour of testing
line[1] against byte values

None of these had a significant effect in either direction:

* replacing range objects with counts
* replacing the string.split()/int() calls with a hand-rolled
space-separated integer parser in Python.

Oh, in my benchmarking, the print() calls were huge and highly variable...
I stubbed them out first.

On Thu, 8 Jun 2017, 21:39 Stestagg,  wrote:

> Apologies, In my previous email, I meant 'insert a marker', rather than
> 'push a marker'
>
> On Thu, Jun 8, 2017 at 7:17 PM Stestagg  wrote:
>
>> I tracked down the challenge on the site, and have a working solution (I
>> won't share for obvious reasons). Basically the timeouts were being caused
>> by 'add_to_first_n' being called in horrible ways in the test cases.
>>
>> Because add_to_first_n alters the bottom of the stack, you can just push
>> a marker onto the stack rather than iterating and mutating each entry,
>> doing this made those test cases pass
>>
>> Personally, I think it's not a well-described problem, because it's
>> expecting you to tune the algo to specific shapes of data without allowing
>> any visibility on the data, or a description of what to code for.  An algo
>> junkie may jump straight to the optimized version, but a pragmatic
>> developer would, in my opinion, hesitate to do that without any actual
>> evidence that the problem required it.
>>
>> Steve
>>
>>
>>
>>
>>
>> On Thu, Jun 8, 2017 at 5:27 PM Jonathan Hartley 
>> wrote:
>>
>>> Yep, that's a great elimination of the suspicious small overheads.
>>>
>>> line_profiler is beautiful, I'll definitely be adding it to my toolbox,
>>> thanks for that!
>>>
>>> I tried a variant of accumulating the output and printing it all as a
>>> single string, but of course this didn't help, printing is already buffered.
>>>
>>> Jonathan
>>>
>>> On 6/8/2017 03:54, Stestagg wrote:
>>>
>>> I honestly can't see a way to improve this in python.  My best solution
>>> is:
>>>
>>> def main(lines):
>>> stack = []
>>> sa = stack.append
>>> sp = stack.pop
>>> si = stack.__getitem__
>>> for line in lines:
>>> meth = line[:3]
>>> if meth == b'pus':
>>> sa(int(line[5:]))
>>> elif meth == b'pop':
>>> sp()
>>> else:
>>> parts = line[15:].split()
>>> end = len(stack)-1
>>> amount = int(parts[1])
>>> for x in range(int(parts[0])):
>>> index = end - x
>>> stack[index] += amount
>>> print(stack[-1] if stack else None)
>>>
>>> which comes out about 25% faster than your solution.
>>>
>>> One tool that's interesting to use here is: line_profiler:
>>> https://github.com/rkern/line_profiler
>>>
>>> putting a @profile decorator on the above main() call, and running with
>>> kernprof produces the following output:
>>>
>>> Line #  Hits Time  Per Hit   % Time  Line Contents
>>>
>>> ==
>>>
>>> 12   @profile
>>>
>>> 13   def main(lines):
>>>
>>> 14 14  4.0  0.0  stack = []
>>>
>>> 15   201   949599  0.5 11.5  for line in lines:
>>>
>>> 16   200  1126944  0.6 13.7  meth = line[:3]
>>>
>>>
>>> 17   200   974635  0.5 11.8  if meth ==
>>> b'pus':
>>>
>>> 18   100  1002733  1.0 12.2
>>> stack.append(int(line[5:]))
>>>
>>> 19   100   478756  0.5  5.8  elif meth ==
>>> b'pop':
>>>
>>> 2099   597114  0.6  7.2  stack.pop()
>>>
>>> 21   else:
>>>
>>> 22 16  6.0  0.0  parts =
>>> line[15:].split()
>>>
>>> 23 12  2.0  0.0  end =
>>> len(stack)-1
>>>
>>> 24 11  1.0  0.0  amount =
>>> int(parts[1])
>>>
>>> 2551   241227  0.5  2.9  for x in
>>> range(int(parts[0])):
>>>
>>> 2650   273477  0.5  3.3  index
>>> = end - x
>>>
>>> 2750   309033  0.6  3.7  
>>> stack[index]
>>> += amount
>>>
>>> 28   200  2295803  1.1 27.8
>>> print(stack[-1])
>>>
>>> which shows that there's no obvious bottleneck (line by line) here (for
>>> my sample data).
>>>
>>> Note the print() overhead dominates the runtime, and that's with me
>>> piping the output to /dev/null directly.
>>>
>>> I had a go at using

[python-uk] PyWeek is next week, 19th-26th February

2017-02-13 Thread Daniel Pope
Hello all,

PyWeek, the Python games programming contest, is coming up next week.

https://pyweek.org/23/

Many of you will have heard me bang on about PyWeek quite a lot over the
years - if so, sorry! It's a games programming contest where you are
challenged to write a game from scratch, in a week. You don't need to spend
a whole week - I just do evenings, for example - and winning games have
been written in an afternoon.

This week is theme voting week, in which we vote on theme options. The
winning theme - to which games must somehow be linked - will be announced
on Sunday 00:00 UTC when the contest starts. The options this time are:

   - A Flight to Remember
   - The Lesser of Two Evils
   - Cold Warriors
   - Obsoletely Fabulous
   - Insane in the Mainframe

Do any of these plant the seed of inspiration in your brain? Perhaps you
could create a 2D game with Pygame or a 3D game with OpenGL... or maybe a
web-based game with Flask... or perhaps an immersive augmented reality game
played out over social media, chaperoned by the mysterious @Ajax (Oooh, I
might do this myself!).

The point is: challenge yourself to do something creative; stretch your
Python muscles; finish something; have people play it and send you
feedback. You can enter as a team or as an individual. Why not register an
entry and give it a go?

Sign up at https://pyweek.org/register/ and register an entry at
https://pyweek.org/23/entry_add/
___
python-uk mailing list
python-uk@python.org
https://mail.python.org/mailman/listinfo/python-uk


Re: [python-uk] Announcing the Yorkshire Inquisition

2016-12-07 Thread Daniel Pope
Right, so we're in the ridiculous situation where there are stricter
standards in what can be posted to this ML than who can be US president.

On Wed, 7 Dec 2016, 14:30 Hansel Dunlop,  wrote:

> It could certainly be violated by embodying his behaviour  ¯\_(ツ)_/¯
>
> h
>
> On Wed, Dec 7, 2016 at 2:15 PM, Daniel Pope  wrote:
>
> Idle thought: can the code of conduct be violated by accurately quoting
> Time Person-of-the-Year Donald Trump?
>
>
> On Wed, 7 Dec 2016, 13:21 Andy Robinson,  wrote:
>
> I believe I am one of the original founding list admins, after 20-odd
> years.  Sadly, the other, John Pinner, has passed away.
>
> I therefore decree, as self-appointed "Benevolent Dictator for List",
> that the Python CoC established by Steve Holden IS the official Code
> of Conduct, and must be respected.
>
> To enforce good conduct in a suitably Pythonic manner, I  hereby
> propose the foundation of the Yorkshire Inquisition, headed by Steve.
> Such an institution will have truly terrifying powers of enforcement.
> Suggestions welcome on this thread
>
> Be pure.  Be vigilant.  Behave!
>
> - Andy
> ___
> python-uk mailing list
> python-uk@python.org
> https://mail.python.org/mailman/listinfo/python-uk
>
>
> ___
> python-uk mailing list
> python-uk@python.org
> https://mail.python.org/mailman/listinfo/python-uk
>
>
>
>
> --
>
> Hansel
> ___
> python-uk mailing list
> python-uk@python.org
> https://mail.python.org/mailman/listinfo/python-uk
>
___
python-uk mailing list
python-uk@python.org
https://mail.python.org/mailman/listinfo/python-uk


Re: [python-uk] Announcing the Yorkshire Inquisition

2016-12-07 Thread Daniel Pope
Idle thought: can the code of conduct be violated by accurately quoting
Time Person-of-the-Year Donald Trump?

On Wed, 7 Dec 2016, 13:21 Andy Robinson,  wrote:

> I believe I am one of the original founding list admins, after 20-odd
> years.  Sadly, the other, John Pinner, has passed away.
>
> I therefore decree, as self-appointed "Benevolent Dictator for List",
> that the Python CoC established by Steve Holden IS the official Code
> of Conduct, and must be respected.
>
> To enforce good conduct in a suitably Pythonic manner, I  hereby
> propose the foundation of the Yorkshire Inquisition, headed by Steve.
> Such an institution will have truly terrifying powers of enforcement.
> Suggestions welcome on this thread
>
> Be pure.  Be vigilant.  Behave!
>
> - Andy
> ___
> python-uk mailing list
> python-uk@python.org
> https://mail.python.org/mailman/listinfo/python-uk
>
___
python-uk mailing list
python-uk@python.org
https://mail.python.org/mailman/listinfo/python-uk


[python-uk] London Python Dojo - 6th October

2016-09-29 Thread Daniel Pope
The next London Python dojo will be on the 6th of October, courtesy of
GoCardless
- 3rd floor, 338-346 Goswell Road, London, EC1V 7LQ. The office is
wheelchair accessible and will be serving Basilico pizza and beer.

Arrive from 6:30pm for our usual mix of pizza and beer and socialising and
hacking and silliness.

For more details, and to register for a free ticket:

https://www.eventbrite.co.uk/e/london-python-code-dojo-season-8-episode-2-tickets-28259114773


Hope to see you there!
___
python-uk mailing list
python-uk@python.org
https://mail.python.org/mailman/listinfo/python-uk


Re: [python-uk] job postings to this list

2016-09-02 Thread Daniel Pope
Just a reminder that the python.org jobs board and pythonjobs.github.io are
available if you want to post job opportunities.

On Fri, 2 Sep 2016 09:10 Nicholas H.Tollervey,  wrote:

> On 01/09/16 22:49, Chris Withers wrote:
> > Hi All,
> >
> > What's the current state of play with job ads and this list?
> >
> > Last I knew, they weren't allowed. Seems to be the majority of list
> > content now...
> >
> > Chris
> >
> > ___
> > python-uk mailing list
> > python-uk@python.org
> > https://mail.python.org/mailman/listinfo/python-uk
>
> As people have mentioned, the consensus that I've seen is that posting a
> job ad is fine so long as it's not recruiter spam.
>
> Of course, recruiters advertising for a specific job with an appropriate
> level of detail about the job in question (location, salary, expectation
> of role, desired skills and experience, information about what the
> company does) is also fine.
>
> What is recruiter spam? How about, "exciting opportunity for Python
> ninja in green-field project at one of London's most exciting employers"
> is, IMHO, NOT welcome. It's just meaningless noise and probably
> recruitment phishing.
>
> Hope this helps,
>
> N.
>
> ___
> python-uk mailing list
> python-uk@python.org
> https://mail.python.org/mailman/listinfo/python-uk
>
___
python-uk mailing list
python-uk@python.org
https://mail.python.org/mailman/listinfo/python-uk


[python-uk] London Python Code Dojo, 7th April

2016-03-31 Thread Daniel Pope
Pyladies and Pygentlemen and py-non-binary-gendered-persons!

The next London Python Dojo will be next Thursday evening, 7th April. This
time the event will be hosted by Essence Digital at 180 Oxford Street, W1D
1NN.

We'll have the usual geek tropes of beer (optional) and pizza
(recommended), and hacking on curious Python puzzles in a friendly
collaborative atmosphere (mandatory).

Please sign up for a free ticket at the link below - which also has full
details - if you would like to attend.

https://www.eventbrite.co.uk/e/london-python-code-dojo-season-7-episode-8-tickets-24314341851
___
python-uk mailing list
python-uk@python.org
https://mail.python.org/mailman/listinfo/python-uk


Re: [python-uk] Pyweek runs Feb-Mar: London team?

2016-02-08 Thread Daniel Pope
Thanks, everyone. Any other takers?

Team, let's take this chat off-list.

On Sun, 7 Feb 2016 07:58 Nick Sarbicki  wrote:

> Looks awesome! I'll get involved if I have any time that week :-).
>
> On Fri, 5 Feb 2016, 01:16 Daniel Pope  wrote:
>
>> The 21st Pyweek competition is coming up at the end of the month, running
>> from 00:00 UTC on 28th February to 00:00 UTC 6th March. Pyweek is a games
>> programming contest in which you must write a game in Python, from scratch,
>> in exactly one week. Games must be written around a theme that is up for
>> voting in the week before the contest. The winning challenge theme is
>> announced at the moment the contest starts. Participants can enter as
>> individuals or teams, and there is one winner in each category based on
>> votes from other entrants.
>>
>> The URL: https://www.pyweek.org/
>>
>> Pyweek is open to everyone: Python novices, adepts or experts. Even
>> people with no programming experience can contribute art, design, sound,
>> music or story to a team project. For some, it might be your first complete
>> end-to-end Python project.
>>
>> You can spend a few hours or all of the week; winning games have been
>> written in a day. One of the most fun aspects of Pyweek is to diarise your
>> progress and upload screenshots. Seeing other games develop, exchanging
>> development war stories and celebrating successes is part of the fun.
>>
>> I would encourage you to consider taking part.
>>
>> Londonites: London Python Dojo regulars have entered a team in the
>> competition a couple of times before, but to my knowledge the last time was
>> several years ago. Since then I've won the individual competition a couple
>> of times, but never the team competition. I think it's time the London
>> Python community stood up to the challenge and took that team trophy home*!
>> Because we're a city of talented, creative, witty Pythonistas. Who's with
>> me?!
>>
>> * There is no trophy.
>>
> ___
>> python-uk mailing list
>> python-uk@python.org
>> https://mail.python.org/mailman/listinfo/python-uk
>>
> ___
> python-uk mailing list
> python-uk@python.org
> https://mail.python.org/mailman/listinfo/python-uk
>
___
python-uk mailing list
python-uk@python.org
https://mail.python.org/mailman/listinfo/python-uk


[python-uk] Pyweek runs Feb-Mar: London team?

2016-02-04 Thread Daniel Pope
The 21st Pyweek competition is coming up at the end of the month, running
from 00:00 UTC on 28th February to 00:00 UTC 6th March. Pyweek is a games
programming contest in which you must write a game in Python, from scratch,
in exactly one week. Games must be written around a theme that is up for
voting in the week before the contest. The winning challenge theme is
announced at the moment the contest starts. Participants can enter as
individuals or teams, and there is one winner in each category based on
votes from other entrants.

The URL: https://www.pyweek.org/

Pyweek is open to everyone: Python novices, adepts or experts. Even people
with no programming experience can contribute art, design, sound, music or
story to a team project. For some, it might be your first complete
end-to-end Python project.

You can spend a few hours or all of the week; winning games have been
written in a day. One of the most fun aspects of Pyweek is to diarise your
progress and upload screenshots. Seeing other games develop, exchanging
development war stories and celebrating successes is part of the fun.

I would encourage you to consider taking part.

Londonites: London Python Dojo regulars have entered a team in the
competition a couple of times before, but to my knowledge the last time was
several years ago. Since then I've won the individual competition a couple
of times, but never the team competition. I think it's time the London
Python community stood up to the challenge and took that team trophy home*!
Because we're a city of talented, creative, witty Pythonistas. Who's with
me?!

* There is no trophy.
___
python-uk mailing list
python-uk@python.org
https://mail.python.org/mailman/listinfo/python-uk


[python-uk] July London Python Dojo tickets available

2015-06-26 Thread Daniel Pope
The next London Python Dojo will be at 6:30pm on Thursday 2nd July at the
offices of Mind Candy in Shoreditch.

Join us for a night of beer, pizza and Python-ing, in the company of
friends.

For details and to sign up for a free ticket, please visit the link below:

https://ldnpydojo.eventwax.com/london-python-code-dojo-season-6-episode-10-2

We have time for a couple of lightning talks if anyone would like to give
one; drop me an e-mail off-list if you'd like to volunteer.

Look forward to seeing you there!

Dan
___
python-uk mailing list
python-uk@python.org
https://mail.python.org/mailman/listinfo/python-uk


Re: [python-uk] hexagonal Django

2014-08-13 Thread Daniel Pope
Coincidentally, I blogged on the topic of Django project organisation at
the weekend.

http://mauveweb.co.uk/posts/2014/08/organising-django-projects.html

May be of interest?
___
python-uk mailing list
python-uk@python.org
https://mail.python.org/mailman/listinfo/python-uk


[python-uk] London Python Dojo TOMORROW (6th March)

2014-03-05 Thread Daniel Pope
Hi all,

There are still a few tickets available for tomorrow's London Python Dojo,
if anyone is interested.

https://ldnpydojo.eventwax.com/london-python-code-dojo-season-5-episode-7

Dan
___
python-uk mailing list
python-uk@python.org
https://mail.python.org/mailman/listinfo/python-uk


Re: [python-uk] London Python Dojo March

2014-02-27 Thread Daniel Pope
> On 27/02/14 12:34, Jon Ribbens wrote:
> > Will you be posting further messages when more tickets are added?

No! Persistence and patience will be rewarded, instead of speed out of the
gate.

Dan
___
python-uk mailing list
python-uk@python.org
https://mail.python.org/mailman/listinfo/python-uk


[python-uk] London Python Dojo March

2014-02-27 Thread Daniel Pope
Hi all,

The next London Python Dojo will be on Thursday 6th March at Mind Candy in
Shoreditch.

We will have the usual mix of beer, pizza, socialising and coding silly
things in Python.

Full details and ticket sign up* is at

https://ldnpydojo.eventwax.com/london-python-code-dojo-season-5-episode-7

* In a change to the usual land rush pattern, tickets will be released in
waves over the next few days. If you can't get a ticket immediately, maybe
check back later.
___
python-uk mailing list
python-uk@python.org
https://mail.python.org/mailman/listinfo/python-uk


Re: [python-uk] copyright info in source

2013-09-09 Thread Daniel Pope
Maybe you could omit license headers in your repo, but add them when
building the sdist?


On 9 September 2013 20:57, Jonathan Hartley  wrote:

> Thanks for all the input, people.
>
> FWIW, The folks downstream said their motivation was the continual
> difficulty of automatically checking for acceptable licenses on the many
> bits of (allegedly) FOSS they use. They have 4k of filenames that the
> license checker can't currently account for, and re-checking them all
> manually every few months is a continual drain.
>
> I'll roll over on this one. That the world is the way it is raises my
> hackles, but no point me making life harder for some other blameless devs.
> I'll squeeze it into 80 chars per file somehow. Thanks for the pointers on
> that.
>
> Jonathan Hartley
> http://tartley.com
>
> Russel Winder  wrote:
>
> >On Mon, 2013-09-09 at 16:13 +0100, Jonathan Hartley wrote:
> >> Why would a file ever be seen out of context? Surely to make my source
> >> available without the LICENSE file is breaking the terms of my license,
> >> so I'm not sure why I ought to jump through hoops just to cater for such
> >> people. Am I wrong?
> >
> >You are both right and wrong. You are right that this should be the case
> >in (programmer) logic. However the issue is what does the amalgam of
> >statute, case law, barristers and judges make of the situation.
> >
> >I would suggest either complying with the request, or withdraw the
> >material from licenced use.
> >
> >--
> >Russel.
>
> >=
> >Dr Russel Winder  t: +44 20 7585 2200   voip:
> sip:russel.win...@ekiga.net
> >41 Buckmaster Roadm: +44 7770 465 077   xmpp: rus...@winder.org.uk
> >London SW11 1EN, UK   w: www.russel.org.uk  skype: russel_winder
> >
> >___
> >python-uk mailing list
> >python-uk@python.org
> >https://mail.python.org/mailman/listinfo/python-uk
> ___
> python-uk mailing list
> python-uk@python.org
> https://mail.python.org/mailman/listinfo/python-uk
>
___
python-uk mailing list
python-uk@python.org
https://mail.python.org/mailman/listinfo/python-uk


Re: [python-uk] copyright info in source

2013-09-09 Thread Daniel Pope
You don't have to include a notice of copyright to enjoy copyright
protection (under the Berne Convention). Nothing is assumed to be public
domain unless it is explicitly disclaimed as such.

Since licence terms are based on copyright I don't think you need to state
it everywhere. If someone fails to receive a copy of the licence they can
assume no rights to copy your code.
On 9 Sep 2013 14:18, "Jonathan Hartley"  wrote:

> A small Python project of mine is apparently being included in Chromium,
> because I've had a bug report from them that my source files (plural) fail
> their build-time license checker.
>
> They'd like me to include a license and copyright info in every source
> file (including empty __init__.py files).
>
> I've responded that I don't want to be unhelpful, but I don't believe in
> putting duplicate license and copyright info in every source code file. To
> my mind, it belongs in a single central place, i.e. the project LICENSE
> file.
>
> Am I being unreasonable and/or daft?
>
> Jonathan
>
> --
> Jonathan Hartleytart...@tartley.comhttp://tartley.com
> Made of meat.   +44 7737 062 225   twitter/skype: tartley
>
> __**_
> python-uk mailing list
> python-uk@python.org
> https://mail.python.org/**mailman/listinfo/python-uk
>
___
python-uk mailing list
python-uk@python.org
https://mail.python.org/mailman/listinfo/python-uk


[python-uk] Steganography Code

2013-06-07 Thread Daniel Pope
Our team's code from last night's London Python Dojo (HTML Steganography)
is on Bitbucket at

https://bitbucket.org/akhare/html-steganography
___
python-uk mailing list
python-uk@python.org
http://mail.python.org/mailman/listinfo/python-uk


Re: [python-uk] Suggestions / best practices for deployment

2013-05-20 Thread Daniel Pope
It doesn't need to be SSH-based, there are orchestration systems that are
RPC or pubsub based (eg. Jenkins, MCollective).

As per the line between provisioning and deployment I've argued in the past
that provisioning should be for state that spans many minor releases of an
application. I also believe it's preferable to require that deployment
cannot use root permissions, as this is less likely to impact independent
services hosted on the same machine. It also allows better auditability -
it prevents deployments making changes that are rightly the domain of the
provisioning system.
On 20 May 2013 11:17, "MikedePlume"  wrote:

> On Sat, 2013-05-18 at 17:41 +0100, Andy Robinson wrote:
> > Daniel, who are you disagreeing with?   Everyone here agrees on
> > automation, I think.
> >
> > - Andy
>
> As a small user (one or two servers, one or two packages to deploy):
>
> I started by doing a lot of typing of commands, got bored with that,
> moved on to command line scripts and I now use a bunch of (python)
> scripts, some fabric based, to manage the server farm api and the ssh
> stuff. I think the point is that the underlying process is always going
> to involve ssh and some server farm api and it is the automation of all
> of that where the cornucopia of choice (?) is displayed.
>
> From a teaching perspective (that's what the book is about, I guess) I'd
> recognise the basics of ssh and so on and then build up from there. The
> basic principles behind testing a fabric deploy should be extendable to
> other environments, I'd have thought?
>
> I must say, I'd love to see something about testing bash scripts, and,
> perhaps, where to draw the line (if at all) between server provisioning
> and ci.
>
> Cheers
>
> Mike S.
> >
> >
> >
> > On 18 May 2013 12:24, Daniel Pope  wrote:
> > > I thoroughly disagree with those who are saying that for small
> > > installations, it's less time-consuming to do things manually. A
> > > deployment/provisioning system gives you reproducibility - an
> executable
> > > record of how to re-create a server configuration or re-run a
> deployment
> > > without missing anything. The number of times I've spent 20 minutes
> > > wondering what I've missed all add up - that is why it automation
> breaks
> > > even so rapidly.
> > >
> > > Of course, you (or your employers) might have other reasons to want
> > > automation:
> > >
> > > - so that your deployment/provisioning is subject to automated testing,
> > > version control, code review, etc
> > > - so that you can build replicas of production servers for development,
> > > testing or disaster recovery
> > > - so that you can smash and rebuild a compromised or faulty machine
> without
> > > wasting time
> > > - so that you can deploy a dozen times a day and get features or fixes
> into
> > > the hands of your users
> > >
> > >
> > > On 17 May 2013 15:39, M.-A. Lemburg  wrote:
> > >>
> > >> On 16.05.2013 17:46, Andy Robinson wrote:
> > >> > Speaking as a relatively obsolete dinosaur, I would suggest that if
> > >> > you are going to discuss specific deployment practices, you start
> with
> > >> > the most fundamental ones:  SSH, the unix shell and so on.
> > >> >
> > >> > We have had issues over the years with people coming in and
> > >> > introducing sexy new deployment tools, but ultimately they all just
> > >> > run unix commands.  Anyone managing a web application in the
> > >> > non-microsoft world is ultimately depending on this.  Some key
> skills
> > >> > (assuming a Linux/Mac/Unix-ish environment):
> > >> > - know about SSH keys and logging into remote machines
> > >> > - know the basics of at least one command line editor (e.g. vi)
> > >> > - basic shell knowledge:  environment variables, testing for
> existence
> > >> > of files and directories etc
> > >> > - how to interact with your database from the command line, if you
> use
> > >> > one (including dump and restore)
> > >> > - how your web server works: starting, stopping, configuration
> files,
> > >> > where log files live and how it talks to Python
> > >> >
> > >> > Fabric may be useful if you want to control half a dozen machines
> from
> > >> > your desktop, and it might add a lot of value if you want to
> control a
> > >> > hund

Re: [python-uk] Suggestions / best practices for deployment

2013-05-18 Thread Daniel Pope
I thoroughly disagree with those who are saying that for small
installations, it's less time-consuming to do things manually. A
deployment/provisioning system gives you reproducibility - an executable
record of how to re-create a server configuration or re-run a deployment
without missing anything. The number of times I've spent 20 minutes
wondering what I've missed all add up - that is why it automation breaks
even so rapidly.

Of course, you (or your employers) might have other reasons to want
automation:

- so that your deployment/provisioning is subject to automated testing,
version control, code review, etc
- so that you can build replicas of production servers for development,
testing or disaster recovery
- so that you can smash and rebuild a compromised or faulty machine without
wasting time
- so that you can deploy a dozen times a day and get features or fixes into
the hands of your users


On 17 May 2013 15:39, M.-A. Lemburg  wrote:

> On 16.05.2013 17:46, Andy Robinson wrote:
> > Speaking as a relatively obsolete dinosaur, I would suggest that if
> > you are going to discuss specific deployment practices, you start with
> > the most fundamental ones:  SSH, the unix shell and so on.
> >
> > We have had issues over the years with people coming in and
> > introducing sexy new deployment tools, but ultimately they all just
> > run unix commands.  Anyone managing a web application in the
> > non-microsoft world is ultimately depending on this.  Some key skills
> > (assuming a Linux/Mac/Unix-ish environment):
> > - know about SSH keys and logging into remote machines
> > - know the basics of at least one command line editor (e.g. vi)
> > - basic shell knowledge:  environment variables, testing for existence
> > of files and directories etc
> > - how to interact with your database from the command line, if you use
> > one (including dump and restore)
> > - how your web server works: starting, stopping, configuration files,
> > where log files live and how it talks to Python
> >
> > Fabric may be useful if you want to control half a dozen machines from
> > your desktop, and it might add a lot of value if you want to control a
> > hundred of them.  But to update one server, you deploy by logging into
> > it and then running commands or short scripts.
> >
> > For example, we have a 'demo site' we rebuild pretty often that uses
> > Django, MYSQL, Celery and a few other things.  It runs on plain
> > vanilla Ubuntu machines we build ourselves.  The sequence is...
> >
> > 1. Log in via SSH
> > 2. CD to correct directory
> > 3. activate virtual environment
> > 4. stop any celery worker processes
> > 5. stop web server processes (* in our setup, we leave Apache running)
> > 6. pull latest code from mercurial - both the app, and 3-4 libraries
> > it depends on
> > 7. run a management command to rebuild the database
> > 8. run a smallish in-place test suite
> > 9. restart celery workers
> > 10.restart web server
> > 11. log out
> >
> > All of this after the login and CD can be handled by a shell script on
> > the path of the server, so you can just run a command called something
> > like
> >   ./update_server
> >
> > More realistically, we tend to end up with a management shell script
> > called 'server' with a bunch of commands/arguments like 'stop / start
> > / restart / update-code-in-staging / copy-live-data-to-staging /
> > run-health-checks / swap-live-and-staging' and so on.  SSH can execute
> > remote commands like this just fine with the right arguments, if
> > actually logging in is too tedious.
> >
> > Production sites are complex and all different.  You might want to do
> > instantaneous swaps from live to staging (and be able to back out fast
> > if stuff goes wrong); to switch DNS so the world is looking at another
> > server while you update one; you might have large databases to copy or
> > migrate that need significant time; it may or may not be acceptable to
> > lose sessions and have downtime; and so on.
> >
> >
> > It takes less time to learn the fundamentals than you will spend
> > debugging why your fancy new deployment tool stopped working after
> > some Python dependency upgrade somewhere.   And it is less likely that
> > your new hires will disagree if you stick with the lowest common
> > denominator.
>
> Fully agreed.
>
> The new devops tools are nice when it comes to managing farms
> of VMs, where each VM is setup in more or less the same way,
> and you want to reduce repetitive tasks, but for a typical
> setup with just a few VMs/servers it'll take you longer to
> write and (most importantly) test your devops scripts than
> it would to write a few scripts that you can run via SSH on
> the servers.
>
> No matter how smart you make your devops scripts, Murphy's law
> is inevitably going to strike and humans are so much better at
> parsing weird intermittent error messages than machines ...
> still, after all these years :-)
>
> --
> Marc-Andre Lemburg
> eGenix.com
>
> Professional Python 

Re: [python-uk] Maze Generator - Team 3

2013-05-07 Thread Daniel Pope
On 4 May 2013 11:13, Ciarán Mooney  wrote:

> Below is a link to my maze generator, using David's idea of procedural
> generator (rather than the algorithm Dan described).
>

Seeing as everyone seems to still be hacking on this, I took a stab at
implementing the algorithm I was suggesting in the dojo, and I hooked it up
to the 3D maze renderer:

https://bitbucket.org/lordmauve/ldnpydojo-s4e9
___
python-uk mailing list
python-uk@python.org
http://mail.python.org/mailman/listinfo/python-uk


Re: [python-uk] Maze Generator - Team 3

2013-05-04 Thread Daniel Pope
My 3D maze-drawing code is at

https://bitbucket.org/lordmauve/ldnpydojo-s4e9

Integrating a maze just requires implementing itercells().


On 4 May 2013 11:13, Ciarán Mooney  wrote:

> To the members of team three and other dojo'ers,
>
> Below is a link to my maze generator, using David's idea of procedural
> generator (rather than the algorithm Dan described).
>
> https://github.com/ciaranmooney/procMaze
>
> I think it works, and only took about 20 mins to write in the end. The
> mazes it makes are not the best in the world.
>
> I've no idea what we were doing wrong, but if someone from Team 3
> (David, Caroline, or Tony) could send me the code we wrote I'd love to
> have another look at it.
>
> Cheers,
>
> Ciarán
> ___
> python-uk mailing list
> python-uk@python.org
> http://mail.python.org/mailman/listinfo/python-uk
>
___
python-uk mailing list
python-uk@python.org
http://mail.python.org/mailman/listinfo/python-uk


[python-uk] Reading Python Dojo, next Tuesday, 26th February

2013-02-21 Thread Daniel Pope
The next Reading Python Dojo will be on Tuesday 26th February at 7pm, at
Austin
Fraser in Forbury Square, Reading.

Please sign up for a free ticket at the link below if you would like to
attend.

https://rdgpydojo.eventwax.com/reading-python-dojo-february-2013

Dan
___
python-uk mailing list
python-uk@python.org
http://mail.python.org/mailman/listinfo/python-uk


[python-uk] Reading Python Dojo, tomorrow (Tuesday 22nd January)

2013-01-21 Thread Daniel Pope
Hi all,

Just a reminder that there are plenty of places still available for
tomorrow's Python Dojo in Reading. If you'd like to brave the cold and
the snow, the reward is beer and pizza, not to mention a couple of
hours to program something cool in Python.

If you would like to attend, please take a ticket at

https://rdgpydojo.eventwax.com/reading-python-dojo-january-2013

Dan
___
python-uk mailing list
python-uk@python.org
http://mail.python.org/mailman/listinfo/python-uk


[python-uk] Next Reading Python Dojo, 22nd January 2013

2013-01-14 Thread Daniel Pope
The next Reading Python Dojo will be on Tuesday 22nd January at 7pm, at Austin
Fraser in Forbury Square, Reading as usual.

Please sign up for a free ticket at the link below if you would like to attend.

https://rdgpydojo.eventwax.com/reading-python-dojo-january-2013

Our hosts Austin Fraser also sponsor free beer and pizza; add a
message on the ticket sign-up form if you have particular preferences.

If anyone would be willing to give a talk on any interesting subject
before coding starts, please drop me an e-mail.

Dan
___
python-uk mailing list
python-uk@python.org
http://mail.python.org/mailman/listinfo/python-uk


Re: [python-uk] hexagonal Django

2012-12-04 Thread Daniel Pope
I go a little way in this direction. I rarely go as far as dependency
injection for business logic, but a good habit I picked up is to ensure
that my business logic is put in appropriate places somewhere other than
view functions, and all queries are kept with the models (ie. as Manager
methods), and all the presentation operations are template tags and
filters. That way the view contains little more than just connecting
queries to business logic to templates, which is useful when it comes to
understanding how an application was plumbed. In fact I've just used this
to quite rapidly port a Postgres backed Django app to entirely
ElasticSearch backed. Because I had defined my queries in terms of Manager
methods it wasn't hard to reimplement them one-by-one with equivalent
ElasticSearch searches. It would have been much harder if I'd littered
.filter()/.exclude() calls all over the place.

Something that was useful for that and slightly mitigates Django in this
regard is that the lazily-evaluated, sliceable QuerySet has become
something of a pattern, to the extent that you can sometimes sort of plug
QuerySet-like result objects, such as those from PyES, MongoEngine,
couchdb-python etc, into logic built around querysets. It also helps that
Django templates are very forgiving.

While interviewing for Python developers I found numerous candidates who
when presented with a generic OOP problem would immediately start writing
Django models, with the result that the solution exhibits exactly the kind
of dependency problems that article describes. For similar reasons, we now
have an application where the cryptically terse dictionary keys favoured by
hardcore MongoDB geeks leak everywhere, including template code and
client-side javascript.
___
python-uk mailing list
python-uk@python.org
http://mail.python.org/mailman/listinfo/python-uk


[python-uk] Reading Python Dojo 20th November

2012-11-07 Thread Daniel Pope
The next Reading Python Dojo will be on Tuesday 20th November at 7pm at
Austin
Fraser in Forbury Square. As usual there will be beer and pizza, but
there's also a slot for talks if anyone would like to give a talk.

Please sign up for a free ticket at the link below if you would like to
attend.

https://rdgpydojo.eventwax.com/reading-python-dojo-november-2012

Dan
___
python-uk mailing list
python-uk@python.org
http://mail.python.org/mailman/listinfo/python-uk


[python-uk] Reading Python Dojo, 25th September

2012-09-14 Thread Daniel Pope
The next Reading Python Dojo will be on Tuesday 25th September at 7pm at Austin
Fraser in Forbury Square, with the usual mix of beer, pizza and coding.

Please sign up for a free ticket at the link below if you would like to attend.

https://rdgpydojo.eventwax.com/reading-python-dojo-september-2012

Dan
___
python-uk mailing list
python-uk@python.org
http://mail.python.org/mailman/listinfo/python-uk


[python-uk] Reading Python Dojo

2012-07-23 Thread Daniel Pope
Hi,

Just another little plug for this Wednesday's Python Dojo in Reading:

https://rdgpydojo.eventwax.com/reading-python-dojo-number-7

Dan
___
python-uk mailing list
python-uk@python.org
http://mail.python.org/mailman/listinfo/python-uk


[python-uk] Reading Python Dojo, 25th July

2012-07-12 Thread Daniel Pope
Hi all,

The next Reading Python Dojo will be on Wednesday 25th July at 7pm at Austin
Fraser in Forbury Square.

Please sign up for a free ticket at the link below if you would like to attend.

https://rdgpydojo.eventwax.com/reading-python-dojo-number-7

Dan
___
python-uk mailing list
python-uk@python.org
http://mail.python.org/mailman/listinfo/python-uk


[python-uk] Reading Python Dojo - Wednesday 20th June

2012-06-12 Thread Daniel Pope
Hi all,

The next Reading Python Dojo will be on Wednesday 20th June at 7pm at Austin
Fraser in Forbury Square. Free beer and pizza will be available as usual.

Please sign up for a free ticket at the link below if you would like to attend.

https://rdgpydojo.eventwax.com/reading-python-dojo-number-6

Dan
___
python-uk mailing list
python-uk@python.org
http://mail.python.org/mailman/listinfo/python-uk


Re: [python-uk] Reading Python Dojo

2012-04-30 Thread Daniel Pope
On Wed, Apr 25, 2012 at 04:45:21PM +0100, Daniel Pope wrote:
> The next Reading Python Dojo will be Tuesday 1st May at 7pm at Austin
> Fraser in Forbury Square. Free beer and pizza will be available as
> usual.
> 
> Please sign up for free ticket on the EventWax site if you would like to 
> attend.
> 
> https://rdgpydojo.eventwax.com/reading-python-dojo-number-5

Bumping, in case anyone missed it. Still plenty of places available!

Dan
___
python-uk mailing list
python-uk@python.org
http://mail.python.org/mailman/listinfo/python-uk


[python-uk] Reading Python Dojo

2012-04-25 Thread Daniel Pope
Hi all,

The next Reading Python Dojo will be Tuesday 1st May at 7pm at Austin
Fraser in Forbury Square. Free beer and pizza will be available as
usual.

Please sign up for free ticket on the EventWax site if you would like to attend.

https://rdgpydojo.eventwax.com/reading-python-dojo-number-5
___
python-uk mailing list
python-uk@python.org
http://mail.python.org/mailman/listinfo/python-uk


[python-uk] Reading Python Dojo Number 4

2012-03-08 Thread Daniel Pope
Hi all,

The next Reading Python Dojo will be next Wednesday, 14th March, at 7pm
at One Forbury Square.  Free beer and pizza will be available as usual,
courtesy of our sponsors and hosts Austin Fraser.

Please sign up for free ticket on our EventWax site if you would like to
attend.

https://rdgpydojo.eventwax.com/reading-python-dojo-number-4

As usual, there is a slot to give a brief presentation (15-30 minutes)
on any Python-related subject. We'd love to hear about what you're
working on or if you've learned about anything really cool recently.
Please drop me an e-mail if you'd like to speak.
___
python-uk mailing list
python-uk@python.org
http://mail.python.org/mailman/listinfo/python-uk


[python-uk] Python Dojo in Reading

2012-01-26 Thread Daniel Pope
Hi all,

After a busy few weeks I've finally managed to get my act together and
arrange the next Reading Python Dojo.

It will be next Tuesday, 31st January, at 7pm at Austin Fraser in Forbury
Square. Free beer and pizza will be available as usual.

Please sign up for free ticket on our EventWax site if you would like to
attend.

https://rdgpydojo.eventwax.com/reading-python-dojo-number-3
___
python-uk mailing list
python-uk@python.org
http://mail.python.org/mailman/listinfo/python-uk


[python-uk] Python Dojo Reading, 7pm 16th November, One Forbury Square

2011-11-08 Thread Daniel Pope
Hello everyone.

The next Reading Python Dojo will be at 7pm on Wednesday 16th November, at One
Forbury Square, Reading, RG1 3BB. 

Before the coding starts, we will have a brief talk by Mal Minhas about his
experiences trying to extract information from Excel files with Python.

There is another ~15 minute slot available if anyone else would like to talk
about a Python-related topic of any description.

Please sign up for a ticket on our EventWax site to let us know who is coming,
and whether you have any particular preference for pizza toppings, etc.

https://rdgpydojo.eventwax.com/reading-python-dojo-number-2

Dan
___
python-uk mailing list
python-uk@python.org
http://mail.python.org/mailman/listinfo/python-uk


[python-uk] Python Dojo in Reading?

2011-10-04 Thread Daniel Pope
Hi all,

A couple of months back I was searching to see if there was a Python Dojo in or
near Reading. This led to a Google search that turned up little except articles
extolling how easy Python code is to read. On the basis of this negligible
research, and Nicholas' talk at Europython, I thought I'd investigate setting
up a dojo, but only in the last couple of weeks have some potential sponsors
made themselves known to me.

If there is a meet-up nearby that already exists, please let me know so I can
stop wasting my time (and attend, obviously)!

But if you'd be interested in attending a Dojo in Reading (potentially within
the next couple of weeks), perhaps you could drop me an e-mail off-list so that
I can gauge interest? I'll set up an Eventwax thing and announce on this list
if this thing has legs.

Dan
___
python-uk mailing list
python-uk@python.org
http://mail.python.org/mailman/listinfo/python-uk


Re: [python-uk] Library for (undirected) graphs in Python?

2011-01-25 Thread Daniel Pope

On 24/01/11 22:29, Alex Willmer wrote:

The only program I know for (un)directed graphs is Graphviz and
associated DOT format. For which there a few hits:
http://pypi.python.org/pypi?:action=search&term=graphviz


You don't need a library to use graphviz. graphviz has a command-line 
interface that renders a DOT file. A DOT file is just a list of nodes 
and edges and how they should be drawn.


At its simplest an undirected graph in DOT format is written like:

graph {
A -- B;
B -- C;
B -- D;
}

This is easy to generate with any version of Python.

Dan
___
python-uk mailing list
python-uk@python.org
http://mail.python.org/mailman/listinfo/python-uk