profile
viewpoint
If you are wondering where the data of this site comes from, please visit https://api.github.com/users/nickdrozd/events. GitMemory does not store any data, but only uses NGINX to cache data for a period of time. The idea behind GitMemory is simply to give users a better reading experience.

nickdrozd/Lisp-C-Compyler 4

Lisp-to-C compiler written in Python. Based on the compiler presented in SICP chapter 5!

nickdrozd/.emacs.d 2

Emacs config

nickdrozd/defkey 1

Clean Emacs key bindings

nickdrozd/glitchy 1

Glitch art generator: guaranteed to create glitched images, "art" not guaranteed

nickdrozd/ace-window 0

Quickly switch windows in Emacs

nickdrozd/astroid 0

A common base representation of python source code for pylint and other projects

nickdrozd/autopep8 0

A tool that automatically formats Python code to conform to the PEP 8 style guide.

nickdrozd/bandit 0

Bandit is a tool designed to find common security issues in Python code.

nickdrozd/Barliman 0

Prototype smart text editor

nickdrozd/batman 0

Fast transit light curves models in Python.

push eventnickdrozd/rado

Nick Drozd

commit sha eea75fefd119b3c4df18d99b3a8cc8c5fe78eb5f

Add CI

view details

Nick Drozd

commit sha 7c21961b13c7ffdb455b128082e93e5efe77bb53

brew upgrade

view details

Nick Drozd

commit sha c3facd85c51cbc7b58ea8da30a4c521faebdbe07

release

view details

push time in 2 days

push eventnickdrozd/rado

Nick Drozd

commit sha 34484d050d64f13e92c92da300d0ec6e3a95b21b

import

view details

push time in 2 days

push eventnickdrozd/rado

Nick Drozd

commit sha e5a0cd60721e86fd1d800a977b099ec1ecfbf11e

Add CI

view details

push time in 2 days

push eventnickdrozd/rado

Nick Drozd

commit sha f3e887311b24bfdc6aef6a9814c504e6fb926d4e

Add CI

view details

push time in 2 days

issue commentrecursecenter/blaggregator

Tag authors in the zulip stream

I looked at the zulip API docs to see if the avatar can be changed for a message, and couldn't find anything. If you know that this is possible, could you link to some documentation/examples? Thanks!

I was just assuming that it would be possible, but I have no idea if it is, or how to do it.

heatherbooker

comment created time in 3 days

pull request commentPyCQA/pylint

Use node_ancestors to get rid of some while-loops

Okay, I pared it down to just the straightforward cases. Thanks for reviewing!

nickdrozd

comment created time in 3 days

push eventnickdrozd/pylint

Pierre Sassoulas

commit sha de9af75104f74f954f3eae0085cc0c400f04511d

Pylint reporter cleanup (#5003) * Create a file for pylint.reporters.BaseWritter * Calculate visitor name only once in Reporter nodes Remove dead code that was always failing and replace it by an attribute directly. Co-authored-by: Marc Mueller <30130371+cdce8p@users.noreply.github.com>

view details

Daniël van Noord

commit sha af407c73064c1a9cb3cce5f056fa1e26c9e7b540

Make consider-iterating-dictionary consider membership check (#4997)

view details

yushao2

commit sha 272596b80c8f9cb6ddb6e3f893298f20242a9c32

Fix false positive ``unused-private-member`` for accessing attributes in a class using ``cls`` (#4965) * Fix false positive ``unused-private-member`` for accessing attributes in a class using ``cls`` Co-authored-by: Pierre Sassoulas <pierre.sassoulas@gmail.com>

view details

Pierre Sassoulas

commit sha 8d3ced46cfc901eed0da0186acba920d93bc4576

Fix deprecation warning for AssignAttr in tests (#5006) * Fix deprecation warning for AssignAttr We should initialize nodes using their constructor Co-authored-by: Marc Mueller <30130371+cdce8p@users.noreply.github.com>

view details

Dimitri Prybysh

commit sha ca6c355e5d5c1ed569962187cc8a87da4d805cad

Add functional test demonstrating #4370 After PyCQA/astroid#1166 is merged, this test should become green.

view details

Dimitri Prybysh

commit sha 5b99e12a686b50510e77764a059b80bec176a085

Update CONTRIBUTORS.txt I feel confident enough to fix my own last name.

view details

Daniël van Noord

commit sha 0687d5caf7a57ebf9c82126e92a3c223d724f5b5

Change lines to lists (#5009)

view details

Pierre Sassoulas

commit sha a3f3405d57558d6d5dd21112a5dfeb1fb1ed50a5

Fix PyreverseConfig imports in pyreverse's tests

view details

Daniël van Noord

commit sha cb896128b0e8f62c0650e980ef77a3c8af21ef8d

Remove most `typing.cast()` calls (#4995)

view details

Daniël van Noord

commit sha 22e56c07cf745d695df1d52fe3988cc071f0951b

Add typing to all calls to ``self.stats`` (#4973) * Add typing to all calls to ``self.stats`` All checkers inherit from a baseclass which has a ``stats`` attribute. This attribute has a fairly unmanageable type, but the current typing includes all variations of the attribute. Other changes not directly related to ``self.stats`` are due to ``mypy``warnings. This incorporate the feedback received in #4954 * Add ``CheckerStatistic`` class to ``pylint/typing`` * Guard `typing.Counter` import Co-authored-by: Marc Mueller <30130371+cdce8p@users.noreply.github.com> Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>

view details

Pierre Sassoulas

commit sha d4e61b9024dd6f073739fc6f7e6ecef2dceb9aaa

Move PyreverseConfig to pylint.testutil (#5013) See : https://github.com/PyCQA/pylint/pull/5010#issuecomment-920291278

view details

Daniël van Noord

commit sha 14f4db56c00cd34ddd60fe9498823806abd6b3f9

Move methods to `BaseLayout` (#5015) * Move methods to `BaseLayout` and change typing, see https://github.com/PyCQA/pylint/pull/5004#discussion_r708532947

view details

Pierre Sassoulas

commit sha dc0c7e97b1e92beffa36f76c5c56164f69b81a2a

Add typing in ``pylint.reporters`` (#5004) * Add typing and fix small issue in pylint.reporters Fix typing error in pylint/checkers/imports.py. Add typing of report related code outside of pylint.reporters. * Remove unused argument in pylint.reporters.VNode constructor * Simplify and specify the typing in reporters nodes Co-authored-by: Daniël van Noord <13665637+DanielNoord@users.noreply.github.com>

view details

Daniël van Noord

commit sha 0d246e55a3d13d4fb0829c000064fa26fcbd4183

Add typing to ``filepath`` (#4980) * Change tests for ``filepath`` changes * Add pylint/typing.py and FileItem NamedTuple * Use NamedTuple more efficiently * Fix errors and tests after adding warning * Add deprecation for future API change in Checker Co-authored-by: Marc Mueller <30130371+cdce8p@users.noreply.github.com> Co-authored-by: Pierre Sassoulas <pierre.sassoulas@gmail.com>

view details

Pierre Sassoulas

commit sha 7add5d00ff5bb36a21bb5fe92cc8e67c5ca80e80

Bump pylint to 2.11.0, update changelog

view details

Pierre Sassoulas

commit sha 67957e233cdd402cacc4389aeba5e717a684f7a2

Move back to a dev version following 2.11.0 release

view details

Daniël van Noord

commit sha f45ab4972bbf140d449a023bf1407237d21c5879

Fix ``unspecified-encoding`` for `Path()` This closes #5017

view details

Daniël van Noord

commit sha 6d07d6f1a51c2e3e3e2db37f23c12ebdec094410

Add typing for ``json_reporter`` and sub-classes

view details

Pierre Sassoulas

commit sha d98e6e8adcdc5ebcd9c863f630e748cdba639b0a

Bump pylint to 2.11.1, update changelog

view details

Pierre Sassoulas

commit sha da36529a6ae1fb83417e600528692530a27aac1f

Move back to a dev version following 2.11.1 release

view details

push time in 3 days

issue openedPyCQA/astroid

Opportunity for performance improvement

The commit that added deprecation warnings (40ea1a3b8e52bbfed43deb1725cde461f4bd8a96) seems to have degraded performance. I ran Pylint agaist the Pandas repos with Astroid set at that commit and the one just before, and the difference in time was significant:

bc14d8ef (one before deprecation)
  real	9m16.218s
  user	9m1.700s
  sys	0m3.113s

  real	9m14.876s
  user	9m2.120s
  sys	0m3.268s

40ea1a3b (deprecation)
  real	9m36.715s
  user	9m25.770s
  sys	0m2.984s

  real	9m39.313s
  user	9m24.253s
  sys	0m3.024s

Profiling suggests that this is mostly due to the use of inspect.signature:

https://github.com/PyCQA/astroid/blob/2e26f0383bc4dacc62b4af655b68767e3e0497f4/astroid/decorators.py#L174

I don't know how to get around this, but doing so might improve performance.

created time in 5 days

Pull request review commentPyCQA/pylint

Use node_ancestors to get rid of some while-loops

 def _check_not_in_finally(self, node, node_name, breaker_classes=()):         if not self._tryfinallys:             return         # the node could be a grand-grand...-children of the try...finally-        _parent = node.parent         _node = node-        while _parent and not isinstance(_parent, breaker_classes):-            if hasattr(_parent, "finalbody") and _node in _parent.finalbody:+        for parent in node.node_ancestors():+            if isinstance(parent, breaker_classes):+                break+            if hasattr(parent, "finalbody") and _node in parent.finalbody:                 self.add_message("lost-exception", node=node, args=node_name)                 return-            _node = _parent-            _parent = _node.parent+            _node = parent

Yet another variation is looping over a node's siblings rather than its ancestors.

nickdrozd

comment created time in 5 days

PullRequestReviewEvent

Pull request review commentPyCQA/pylint

Use node_ancestors to get rid of some while-loops

 def _check_not_in_finally(self, node, node_name, breaker_classes=()):         if not self._tryfinallys:             return         # the node could be a grand-grand...-children of the try...finally-        _parent = node.parent         _node = node-        while _parent and not isinstance(_parent, breaker_classes):-            if hasattr(_parent, "finalbody") and _node in _parent.finalbody:+        for parent in node.node_ancestors():+            if isinstance(parent, breaker_classes):+                break+            if hasattr(parent, "finalbody") and _node in parent.finalbody:                 self.add_message("lost-exception", node=node, args=node_name)                 return-            _node = _parent-            _parent = _node.parent+            _node = parent

There's another common variation where the last ancestor satisfying some condition is returned. I'm not sure if that needs another method or if there's a different pattern for that kind of thing.

nickdrozd

comment created time in 5 days

PullRequestReviewEvent

Pull request review commentPyCQA/pylint

Use node_ancestors to get rid of some while-loops

 def get_numversion_from_version(v: str) -> Tuple:                 version.append(int(num))             except ValueError:                 version.append(0)-    while len(version) != 3:-        version.append(0)+    # pad out version with 0s+    version += [0] * (3 - len(version))

Lately I've been exploring the idea of programming using only primitive-recursive operators. Turing-completeness is not often required, and most tasks can be done without it. The while operator is awfully powerful, and it's definitely overkill for such a simple task as "pad out this list until it's at least of length 3". Ideally there would be no while loops at all except for where they're really needed, like perhaps in inference.

Of course this is an idiosyncratic concern, so I reverted the change.

nickdrozd

comment created time in 5 days

PullRequestReviewEvent

push eventnickdrozd/pylint

Nick Drozd

commit sha b8039e2d5b9859e0fc27ad6fc66e4b94fa0be3e8

Leave version loop alone

view details

push time in 5 days

delete branch nickdrozd/pytur

delete branch : idris-merge

delete time in 6 days

delete branch nickdrozd/pytur

delete branch : merge-2

delete time in 6 days

push eventnickdrozd/pytur

Nick Drozd

commit sha a24547b8485c4610ecdf92f527ddf27a745a3c46

Add make idris command

view details

push time in 6 days

push eventnickdrozd/pytur

Nick Drozd

commit sha c1d9bf19899cbefa73f74d50e057b235d22a40bf

Add make idris command

view details

push time in 6 days

push eventnickdrozd/pytur

Nick Drozd

commit sha bb2928be3774403a005947f190756d9a29974027

Start new repo

view details

Nick Drozd

commit sha d69def2813f1485d5814a5353e128b81105fb680

Add Busy Beavers

view details

Nick Drozd

commit sha 9737914ce87629a89fb4674a81f2822a6f6bbeaa

Add gitignore

view details

Nick Drozd

commit sha 7492eb8ea09bffe57399dfd2cceb082aea3d15cc

Rework Action type

view details

Nick Drozd

commit sha 6f1cc72bf1755b3165c73160bce0ebe81055ba91

Add MachineResult

view details

Nick Drozd

commit sha 0f89b4a7e7b93e06831fe6266722556de1545555

Capitalize filename

view details

Nick Drozd

commit sha bee2d57d822a15d793055ac29824c6ef93c47235

Start parsing

view details

Nick Drozd

commit sha f69244e2c27177aefafdb56f9c4a8ef37fd3eba4

More parsing

view details

Nick Drozd

commit sha 1a0b0980f75af2daa2049159b8bb50d404fdb132

Instruction, Casts

view details

Nick Drozd

commit sha a3877e442e98f1f4bb2809831141fd2d5ba32d59

BB4, where ya at?

view details

Nick Drozd

commit sha f838020ad66e74f4782913d5e8c986a6b1902ec0

Some Show implementations

view details

Nick Drozd

commit sha 91d570574f97730d6f48bfbd5db7ceb086074ff4

Add BWAction This is inelegant, but slightly tidier than the current situation.

view details

Nick Drozd

commit sha d9a9aa4b6608213445d608309751ff83393b3755

Cast Your State to the Fin

view details

Nick Drozd

commit sha 55151963dcd49f8011bebc06916bb59739862c08

Clean up; add temp partwayParse

view details

Nick Drozd

commit sha e4ec8975a889fc02e73788638e0a2bc1efb49036

Add BB3 / bb3; move stuff

view details

Nick Drozd

commit sha 9cef9f58da18c37474bbffc7cdbb935a1f4b066d

Add main, a medium 5-stater

view details

Nick Drozd

commit sha a2a7b637650f7adb8531d84ad98fdcdf1acc45de

Add program counter, misc

view details

Nick Drozd

commit sha 01eb6957dd52bb448b765500538ed19c244b6eac

This thing really seems to work

view details

Nick Drozd

commit sha bee944cc5df733e6b871f1d09ba2acba8ca965ef

Add makefile

view details

Nick Drozd

commit sha 485fac23a141711c5bcc970f92574295838d7d47

BB5 -- cut off after around one hour (791146 steps)

view details

push time in 6 days

push eventnickdrozd/pytur

Nick Drozd

commit sha d562a7112b10aab1d1f9457cd8a727cbfa629db1

Add make idris command

view details

push time in 6 days

create barnchnickdrozd/pytur

branch : merge-2

created branch time in 6 days

PR closed nickdrozd/pytur

Merge Idris simulator (Rado)
+1671 -547

0 comment

41 changed files

nickdrozd

pr closed time in 6 days

PR opened nickdrozd/pytur

Merge Idris simulator (Rado)
+1671 -547

0 comment

41 changed files

pr created time in 6 days

create barnchnickdrozd/pytur

branch : idris-merge

created branch time in 6 days

Pull request review commentPyCQA/pylint

Use node_ancestors to get rid of some while-loops

 def _check_else_on_loop(self, node):      def _check_in_loop(self, node, node_name):         """check that a node is inside a for or while loop"""-        _node = node.parent-        while _node:+        for _node in node.node_ancestors():

My first thought was to make the changes while disturbing the rest of the code as little as possible. But the variables are renamed now.

nickdrozd

comment created time in 6 days

PullRequestReviewEvent

Pull request review commentPyCQA/pylint

Use node_ancestors to get rid of some while-loops

 def get_numversion_from_version(v: str) -> Tuple:                 version.append(int(num))             except ValueError:                 version.append(0)-    while len(version) != 3:+    for _ in range(3 - len(version)):

I tried another way with no loop at all. Compare this with https://github.com/PyCQA/pylint/pull/4860/files#diff-26d7b9f740481d02edafcd71a3f448d5d2f5a7ff9858bfa59622e72cfc87a3ed

nickdrozd

comment created time in 6 days

PullRequestReviewEvent

push eventnickdrozd/pylint

Nick Drozd

commit sha 907792b5a60c071dcb1575c6203d24ff8fb95921

Rename loop variables

view details

Nick Drozd

commit sha 2efefb413172a9d16af1bd41418e2bd51c3f4d25

Don't use a loop at all for version

view details

push time in 6 days